[Bps-public-commit] r10263 - bpsbuilder/BPB/lib/BPB

sunnavy at bestpractical.com sunnavy at bestpractical.com
Tue Jan 8 05:30:56 EST 2008


Author: sunnavy
Date: Tue Jan  8 05:30:54 2008
New Revision: 10263

Modified:
   bpsbuilder/BPB/lib/BPB/Backend.pm

Log:
get __build from scripts dir

Modified: bpsbuilder/BPB/lib/BPB/Backend.pm
==============================================================================
--- bpsbuilder/BPB/lib/BPB/Backend.pm	(original)
+++ bpsbuilder/BPB/lib/BPB/Backend.pm	Tue Jan  8 05:30:54 2008
@@ -76,10 +76,16 @@
 
 $args{perl} ||= 'perl';
 $args{skip} = [ split /,\s*/, $args{skip} || '' ];
-$ENV{DYLD_LIBRARY_PATH} = File::Spec->catfile( $args{'install-base'}, 'lib' )
-    . ':' . $ENV{DYLD_LIBRARY_PATH};
-$ENV{LD_LIBRARY_PATH} = File::Spec->catfile( $args{'install-base'}, 'lib' ) .
-    ':' . $ENV{LD_LIBRARY_PATH};
+
+{
+    no warnings 'uninitialized';
+    $ENV{DYLD_LIBRARY_PATH} =
+      File::Spec->catfile( $args{'install-base'}, 'lib' ) . ':'
+      . $ENV{DYLD_LIBRARY_PATH};
+    $ENV{LD_LIBRARY_PATH} =
+      File::Spec->catfile( $args{'install-base'}, 'lib' ) . ':'
+      . $ENV{LD_LIBRARY_PATH};
+}
 
 open my $fh, '>', 'build.log' or die $!;
 close $fh;
@@ -108,6 +114,12 @@
 
 sub install {
     my $dir = shift;
+
+    copy(
+        File::Spec->catfile( 'scripts', $dir, 'build' ),
+        File::Spec->catfile( 'dists', $dir, '__build' )
+    );
+
     chdir File::Spec->catfile( 'dists', $dir );
 
     my $lib = " -I"
@@ -157,9 +169,8 @@
     }
     chmod 0755, '__build';
     open my $fh, '>>', '../../build.log' or die $!;
-    my $exit = system('./__build');
-    if ( $exit ) {
-        print $fh "build $dir with failure: $!\n";
+    if ( system('./__build') ) {
+        print $fh "build $dir with failure $?: $!\n";
     }
     else {
         print $fh "build $dir with success!\n";



More information about the Bps-public-commit mailing list