Changeset 916 in ProjectBuilder for devel/pb/lib
- Timestamp:
- Nov 29, 2009, 3:12:56 AM (15 years ago)
- Location:
- devel/pb/lib/ProjectBuilder
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
devel/pb/lib/ProjectBuilder/Changelog.pm
r642 r916 48 48 Function that generates the changelog used in build files, or for announcements (web, mailing-list, ...) 49 49 50 It takes up to 9 parameters: 51 The first parameter is the type of the distribution. 52 The second parameter is the package name generated. 53 The third parameter is the version of the package. 54 The fourth parameter is the tag of the package. 55 The fifth parameter is the suffix of the package. 56 The sixth parameter is now unused. 57 The seventh parameter is the file descriptor on which to write the changelog content. 58 The eighth parameter is a flag in the configuration file indicating whether we want changelog expansion or not. 59 The nineth parameter is the potential changelog file pbcl. 50 It takes 3 parameters: 51 The first parameter is the %pb hash containing packge info 52 The second parameter is the file descriptor on which to write the changelog content. 53 The third parameter is a flag in the configuration file indicating whether we want changelog expansion or not. 60 54 61 55 =cut … … 119 113 if ($dtype eq "deb") { 120 114 if ($pbver !~ /^[0-9]/) { 121 # dpkg-deb doesn't accept non digit versions. Prepending date122 my $ldate = strftime("%Y%m%d", @date);123 $pbver =~ s/^/ $ldate/;124 } 125 print $OUTPUT "$pbrealpkg ($pbver ) unstable; urgency=low\n";126 print $OUTPUT " \n";115 # dpkg-deb doesn't accept non digit versions. 116 # Prepending 0 in order to make updates easy hopefully 117 $pbver =~ s/^/0/; 118 } 119 print $OUTPUT "$pbrealpkg ($pbver-$pbtag) unstable; urgency=low\n"; 120 print $OUTPUT " * Updated to $pbver\n"; 127 121 print $OUTPUT " -- $pbpackager->{$ENV{'PBPROJ'}} $n2date\n\n\n"; 128 122 } … … 154 148 chomp($date); 155 149 $date =~ s/\(([0-9-]+)\)/$1/; 156 #pb_log(2,"**$date**\n";150 pb_log(3,"**Date:$date**\n"); 157 151 $ndate = UnixDate($date,"%a", "%b", "%d", "%Y"); 158 152 $n2date = UnixDate($date,"%a, %d %b %Y %H:%M:%S %z"); 159 #pb_log(2,"**$ndate**\n"; 153 pb_log(3,"**nDate:$ndate**\n"); 154 155 pb_log(3,"**Ver:$ver**\n"); 156 if ($ver !~ /-/) { 157 if ($first eq 1) { 158 $ver2 = "$ver-$pbtag"; 159 $first = 0; 160 } else { 161 $ver2 = "$ver-1"; 162 } 163 } else { 164 $ver2 = $ver; 165 } 166 pb_log(3,"**Ver2:$ver2**\n"); 160 167 161 168 if (($dtype eq "rpm") || ($dtype eq "fc")) { 162 if ($ver !~ /-/) {163 if ($first eq 1) {164 $ver2 = "$ver-$pbtag";165 $first=0;166 } else {167 $ver2 = "$ver-1";168 }169 } else {170 $ver2 = "$ver";171 }172 169 print $OUTPUT "* $ndate $pbpackager->{$ENV{'PBPROJ'}} $ver2\n"; 173 170 print $OUTPUT "- Updated to $ver\n"; 174 171 } 175 172 if ($dtype eq "deb") { 176 if ($ver !~ /^[0-9]/) {177 # dpkg-deb doesn't accept non digit versions. Prepending date178 my $ldate = strftime("%Y%m%d", @date);179 $ver =~ s/^/$ldate/;180 } 181 print $OUTPUT "$pbrealpkg ($ver ) unstable; urgency=low\n";173 if ($ver2 !~ /^[0-9]/) { 174 # dpkg-deb doesn't accept non digit versions. 175 # Prepending 0 in order to make updates easy hopefully 176 $ver2 =~ s/^/0/; 177 } 178 print $OUTPUT "$pbrealpkg ($ver2) unstable; urgency=low\n"; 182 179 print $OUTPUT "\n"; 183 180 } -
devel/pb/lib/ProjectBuilder/Env.pm
r904 r916 533 533 filter PBDATE = \$pb->{'date'} 534 534 535 # PBLOG is replaced by the changelog if value is yes536 #filter PBLOG = yes537 538 535 # PBPATCHSRC is replaced by the patches names if value is yes 539 536 #filter PBPATCHSRC = yes … … 563 560 #filter PBDESC = "Bla-Bla" 564 561 562 # PBSUMMARY contains a short single line description of the package 563 #filter PBSUMMARY = "Bla" 564 565 565 # PBURL contains the URL of the Web site of the project 566 566 #filter PBURL = http://www.$ENV{'PBPROJ'}.org 567 568 # PBLOG is replaced by the changelog if value is yes 569 # and should be last as when used we need the %pb hash filled 570 #filter PBLOG = yes 571 567 572 EOF 568 573 close(CONF); … … 656 661 # PBREC is replaced by the list of recommandations 657 662 #filter PBREC = 663 664 EOF 665 close(CONF); 666 open(CONF,"> $ENV{'PBROOTDIR'}/pbfilter/debian-4.0.pbf") || die "Unable to create $ENV{'PBROOTDIR'}/pbfilter/debian-4.0.pbf"; 667 print CONF << "EOF"; 668 # 669 # \$Id\$ 670 # 671 # Filter for debian build 672 # 673 # PBDEBSTD is replaced by the Debian standard version 674 filter PBDEBSTD = 3.6.1 675 676 # PBDEBCOMP is replaced by the Debian Compatibility value 677 filter PBDEBCOMP = 5 678 679 EOF 680 close(CONF); 681 open(CONF,"> $ENV{'PBROOTDIR'}/pbfilter/debian-5.0.pbf") || die "Unable to create $ENV{'PBROOTDIR'}/pbfilter/debian-5.0.pbf"; 682 print CONF << "EOF"; 683 # 684 # \$Id\$ 685 # 686 # Filter for debian build 687 # 688 # PBDEBSTD is replaced by the Debian standard version 689 filter PBDEBSTD = 3.8.0 690 691 # PBDEBCOMP is replaced by the Debian Compatibility value 692 filter PBDEBCOMP = 7 658 693 659 694 EOF … … 688 723 print CONF << "EOF"; 689 724 Source: PBPKG 725 # http://www.debian.org/doc/debian-policy/ch-archive.html#s-subsections 690 726 Section: PBGRP 691 727 Priority: optional 692 728 Maintainer: PBPACKAGER 693 729 Build-Depends: debhelper (>= 4.2.20), PBDEP 694 Standards-Version: 3.6.1 730 Standards-Version: PBDEBSTD 731 Vcs-Svn: svn://svn.PBPROJ.org/svn/PBVER/PBPKG 732 Vcs-Browser: http://trac.PBPROJ.org/browser/PBVER/PBPKG 733 Homepage: PBURL 695 734 696 735 Package: PBPKG 697 736 Architecture: amd64 i386 ia64 737 # http://www.debian.org/doc/debian-policy/ch-archive.html#s-subsections 698 738 Section: PBGRP 699 739 Priority: optional … … 701 741 Recommends: PBREC 702 742 Suggests: PBSUG 703 Description: 743 Description: PBSUMMARY 704 744 PBDESC 705 745 . 706 Homepage: PBURL707 746 708 747 EOF … … 746 785 open(CONF,"> $ENV{'PBROOTDIR'}/$pp/deb/compat") || die "Unable to create $ENV{'PBROOTDIR'}/$pp/deb/compat"; 747 786 print CONF << "EOF"; 748 4 787 DBDEBCOMP 749 788 EOF 750 789 close(CONF); … … 908 947 #%define srcname PBPKG 909 948 910 Summary: bla-bla949 Summary: PBSUMMARY 911 950 Summary(fr): french bla-bla 912 951 -
devel/pb/lib/ProjectBuilder/Filter.pm
r585 r916 156 156 eval { $tmp =~ s/(\$\w+-\>\{\'\w+\'\})/$1/eeg }; 157 157 eval { $tmp =~ s/(\$\w+)/$1/eeg }; 158 if (($s =~ /^PBDESC$/) && ($line =~ /^ PBDESC/)) { 159 # if on debian, we need to preserve the space before each desc line 160 pb_log(3,"*** DEBIAN CASE ADDING SPACE ***\n"); 161 $tmp =~ s/\$\//\$\/ /g; 162 pb_log(3,"*** tmp:$tmp ***\n"); 163 } 158 164 eval { $tmp =~ s/(\$\/)/$1/eeg }; 159 # special case for ChangeLog only for pb160 165 } elsif (($s =~ /^PBLOG$/) && ($line =~ /^PBLOG$/)) { 166 # special case for ChangeLog only for pb 161 167 pb_log(3,"DEBUG filtering PBLOG\n"); 162 168 pb_changelog($pb, \*DEST, $tmp);
Note:
See TracChangeset
for help on using the changeset viewer.