[libinline-java-perl] 192/398: Fixed some bugs. Replaced File::Spec stuff that wasn't there in 5.005_03

Jonas Smedegaard dr at jones.dk
Thu Feb 26 11:43:02 UTC 2015


This is an automated email from the git hooks/post-receive script.

js pushed a commit to tag 0.55
in repository libinline-java-perl.

commit fc31dbfef86d3d468f9ab0435846a7ea9878d216
Author: patrick_leb <>
Date:   Wed Mar 13 17:07:55 2002 +0000

    Fixed some bugs.
    Replaced File::Spec stuff that wasn't there in 5.005_03
---
 Java.pm | 16 +++++++++-------
 1 file changed, 9 insertions(+), 7 deletions(-)

diff --git a/Java.pm b/Java.pm
index aed7abb..b660d38 100644
--- a/Java.pm
+++ b/Java.pm
@@ -7,7 +7,7 @@ package Inline::Java ;
 
 use strict ;
 
-$Inline::Java::VERSION = '0.31' ;
+$Inline::Java::VERSION = '0.32' ;
 
 
 # DEBUG is set via the DEBUG config
@@ -28,6 +28,7 @@ use Cwd ;
 use Data::Dumper ;
 
 use IO::Socket ;
+use File::Spec ;
 
 use Inline::Java::Portable ;
 use Inline::Java::Class ;
@@ -356,7 +357,7 @@ sub build {
 	}
 
 	my $code = $o->get_api('code') ;
-	my $study_only = ($code =~ /(STUDY|SERVER)/) ;
+	my $study_only = ($code =~ /^(STUDY|SERVER)$/) ;
 
 	$o->write_java($study_only, $code) ;
 	$o->compile($study_only) ;
@@ -525,8 +526,7 @@ sub copy_classes {
 	my $src_dir = $build_dir ;
 	my $dest_dir = $install ;
 
-	my @flist = glob("*.class") ;
-
+	my @flist = Inline::Java::Portable::find_classes_in_dir(".") ;
 	if (portable('COMMAND_COM')){
 		if (! scalar(@flist)){
 			croak "No files to copy. Previous command failed under command.com?" ;
@@ -712,10 +712,10 @@ sub report {
 		$use_cache = 1 ;
 
 		# We need to take the classes that are in the directory...
-		my @cl = glob(File::Spec->catfile($install, "*.class")) ;
+		my @cl = Inline::Java::Portable::find_classes_in_dir($install) ;
 		foreach my $class (@cl){
-			if ($class =~ s/\.class$//){
-				my ($v, $d, $f) = File::Spec->splitpath($class) ;
+			if ($class =~ s/([\w\$]+)\.class$/$1/){
+				my $f = $1 ;
 				if ($f !~ /^InlineJava(Server|Perl)/){
 					push @{$classes}, $f ;
 				}
@@ -914,6 +914,8 @@ tie \$$class$colon:$field, "Inline::Java::Object::StaticMember",
 CODE
 					# We have at least one static version of this field,
 					# that's enough.
+					# Don't forget to reset the 'each' static pointer
+					keys %{$types} ;
 					last ;
 				}
 			}

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-perl/packages/libinline-java-perl.git



More information about the Pkg-perl-cvs-commits mailing list