LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   How to use changelog to update Slackware package? (https://www.linuxquestions.org/questions/slackware-14/how-to-use-changelog-to-update-slackware-package-477889/)

JockVSJock 08-27-2006 05:59 PM

How to use changelog to update Slackware package?
 
Ok, so I've been burnt twice using Swaret to update/upgrade packages

http://www.linuxquestions.org/questi...d.php?t=468883

Many have recommended to read the Slackware changelog before doing anything

ftp://ftp.slackware.com/pub/slackwar.../ChangeLog.txt

It needs to be asked, how does one use or what is the best way to use the changelog to update/upgrade packages without getting burnt or running into problems?

thanks

kodon 08-27-2006 06:24 PM

not entirely sure what you mean

the changelog is fairly self-explanatory
eg: added X package and rebuilt Y against X etc

JockVSJock 08-27-2006 07:03 PM

So I have some x11 packages that need to update/upgraded

Code:

New: x11-6.9.0-i486-9 (18811 kB) - Installed: x11-6.9.0-i486-5
New: x11-devel-6.9.0-i486-9 (5001 kB) - Installed: x11-devel-6.9.0-i486-5
New: x11-xdmx-6.9.0-i486-9 (871 kB) - Installed: x11-xdmx-6.9.0-i486-5
New: x11-xnest-6.9.0-i486-9 (1397 kB) - Installed: x11-xnest-6.9.0-i486-5
New: x11-xvfb-6.9.0-i486-9 (1534 kB) - Installed: x11-xvfb-6.9.0-i486-5

If I look thru the changelog this is what I'm finding:

Code:

x11-6.9.0-i486-9
So what do I do here? The changelog says this:

Code:

x/x11-6.9.0-i486-9.tgz:  Patched a PCF font parsing bug that could crash X.
  Fixed the Greek keyboard layout.  Thanks to Thanos Kyritsis.
  Fixed ATI lockup bugs.  Thanks to Mark Canter.

Grab the package from linuxpackages, put it in the directory it currently exist, and run upgradepkg? Is there anything that I have to be aware of?

Here are the other ones that I'm pulling out the changelog, cause I seem to have problems with x11 when it comes to update/upgrading packages

Code:

x/x11-xdmx-6.9.0-i486-9.tgz:  Recompiled.
x/x11-xnest-6.9.0-i486-9.tgz:  Recompiled.
x/x11-xvfb-6.9.0-i486-9.tgz:  Recompiled.

thanks for you help in advance...

ryanoa 08-27-2006 08:17 PM

If you are running current you will find those packages in the corresponding directory (a,n,etc) on any slackware mirror.If you are running 10.2 they will be in the patches directory. Download them to your box, and ,as root, run:

upgradepkg xxxx

(where xxxx is the complete name of the package, for example: upgradepkg x11-xvfb-6.9.0-i486-9.tgz)

This will replace the old package with the new one. Doesn't get much easier. I've been screwed by swaret also and decided this was a much safer aprroach for me. One less layer to screw up.

ps--you may need to restart some services that are upgraded

Ryan

shilo 08-27-2006 09:04 PM

The important part to reading the changelog is looking for re-named packages, removed packages, an split packages. For instance, you are looking at upgrading x11. An important entry in the changelog is:
Quote:

x/fontconfig-2.2.3-i486-1.tgz: Split fontconfig into a separate package.
Look, we're modularizing for ease of maintainance! :-)
x/freetype-2.1.9-i486-1.tgz: Split freetype into a separate package.
Patched CVE-2006-1861 linux 2.6.x setuid() related bugs.
(* Security fix *)
x/x11-6.9.0-i486-5.tgz: Rebuilt. Removed fontconfig/freetype files.
Patched some more possible linux 2.6.x setuid() related bugs:
http://lists.freedesktop.org/archive...ne/000100.html
(* Security fix *)
x/x11-devel-6.9.0-i486-5.tgz: Rebuilt. Removed fontconfig/freetype files.
Patched with setuid() usage fixes as described above. Again, this issue
is only vulnerable on certain 2.6 kernels.
(* Security fix *)
x/x11-docs-6.9.0-noarch-5.tgz: Rebuilt. Removed fontconfig/freetype files.
This means that you need to not just upgrade the x11 packages, but you also have to add the new fontconfig and freetype packages.

kodon 08-27-2006 09:05 PM

do not upgrade your official packages with linuxpackages.net packages

the recompiled in your example just indicates
that there weren't any changes to those packages
basically, just keeping the build numbers consistent

as long as you're not touching kernel* lilo glibc* aaa*
and you read the entire changelog relating to your upgrade
and take the necessary actions (adding new packages that
others depend on, upgrading other existing packages that
packages depend on, etc) you should be fine

for instance, if a while back you upgraded x11
and hadn't read that some packages were split out of it
and hadn't installed those new packages...
most everybody would have told you to read the changelog

---

'doh!

Franklin 08-27-2006 09:07 PM

What you do will depend on what you are running to some degree.

I have been running -current for a long time and it is easier for me to maintain my own copy of the entire -current tree on my server. I do this with a script that makes use of rsync. I then run upgradepkge --install-new against the entire tree to upgrade what has been upgraded and install any new additions. Anything removed I remove myself using pkgtool or removepkg.

I plan to stick with the stable release when slackware 11.0 is officially released. In that situation, I would only check the "patches" directory for official packages to install using "upgradepkg patchname.tgz".

In either case, the changelog will tell you what changes have happened and why. Then you go out and get them. Pretty simple.

Examples of mirrors for rsync would be:

ftp://carroll.cac.psu.edu/pub/linux/...ons/slackware/
ftp://inferno.bioinformatics.vt.edu/slackware/
ftp://rsync.osuosl.org/pub/slackware

These are just ftp sites that allow rsync. If you poke arround you will see how they are set up. There are directories for each release much like a repository except all the packages are official slackware packages. rsync is nice in that it only downloads the changes - nice for -current which gets changed often. If you start by copying the install disks to your drive, then you will only download the changes (at this point there have been many so maybe wait till 11 ;))

