Debian Bug report logs - #216135
apt-build: Unable to find a source package

version graph

Package: apt-build; Maintainer for apt-build is Debian QA Group <packages@qa.debian.org>; Source for apt-build is src:apt-build (PTS, buildd, popcon).

Reported by: Ruben Porras <nahoo82@telefonica.net>

Date: Thu, 16 Oct 2003 19:33:19 UTC

Severity: important

Found in versions 0.9, 0.9.1, 0.9.16

Done: Julien Danjou <acid@debian.org>

Bug is archived. No further changes may be made.

Toggle useless messages

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to debian-bugs-dist@lists.debian.org, Julien Danjou <acid@debian.org>:
Bug#216135; Package apt-build. (full text, mbox, link).


Acknowledgement sent to Ruben Porras <nahoo82@telefonica.net>:
New Bug report received and forwarded. Copy sent to Julien Danjou <acid@debian.org>. (full text, mbox, link).


Message #5 received at submit@bugs.debian.org (full text, mbox, reply):

From: Ruben Porras <nahoo82@telefonica.net>
To: Debian Bug Tracking System <submit@bugs.debian.org>
Subject: apt-build: Unable to find a source package
Date: Thu, 16 Oct 2003 21:28:17 +0200
Package: apt-build
Version: 0.9
Severity: important

apt-get finds the source without problems

apt-get source bash
Reading Package Lists... Done
Building Dependency Tree... Done
Need to get 2509kB of source archives.
Get:1 ftp://ftp.rediris.es sid/main bash 2.05b-2-11 (tar) [1956kB]
Get:2 ftp://ftp.rediris.es sid/main bash 2.05b-2-11 (diff) [552kB]
Fetched 2509kB in 5m58s (6997B/s)
dpkg-source: extracting bash in bash-2.05b-2

but I don't know why with some packages apt-build
decides to download another version of the source package,
and fails:

apt-build install bash
-----> Installing build dependencies (for bash) <-----
Reading Package Lists... Done
Building Dependency Tree... Done
0 upgraded, 0 newly installed, 0 to remove and 49 not upgraded.
-----> Downloading bash source (bash 2.05b-11) <-----
Taking version 2.05b-11 over 2.05b-2-11
 
Reading Package Lists... Done
Building Dependency Tree... Done
E: Unable to find a source package for bash
-----> Building bash <-----
E: Unable to find a source package for bash
Use of uninitialized value in concatenation (.) or string at /usr/bin/apt-build line 275.
Can't chdir(bash-): No such file or directory at (eval 1) line 3
        main::__ANON__('bash-') called at /usr/bin/apt-build line 275
        main::build('bash','2.05b',-11) called at /usr/bin/apt-build line 420
        main::install called at /usr/bin/apt-build line 82
bennett@nahoo:~$ sudo apt-build --noupdate source bash
-----> Downloading bash source (bash 2.05b-11) <-----
Taking version 2.05b-11 over 2.05b-2-11
 
Reading Package Lists... Done
Building Dependency Tree... Done
E: Unable to find a source package for bash


-- System Information:
Debian Release: testing/unstable
Architecture: i386
Kernel: Linux nahoo 2.6.0-test7 #16 Thu Oct 9 14:34:21 CEST 2003 i686
Locale: LANG=es_ES.UTF-8, LC_CTYPE=es_ES.UTF-8

Versions of packages apt-build depends on:
ii  apt                           0.5.14     Advanced front-end for dpkg
ii  apt-utils                     0.5.14     APT utility programs
ii  debconf                       1.3.15     Debian configuration management sy
ii  devscripts                    2.7.91     Scripts to make the life of a Debi
ii  dpkg-dev                      1.10.15    Package building tools for Debian
ii  g++                           4:3.3.1-2  The GNU C++ compiler.
ii  gcc                           4:3.3.1-2  The GNU C compiler.
ii  libappconfig-perl             1.52-8     Perl module for configuration file
ii  libapt-pkg-perl               0.1.11     Perl interface to libapt-pkg
ii  perl                          5.8.1-2    Larry Wall's Practical Extraction 

-- debconf information:
* apt-build/olevel: Strong
* apt-build/arch_intel: pentium4
* apt-build/add_to_sourceslist: true
* apt-build/build_dir: /var/cache/apt-build/build
  apt-build/arch_sparc: sparc
