Update of /cvsroot/fink/fink/perlmod/Fink
In directory fdv4jf1.ch3.sourceforge.com:/tmp/cvs-serv11041

Modified Files:
        ChangeLog PkgVersion.pm 
Log Message:
use architecture-dependent path-prefix on <redacted>


Index: PkgVersion.pm
===================================================================
RCS file: /cvsroot/fink/fink/perlmod/Fink/PkgVersion.pm,v
retrieving revision 1.619
retrieving revision 1.620
diff -u -d -r1.619 -r1.620
--- PkgVersion.pm       2 Apr 2009 21:55:05 -0000       1.619
+++ PkgVersion.pm       5 Apr 2009 13:40:40 -0000       1.620
@@ -4717,7 +4717,7 @@
 =cut
 
 sub ensure_gpp106_prefix {
-       my $vers = shift;
+       my $arch = shift;
        
        my $dir = "$basepath/var/lib/fink/path-prefix-10.6";
        unless (-d $dir) {
@@ -4729,7 +4729,7 @@
                open GPP, ">$gpp" or die "Path-prefix file $gpp cannot be 
created!\n";
                print GPP <<EOF;
 #!/bin/sh
-exec /usr/bin/\${0##*/}  "-arch" "i386" "\$@"
+exec /usr/bin/\${0##*/}  "-arch" "$arch" "\$@"
 EOF
                close GPP;
                chmod 0755, $gpp or die "Path-prefix file $gpp cannot be made 
executable!\n";
@@ -4964,18 +4964,19 @@
        # Enforce g++-3.3 or g++-4.0 even for uncooperative packages, by making 
        # it the first g++ in the path
        unless ($self->has_param('NoSetPATH')) {
-               my $vers;
-               if (($config->param("Distribution") lt "10.4") or 
($config->param("Distribution") eq "10.4-transitional")) {
-                       $vers = '3.3';
+               my $pathprefix;
+               if  ($config->param("Distribution") lt "10.6") {
+                       my $vers;
+                       if (($config->param("Distribution") lt "10.4") or 
($config->param("Distribution") eq "10.4-transitional")) {
+                               $vers = '3.3';
+                       } else {
+                               $vers = '4.0';
+                       }
+                       $pathprefix = ensure_gpp_prefix($vers);
                } else {
-                       $vers = '4.0';
+                       $pathprefix = 
ensure_gpp106_prefix($config->param("Architecture"));
                }
-               my $pathprefix = ensure_gpp_prefix($vers);
                $script_env{'PATH'} = "$pathprefix:" . $script_env{'PATH'};
-               if (($config->param("Architecture") eq "i386" ) and 
($config->param("Distribution") gt "10.5")) {
-                       my $pathprefix = ensure_gpp106_prefix($vers);
-                       $script_env{'PATH'} = "$pathprefix:" . 
$script_env{'PATH'};
-               }
        }
        
        # special things for Type:java

Index: ChangeLog
===================================================================
RCS file: /cvsroot/fink/fink/perlmod/Fink/ChangeLog,v
retrieving revision 1.1588
retrieving revision 1.1589
diff -u -d -r1.1588 -r1.1589
--- ChangeLog   4 Apr 2009 15:50:27 -0000       1.1588
+++ ChangeLog   5 Apr 2009 13:40:40 -0000       1.1589
@@ -1,3 +1,7 @@
+2009-04-05  Dave Morrison  <d...@finkproject.org>
+
+       * PkgVersion.pm: use architecture-dependent path-prefix on <redacted>
+
 2009-04-04  Dave Morrison  <d...@finkproject.org>
 
        * Validation.pm: Allow "new-style" GPL license fields which follow 


------------------------------------------------------------------------------
_______________________________________________
Fink-commits mailing list
Fink-commits@lists.sourceforge.net
http://news.gmane.org/gmane.os.apple.fink.cvs

Reply via email to