Check the stable trees while you are out there. You will see a directory called patches. If you are only running the stable release and have the install disks then all you need to download when indicated is the contents of the patches directory. Example:

ftp://rsync.osuosl.org/pub/slackware...tches/packages

I will include the script I use to rsync. It's pretty simple and mostly self-explanatory. I found it on usenet and made minor changes. I call it "check-current" and -c checks only, -d downloads. I put it in /usr/local/bin and make it executable.

Code:

#!/bin/bash
#
# Check slackware-current
#

# Where to download from

#SOURCE="rsync://carroll.cac.psu.edu/slackware/slackware-current"
#SOURCE="rsync://inferno.bioinformatics.vt.edu/slackware/slackware-current"

SOURCE="rsync://rsync.osuosl.org::/slackware/slackware-current"

# Change as necessary

  OPTIONS="-avzP --delete --delete-after"

  EXCLUDE="--exclude=pasture --exclude=kdei --exclude=source --exclude=zipslack"

  DEST="/nfs/slack"  # change this to the location of your "slackware-current" directory

# end options

case "$1" in

 "-c" )
 echo "Checking..."
 /usr/bin/rsync $OPTIONS $EXCLUDE --dry-run $SOURCE $DEST
 ;;

 "-d" )
 echo "Downloading..."
 /usr/bin/rsync $OPTIONS $EXCLUDE $SOURCE $DEST
 ;;
 
 * )
 echo "Usage: `basename $0` {-c|-d}"
 echo -e "\t-c : Check for updates"
 echo -e "\t-d : Download updates"
 exit
 ;;

esac

Real basic stuff, but I'm not a computer person (relatively speaking).
Read man rsync to understand the options.