* apt-build/options: 
* apt-build/arch: i686
* apt-build/cc: gcc-3.2
  apt-build/arch_arm: armv2
  apt-build/arch_alpha: ev4
  apt-build/arch_amd: k6
* apt-build/repository_dir: /var/cache/apt-build/repository




Information forwarded to debian-bugs-dist@lists.debian.org, Julien Danjou <acid@debian.org>:
Bug#216135; Package apt-build. (full text, mbox, link).


Acknowledgement sent to Ruben Porras <nahoo82@telefonica.net>:
Extra info received and forwarded to list. Copy sent to Julien Danjou <acid@debian.org>. (full text, mbox, link).


Message #10 received at 216135@bugs.debian.org (full text, mbox, reply):

From: Ruben Porras <nahoo82@telefonica.net>
To: Debian Bug Tracking System <216135@bugs.debian.org>
Subject: apt-build: more info
Date: Sun, 25 Jan 2004 17:45:13 +0100
Package: apt-build
Version: 0.9.1
Severity: normal
Followup-For: Bug #216135

I've investigated a little far and I've realized that the problem is that
apt-build assumes that the version of the binary and source package are the
same, which isn't true in this case:

apt-cache show bash
[...]
Source: bash (2.05b-2-12)
Version: 2.05b-12
[...]

I think parsing the output of apt-cache to find the version of the source
corresponding to the binary will solve the problem. 


-- System Information:
Debian Release: testing/unstable
Architecture: i386
Kernel: Linux nahoo 2.6.1 #1 Fri Jan 9 16:43:42 CET 2004 i686
Locale: LANG=es_ES.UTF-8, LC_CTYPE=es_ES.UTF-8

Versions of packages apt-build depends on:
ii  apt                           0.5.21     Advanced front-end for dpkg
ii  apt-utils                     0.5.21     APT utility programs
ii  debconf                       1.4.7      Debian configuration management sy
ii  devscripts                    2.7.95.1   Scripts to make the life of a Debi
ii  dpkg-dev                      1.10.18    Package building tools for Debian
ii  g++                           4:3.3.2-2  The GNU C++ compiler
ii  gcc                           4:3.3.2-2  The GNU C compiler
ii  libappconfig-perl             1.52-8     Perl module for configuration file
ii  libapt-pkg-perl               0.1.11     Perl interface to libapt-pkg
ii  perl                          5.8.2-2    Larry Wall's Practical Extraction 

-- debconf information excluded




Information forwarded to debian-bugs-dist@lists.debian.org:
Bug#216135; Package apt-build. (full text, mbox, link).


Acknowledgement sent to Julien Danjou <acid@debian.org>:
Extra info received and forwarded to list. (full text, mbox, link).


Message #15 received at 216135@bugs.debian.org (full text, mbox, reply):

From: Julien Danjou <acid@debian.org>
To: Ruben Porras <nahoo82@telefonica.net>, 216135@bugs.debian.org
Subject: Re: Bug#216135: apt-build: more info
Date: Sun, 25 Jan 2004 18:13:58 +0100
On Sun, Jan 25, 2004 at 05:45:13PM +0100, Ruben Porras wrote:
> Package: apt-build
> Version: 0.9.1
> Severity: normal
> Followup-For: Bug #216135
> 
> I've investigated a little far and I've realized that the problem is that
> apt-build assumes that the version of the binary and source package are the
> same, which isn't true in this case:
> 
> apt-cache show bash
> [...]
> Source: bash (2.05b-2-12)
> Version: 2.05b-12
> [...]
> 
> I think parsing the output of apt-cache to find the version of the source
> corresponding to the binary will solve the problem. 

