]> err.no Git - dpkg/commitdiff
scripts/controllib.pl: Removed as it's no more needed by any script.
authorRaphael Hertzog <hertzog@debian.org>
Tue, 1 Jan 2008 17:16:24 +0000 (18:16 +0100)
committerRaphael Hertzog <hertzog@debian.org>
Tue, 1 Jan 2008 19:38:52 +0000 (20:38 +0100)
debian/dpkg-dev.install
scripts/Makefile.am
scripts/controllib.pl [deleted file]
scripts/po/POTFILES.in

index 47d485b72e54d67e1b681ad5b35a18e6ae99ea6f..2f497272dece5411f78ee38a25bfa18833a95963 100644 (file)
@@ -15,7 +15,6 @@ usr/bin/dpkg-scanpackages
 usr/bin/dpkg-scansources
 usr/bin/dpkg-shlibdeps
 usr/bin/dpkg-source
-usr/lib/dpkg/controllib.pl
 usr/lib/dpkg/parsechangelog
 usr/share/locale/*/LC_MESSAGES/dpkg-dev.mo
 usr/share/man/*/*/822-date.1
index 19863b4866f416a782b9cb3e82e0a0fda26bae9f..b70a576dbf90240df1eaa9be2c2a4a52b96de09d 100644 (file)
@@ -103,10 +103,6 @@ nobase_dist_perllib_DATA = \
        Dpkg/Version.pm \
        Dpkg.pm
 
-dist_pkglib_SCRIPTS = \
-       controllib.pl
-
-
 do_perl_subst = sed -e "s:^\#![:space:]*/usr/bin/perl:\#!$(PERL):" \
                    -e "s:\$$dpkglibdir[[:space:]]*=[[:space:]]*['\"][^'\"]*['\"]:\$$dpkglibdir=\"$(pkglibdir)\":" \
                    -e "s:\$$pkgdatadir[[:space:]]*=[[:space:]]*['\"][^'\"]*['\"]:\$$pkgdatadir=\"$(pkgdatadir)\":" \
diff --git a/scripts/controllib.pl b/scripts/controllib.pl
deleted file mode 100755 (executable)
index 5ed435d..0000000
+++ /dev/null
@@ -1,118 +0,0 @@
-#!/usr/bin/perl
-
-use strict;
-use warnings;
-
-use English;
-use POSIX qw(:errno_h);
-use Dpkg;
-use Dpkg::Gettext;
-use Dpkg::ErrorHandling qw(warning error failure internerr syserr subprocerr);
-use Dpkg::Fields qw(capit sort_field_by_importance);
-
-textdomain("dpkg-dev");
-
-our %fi;            # - map of fields values. keys are of the form "S# key"
-                    #   where S is source (L is changelog, C is control)
-                    #   and # is an index
-our %p2i;           # - map from datafile+packagename to index in controlfile
-                    #   (used if multiple packages can be listed). Key is
-                    #   "S key" where S is the source and key is the packagename
-
-my $parsechangelog = 'dpkg-parsechangelog';
-
-sub parsechangelog {
-    my ($changelogfile, $changelogformat, $since) = @_;
-
-    defined(my $c = open(CDATA, "-|")) || syserr(_g("fork for parse changelog"));
-    if ($c) {
-       binmode(CDATA);
-       parsecdata(\*CDATA, 'L', 0, _g("parsed version of changelog"));
-       close(CDATA);
-       $? && subprocerr(_g("parse changelog"));
-    } else {
-       binmode(STDOUT);
-       my @al = ($parsechangelog);
-        push(@al,"-l$changelogfile");
-        push(@al, "-F$changelogformat") if defined($changelogformat);
-        push(@al, "-v$since") if defined($since);
-        exec(@al) || &syserr("exec parsechangelog $parsechangelog");
-    }
-}
-
-sub readmd5sum {
-    (my $md5sum = shift) or return;
-    $md5sum =~ s/^([0-9a-f]{32})\s*\*?-?\s*\n?$/$1/o
-        || failure(_g("md5sum gave bogus output `%s'"), $md5sum);
-    return $md5sum;
-}
-
-# XXX: Should not be a global!!
-my $whatmsg;
-
-sub parsecdata {
-    my ($cdata, $source, $many);
-    ($cdata, $source, $many, $whatmsg) = @_;
-
-    # many=0: ordinary control data like output from dpkg-parsechangelog
-    # many=1: many paragraphs like in source control file
-    # many=-1: single paragraph of control data optionally signed
-
-    my $index = '';
-    my $cf = '';
-    my $paraborder = 1;
-
-    while (<$cdata>) {
-        s/\s*\n$//;
-       next if (m/^$/ and $paraborder);
-       next if (m/^#/);
-       $paraborder=0;
-        if (m/^(\S+?)\s*:\s*(.*)$/) {
-           $cf = $1;
-           my $v = $2;
-            $cf= &capit($cf);
-            $fi{"$source$index $cf"}= $v;
-            $fi{"o:$source$index $cf"}= $1;
-            if (lc $cf eq 'package') { $p2i{"$source $v"}= $index; }
-        } elsif (m/^\s+\S/) {
-            length($cf) || &syntax(_g("continued value line not in field"));
-            $fi{"$source$index $cf"}.= "\n$_";
-        } elsif (m/^-----BEGIN PGP/ && $many<0) {
-            $many == -2 && syntax(_g("expected blank line before PGP signature"));
-           while (<$cdata>) {
-               last if m/^$/;
-           }
-            $many= -2;
-        } elsif (m/^$/) {
-           $paraborder = 1;
-            if ($many>0) {
-                $index++; $cf='';
-            } elsif ($many == -2) {
-               $_ = <$cdata> while defined($_) && $_ =~ /^\s*$/;
-                length($_) ||
-                    &syntax(_g("expected PGP signature, found EOF after blank line"));
-                s/\n$//;
-                m/^-----BEGIN PGP/ ||
-                    &syntax(sprintf(_g("expected PGP signature, found something else \`%s'"), $_));
-                $many= -3; last;
-            } else {
-               while (<$cdata>) {
-                   /^\s*$/ ||
-                       &syntax(_g("found several \`paragraphs' where only one expected"));
-               }
-            }
-        } else {
-            &syntax(_g("line with unknown format (not field-colon-value)"));
-        }
-    }
-    $many == -2 && &syntax(_g("found start of PGP body but no signature"));
-    if (length($cf)) { $index++; }
-    $index || &syntax(_g("empty file"));
-    return $index;
-}
-
-sub syntax {
-    error(_g("syntax error in %s at line %d: %s"), $whatmsg, $., $_[0]);
-}
-
-1;
index 55554a1cbb7575c4a147ec8ac923afd00873da78..864516ec28518e77c2d18c8c35d11d06c3c67cf5 100644 (file)
@@ -1,7 +1,6 @@
 # This is the list of all source files with translatable strings.
 
 scripts/822-date.pl
-scripts/controllib.pl
 scripts/dpkg-architecture.pl
 scripts/dpkg-buildpackage.pl
 scripts/dpkg-checkbuilddeps.pl