The following commit has been merged in the master branch:
commit bb9af2d083538d4ffa2033b1e3380ec9d924d32b
Author: Raphaël Hertzog <[email protected]>
Date:   Sat Oct 24 18:04:47 2009 +0200

    Drop compatibility with old changelog parsers (as planned)

diff --git a/doc/README.feature-removal-schedule 
b/doc/README.feature-removal-schedule
index 225ec2f..afd5735 100644
--- a/doc/README.feature-removal-schedule
+++ b/doc/README.feature-removal-schedule
@@ -25,18 +25,6 @@ Warning: program
 Why:
  This option has been superseded by -tudeb.
 
-What: support of custom changelog parsers understanding only -v
-Status: obsolete
-When: 1.15.x
-Warning: none
-Why:
- The debian changelog parser has been enhanced. It supports new options
- that enable more fine-grained retrieval of information. Those new options
- will be used by scripts (like dpkg-genchanges).
- .
- Custom changelog parsers must be updated to support the new API (see
- dpkg-parsechangelog(1) and README.api).
-
 What: support of PGP
 Status: deprecated
 When: 1.15.x
@@ -99,3 +87,15 @@ When: 1.15.1
 Why:
  Should switch to use 'date -R'.
 
+What: support of custom changelog parsers understanding only -v
+Status: removed
+Since: 1.15.5
+Why:
+ The debian changelog parser has been enhanced. It supports new options
+ that enable more fine-grained retrieval of information. Those new options
+ will be used by scripts (like dpkg-genchanges).
+ .
+ Custom changelog parsers must be updated to support the new API (see
+ dpkg-parsechangelog(1) and README.api).
+
+
diff --git a/scripts/Dpkg/Changelog/Parse.pm b/scripts/Dpkg/Changelog/Parse.pm
index 91a54c1..35ca2c7 100644
--- a/scripts/Dpkg/Changelog/Parse.pm
+++ b/scripts/Dpkg/Changelog/Parse.pm
@@ -93,13 +93,6 @@ sub changelog_parse {
        delete $options{"changelogformat"};
        $force = 1;
     }
-    # XXX: For compatibility with old parsers, don't use --since but -v
-    # This can be removed later (in lenny+1 for example)
-    if (exists $options{"since"}) {
-       my $since = $options{"since"};
-       $options{"-v$since"} = undef;
-       delete $options{"since"};
-    }
 
     # Extract the format from the changelog file if possible
     unless($force or ($changelogfile eq "-")) {
diff --git a/scripts/dpkg-genchanges.pl b/scripts/dpkg-genchanges.pl
index f5e44b4..1ec0a56 100755
--- a/scripts/dpkg-genchanges.pl
+++ b/scripts/dpkg-genchanges.pl
@@ -190,11 +190,7 @@ my $changelog = changelog_parse(%options);
 delete $options{"since"};
 $options{"count"} = 1;
 $options{"offset"} = 1;
-my ($prev_changelog, $bad_parser);
-eval { # Do not fail if parser failed due to unsupported options
-    $prev_changelog = changelog_parse(%options);
-};
-$bad_parser = 1 if ($@);
+my $prev_changelog = changelog_parse(%options);
 # Other initializations
 my $control = Dpkg::Control::Info->new($controlfile);
 my $fields = Dpkg::Control->new(type => CTRL_FILE_CHANGES);
@@ -430,14 +426,8 @@ if (!is_binaryonly) {
        my $prev = Dpkg::Version->new($prev_changelog->{"Version"});
        $include_tarball = ($cur->version() ne $prev->version()) ? 1 : 0;
     } else {
-       if ($bad_parser) {
-           # The parser doesn't support extracting a previous version
-           # Fallback to version check
-           $include_tarball = ($sversion =~ /-(0|1|0\.1)$/) ? 1 : 0;
-       } else {
-           # No previous entry means first upload, tarball required
-           $include_tarball = 1;
-       }
+       # No previous entry means first upload, tarball required
+       $include_tarball = 1;
     }
 
     if ((($sourcestyle =~ m/i/ && not($include_tarball)) ||

-- 
dpkg's main repository


-- 
To UNSUBSCRIBE, email to [email protected]
with a subject of "unsubscribe". Trouble? Contact [email protected]

Reply via email to