Procházet zdrojové kódy

scripts: Allow specifying the same build type option multiple times

For backwards compatibility allow the same exact option, as it seems
such invocations are found in the wild in scripts and similar.

Closes: #757795
Guillem Jover před 12 roky
rodič
revize
ee66f6753c
3 změnil soubory, kde provedl 5 přidání a 2 odebrání
  1. 3 0
      debian/changelog
  2. 1 1
      scripts/dpkg-buildpackage.pl
  3. 1 1
      scripts/dpkg-genchanges.pl

+ 3 - 0
debian/changelog

@@ -18,6 +18,9 @@ dpkg (1.17.12) UNRELEASED; urgency=low
     Thanks to Jan Blunck <jblunck@infradead.org>..
   * Use perl's length instead of defined when checking some environment
     variables, if we require them to have content.
+  * Allow specifying the same build type option multiple times in
+    dpkg-buildpackage and dpkg-genchanges. There seems to be scripts with
+    such invocations in the wild. Closes: #757795
 
   [ Updated programs translations ]
   * German (Sven Joachim).

+ 1 - 1
scripts/dpkg-buildpackage.pl

@@ -196,7 +196,7 @@ sub set_build_type
     my ($build_type, $build_option) = @_;
 
     usageerr(_g('cannot combine %s and %s'), build_opt(), $build_option)
-        if not build_is_default;
+        if not build_is_default and $include != $build_type;
     $include = $build_type;
 }
 

+ 1 - 1
scripts/dpkg-genchanges.pl

@@ -114,7 +114,7 @@ sub set_build_type
     my ($build_type, $build_option) = @_;
 
     usageerr(_g('cannot combine %s and %s'), build_opt(), $build_option)
-        if not build_is_default;
+        if not build_is_default and $include != $build_type;
     $include = $build_type;
 }