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

dkogan-guest pushed a commit to branch realupstream
in repository libpdl-linearalgebra-perl.

commit 8d59cfbdc4f27e14dfc765cbc442cebc271ddf7f
Author: kmx <k...@cpan.org>
Date:   Mon Jan 5 09:32:05 2015 -0500

    Use PkgConfig for improved library detection
---
 Complex/Makefile.PL | 11 +++++++++--
 Real/Makefile.PL    | 12 ++++++++++--
 Trans/Makefile.PL   | 10 +++++++---
 3 files changed, 26 insertions(+), 7 deletions(-)

diff --git a/Complex/Makefile.PL b/Complex/Makefile.PL
index 05f34c0..8ada085 100755
--- a/Complex/Makefile.PL
+++ b/Complex/Makefile.PL
@@ -4,16 +4,23 @@
 
 use ExtUtils::MakeMaker;
 use PDL::Core::Dev;
+use Config;
 
 @pack = (["complex.pd",Complex, PDL::LinearAlgebra::Complex]);
 
 %hash = pdlpp_stdargs(@::pack);
 # $hash{'OPTIMIZE'}  = '-g'; # If you want to debug, uncomment this.
 #$hash{LIBS}[0] .= $^O =~ /MSWin/ ? '' : '-lacml -lgfortran ';
-$hash{LIBS}[0] .= $^O =~ /MSWin/ ? '' : '-L/usr/lib/atlas -llapack -lblas 
-latlas ';
+#$hash{LIBS}[0] .= $^O =~ /MSWin/ ? '' : '-L/usr/lib/atlas -llapack -lblas 
-latlas ';
 #$hash{'OPTIMIZE'}  = '-O2 -mtune=k8'; # If you want to debug, uncomment this.
 
