Changeset 34087
- Timestamp:
- Jun 26, 2012, 11:39:02 AM (14 years ago)
- Location:
- trunk/psconfig
- Files:
-
- 6 edited
-
psbuild (modified) (5 diffs)
-
pschecklibs (modified) (3 diffs)
-
pscheckmods (modified) (6 diffs)
-
pscheckperl (modified) (5 diffs)
-
psconfig.csh.in (modified) (2 diffs)
-
tagsets/ipp-3.0.perl (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/psconfig/psbuild
r31466 r34087 9 9 $optimize = 0; 10 10 $profile = 0; 11 $no_as_needed = 0; 12 $debug_build = 0; 11 13 $developer = 0; 12 14 $magic = 0; … … 72 74 if ($ARGV[0] eq "-profile") { 73 75 $profile = 1; 76 shift; next; 77 } 78 if ($ARGV[0] eq "-no-as-needed") { 79 $no_as_needed = 1; 80 shift; next; 81 } 82 if ($ARGV[0] eq "-debug-build") { 83 $debug_build = 1; 74 84 shift; next; 75 85 } … … 262 272 if ($optimize) { $psopts = "$psopts --enable-optimize"; } 263 273 if ($profile) { $psopts = "$psopts --enable-profile --disable-shared --enable-static"; } 274 if ($debug_build) { $psopts = "$psopts --enable-debug-build"; } 275 if ($no_as_needed) { $psopts = "$psopts --enable-no-as-needed"; } 264 276 $psopts .= " --disable-version" if $offline; 265 277 … … 383 395 384 396 sub bootstrap { 385 386 if (@ARGV != 2) { die "USAGE: psbuild -bootstrap (install_dir)\n"; } 397 if (@ARGV != 2) { die "USAGE: psbuild -bootstrap (install_dir | current)\n"; } 387 398 $psconfdir = $ARGV[1]; 399 400 if ($psconfdir eq "current") { 401 $psconfdir = $ENV{'PSCONFDIR'}; 402 if (! $psconfdir) { die "no env variable PSCONFDIR found for psbuild -bootstrap current\n"; } 403 } 388 404 die "Target directory must be absolute, not relative: $psconfdir\n" unless $psconfdir =~ m|^/|; 389 405 … … 479 495 print STDERR " : -optimize : set flags for optimized code\n"; 480 496 print STDERR " : -profile : set flags for profiling\n"; 497 print STDERR " : -debug-build : set flags for debug build (Wall, but not Werror; use to find and fix warnings from Wall)\n"; 498 print STDERR " : -no-as-needed : add --no-as-needed flag to gcc (to disable default --as-needed flags from Ubuntu, etc)\n"; 481 499 print STDERR " : -only (module) : only build the specified module\n"; 482 500 print STDERR " : -start (module) : begin build at specified module\n"; -
trunk/psconfig/pschecklibs
r26273 r34087 142 142 unshift @incpath, $incdir; 143 143 144 # get a list of implicit paths from cpp directly 145 &checkpreprocessor (); 146 147 # get a list of implicit paths from the linker directly 148 &checklinker (); 149 144 150 # add the system paths specified for each architecture 145 151 &checkarch (); 146 152 print "setting architecture to: $arch\n"; 147 153 print "searching for libraries in: @libpath\n"; 154 print "searching for headers in: @incpath\n"; 148 155 print "searching for programs in: @binpath\n"; 149 156 print "\n"; … … 404 411 $path = "$topdir/$subdir"; 405 412 } 406 # print "trying $path\n";407 413 if (! -e $path) { next; } 408 414 $binname = "$path/$name"; … … 441 447 } 442 448 449 sub checklinker { 450 # we are going to supplement the libpath with entries reported by 451 # the linker (this depends on ld --verbose 452 453 my $line, @lines; 454 my $item, @items; 455 456 @lines = `ld --verbose | grep SEARCH_DIR`; 457 foreach $line (@lines) { 458 # we expect items of the form SEARCH_DIR("path"); 459 # or SEARCH_DIR("=path") -- in that case we should prepend sysroo 460 next unless ($line =~ m|SEARCH_DIR|); 461 @items = split (";", $line); 462 foreach $item (@items) { 463 next unless ($item); 464 ($p1) = $item =~ m|SEARCH_DIR\050"=(\S*)"|; 465 ($p2) = $item =~ m|SEARCH_DIR\050"(\S*)"|; 466 next if (!$p1 && !$p2); 467 if (!$p1 && $p2) { 468 push @libpath, $p2; 469 } 470 if ($p1 && $p2) { 471 push @libpath, $p1; 472 } 473 if ($p1 && !$p2) { 474 print "programming error!\n"; 475 exit 4; 476 } 477 } 478 } 479 return 0; 480 } 481 482 sub checkpreprocessor { 483 # we are going to supplement the libpath with entries reported by 484 # the linker (this depends on ld --verbose 485 486 ### #include <...> search starts here: 487 ### /home/eugene/src/psconfig/ipp-dev.linux/include 488 ### . 489 ### /usr/lib/gcc/i686-linux-gnu/4.6/include 490 ### /usr/local/include 491 ### /usr/lib/gcc/i686-linux-gnu/4.6/include-fixed 492 ### /usr/include/i386-linux-gnu 493 ### /usr/include 494 ### End of search list. 495 496 my $line, @lines; 497 my $found_start; 498 499 @lines = `cpp --verbose < /dev/null 2>&1`; 500 $found_start = 0; 501 foreach $line (@lines) { 502 if (!$found_start) { 503 if ($line =~ m|include \<...\> search starts here|) { 504 $found_start = 1; 505 next; 506 } else { 507 next; 508 } 509 } 510 chomp $line; 511 if ($line =~ m|End of search list|) { 512 return 1; 513 } 514 ($cleanline) = $line =~ m|\s*(\S*)|; 515 push @incpath, $cleanline; 516 } 517 return 0; 518 } 519 443 520 sub checkarch { 444 521 # we are going to supplement the global libpath supplied -
trunk/psconfig/pscheckmods
r31162 r34087 1 1 #!/usr/bin/env perl 2 2 3 $DEBUG = 0; 3 4 $VERBOSE = 0; 4 5 if (@ARGV > 2 && $ARGV[0] eq "-v") { … … 10 11 if ($VERBOSE) { print STDERR "checking in @INC\n"; } 11 12 12 # &detailed_require ($ARGV[0]); 13 if ($DEBUG) { &detailed_require ($ARGV[0]);} 13 14 14 15 $x = eval "require $ARGV[0]; 1"; … … 18 19 &detailed_require ($ARGV[0]); 19 20 } 20 if ($VERBOSE) { print " x: $x\n"; }21 if ($VERBOSE) { print "result of require: $x\n"; } 21 22 22 23 $version = eval "\$$ARGV[0]::VERSION"; … … 34 35 $filename =~ s|::|/|g; 35 36 $filename = "$filename.pm"; 36 print " $filename\n";37 print "\ntesting : $filename\n" if $DEBUG; 37 38 if (exists $INC{$filename}) { 38 39 return 1 if $INC{$filename}; 39 die "Compilation failed in require";40 40 } 41 41 my ($realfilename,$result); … … 43 43 foreach $prefix (@INC) { 44 44 $realfilename = "$prefix/$filename"; 45 print " $realfilename\n";45 print "real: $realfilename\n" if $DEBUG; 46 46 if (-f $realfilename) { 47 47 $INC{$filename} = $realfilename; 48 print "calling 'do' on $realfilename\n" if $DEBUG; 48 49 $result = do $realfilename; 50 print "result: $result\n" if $DEBUG; 49 51 last ITER; 50 52 } … … 53 55 } 54 56 if ($@) { 57 print "$@" if $DEBUG; 55 58 $INC{$filename} = undef; 56 59 die $@; 57 60 } elsif (!$result) { 61 print "no result\n" if $DEBUG; 58 62 delete $INC{$filename}; 59 63 die "$filename did not return true value"; 60 64 } else { 65 print "done with detailed_require\n" if $DEBUG; 61 66 return $result; 62 67 } -
trunk/psconfig/pscheckperl
r28191 r34087 5 5 $version = ""; 6 6 $build = 0; 7 $clean = 0; 7 8 my %force; # Names of module to force build 8 9 @tARGV = (); … … 14 15 if ($ARGV[0] eq "-build") { 15 16 $build = 1; 17 shift; next; 18 } 19 if ($ARGV[0] eq "-clean") { 20 $clean = 1; 16 21 shift; next; 17 22 } … … 32 37 if ( @ARGV > 1) { &usage(); } 33 38 39 if ($build && $clean) {die "-build and -clean are incompatible\n";} 40 34 41 if ( @ARGV == 0) { 35 42 @list = <$tagsets/*.perl>; … … 95 102 # if ($modver eq "") { $modver = 0; } 96 103 104 if ($clean) { 105 ($tardir) = $tarball =~ m|(\S*).tar.gz|; 106 $tardir = "../extperl/$tardir"; 107 if (-d $tardir) { 108 print "remove tardir: $tardir\n"; 109 vsystem ("rm -rf $tardir"); 110 } 111 next; 112 } 113 97 114 system ("pscheckmods $module $modver"); 98 115 if (($? == 0) and not defined $force{$module} and not defined $force{'all'}) { … … 127 144 if ($prompts eq "NONE") { $prompts = ""; } 128 145 129 if (-e "Build.PL" and $module ne " Params::Validate" and $module ne "DateTime::TimeZone") {146 if (-e "Build.PL" and $module ne "DateTime::TimeZone") { 130 147 # vsystem("perl Build.PL --install_path lib=$perldir "); 131 148 vsystem("perl Build.PL --install_base $prefix $buildopts"); -
trunk/psconfig/psconfig.csh.in
r31162 r34087 125 125 if ($?PERL5LIB == 0) setenv PERL5LIB 126 126 if ($?MANPATH == 0) setenv MANPATH 127 if ($?LDFLAGS == 0) setenv LDFLAGS 127 128 128 129 # identify system architecture … … 318 319 case linux: 319 320 case linrh: 321 gcc --version | grep 4.6.3 | grep Ubuntu >& /dev/null 322 if ($status == 0) then 323 set xtraflags = "-Wl,--no-as-needed" 324 echo $LDFLAGS | grep -- $xtraflags >& /dev/null 325 if ($status) then 326 setenv LDFLAGS "$LDFLAGS $xtraflags" 327 endif 328 endif 320 329 breaksw; 321 330 322 331 case lin64: 323 332 case linrh64: 333 gcc --version | grep 4.6.3 | grep Ubuntu >& /dev/null 334 if ($status == 0) then 335 set xtraflags = "-Wl,--no-as-needed" 336 echo $LDFLAGS | grep -- $xtraflags >& /dev/null 337 if ($status) then 338 setenv LDFLAGS "$LDFLAGS $xtraflags" 339 endif 340 endif 324 341 set xtralibs = ( $xtralibs "/usr/lib64" "/usr/X11R6/lib64" "/lib64" ) 325 342 breaksw; -
trunk/psconfig/tagsets/ipp-3.0.perl
r31162 r34087 6 6 # a Version of 0 is required if no specific version is desired options responses 7 7 00 Getopt::Long Getopt-Long-2.36.tar.gz 2.3 NONE n 8 00 Module::Build Module-Build-0.2806.tar.gz 0.2806 NONE NONE # special comment here 8 # 00 Module::Build Module-Build-0.40.tar.gz 0.38 NONE NONE # special comment here 9 00 Module::Build Module-Build-0.3601.tar.gz 0.3601 NONE NONE # special comment here 9 10 01 ExtUtils::MakeMaker ExtUtils-MakeMaker-6.54.tar.gz 0 NONE NONE 10 11 02a Attribute::Handlers Attribute-Handlers-0.87.tar.gz 0.79 NONE NONE 11 02 Params::Validate Params-Validate-0.92.tar.gz 0.92 NONE NONE 12 # Params::Validate 0.92 breaks with Perl >= 5.14 (and probably earlier) because 'ref' added RegExp as a type 13 02 Params::Validate Params-Validate-0.96.tar.gz 0.96 NONE NONE 12 14 # 02 Apache::Test Apache-Test-1.29.tar.gz 1.29 NONE NONE 13 15 03a Class::Singleton Class-Singleton-1.4.tar.gz 0 NONE NONE … … 81 83 70 Config::YAML Config-YAML-1.42.tar.gz 0 NONE NONE 82 84 # 72 File::ExtAttr File-ExtAttr-1.07.tar.gz 0 NONE NONE 83 73 DBI DBI-1.601.tar.gz 0 NONE NONE 84 71 DBD::mysql DBD-mysql-4.006.tar.gz 0 NONE NONE 85 # version 1.622 updates sv_undef and related to new namespace (PL_*) (needed as of Perl 5.13.XX) 86 73 DBI DBI-1.622.tar.gz 1.622 NONE NONE 87 # version 4.021 updates sv_undef and related to new namespace (PL_*) (needed as of Perl 5.13.XX) 88 71 DBD::mysql DBD-mysql-4.021.tar.gz 4.021 NONE NONE 89 85 90 # 74 Net::Server::Daemonize Net-Server-0.97.tar.gz 0.05 NONE NONE 86 91 75 File::Path File-Path-2.04.tar.gz 0 NONE NONE
Note:
See TracChangeset
for help on using the changeset viewer.
