Sourcery fails to install successfully created packages

You think you have found a bug? Let us know about it.
User avatar
mimosa
Salix Warrior
Posts: 3311
Joined: 25. May 2010, 17:02
Contact:

Sourcery fails to install successfully created packages

Post by mimosa »

I normally use slapt-src, but just installed a couple of packages using Sourcery. The packages worked fine when I installed them manually, but Sourcery itself tells me:

Code: Select all

Slackware package /usr/src/slapt-src/desktop/q4wine/q4wine-0.114_r1-i486-1_SBo.txz created.

sh: spkg: command not found
spkg -u --reinstall --install-new q4wine-0.114_r1-i486-1_SBo.txz Failed
I uninstalled this [in fact, not this, but icoutils; but the problem was apparently identical] and reinstalled using slapt-src, without having the same problem. I don't normally use Sourcery, so it may just be something silly I'm doing wrong.
Shador
Posts: 1295
Joined: 11. Jun 2009, 14:04
Location: Bavaria

Re: Sourcery fails to install successfully created packages

Post by Shador »

Do you have spkg installed? What's the output of:

Code: Select all

slapt-get -search 'spkg-*|pkgtools-*'
Probably spkg should be a dependency of slapt-src or even better a fallback for pkgtools.
Image
User avatar
mimosa
Salix Warrior
Posts: 3311
Joined: 25. May 2010, 17:02
Contact:

Re: Sourcery fails to install successfully created packages

Post by mimosa »

Yes, I already checked this:

Code: Select all

root[vanilla]# slapt-get --search 'spkg-*|pkgtools-*'
pkgtools-13.37-noarch-9 [inst=yes]: pkgtools (The Slackware package maintenance system)
spkg-1.0-i486-1gv [inst=yes]: spkg (package manager)
Also it worked fine on the command line; presumably slapt-src uses the same commands as Sourcery, in this case, following the Slackbuild?

EDIT

Incidentally, it seems another user didn't have any problem installing the same packages using Sourcery:

http://www.salixos.org/forum/viewtopic. ... 875#p18875

... so it's probably not a bug in Sourcery.
Last edited by mimosa on 18. Dec 2011, 11:59, edited 1 time in total.
User avatar
laprjns
Salix Warrior
Posts: 1113
Joined: 28. Aug 2009, 01:30
Location: Connecticut USA

Re: Sourcery fails to install successfully created packages

Post by laprjns »

mimosa wrote:Incidentally, it seems another user didn't have any problem installing the same packages using Sourcery
I didn't have any problems installing those two packages using sourcery either. Maybe you forgot to update sourcery first, before building the packages.
“The past was erased, the erasure was forgotten, the lie became the truth.”
― George Orwell, 1984
User avatar
mimosa
Salix Warrior
Posts: 3311
Joined: 25. May 2010, 17:02
Contact:

Re: Sourcery fails to install successfully created packages

Post by mimosa »

Does Sourcery need to be updated separately from slapt-src? it worked with slapt-src. Surely Sourcery is just a graphical front end for the command line tool?

... just tried installing a random package, same thing, so I guess it affects all of them. Just to be safe I updated both in console and using Sourcery's menu, but the install failed with the same error. slapt-src was successful.

It does look like this is a local problem, not a bug, and since I can just use slapt-src, it's not an inconvenience. However, it's odd. :?

Also the actual error is strange. spkg *is* present.

Could it have anything to do with the fact I'm using Ratpoison? I can't really see how though.

EDIT

The exact command mentioned in the Sourcery log worked when I uninstalled one of the packages and reinstalled manually:

Code: Select all

root[vanilla]# cd /usr/src/slapt-src/development/icoutils
root[icoutils]# spkg -u --reinstall --install-new icoutils-0.26.0-i486-1_SBo.txz
Installing package icoutils-0.26.0-i486-1_SBo...
Shador
Posts: 1295
Joined: 11. Jun 2009, 14:04
Location: Bavaria

Re: Sourcery fails to install successfully created packages

Post by Shador »

Are you running slapt-src as root? Is your path set properly? Try running gksu xterm and check PATH there, also try running the slapt-src command from that window.
And yes slapt-src is a graphical frontend for slapt-src.
Image
User avatar
mimosa
Salix Warrior
Posts: 3311
Joined: 25. May 2010, 17:02
Contact:

Re: Sourcery fails to install successfully created packages

Post by mimosa »

Solved - though I don't fully understand why. I called Sourcery by doing

Code: Select all

: exec ktsuss sourcery
but when called using the Ratpoison menu, it works normally. So I guess ktsuss doesn't give all the needed root privileges. The menu uses gksu, and :exec gksu sourcery also works. So I was calling Sourcery in the wrong way.
Shador
Posts: 1295
Joined: 11. Jun 2009, 14:04
Location: Bavaria

Re: Sourcery fails to install successfully created packages

Post by Shador »

ktsuss probably doesn't update the environment properly, especially path. There might be an option to change that behaviour, check with ktsuss --help.
Image
User avatar
mimosa
Salix Warrior
Posts: 3311
Joined: 25. May 2010, 17:02
Contact:

Re: Sourcery fails to install successfully created packages

Post by mimosa »

Well, I think I'll use gksu in future. Thanks Shador and laprjns, and sorry for the false alarm :oops:

Just found this post:

http://www.salixos.org/forum/viewtopic.php?p=6616

... so is gksu just a wrapper for ktsuss precisely to avoid this problem?

See also this short post, which describes the problem exactly:

http://mike.opennix.com/2010/07/ktsuss- ... ware-13-1/

ktsuss gives the app it calls root privileges, but if that app in turn calls apps that need to be run as root, they don't inherit the privileges. In this case, that was spkg.
User avatar
gapan
Salix Wizard
Posts: 6361
Joined: 6. Jun 2009, 17:40

Re: Sourcery fails to install successfully created packages

Post by gapan »

mimosa wrote:... so is gksu just a wrapper for ktsuss precisely to avoid this problem?
Not only that. It's also a replacement for the standard (and now obsolete) gksu tool.
Image
Image
Post Reply