Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

[workaround] gbp buildpackage - Failed extracting the source

Programming languages, Coding, Executables, Package Creation, and Scripting.
Post Reply
Message
Author
User avatar
GuillaumeBrochu
Posts: 4
Joined: 2018-10-26 00:17
Location: Lévis, Québec, Canada

[workaround] gbp buildpackage - Failed extracting the source

#1 Post by GuillaumeBrochu »

Hi,

I'm trying to build the geneweb package with gbp buildpackage using the command:

Code: Select all

gbp buildpackage --git-export-dir=../result --git-pbuilder --git-pbuilder-options=--debug
I get this error and I don't understand why:

Code: Select all

I: Extracting source
+ echo 'chown pbuilder:pbuilder /build /build/*'
+ chroot /var/cache/pbuilder/build/cow.31392 cow-shell /bin/bash
+ :
+ unshare -n -- /usr/lib/pbuilder/pbuilder-unshare-wrapper chroot /var/cache/pbuilder/build/cow.31392 cow-shell env LD_PRELOAD= LOGNAME=pbuilder USER=pbuilder /sbin/start-stop-daemon --start --pidfile /dev/null --chuid pbuilder --startas /bin/sh
++ basename /home/user/result/geneweb_6.08+git20181019+dfsg-1.dsc
+ echo '( cd /build; env PATH="/usr/sbin:/usr/bin:/sbin:/bin" dpkg-source -x geneweb_6.08+git20181019+dfsg-1.dsc geneweb-6.08+git20181019+dfsg )'
/sbin/start-stop-daemon: unable to start /bin/sh (Permission denied)
+ log.e 'pbuilder: Failed extracting the source'
+ case "${LOGLEVEL-I}" in
+ log 'E: pbuilder: Failed extracting the source'
+ set +x
E: pbuilder: Failed extracting the source
I'm using Debian stretch.

Code: Select all

apt-cache policy git-buildpackage
git-buildpackage:
  Installé : 0.8.12.2
  Candidat : 0.8.12.2
 Table de version :
 *** 0.8.12.2 700
        700 http://ftp.ca.debian.org/debian stretch/main amd64 Packages
        100 /var/lib/dpkg/status

apt-cache policy cowbuilder
cowbuilder:
  Installé : 0.87~bpo9+1
  Candidat : 0.87~bpo9+1
 Table de version :
 *** 0.87~bpo9+1 700
        700 http://ftp.ca.debian.org/debian stretch-backports/main amd64 Packages
        100 /var/lib/dpkg/status
     0.85 700
        700 http://ftp.ca.debian.org/debian stretch/main amd64 Packages

apt-cache policy pbuilder
pbuilder:
  Installé : 0.229.3~bpo9+1
  Candidat : 0.229.3~bpo9+1
 Table de version :
 *** 0.229.3~bpo9+1 700
        700 http://ftp.ca.debian.org/debian stretch-backports/main amd64 Packages
        100 /var/lib/dpkg/status
     0.228.7 700
        700 http://ftp.ca.debian.org/debian stretch/main amd64 Packages
Any idea/comment/suggestion/advice?

Thank you.
Last edited by GuillaumeBrochu on 2018-11-11 21:47, edited 1 time in total.

User avatar
GuillaumeBrochu
Posts: 4
Joined: 2018-10-26 00:17
Location: Lévis, Québec, Canada

Re: Problem with gbp buildpackage - Failed extracting the so

#2 Post by GuillaumeBrochu »

I think it corresponds to this piece of code in /usr/lib/pbuilder/pbuilder-buildpackage (line 134):

Code: Select all

log.i "Extracting source"
if echo "chown $BUILDUSERNAME:$BUILDUSERNAME $BUILDDIR $BUILDDIR/*" | $CHROOTEXEC /bin/bash; then
    : # success
else
    log.e "pbuilder: Failed chowning to $BUILDUSERNAME:$BUILDUSERNAME"
    exit 1;
fi
if echo "( cd $BUILDDIR; env PATH=\"$PATH\" dpkg-source -x $(basename "$PACKAGENAME") "$BUILDSUBDIR" )" | $UNSHARE $CHROOTEXEC env $SUTOUSER ; then
    : # success
else
    log.e "pbuilder: Failed extracting the source"
    exit 1;
fi

User avatar
stevepusser
Posts: 12930
Joined: 2009-10-06 05:53
Has thanked: 41 times
Been thanked: 71 times

Re: Problem with gbp buildpackage - Failed extracting the so

#3 Post by stevepusser »

When I use pbuilder, it asks for a password (my root and sudo password are the same, since this is a laptop, so I don't know which one it uses). Does it ask you?

Have you been able to use the same procedure in the past to build packages from git, or is this the first time you've tried?

Does it work with the standard Stretch cowbuilder instead of the backported one?
MX Linux packager and developer

User avatar
GuillaumeBrochu
Posts: 4
Joined: 2018-10-26 00:17
Location: Lévis, Québec, Canada

Re: Problem with gbp buildpackage - Failed extracting the so

#4 Post by GuillaumeBrochu »

.
.
Thank you for your feedback.
stevepusser wrote:When I use pbuilder, it asks for a password (my root and sudo password are the same, since this is a laptop, so I don't know which one it uses). Does it ask you?
Yes. sudo password.

I also tried to changed my umask to 002, but I still get the same error.
stevepusser wrote:Have you been able to use the same procedure in the past to build packages from git, or is this the first time you've tried?
First time with Stretch.

With Jessie, I was using :

Code: Select all

git-buildpackage --git-export-dir=../result -S
sudo pbuilder build --buildresult ../result ../result/*.dsc
but the first command no longer works with Stretch.

Actually, if I start to build the package with the procedure described in my first message (with gbp buildpackage), and when the described failure happens (after the completion of the build of the source package), if I use:

Code: Select all

sudo pbuilder build --buildresult ../result ../result/*.dsc
to complete the build of the .deb, it works!

It's only cowbuilder (called by gbp buildpackage) that doesn't work. It looks like a bug in gbp buildpackage or cowbuilder or pbuilder.
stevepusser wrote:Does it work with the standard Stretch cowbuilder instead of the backported one?
I will try to downgrade these packages, to see if it helps.

User avatar
GuillaumeBrochu
Posts: 4
Joined: 2018-10-26 00:17
Location: Lévis, Québec, Canada

Re: Problem with gbp buildpackage - Failed extracting the so

#5 Post by GuillaumeBrochu »

Finally, I was able to build with

Code: Select all

gbp buildpackage --git-export-dir=../result -d -S --force-sign
sudo pbuilder build --buildresult ../result ../result/*.dsc
The problem is probably related to cowbuilder. I have not tried to downgrade the packages from backports to stable.

Post Reply