Slackware This Forum is for the discussion of Slackware Linux.
|
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
 |
03-04-2014, 04:39 AM
|
#1
|
Member
Registered: Jan 2014
Distribution: Slackware 14.1 (MLED 32-bit)
Posts: 84
Rep: 
|
Installing a package built via src2pkg: package description do not appear
Having taken extra care to provide a valid slack-desc file in the build directory prior to `src2pkg -CWD source.tar.gz`, when installing (or upgrading) the package it seems that the description does not show up.
Is this a bug or a feature?
|
|
|
03-05-2014, 02:41 AM
|
#2
|
Amigo developer
Registered: Dec 2003
Location: Germany
Distribution: Slackware
Posts: 4,928
|
Strange, is it being included in the package?
|
|
|
03-05-2014, 03:17 AM
|
#3
|
Member
Registered: Jan 2014
Distribution: Slackware 14.1 (MLED 32-bit)
Posts: 84
Original Poster
Rep: 
|
Yes, the slack-desc is included in the package! I have also generated one using the script found at the slacky.eu wiki just to make sure it is valid.
Then I have re-built a package via src2pkg (as root, to set ownership correctly) and upgradepkg-ed it to check, but the package description is still not displayed:
Code:
# upgradepkg somepackage-i486-src2pkg-3.txz
+==============================================================================
| Upgrading somepackage-i486-src2pkg-2 package using ./somepackage-i486-src2pkg-3.txz
+==============================================================================
Pre-installing package somepackage-i486-src2pkg-3...
Removing package /var/log/packages/somepackage-i486-src2pkg-2-upgraded-2014-03-05,11:03:23...
Verifying package somepackage-2.1.24-i486-src2pkg-3.txz.
Installing package somepackage-i486-src2pkg-3.txz:
PACKAGE DESCRIPTION:
Executing install script for somepackage-i486-src2pkg-3.txz.
Package somepackage-i486-src2pkg-3.txz installed.
Package somepackage-i486-src2pkg-2 upgraded with new package ./somepackage-i486-src2pkg-3.txz.
EDIT: The slack-desc was, of course, placed in the build directory as referred to in the build command:
Code:
src2pkg -CWD -b=src2pkg-3 source.tar.gz
Last edited by s09; 03-05-2014 at 03:37 AM.
Reason: Provided additional details
|
|
|
03-05-2014, 03:23 AM
|
#4
|
LQ Guru
Registered: Aug 2004
Location: Pisa, Italy
Distribution: Slackware
Posts: 7,463
|
I'm just guessing, but have you placed the slack-desc file in the ./install subdirectory of the one you're using to make the package?
makepkg expect it to be there.
|
|
|
03-05-2014, 03:33 AM
|
#5
|
Member
Registered: Jan 2014
Distribution: Slackware 14.1 (MLED 32-bit)
Posts: 84
Original Poster
Rep: 
|
Yes, ponce, src2pkg has placed the slack-desc file there.
|
|
|
03-05-2014, 04:29 AM
|
#6
|
Senior Member
Registered: Sep 2009
Location: Yorks. W.R. 167397
Distribution: Slackware
Posts: 1,307
Rep: 
|
It looks like your package name is messed up (sorry!) and it is confusing upgradepkg.
A valid package name is PRGNAM-VERSION-ARCH-BUILD.t?z, where
PRGNAM can include '-'
VERSION can *not* include '-'
ARCH can *not* include '-'
BUILD (including TAG) can *not* include '-'
Your package name is
PRGNAM='somepackage'
VERSION='i486', which is 'interesting' 
ARCH='src2pkg', which is also 'interesting' 
BUILD='3'
Any mistake in the package name will confuse upgradepkg. It has to work backwards, starting with the BUILD, because it does not know how many '-' are included in PRGNAM. If upgradepkg calculates the wrong PRGNAM from the package name, then the PRGNAM it calculated will not be the same as the name in the slack-desc, and it will not show the slack-desc properly.
If src2pkg is not giving you a correct package name, you need to set the correct command line arguments so that it does. -b=src2pkg-3 is not correct 
|
|
|
03-05-2014, 11:20 AM
|
#7
|
Member
Registered: Jan 2014
Distribution: Slackware 14.1 (MLED 32-bit)
Posts: 84
Original Poster
Rep: 
|
Quote:
It looks like your package name is messed up (sorry!) and it is confusing upgradepkg.
...
|
Thanks for the suggestion! I have tried with a version number and the result is the same. 
|
|
|
03-05-2014, 12:33 PM
|
#8
|
Amigo developer
Registered: Dec 2003
Location: Germany
Distribution: Slackware
Posts: 4,928
|
Yeah, that's the problem. Show us the slack-desc and the output from when you run src2pkg. You have named the package somepackage, so the slack-desc should have lines like:
somepackage:
somepackage:
...
src2pkg tries to guess a correct name for the package -based on the name of the sources. It doesn't always get it correct, in which case you need to supply the name and version for it. As pointed out, you have weirdness in the arch and versions, too. Are you building from source or using src2pkg to re-package an already-created package? What are the names of these things, and what src2pkg command-line options are you using? Have you created entries in the src2pkg.conf file which are confusing things?
|
|
|
03-06-2014, 02:57 AM
|
#9
|
Member
Registered: Jan 2014
Distribution: Slackware 14.1 (MLED 32-bit)
Posts: 84
Original Poster
Rep: 
|
Well, here is the whole process documented once again with a different package:
Code:
# ls
slack-desc udunits-2.1.24.tar.gz
# src2pkg -b=src2pkg-1 udunits-2.1.24.tar.gz
hostname: Unknown host
Found source archive: udunits-2.1.24.tar.gz
Creating working directories:
PKG_DIR=/tmp/udunits-2.1.24-i486-src2pkg-1
SRC_DIR=/tmp/udunits-2.1.24-src-src2pkg-1
Unpacking source archive - Done
Correcting source permissions - Done
Checking for patches - None found
Found configure script - Done
Configuring sources using:
LDFLAGS="-Wl,-O1,-L/lib,-L/usr/lib" CFLAGS="-O2 -m32 -march=i486 -mtune=i686" ./configure --prefix=/usr
Configuration has been - Successful!
Compiling sources - Using: 'make'
Compiling has been - Successful!
Checking for Makefile rule: 'install' Okay
Checking support for DESTDIR (or similar) - Found DESTDIR
Creating package content using:
make DESTDIR=/tmp/udunits-2.1.24-i486-src2pkg-1 install
Installation in DESTDIR - Successful
Processing package content:
Correcting libtool files - Done
Correcting package permissions - Done
Stripping ELF binaries - Using: strip -p --strip-unneeded Done
Stripping static archives - Using: strip -p --strip-debug Done
Stripping shared libraries - Using: strip -p --strip-unneeded Done
Notice - Moving docs installed under usr/share/doc to usr/doc.
Notice - Renaming doc directory installed without a version number.
Checking for standard documents - Done
Notice - Moving info pages installed under usr/share/info to /usr/info
Compressing info pages - Done
Verified slack-desc found - Inserting in package as PKG_DIR/install/slack-desc
Rechecking package correctness:
Checking for misplaced dirs - Done
Rechecking package permissions - Done
Checking for dead links in PKG_DIR - Done
Searching for links in: udunits-2.1.24-i486-src2pkg-1 - Done
Adding links to doinst.sh - Adding links-creation to the doinst.sh
Notice - Adding 'install-info ' routine to doinst.sh
Deleting symbolic links - Removing links from the package directory
Creating package: udunits-2.1.24-i486-src2pkg-1.txz - Done
Package Creation - Successful! Package Location:
/tmp/udunits-2.1.24-i486-src2pkg-1.txz
# installpkg /tmp/udunits-2.1.24-i486-src2pkg-1.txz
Verifying package udunits-2.1.24-i486-src2pkg-1.txz.
Installing package udunits-2.1.24-i486-src2pkg-1.txz:
PACKAGE DESCRIPTION:
Executing install script for udunits-2.1.24-i486-src2pkg-1.txz.
Package udunits-2.1.24-i486-src2pkg-1.txz installed.
# cat slack-desc
# HOW TO EDIT THIS FILE:
# The "handy ruler" below makes it easier to edit a package description. Line
# up the first '|' above the ':' following the base package name, and the '|'
# on the right side marks the last column you can put a character in. You must
# make exactly 11 lines for the formatting to be correct. It's also customary
# to leave one space after the ':'.
|----handy-ruler-------------------------------------------------------|
udunits: udunits (The UDUNITS package supports units of physical quantities.)
udunits:
udunits: The UDUNITS package supports units of physical quantities. Its
udunits: C library provides for arithmetic manipulation of units and for
udunits: conversion of numeric values between compatible units. The package
udunits: contains an extensive unit database, which is in XML format and
udunits: user-extendable. The package also contains a command-line utility
udunits: for investigating units and converting values.
udunits:
udunits: (http://www.unidata.ucar.edu/software/udunits/)
udunits:
BTW, now I've also noticed that src2pkg has problems finding the hostname, although it is the default one:
Code:
# hostname
darkstar
I hope now the case is perfectly clear.
|
|
|
03-06-2014, 05:38 AM
|
#10
|
Senior Member
Registered: Sep 2009
Location: Yorks. W.R. 167397
Distribution: Slackware
Posts: 1,307
Rep: 
|
Quote:
Originally Posted by s09
# src2pkg -b=src2pkg-1 udunits-2.1.24.tar.gz
[...]
Creating package: udunits-2.1.24-i486-src2pkg-1.txz - Done
Package Creation - Successful! Package Location:
/tmp/udunits-2.1.24-i486-src2pkg-1.txz
|
I *told* you not to do "-b=src2pkg-1" 
and that is the exact cause of your problem
installpkg / upgradepkg parses your package name 'udunits-2.1.24-i486-src2pkg-1.txz' as:
PRGNAM udunits-2.1.24 => wrong, should be udunits
VERSION i486 => wrong, should be 2.1.24
ARCH src2pkg => wrong, should be i486
BUILD 1 => ok, but I guess you want something like '1_src2pkg'?
DO NOT USE '-' IN THE BUILD. NOT EVER. USE '_' INSTEAD.
I hope now the case is perfectly clear...
|
|
1 members found this post helpful.
|
03-06-2014, 12:24 PM
|
#11
|
Amigo developer
Registered: Dec 2003
Location: Germany
Distribution: Slackware
Posts: 4,928
|
Yeah, use -b=1_src2pkg or -b=src2pkg_1 if that's what you want.
As to hostname, that's not all necessary anyway. What's the output of `hostname -s` on your system? That's what src2pkg is running, but the -s option may be unsupported with your version of hostname.
|
|
1 members found this post helpful.
|
03-07-2014, 04:19 AM
|
#12
|
Member
Registered: Jan 2014
Distribution: Slackware 14.1 (MLED 32-bit)
Posts: 84
Original Poster
Rep: 
|
Quote:
Yeah, use -b=1_src2pkg or -b=src2pkg_1 if that's what you want.
As to hostname, that's not all necessary anyway. What's the output of `hostname -s` on your system? That's what src2pkg is running, but the -s option may be unsupported with your version of hostname.
|
The suggested build-tag fixed the issue! Thank you both, 55020 and gnashley!
gives
Code:
hostname: Unknown host
|
|
|
03-07-2014, 12:00 PM
|
#13
|
Amigo developer
Registered: Dec 2003
Location: Germany
Distribution: Slackware
Posts: 4,928
|
"hostname: Unknown host" I'll fix that for the next version, thanks for reporting. Does MLED use an alternative hostname than Slackware -or is this happening on Slackware also?
|
|
|
03-07-2014, 02:39 PM
|
#14
|
Member
Registered: Jan 2014
Distribution: Slackware 14.1 (MLED 32-bit)
Posts: 84
Original Poster
Rep: 
|
Quote:
"hostname: Unknown host" I'll fix that for the next version, thanks for reporting. Does MLED use an alternative hostname than Slackware -or is this happening on Slackware also?
|
I think it's the standard hostname from Slackware:
Code:
> ack -i bin/hostname /var/log/packages/
/var/log/packages/util-linux-2.21.2-i486-6
29:bin/hostname
/var/log/packages/net-tools-1.60.20120726git-i486-1
22:bin/hostname
|
|
|
All times are GMT -5. The time now is 04:27 PM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|