Преглед изворни кода

dpkg-gensymbols: Use the new Dpkg module

Guillem Jover пре 19 година
родитељ
комит
2b6c769da7
2 измењених фајлова са 9 додато и 10 уклоњено
  1. 5 0
      ChangeLog
  2. 4 10
      scripts/dpkg-gensymbols.pl

+ 5 - 0
ChangeLog

@@ -1,3 +1,8 @@
+2007-10-09  Guillem Jover  <guillem@debian.org>
+
+	* scripts/dpkg-gensymbols.pl: Use new Dpkg module. Do not declare
+	nor initialize $version, $dpkglibdir and $progname anymore.
+
 2007-10-09  Frank Lichtenheld  <djpig@debian.org>
 
 	* scripts/dpkg-buildpackage.pl: Add -z/-Z to

+ 4 - 10
scripts/dpkg-gensymbols.pl

@@ -3,15 +3,7 @@
 use strict;
 use warnings;
 
-our $version;
-our $dpkglibdir;
-BEGIN {
-    $version="1.14.4"; # This line modified by Makefile
-    $dpkglibdir="."; # This line modified by Makefile
-    push(@INC,$dpkglibdir);
-}
-require 'controllib.pl';
-
+use Dpkg;
 use Dpkg::Shlibs qw(@librarypaths);
 use Dpkg::Shlibs::Objdump;
 use Dpkg::Shlibs::SymbolFile;
@@ -19,7 +11,9 @@ use Dpkg::Gettext;
 
 textdomain("dpkg-dev");
 
-our $progname;
+push(@INC, $dpkglibdir);
+require 'controllib.pl';
+
 our (%f, %fi);
 our %p2i;
 our @librarypaths;