Changeset 188
- Timestamp:
- 07/11/15 22:31:45 (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/debbuild
r187 r188 695 695 if (/^\%build/) { 696 696 $stage = 'build'; 697 $buildscript .= "cd $tarballdir\n" if $pkgdata{main}{hassetup};697 $buildscript .= "cd '$tarballdir'\n" if $pkgdata{main}{hassetup}; 698 698 next LINE; 699 699 } # %build … … 701 701 if (/^\%install/) { 702 702 $stage = 'install'; 703 $installscript .= "cd $tarballdir\n" if $pkgdata{main}{hassetup};703 $installscript .= "cd '$tarballdir'\n" if $pkgdata{main}{hassetup}; 704 704 next LINE; 705 705 } # %install … … 707 707 if (/^\%clean/) { 708 708 $stage = 'clean'; 709 $cleanscript .= "cd $tarballdir\n" if $pkgdata{main}{hassetup};709 $cleanscript .= "cd '$tarballdir'\n" if $pkgdata{main}{hassetup}; 710 710 next LINE; 711 711 } # %clean … … 787 787 my $altsource = 0; 788 788 789 # yes, really. It's not clear how this cascades down to %build or %install, but evidence suggests ? 790 my $thistarballdir = $tarballdir; 791 789 792 my @sbits = split /\s+/; 790 793 shift @sbits; 791 794 while (my $sopt = shift @sbits) { 792 795 if ($sopt eq '-n') { 793 $t arballdir = shift @sbits;796 $thistarballdir = shift @sbits; 794 797 } elsif ($sopt eq '-a') { 795 798 # shift, next opt must be numeric (which sourcenn:) … … 830 833 $prepscript .= "cd '$topdir/BUILD'\n"; 831 834 $tarballdir = expandmacros($tarballdir,'gp'); 832 $prepscript .= "rm -rf '$t arballdir'\n" if $deldir;833 $prepscript .= "/bin/mkdir -p $t arballdir\n" if $changedir;835 $prepscript .= "rm -rf '$thistarballdir'\n" if $deldir; 836 $prepscript .= "/bin/mkdir -p $thistarballdir\n" if $changedir; 834 837 835 838 if ($deftarball) { 839 $prepscript .= "cd '$thistarballdir'\n" if $changedir; 836 840 $prepscript .= 837 841 ( $pkgdata{main}{source} =~ /\.tar\.gz$/ ? "/bin/gzip" : "" ). … … 845 849 if ($altsource) { 846 850 if ($altsource == 1) { # -a 847 $prepscript .= "cd '$t arballdir'\n";851 $prepscript .= "cd '$thistarballdir'\n"; 848 852 $prepscript .= 849 853 ( $pkgdata{sources}{$snum} =~ /\.tar\.gz$/ ? "/bin/gzip" : "" ). … … 863 867 ( $quietunpack ? '' : 'vv' )."f -\n". 864 868 qq(STATUS=\$?\nif [ \$STATUS -ne 0 ]; then\n exit \$STATUS\nfi\n); 865 $prepscript .= "cd '$t arballdir'\n";869 $prepscript .= "cd '$thistarballdir'\n"; 866 870 } # $altsource == 2 867 } else {868 $prepscript .= "cd '$tarballdir'\n" unless $changedir;869 871 } 870 872 … … 2105 2107 debbuild. However, rpmbuild doesn't create these directories either. 2106 2108 2109 debbuild's %setup -q is arguably less buggy than rpmbuild's implementation; with rpmbuild 2110 it must appear before -a or -b at least to be effective. debbuild does not care. 2111 2112 %setup -c, -a, and -b should arguably throw errors if specified together; otherwise the 2113 results are almost certainly not what you want to happen. 2114 2107 2115 =head1 SEE ALSO 2108 2116
Note:
See TracChangeset
for help on using the changeset viewer.