LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 04-22-2014, 02:45 PM   #1
stf92
Senior Member
 
Registered: Apr 2007
Location: Buenos Aires.
Distribution: Slackware
Posts: 4,442

Rep: Reputation: 76
What if I use installpkg with .xz packages?


Hi: installpkg makes no objections when given a .xz packages. Does it manage them correctly? It would be more logical that xz understands and correctly manages .tgz packages, which is my second question.

Last edited by stf92; 04-22-2014 at 02:48 PM.
 
Old 04-22-2014, 03:36 PM   #2
gengisdave
Member
 
Registered: Dec 2013
Location: Turin, Italy
Distribution: slackware
Posts: 328

Rep: Reputation: 74
xz/lzma is the current compression for slackware packages (obviously not all, like xz pakcage itself)

take a look at /sbin/installpkg, there is a case construct to determine which compression utility should be used: tgz/gzip, tbz/bzip2, tlz/lzma, txz/xz; for other extensions, installpkg will refuse to operate on the package
 
Old 04-22-2014, 03:48 PM   #3
Didier Spaier
LQ Addict
 
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-15.0
Posts: 11,210

Rep: Reputation: Disabled
installpkg is very versatile and can handle several package compression methods, as shows this code snippet:
Code:
    case $packageext in
    'tgz' )
      packagecompression=gzip
      ;;
    'tbz' )
      packagecompression=bzip2
      ;;
    'tlz' )
      packagecompression=lzma
      ;;
    'txz' )
      packagecompression=xz
      ;;
    esac
All compression utilities listed honor the " -dc" option and of course should be present.

Last edited by Didier Spaier; 04-22-2014 at 03:53 PM.
 
Old 04-22-2014, 03:58 PM   #4
stf92
Senior Member
 
Registered: Apr 2007
Location: Buenos Aires.
Distribution: Slackware
Posts: 4,442

Original Poster
Rep: Reputation: 76
Well,
Code:
root@local:/mnt/cd0/slackware/a# installpkg -warn lilo-23.2-i486-3.txz
#### Scanning the contents of lilo-23.2-i486-3.txz...
The following files will be overwritten when installing this package.
Be sure they aren't important before you install this package:

gzip: stdin: not in gzip format
tar-1.13: Child returned status 1
tar-1.13: Error exit delayed from previous errors

root@local:/mnt/cd0/slackware/a#
this is because this is installpg from slackware 12.0. But using that from 14.0 installpkg did not complain. And based on what Didier posted, I take it is perfectly correct to install a .txz package with the new installpkg. Am I right?
 
Old 04-22-2014, 04:19 PM   #5
ruario
Senior Member
 
Registered: Jan 2011
Location: Oslo, Norway
Distribution: Slackware
Posts: 2,557

Rep: Reputation: 1763Reputation: 1763Reputation: 1763Reputation: 1763Reputation: 1763Reputation: 1763Reputation: 1763Reputation: 1763Reputation: 1763Reputation: 1763Reputation: 1763
You can change the compression as follows:

Code:
xzdec lilo-23.2-i486-3.txz | gzip > lilo-23.2-i486-3.tgz
Assuming you use Slackware 14.0 or locally compile xzdec.

P.S. Generally it is not a great idea to install packages intended for 14.0 in an older version.

Last edited by ruario; 04-22-2014 at 04:48 PM. Reason: added shelr.tv link
 
Old 04-22-2014, 04:21 PM   #6
Didier Spaier
LQ Addict
 
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-15.0
Posts: 11,210

Rep: Reputation: Disabled
What I wrote in my previous post stands for Slackware 14.0. Back in 2007 when Slackware 12.0 was released installpkg only dealt with gzip.

Furthermore why would you use installpkg from 12.0 to install a package intended for a later release?