Alien Bob posted links his that also creates isos for you (very nice!)
The thread is here:

http://www.linuxquestions.org/questi...d.php?t=467212

Sorry if this is over-kill on the question, but I remember being clueless regarding the same things.

As usual, the doing is the easy part. Figuring out what to do is harder.

HTH

JockVSJock 09-09-2006 06:56 PM

Ok so I'm updating my packages by hand.

For example, the first one I've upgraded was libtiff...
Let me know if I'm doing this right.

First I go to

ftp://ftp.slackware.com/pub/slackwar.../ChangeLog.txt

Use cntl + f to find libtiff and it returns this...

Code:

+--------------------------+
Fri Aug 18 00:20:46 CDT 2006
a/aaa_elflibs-11.0.0-i486-8.tgz:  Upgraded to the mm-1.4.2 library, patched
  libtiff, upgraded to pcre-6.7 libraries, and included the recompiled
  cups-1.1.23 and slang libraries.
a/cups-1.1.23-i486-4.tgz:  Fixed broken es and fr man page symlinks.
d/git-1.4.2-i486-1.tgz:  Upgraded to git-1.4.2.
kde/kdenetwork-3.5.4-i486-2.tgz:  Patched a bug in kopete that could freeze
  KDE under certain circumstances.  Thanks to JaguarWan and Olivier Goffart.
l/libtiff-3.8.2-i486-2.tgz:  Patched vulnerabilities in libtiff which were
  found by Tavis Ormandy of the Google Security Team.  These issues could
  be used to crash programs linked to libtiff or possibly to execute code
  as the program's user.  A low risk command-line overflow in tiffsplit was
  also patched.

So I don't see anything it will break if I upgradepkg, which is kewl, if I'm reading this right...

Next step, is that I hit the following url:

ftp://rsync.osuosl.org/pub/slackware...2/slackware/l/

Cntl + F and find libtiff and d/l it

Use whereis to find libtiff

Code:

root@probot:/etc/gimp/2.0# whereis libtiff
libtiff: /usr/lib/libtiff.la /usr/lib/libtiff.a /usr/lib/libtiff.so /usr/local/lib/libtiff /usr/local/lib/libtiff.so /usr/local/lib/libtiff.la /usr/local/lib/libtiff.a /usr/man/man3/libtiff.3tiff.gz /usr/share/man/man3/libtiff.3tiff.gz

So I move the package to /usr/lib, this looks right to me...right?

Change permission on the package and run

Code:


root@probot:/usr/lib# upgradepkg libtiff-3.8.2-i486-1_slack10.2.tgz

+==============================================================================
| Upgrading libtiff-3.7.3-i486-1 package using ./libtiff-3.8.2-i486-1_slack10.2.tgz
+==============================================================================

Pre-installing package libtiff-3.8.2-i486-1_slack10.2...

Removing package /var/log/packages/libtiff-3.7.3-i486-1-upgraded-2006-09-09,16:44:26...
  --> Deleting /usr/doc/libtiff-3.7.3/COPYRIGHT
  --> Deleting /usr/doc/libtiff-3.7.3/README
  --> Deleting /usr/doc/libtiff-3.7.3/RELEASE-DATE
  --> Deleting /usr/doc/libtiff-3.7.3/TODO
  --> Deleting /usr/doc/libtiff-3.7.3/VERSION
  --> Deleting /usr/lib/libtiffxx.so.3.7.3
  --> Deleting empty directory /usr/doc/libtiff-3.7.3/

Installing package libtiff-3.8.2-i486-1_slack10.2...
PACKAGE DESCRIPTION:
libtiff: libtiff (a library for reading and writing TIFF files)
libtiff:
libtiff: This package provides support for the Tag Image File Format (TIFF),
libtiff: a widely used format for storing image data.  Included is the libtiff
libtiff: library (for reading and writing TIFF files), and a collection of
libtiff: tools for working with TIFF images.
libtiff:
Executing install script for libtiff-3.8.2-i486-1_slack10.2...

