[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[debian-devel:10336] lintian error ?



Hi.

I found on Debian Weekly News that debhelper is updated, and try to remake 
my package with debhelper 2.0.42 with some required change.

The package looks fine for me, but when I check it with lintian, 
the lintian said:

  tar: control: Not found in archive
  tar: Error exit delayed from previous errors
  internal error: broken input pipe for unpacking xxxxx.deb: 

I tracked down and found that dpkg --build generates control.tar.gz in *.deb
like:

  drwxr-xr-x root/root         0 1999-09-09 15:09:48 ./
  -rwxr-xr-x root/root       249 1999-09-09 15:09:40 ./postinst
  -rwxr-xr-x root/root       190 1999-09-09 15:09:40 ./prerm
  -rw-r--r-- root/root      1653 1999-09-09 15:09:48 ./md5sums
  -rw-r--r-- root/root       580 1999-09-09 15:09:48 ./control

while previous package have the control.tar.gz like

  drwxr-xr-x root/root         0 1999-06-19 06:45:28 ./
  -rw-r--r-- root/root      1521 1999-06-19 06:45:28 md5sums
  -rw-r--r-- root/root       580 1999-06-19 06:45:27 control

This caused error in /usr/share/lintian/lib/util.pl at

  sub get_deb_info
  {       my ($file) = @_;

      # `dpkg-deb -f $file' is very slow. Instead, we use ar and tar.
      pipeline_open(CONTROL,
                    (sub { exec 'ar', 'p', $file, 'control.tar.gz' }),
                    (sub { exec 'tar', 'xfzO', '-', 'control' }))
          or fail("cannot fork to unpack $file: $!\n");
      my @data = parse_dpkg_control();
      close(CONTROL) or fail("broken input pipe for unpacking $file: $!");
      return $data[0];
 }

I change these to use "dpkg -f", but with this change many bogus
warnings are shown like:

  E: extipl: unknown-control-file ./postinst
  E: extipl: unknown-control-file ./prerm
  E: extipl: unknown-control-file ./md5sums
  E: extipl: unknown-control-file ./control
  E: extipl: no-copyright-file

# but the deb DOES have copyright file,,,

I check debian/rules using "dpkg --build", and try to use 
"dpkg --build" manually, but the results are the same.

I am using dpkg 1.4.1.6, and checked it's code, and found
that  dpkg-deb/build.c has following:

  if (!(c1= m_fork())) {
    m_dup2(p1[1],1); close(p1[0]); close(p1[1]);
    if (chdir(directory)) ohshite(_("failed to chdir to `%.255s'"),directory);
    if (chdir(BUILDCONTROLDIR)) ohshite(_("failed to chdir to .../DEBIAN"));
    execlp(TAR,"tar","-cf","-",".",(char*)0); ohshite(_("failed to exec tar -cf"
  ));

Does this "tar -cf - ." generate "./control" into control.tar.gz ?
If so, then does lintian have to be modified so that it can handle 
this situation.

Ah, I find the "tar" package is upgraded

   tar (1.13.11-1) unstable; urgency=low

     * new upstream source from alpha.gnu.org recommended by uptream maintainer
       Paul Eggert.
     * move to FHS compliance with new debhelper
  
    -- Bdale Garbee <bdale@xxxxxxx>  Mon,  6 Sep 1999 16:49:51 -0600

And slink's tar (Version: 1.12-7) behaves like:

  [slink] # tar -cf - . |tar -tvf -
   drwxrwxr-x sano/sano         0 1999-07-28 17:13 ./
   -rw-r--r-- sano/sano    607232 1999-07-28 17:13 file_a
   -rw-r--r-- sano/sano    607232 1999-07-28 17:13 file_b

but current potato's tar behaves like:

  [yadon] $ tar -cf - .|tar -tvf - 
   drwxr-xr-x root/root         0 1999-09-09 15:09:48 ./
   -rwxr-xr-x root/root       249 1999-09-09 15:09:40 ./postinst
   -rwxr-xr-x root/root       190 1999-09-09 15:09:40 ./prerm
   -rw-r--r-- root/root      1653 1999-09-09 15:09:48 ./md5sums
   -rw-r--r-- root/root       580 1999-09-09 15:09:48 ./control

So this change caused by tar's change.

and maybe lintian should be modified to match this change.

Anyone can help ? Thanks.

-- 
  Taketoshi Sano: <sano@debian.org>,<sano@debian.or.jp>,<kgh12351@xxxxxxxxxxx>