-$hash{LDLOADLIBS} .= 'oldnames.lib kernel32.lib user32.lib gdi32.lib 
winspool.lib  comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib  
netapi32.lib uuid.lib wsock32.lib mpr.lib winmm.lib  version.lib odbc32.lib 
odbccp32.lib msvcrt.lib  ../lapack/libacml.lib "C:\Program Files\Microsoft 
Visual Studio .NET 2003\Vc7\lib\msvcrt.lib" ' if $^O =~ /MSWin/;
+$hash{LIBS}[0] .= ( eval {require PkgConfig; join ' ', 
PkgConfig->find('lapack')->get_ldflags} ||
+                    eval {require ExtUtils::PkgConfig; 
ExtUtils::PkgConfig->libs('lapack')} ||
+                    `pkg-config lapack blas --libs` ||
+                    '-L/usr/lib/atlas -llapack -lblas -latlas' ) . " 
-lgfortran";
+
+$hash{LDLOADLIBS} .= 'oldnames.lib kernel32.lib user32.lib gdi32.lib 
winspool.lib  comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib  
netapi32.lib uuid.lib wsock32.lib mpr.lib winmm.lib  version.lib odbc32.lib 
odbccp32.lib msvcrt.lib  ../lapack/libacml.lib "C:\Program Files\Microsoft 
Visual Studio .NET 2003\Vc7\lib\msvcrt.lib" ' if $^O =~ /MSWin/ && $Config{cc} 
eq 'cl';
+
 WriteMakefile(
        %hash,
        'VERSION_FROM' => 'complex.pd',
diff --git a/Real/Makefile.PL b/Real/Makefile.PL
index 8b857cd..fdc8354 100755
--- a/Real/Makefile.PL
+++ b/Real/Makefile.PL
@@ -4,16 +4,24 @@
 
 use ExtUtils::MakeMaker;
 use PDL::Core::Dev;
+use Config;
 do('../Config');
 
 @pack = (["real.pd",Real,PDL::LinearAlgebra::Real]);
 %hash = pdlpp_stdargs(@::pack);
+#$hash{LIBS}[0] .= $^O =~ /MSWin/ ? '' : '-lacml -lgfortran ';
+#$hash{LIBS}[0] .= $^O =~ /MSWin/ ? '' : '-L/usr/lib/atlas -llapack -lblas 
-latlas ';
 # $hash{'OPTIMIZE'}  = '-g'; # If you want to debug, uncomment this.
 #$hash{LIBS}[0] .= $^O =~ /MSWin/ ? '' : '-lacml -lgfortran ';
-$hash{LIBS}[0] .= $^O =~ /MSWin/ ? '' : '-L/usr/lib/atlas -llapack -lblas 
-latlas ';
+#$hash{LIBS}[0] .= $^O =~ /MSWin/ ? '' : '-L/usr/lib/atlas -llapack -lblas 
-latlas ';
 #$hash{'OPTIMIZE'}  = '-O2 -mtune=k8'; # If you want to debug, uncomment this.
 
-$hash{LDLOADLIBS} .= 'oldnames.lib kernel32.lib user32.lib gdi32.lib 
winspool.lib  comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib  
netapi32.lib uuid.lib wsock32.lib mpr.lib winmm.lib  version.lib odbc32.lib 
odbccp32.lib msvcrt.lib  ../lapack/libacml.lib "C:\Program Files\Microsoft 
Visual Studio .NET 2003\Vc7\lib\msvcrt.lib" ' if $^O =~ /MSWin/;
+$hash{LIBS}[0] .= ( eval {require PkgConfig; join ' ', 
PkgConfig->find('lapack')->get_ldflags} ||
+                    eval {require ExtUtils::PkgConfig; 
ExtUtils::PkgConfig->libs('lapack')} ||
+                    `pkg-config lapack blas --libs` ||
+                    '-L/usr/lib/atlas -llapack -lblas -latlas' ) . " 
-lgfortran";
+
+$hash{LDLOADLIBS} .= 'oldnames.lib kernel32.lib user32.lib gdi32.lib 
winspool.lib  comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib  
netapi32.lib uuid.lib wsock32.lib mpr.lib winmm.lib  version.lib odbc32.lib 
odbccp32.lib msvcrt.lib  ../lapack/libacml.lib "C:\Program Files\Microsoft 
Visual Studio .NET 2003\Vc7\lib\msvcrt.lib" ' if $^O =~ /MSWin/ && $Config{cc} 
eq 'cl';
 
 WriteMakefile(
        %hash,
diff --git a/Trans/Makefile.PL b/Trans/Makefile.PL
index 6ff9bad..44af078 100644
--- a/Trans/Makefile.PL
+++ b/Trans/Makefile.PL
@@ -5,14 +5,18 @@
 use ExtUtils::MakeMaker;
 
 use PDL::Core::Dev;
+use Config;
 @pack = (["trans.pd",Trans,PDL::LinearAlgebra::Trans]);
 
 %hash = pdlpp_stdargs(@::pack);
-#$hash{LIBS}[0] .= $^O =~ /MSWin/ ? '' : '-lacml -lgfortran ';
-$hash{LIBS}[0] .= $^O =~ /MSWin/ ? '' : '-L/usr/lib/atlas -llapack -lblas 
-latlas ';
 # $hash{'OPTIMIZE'}  = '-O2 -mtune=k8'; # If you want to debug, uncomment this.
 
-$hash{LDLOADLIBS} .= 'oldnames.lib kernel32.lib user32.lib gdi32.lib 
winspool.lib  comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib  
netapi32.lib uuid.lib wsock32.lib mpr.lib winmm.lib  version.lib odbc32.lib 
odbccp32.lib msvcrt.lib  ../lapack/libacml.lib "C:\Program Files\Microsoft 
Visual Studio .NET 2003\Vc7\lib\msvcrt.lib" ' if $^O =~ /MSWin/;
+$hash{LIBS}[0] .= ( eval {require PkgConfig; join ' ', 
PkgConfig->find('lapack')->get_ldflags} ||
+                    eval {require ExtUtils::PkgConfig; 
ExtUtils::PkgConfig->libs('lapack')} ||
+                    `pkg-config lapack blas --libs` ||
+                    '-L/usr/lib/atlas -llapack -lblas -latlas' ) . " 
-lgfortran";
+
+$hash{LDLOADLIBS} .= 'oldnames.lib kernel32.lib user32.lib gdi32.lib 
winspool.lib  comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib  
netapi32.lib uuid.lib wsock32.lib mpr.lib winmm.lib  version.lib odbc32.lib 
odbccp32.lib msvcrt.lib  ../lapack/libacml.lib "C:\Program Files\Microsoft 
Visual Studio .NET 2003\Vc7\lib\msvcrt.lib" ' if $^O =~ /MSWin/ && $Config{cc} 
eq 'cl';
 
 WriteMakefile(
        %hash,

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

_______________________________________________
Pkg-perl-cvs-commits mailing list
Pkg-perl-cvs-commits@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-perl-cvs-commits

Reply via email to