Package libtiff-3.7.3-i486-1 upgraded with new package ./libtiff-3.8.2-i486-1_slack10.2.tgz.


So that's it for libtiff, I have a bunch more I have to do...let me know if I'm doing right, and I'm sure I'll have more questions...

thanks!!!

shilo 09-09-2006 09:46 PM

Quote:

Originally Posted by JockVSJock
Use whereis to find libtiff

Code:

root@probot:/etc/gimp/2.0# whereis libtiff
libtiff: /usr/lib/libtiff.la /usr/lib/libtiff.a /usr/lib/libtiff.so /usr/local/lib/libtiff /usr/local/lib/libtiff.so /usr/local/lib/libtiff.la /usr/local/lib/libtiff.a /usr/man/man3/libtiff.3tiff.gz /usr/share/man/man3/libtiff.3tiff.gz

So I move the package to /usr/lib, this looks right to me...right?

Change permission on the package and run

Code:


root@probot:/usr/lib# upgradepkg libtiff-3.8.2-i486-1_slack10.2.tgz

thanks!!!

You have some extra stuff that you are doing that is not needed. No need to move libtiff-3.8.2-i486-1_slack10.2.tgz to /usr/lib. It will get installed where it needs to be no matter where it is located. Also, there is no need to change permissions on the package. The files contained in the tarball (package) should already have the correct permissions.

The only really interesting thing is that it looks like you have manually installed libtiff in the past (find shows it is in /usr/local/lib). You may want to remove that so that you don't have any conflicts.

JockVSJock 09-10-2006 01:27 PM

Quote:

Originally Posted by shilo
You have some extra stuff that you are doing that is not needed. No need to move libtiff-3.8.2-i486-1_slack10.2.tgz to /usr/lib. It will get installed where it needs to be no matter where it is located. Also, there is no need to change permissions on the package. The files contained in the tarball (package) should already have the correct permissions.

The only really interesting thing is that it looks like you have manually installed libtiff in the past (find shows it is in /usr/local/lib). You may want to remove that so that you don't have any conflicts.


So I don't get it. What directory do I install the pkg too?

And, I've never installed anything by hand before, I've always used slapt-get to update my packages. When I ran upgradepkg, it
said it was successful...?

thanks

shilo 09-10-2006 01:51 PM

Quote:

Originally Posted by JockVSJock
So I don't get it. What directory do I install the pkg too?

You don't have to install "to" a specific directory. Slackware packages are just tarred and gzipped binaries. pkgtools and friends will install them to / regardless of where the package is when you run the install/upgrade command.

Quote:

Originally Posted by JockVSJock
And, I've never installed anything by hand before, I've always used slapt-get to update my packages. When I ran upgradepkg, it
said it was successful...?

It was successful, you just don't need the extra steps. :) The package will install/upgrade from anywhere, so there is no need to move the package or change it's permissions. Furthermore, there is no reason to run the whereis.

Though running whereis was not needed, it did point out that you have some packages installed to /usr/local. You may want to look through there to see what else you have installed to /usr/local.

Franklin 09-10-2006 06:38 PM

Quote:

So I don't get it. What directory do I install the pkg too?
Maybe an example would help you understand things better.

Generally, there are 3 main places where programs get installed:

/usr
/usr/local
/opt

Many distros put KDE in /opt, but some (like Debian) do not. You can really put things anywhere, but if you are making packages for others, it is best to keep with convention.

Lets say I want to install the KDE app digikam. In Slackware, this program is not included by default. If I were to compile from source, I would do the

./configure
make
make install

BUT, before I did that I would check the options I could enable or disable when I compile the program by entering the following:

./configure -h or
./configure --help

One of the options to choose would be where I wanted to install the program. This is done by using the "prefix=" option. A program will always have a default location, but you can always change that by using this flag.