PS I didn't see ruario's answer before posting but if you aim was actually to upgrade lilo on 12.0 (maybe because old lilos can't install new kernels as too big), then you should build yourself a newer lilo package on Slackware 12.0.

In any case if you're still using Slackware 12.0 I suggest that you upgrade as this version is no more maintained, so possible security holes will remain open.

Last edited by Didier Spaier; 04-22-2014 at 04:38 PM.
 
Old 04-22-2014, 04:40 PM   #7
ruario
Senior Member
 
Registered: Jan 2011
Location: Oslo, Norway
Distribution: Slackware
Posts: 2,557

Rep: Reputation: 1763Reputation: 1763Reputation: 1763Reputation: 1763Reputation: 1763Reputation: 1763Reputation: 1763Reputation: 1763Reputation: 1763Reputation: 1763Reputation: 1763
You may well already know this but in case you don't, Slackware 12.0 has been end of lifed and does not receive security updates (since the 27th of July 2012).
 
Old 04-22-2014, 04:46 PM   #8
ruario
Senior Member
 
Registered: Jan 2011
Location: Oslo, Norway
Distribution: Slackware
Posts: 2,557

Rep: Reputation: 1763Reputation: 1763Reputation: 1763Reputation: 1763Reputation: 1763Reputation: 1763Reputation: 1763Reputation: 1763Reputation: 1763Reputation: 1763Reputation: 1763
Quote:
Originally Posted by stf92 View Post
I take it is perfectly correct to install a .txz package with the new installpkg. Am I right?
It is fine to install .txz packages on Modern Slackware but not on 12.0.
 
Old 04-22-2014, 04:49 PM   #9
TobiSGD
Moderator
 
Registered: Dec 2009
Location: Germany
Distribution: Whatever fits the task best
Posts: 17,148
Blog Entries: 2

Rep: Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886
Quote:
Originally Posted by stf92 View Post
Hi: installpkg makes no objections when given a .xz packages. Does it manage them correctly? It would be more logical that xz understands and correctly manages .tgz packages, which is my second question.
Not only can pkgtools handle .txz packages, since version 13.0 xz-compression is the default for Slackware packages.
 
Old 04-22-2014, 05:18 PM   #10
stf92
Senior Member
 
Registered: Apr 2007
Location: Buenos Aires.
Distribution: Slackware
Posts: 4,442

Original Poster
Rep: Reputation: 76
Quote:
Originally Posted by Didier Spaier View Post
(maybe because old lilos can't install new kernels as too big)
That is precisely the case. When giving lilo the path to the kernel image for the Debian 7.4 kernel, he complain: ""Fatal: Setup length exceeds 31 muximum; kernel setup will overwrite boot loader" (I opened a thread about this). To solve the issue in the old lilo, I booted from the slackware 14.0 disk, and let the installer to proceed as if installing in an empty hard disk. I got the prompt, and not finding lilo (every candidate path was in $PATH but 'lilo' got 'Command not found') I went to /slackware/a/ and ran installpkg on the lilo package. However, when I ran this lilo, I got "Fatal: trying to map files from unnamed device 0x001". What I am now doing is to install 14.0. In an hour I will be running lilo under 14.0 installed on the hard and will see what happens.
 
Old 04-23-2014, 04:03 AM   #11
ruario
Senior Member
 
Registered: Jan 2011
Location: Oslo, Norway
Distribution: Slackware
Posts: 2,557

Rep: Reputation: 1763Reputation: 1763Reputation: 1763Reputation: 1763Reputation: 1763Reputation: 1763Reputation: 1763Reputation: 1763Reputation: 1763Reputation: 1763Reputation: 1763
Quote:
Originally Posted by ruario View Post
Generally it is not a great idea to install packages intended for 14.0 in an older version.
To continue on from this point, if you had really wanted to stick with Slackware 12.0 for some reason (even though it no longer receives security updates). The correct thing to do would have been to rebuild a more recent Lilo on 12.0 itself. This could be achieved as follows.

Fetch and unpack the Lilo source and SlackBuild files to a suitable directory:

Code:
$ mkdir -p /tmp/staging
$ cd /tmp/staging
$ lftp -c 'open http://mirrors.slackware.com/slackware/slackware-14.1/source/a/; mirror -x ".*\.mirrorlist" lilo'
Tweak lilo.SlackBuild to produce an .tgz package instead of a .txz package:

Code:
$ sed -i '/makepkg/s/txz$/tgz/' /tmp/staging/lilo/lilo.SlackBuild
Switch to root and run the SlackBuild:

Code:
$ su -
# cd /tmp/staging/lilo
# sh lilo.SlackBuild
Upgrade Lilo:

Code:
# upgradepkg /tmp/lilo-24.0-i486-4.tgz
If you have now decided to move to a more recent Slackware instead, why not go directly to 14.1 so that support lasts as long as possible.

Last edited by ruario; 04-23-2014 at 04:13 AM. Reason: spelling; removed redundant mirror options
 
Old 04-23-2014, 12:26 PM   #12
stf92
Senior Member
 
Registered: Apr 2007
Location: Buenos Aires.
Distribution: Slackware
Posts: 4,442

Original Poster
Rep: Reputation: 76
Thank you for those instructions. I've been running 14.0 for a while now. But I don't like to change the OS as if it were the shirt. I observe that the trend is towards transforming the computer into a thing not unlike the television set, or a vacuum cleaner. A thing that can be comfortably operated by everybody. Things like USB and udev find their justification in the public acceptance, ease of use. But they introduce huge amounts of complexity. And why? So that my sister can plug in her camera into the computer and organize her pictures?

What about the common people like me? They have enormously complicated my life. To Hell with USB and udev and all unnecessary "improvements" whose only aim is to increase sales. To Hell with multimedia. To Hell with color itself and graphical user interfaces. The aim is to make computers controllable by an imbecile. But that which for an imbecile can be easy is infinitely complicated for me. I don't know why but it turns up to be so. I'm very sorry if this seems extemporaneous.
 
Old 04-24-2014, 01:19 AM   #13
gnashley
Amigo developer
 
Registered: Dec 2003
Location: Germany
Distribution: Slackware
Posts: 4,928

Rep: Reputation: 613Reputation: 613Reputation: 613Reputation: 613Reputation: 613Reputation: 613
What sort of pacakges have the .tar.xz suffix?? The only thing I can think of is that you might be trying to install packages meant for archlinux -which is not a good idea.
 
Old 04-24-2014, 01:37 AM   #14
kikinovak
MLED Founder
 
Registered: Jun 2011
Location: Montpezat (South France)
Distribution: CentOS, OpenSUSE
Posts: 3,453

Rep: Reputation: 2154Reputation: 2154Reputation: 2154Reputation: 2154Reputation: 2154Reputation: 2154Reputation: 2154Reputation: 2154Reputation: 2154Reputation: 2154Reputation: 2154
Quote:
Originally Posted by stf92 View Post
What about the common people like me? They have enormously complicated my life. To Hell with USB and udev and all unnecessary "improvements" whose only aim is to increase sales. To Hell with multimedia. To Hell with color itself and graphical user interfaces. The aim is to make computers controllable by an imbecile. But that which for an imbecile can be easy is infinitely complicated for me. I don't know why but it turns up to be so. I'm very sorry if this seems extemporaneous.
You might want to replace your PC by an abacus.
 
Old 04-24-2014, 02:07 AM   #15
Didier Spaier
LQ Addict
 
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-15.0
Posts: 11,210

Rep: Reputation: Disabled
Quote:
Originally Posted by kikinovak View Post
You might want to replace your PC by an abacus.
This reminds me of a trip I made to China back in 1988. I went to a currency exchange office to change US $ in renminbin yuans. A first employee took the dollars, used a pocket calculator to compute how many yuans I should get, then checked the result with an abacus. She then handed over her results to a second employee who gave me the yuans. Oh, and that was the last time I traveled in a steam train. Nostalgy...

Last edited by Didier Spaier; 04-24-2014 at 02:13 AM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] How to uninstall packages installed via compiling and installpkg? rubankumars Slackware 1 04-08-2014 08:44 PM
Unable to install packages with installpkg Sargalus Linux - Software 2 03-07-2010 06:48 PM
Installpkg ignoring tar-1.13; throwing up warning while installing packages corbis_demon Slackware 2 09-07-2009 04:44 AM
something about installpkg tintilin Slackware 5 11-26-2004 01:13 AM
help with installpkg mep]-[isto Slackware 3 11-19-2003 03:27 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 06:57 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration