[libinline-java-perl] 141/398: *** empty log message ***
Jonas Smedegaard
dr at jones.dk
Thu Feb 26 11:42:57 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 60566df7afab9227b9ad3cc5ef537104085bd354
Author: Patrick LeBoutillier <patl at cpan.org>
Date: Mon Jan 14 20:07:16 2002 +0000
*** empty log message ***
---
Java.pm | 1 -
Java/Makefile.PL | 34 ++++++++++++++++++++++++++++++++--
Java/Portable.pm | 4 +++-
Makefile.PL | 2 +-
4 files changed, 36 insertions(+), 5 deletions(-)
diff --git a/Java.pm b/Java.pm
index 2d05a17..fe7a4b0 100644
--- a/Java.pm
+++ b/Java.pm
@@ -23,7 +23,6 @@ if (! defined($Inline::Java::DEBUG)){
require Inline ;
use Carp ;
use Config ;
-use FindBin ;
use File::Copy ;
use Cwd ;
use Data::Dumper ;
diff --git a/Java/Makefile.PL b/Java/Makefile.PL
index b58aafb..8e74944 100644
--- a/Java/Makefile.PL
+++ b/Java/Makefile.PL
@@ -83,13 +83,17 @@ if (($build_jni || AskYN("Do you wish to build the JNI extension?"))){
if (! $done){
# We have all the required files selected.
+ CleanSoDirs() ;
+
print "Building with:\n" ;
foreach my $f (@files){
print File::Spec->catfile($files->{$f}->{selected}, $f) . "\n" ;
}
print "\n" ;
- $done = WriteBSFile() ;
+ $done = 0 ;
+ # BS file used to be written here
+
if (! $done){
WriteMakefile(
NAME => 'Inline::Java::JNI',
@@ -102,6 +106,14 @@ if (($build_jni || AskYN("Do you wish to build the JNI extension?"))){
"\nNote: In order for Inline::Java to use the JNI extension, you\n" .
"will need to use the JNI configuration option or set the\n" .
"PERL_INLINE_JAVA_JNI environment variable to a true value.\n" .
+ "You will also need to add the following directories to your\n" .
+ Inline::Java::Portable::portable('SO_LIB_PATH_VAR') . " environment variable:\n" ;
+
+ foreach my $d (keys %so_dirs){
+ print " $d\n" ;
+ }
+
+ print
"See README.JNI for more information.\n" ;
print "\n" ;
@@ -128,7 +140,6 @@ sub search {
my $ext = Inline::Java::Portable::portable('SO_EXT') ;
if ($File::Find::dir =~ /jre/){
if ($file =~ /\.$ext$/){
- print $File::Find::dir . "\n" ;
$so_dirs{$File::Find::dir} = 1 ;
}
}
@@ -145,6 +156,25 @@ sub search {
}
+sub CleanSoDirs {
+ foreach my $d (keys %so_dirs){
+ if (-e File::Spec->catfile($d, $jvm_so)){
+ delete $so_dirs{$d} ;
+ }
+ elsif ($d =~ /plugin/){
+ delete $so_dirs{$d} ;
+ }
+ elsif ($d =~ /_threads/){
+ if ($d !~ /native_threads/){
+ delete $so_dirs{$d} ;
+ }
+ }
+ }
+ $so_dirs{$files->{$jvm_lib}->{selected}} = 1 ;
+}
+
+
+
sub WriteBSFile {
if (! open(BS, '>JNI_BS')){
return 1 ;
diff --git a/Java/Portable.pm b/Java/Portable.pm
index c23b098..5b6a2b3 100644
--- a/Java/Portable.pm
+++ b/Java/Portable.pm
@@ -24,7 +24,7 @@ my $COMMAND_COM =
(defined($ENV{COMSPEC}))&&
($ENV{COMSPEC} =~ /(command|4dos)\.com/i)
)||
- (`ver` =~ /win(dows )?(9[58]|m[ei])/i)
+ (`ver` =~ /win(dows )?((9[58])|(m[ei]))/i)
)
) || 0 ;
@@ -45,6 +45,7 @@ sub portable {
GOT_FORK => $Config{d_fork},
ENV_VAR_PATH_SEP => $Config{path_sep},
SO_EXT => $Config{dlext},
+ SO_LIB_PATH_VAR => 'LD_LIBRARY_PATH',
ENV_VAR_PATH_SEP_CP => ':',
IO_REDIR => '2>&1',
COMMAND_COM => 0,
@@ -59,6 +60,7 @@ sub portable {
# 2>&1 doesn't work under command.com
IO_REDIR => ($COMMAND_COM ? '' : undef),
COMMAND_COM => $COMMAND_COM,
+ SO_LIB_PATH_VAR => 'PATH',
JVM_LIB => 'jvm.lib',
JVM_SO => 'jvm.dll',
},
diff --git a/Makefile.PL b/Makefile.PL
index 858333d..5323206 100644
--- a/Makefile.PL
+++ b/Makefile.PL
@@ -21,7 +21,7 @@ WriteMakefile(
if (Inline::Java::Portable::portable('COMMAND_COM')){
- print "\nFixing Makefile for Win9x...\n" ;
+ print "\nFixing Makefile for Win95/98/Me...\n" ;
open(MAKEFILE, "<Makefile") or die "Can't open Makefile for reading" ;
my @lines = <MAKEFILE> ;
close(MAKEFILE) ;
--
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