Yes, but that's not so simple if apt-cache show output several versions
of the same package :-(

-- 
Julien Danjou
.''`.  Debian developer
: :' : http://jdanjou.org
`. `'  http://people.debian.org/~acid
  `-   9A0D 5FD9 EB42 22F6 8974  C95C A462 B51E C2FE E5CD



Information forwarded to debian-bugs-dist@lists.debian.org, Julien Danjou <acid@debian.org>:
Bug#216135; Package apt-build. (full text, mbox, link).


Acknowledgement sent to Ruben Porras <nahoo82@telefonica.net>:
Extra info received and forwarded to list. Copy sent to Julien Danjou <acid@debian.org>. (full text, mbox, link).


Message #20 received at 216135@bugs.debian.org (full text, mbox, reply):

From: Ruben Porras <nahoo82@telefonica.net>
To: Debian Bug Tracking System <216135@bugs.debian.org>
Subject: apt-build: possible solution
Date: Sun, 25 Jan 2004 20:14:07 +0100
Package: apt-build
Version: 0.9.1
Severity: normal
Followup-For: Bug #216135

And what about something like this?

@@ -264,12 +281,31 @@
                        ($srcpkg, $srcver) = ($n, $v)
                });
  
+       $srcver = $upver.$maintver;
+       my $seen;
+       read_apt_list("apt-cache show $pkg |", "^Version:|Source:",
+                     sub {
+                         my $srcvertemp;
+                         if(/^Source: $srcpkg \((.+)\)$/) {
+                             $seen = 1;
+                             $srcvertemp = $1;
+                         }
+                         if(/^Version: (.+)$/ && $seen && $1 eq $upver.$maintver) {
+                             $srcver = $srcvertemp; $seen = 0;
+                         }
+                     });
  
        read_apt_list(
-               "apt-get --print-uris @apt_args source $srcpkg=".$upver.$maintver." |",
+               "apt-get --print-uris @apt_args source $srcpkg=".$srcver." |",


I think it selects the right version, with this I can apt-build install bash
without problems. I didn't send this the first time because I don't consider
myself a perl expert.

-- System Information:
Debian Release: testing/unstable
Architecture: i386
Kernel: Linux nahoo 2.6.1 #1 Fri Jan 9 16:43:42 CET 2004 i686
Locale: LANG=es_ES.UTF-8, LC_CTYPE=es_ES.UTF-8

Versions of packages apt-build depends on:
ii  apt                           0.5.21     Advanced front-end for dpkg
ii  apt-utils                     0.5.21     APT utility programs
ii  debconf                       1.4.7      Debian configuration management sy
ii  devscripts                    2.7.95.1   Scripts to make the life of a Debi
ii  dpkg-dev                      1.10.18    Package building tools for Debian
ii  g++                           4:3.3.2-2  The GNU C++ compiler
ii  gcc                           4:3.3.2-2  The GNU C compiler
ii  libappconfig-perl             1.52-8     Perl module for configuration file
ii  libapt-pkg-perl               0.1.11     Perl interface to libapt-pkg
ii  perl                          5.8.2-2    Larry Wall's Practical Extraction 

-- debconf information excluded




Information forwarded to debian-bugs-dist@lists.debian.org, Julien Danjou <acid@debian.org>:
Bug#216135; Package apt-build. (full text, mbox, link).


Acknowledgement sent to Ruben Porras <nahoo82@telefonica.net>:
Extra info received and forwarded to list. Copy sent to Julien Danjou <acid@debian.org>. (full text, mbox, link).


Message #25 received at 216135@bugs.debian.org (full text, mbox, reply):

From: Ruben Porras <nahoo82@telefonica.net>
To: Debian Bug Tracking System <216135@bugs.debian.org>
Subject: apt-build: possible solution
Date: Sun, 25 Jan 2004 20:57:29 +0100
Package: apt-build
Version: 0.9.1
Severity: normal
Followup-For: Bug #216135

The last patch worked by a side effect, just because $srcvertemp was declared in
the subroutine and $srcver ends as "undef". I hope that the previous patch with
this modifications is useful.

+       $srcver = $upver.$maintver;
+       my ($seen, $srcvertemp);
+       read_apt_list("apt-cache show $pkg |", "^Version:|Source:",
+                     sub {
+                       if(/^Source: $srcpkg \((.+)\)$/) {
+                         $srcvertemp = $1; $seen = 1;
+                       } elsif(/^Version: (.+)$/ && $seen && $1 eq $upver.$maintver) {
+                         $srcver = $srcvertemp; $seen = 0;
+                       }
+                     });


-- System Information:
Debian Release: testing/unstable
Architecture: i386
Kernel: Linux nahoo 2.6.1 #1 Fri Jan 9 16:43:42 CET 2004 i686
Locale: LANG=es_ES.UTF-8, LC_CTYPE=es_ES.UTF-8

Versions of packages apt-build depends on:
ii  apt                           0.5.21     Advanced front-end for dpkg
ii  apt-utils                     0.5.21     APT utility programs
ii  debconf                       1.4.7      Debian configuration management sy
ii  devscripts                    2.7.95.1   Scripts to make the life of a Debi
ii  dpkg-dev                      1.10.18    Package building tools for Debian
ii  g++                           4:3.3.2-2  The GNU C++ compiler
ii  gcc                           4:3.3.2-2  The GNU C compiler
ii  libappconfig-perl             1.52-8     Perl module for configuration file
ii  libapt-pkg-perl               0.1.11     Perl interface to libapt-pkg
ii  perl                          5.8.2-2    Larry Wall's Practical Extraction 

-- debconf information excluded




Information forwarded to debian-bugs-dist@lists.debian.org, Julien Danjou <acid@debian.org>:
Bug#216135; Package apt-build. (full text, mbox, link).


Acknowledgement sent to Alberto Mardegan <mardy@despammed.com>:
Extra info received and forwarded to list. Copy sent to Julien Danjou <acid@debian.org>. (full text, mbox, link).


Message #30 received at 216135@bugs.debian.org (full text, mbox, reply):

From: Alberto Mardegan <mardy@despammed.com>
To: 216135@bugs.debian.org
Subject: Same building gtk
Date: Sun, 24 Oct 2004 23:28:44 +0200
I have the same problem while building libgtk2.0-0. If you need some
additional informations, please ask:


# apt-build --reinstall install libgtk2.0-0
-----> Installing build dependencies (for libgtk2.0-dbg) <-----
Reading Package Lists... Done
Building Dependency Tree... Done
0 upgraded, 0 newly installed, 0 to remove and 635 not upgraded.
-----> Downloading libgtk2.0-dbg source (gtk+2.0 2.4.13-1) <-----
Taking version 2.4.13-1 over 2.4.10-1

-----> Updating package lists <-----
Hit http://ftp.it.debian.org sarge/main Packages
Hit http://ftp.it.debian.org sarge/main Release
Hit http://ftp.it.debian.org sarge/contrib Packages
Hit http://ftp.it.debian.org sarge/contrib Release
[...]
Reading Package Lists... Done
Reading Package Lists... Done
Building Dependency Tree... Done
E: Unable to find a source package for gtk+2.0
-----> Building libgtk2.0-dbg <-----
E: Unable to find a source package for gtk+2.0
Use of uninitialized value in concatenation (.) or string at
/usr/bin/apt-build line 280.
Can't chdir(gtk+2.0-): No such file or directory at (eval 1) line 3
        main::__ANON__('gtk+2.0-') called at /usr/bin/apt-build line 280
        main::build('libgtk2.0-dbg', 2.4.13, -1) called at
/usr/bin/apt-build line 436
        main::install called at /usr/bin/apt-build line 82



-- System Information:
Debian Release: testing/unstable
  APT prefers unstable
  APT policy: (500, 'unstable'), (500, 'testing')
Architecture: i386 (i686)
Kernel: Linux 2.6.9-rc3
Locale: LANG=it_IT.UTF-8@euro, LC_CTYPE=it_IT.UTF-8@euro

Versions of packages apt-build depends on:
ii  apt                           0.5.26     Advanced front-end for dpkg
ii  apt-utils                     0.5.26     APT utility programs
ii  debconf                       1.4.30     Debian configuration management sy
ii  devscripts                    2.7.95.1   Scripts to make the life of a Debi
ii  dpkg-dev                      1.10.22    Package building tools for Debian
ii  g++                           4:3.3.4-2  The GNU C++ compiler
ii  gcc                           4:3.3.4-2  The GNU C compiler
ii  libappconfig-perl             1.52-8     Perl module for configuration file
ii  libapt-pkg-perl               0.1.13     Perl interface to libapt-pkg
ii  perl                          5.8.4-2.3  Larry Wall's Practical Extraction 

-- debconf information:
  apt-build/arch_alpha: ev4
  apt-build/arch_arm: armv2
* apt-build/olevel: Medium
* apt-build/build_dir: /var/cache/apt-build/build
  apt-build/arch_sparc: sparc
* apt-build/arch_amd: athlon-xp
* apt-build/options:
  apt-build/arch_intel: pentium
* apt-build/repository_dir: /var/cache/apt-build/repository
* apt-build/add_to_sourceslist: true


-- 
Saluti,
    Mardy
http://interlingua.altervista.org



Information forwarded to debian-bugs-dist@lists.debian.org, dragontamer5788@yahoo.com, Julien Danjou <acid@debian.org>:
Bug#216135; Package apt-build. (full text, mbox, link).


Acknowledgement sent to Percival Tiglao <dragontamer5788@yahoo.com>:
Extra info received and forwarded to list. Copy sent to dragontamer5788@yahoo.com, Julien Danjou <acid@debian.org>. (full text, mbox, link).


Message #35 received at 216135@bugs.debian.org (full text, mbox, reply):

From: Percival Tiglao <dragontamer5788@yahoo.com>
To: Debian Bug Tracking System <216135@bugs.debian.org>
Subject: apt-build: A way around the "cannot find source package" bug
Date: Sat, 01 Jan 2005 02:17:23 -0500
Package: apt-build
Version: 0.9.16
Followup-For: Bug #216135

By using apt-get source in the /var/cache/apt-build/build directory, i
can download specific package sources manually. From there, 

apt-build --reinstall --rebuild --nosource install (whatever)

works to build the package that "didn't have a source" but did.

I guess this could work until the maintainers find the bug.

-- System Information:
Debian Release: 3.1
  APT prefers unstable
  APT policy: (500, 'unstable')
Architecture: i386 (i686)
Kernel: Linux 2.6.8try
Locale: LANG=C, LC_CTYPE=C (charmap=ANSI_X3.4-1968)

Versions of packages apt-build depends on:
ii  apt                           0.5.27     Advanced front-end for dpkg
ii  apt-utils                     0.5.27     APT utility programs
ii  debconf                       1.4.41     Debian configuration management sy
ii  devscripts                    2.8.6      Scripts to make the life of a Debi
ii  dpkg-dev                      1.10.25    Package building tools for Debian
ii  g++                           4:3.3.5-1  The GNU C++ compiler
ii  gcc                           4:3.3.5-1  The GNU C compiler
ii  libappconfig-perl             1.56-2     Perl module for configuration file
ii  libapt-pkg-perl               0.1.13     Perl interface to libapt-pkg
ii  perl                          5.8.4-5    Larry Wall's Practical Extraction 

-- debconf information:
* apt-build/options: -pipe -mfpmath=sse -msse2
* apt-build/arch_intel: pentium4
* apt-build/olevel: Strong
* apt-build/build_dir: /var/cache/apt-build/build
* apt-build/repository_dir: /var/cache/apt-build/repository
* apt-build/add_to_sourceslist: true



Reply sent to Julien Danjou <acid@debian.org>:
You have taken responsibility. (full text, mbox, link).


Notification sent to Ruben Porras <nahoo82@telefonica.net>:
Bug acknowledged by developer. (full text, mbox, link).


Message #40 received at 216135-done@bugs.debian.org (full text, mbox, reply):

From: Julien Danjou <acid@debian.org>
To: 216135-done@bugs.debian.org
Subject: Fixed in 0.10 series
Date: Fri, 7 Jan 2005 16:06:01 +0100
[Message part 1 (text/plain, inline)]
Hello,

This bug should have been fixed in 0.10 series.

Regards,
-- 
Julien Danjou
.''`.  Debian developer
: :' : http://julien.danjou.info
`. `'  http://people.debian.org/~acid
  `-   9A0D 5FD9 EB42 22F6 8974  C95C A462 B51E C2FE E5CD
[signature.asc (application/pgp-signature, inline)]

Send a report that this bug log contains spam.


Debian bug tracking system administrator <owner@bugs.debian.org>. Last modified: Wed Jan 10 19:06:51 2018; Machine Name: beach

Debian Bug tracking system

Debbugs is free software and licensed under the terms of the GNU Public License version 2. The current version can be obtained from https://bugs.debian.org/debbugs-source/.

Copyright © 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson, 2005-2017 Don Armstrong, and many other contributors.