KDE programs - like digikam - usually have a default location of prefix=/opt/kde. If I were running a distro that had KDE in /usr, I might want to change the install location to /usr by using the "prefix=/usr" flag.

Others users will only install new (added) programs to /usr/local and, if /usr/local is on it's own partition, this can have some benefits if a re-install is ever needed.

Regardless, the point to take home here is that the location where a "package" is installed is determined at compile time "by the person who created the package". You, as a person installing foo.tgz with installpkg or pkgtool, don't need to be concerned about this because the decision has been made allready.

For example, if I created a digikam.tgz package with prefix=/usr/local, then everyone who used that package would have digikam installed to /usr/local with the binary in /usr/local/bin. If I built the package using the default (/opt/kde) then everyone who used that package would have it installed to /opt/kde and the binary would be found in /opt/kde/bin.

A package is a "precompiled program" in the form that is particular to a given distro: rpm for redhat etc., deb for debian etc., and tgz for slackware. Installing a program in package form vs. /configure, make,make_install is benificial in that it is easier to install, uninstall, or upgrade programs when they are installed this way.

When people create a slackware package like digikam.tgz, the location and other compile-time options have allready been determined by the person who made that package. If you got your package from a reputable source, then they will have followed established practices for slackware package-building and the program will be placed where it is expected to be found. But, even if they - or you for that matter - chose a different location, things will still work fine so long as the system and any other programs that might depend on that program know where to look for the libraries. This is done using ldconfig and the /etc/ld.so.conf file.

This was a very quick overview. I'm sure if I left something important out it will be posted.

HTH

JockVSJock 09-11-2006 11:57 AM

Quote:

Originally Posted by Franklin

Regardless, the point to take home here is that the location where a "package" is installed is determined at compile time "by the person who created the package". You, as a person installing foo.tgz with installpkg or pkgtool, don't need to be concerned about this because the decision has been made allready.

Thanks for the writeup, and this does help.

I will post more to this thread as I continue to upgrade my packages manually.

JockVSJock 09-16-2006 04:57 PM

UPDATE:

So I updated all of my packages, but I used slapt-get.

Let me tell you why...

I was trying to use upgradepkg and pkgtool to upgrade Gimp. After reading thru the changelog, I though should be no problem.

Got the package and tried to install it but the package was corrupt, it was late at night..too tired...so I said to hell with it.

Grabbed the latest Gimp package from linuxpackages and then ran slapt-get and everything went ok.

Now I still have to upgrade some X11 packages on my main PC, so I will have to do these by hand becaues this is the machine I've had problems on the in past.

thanks again everyone...

liquidtenmilion 09-17-2006 04:00 PM

You are not supposed to upgrade from linuxpackages.net

ftp://ftp.slackware.no/pub/Linux/sla.../ChangeLog.txt

Is the current changelog for slackware stable. Just open that in a browser and look at the most recent entries(Every entry since the last time you upgraded).

Quote:

Thu Sep 14 19:44:27 CDT 2006
patches/packages/mozilla-firefox-1.5.0.7-i686-1.tgz:
Upgraded to firefox-1.5.0.7.
This upgrade fixes several possible security bugs.
For more information, see:
http://www.mozilla.org/projects/secu...s.html#firefox
(* Security fix *)
patches/packages/mozilla-thunderbird-1.5.0.7-i686-1.tgz:
Upgraded to thunderbird-1.5.0.7.
This upgrade fixes several possible security bugs.
For more information, see:
http://www.mozilla.org/projects/secu...ml#thunderbird
(* Security fix *)
This is an example of part of the changelog. Notice the bold packages? those are what need to be updated.

You can find those packages inside this directory right here.

ftp://ftp.slackware.no/pub/Linux/sla...tches/packages

Just download the .tgz and run "upgradepkg filename.tgz" and then you can delete the TGZ. That is all. It's really very simple.


All times are GMT -5. The time now is 02:42 AM.