glibc upgrade

How to do things, solutions, recipes, tutorials
Message
Author
User avatar
Monsie
Posts: 631
Joined: Thu 01 Dec 2011, 07:37
Location: Kamloops BC Canada

glibc upgrade

#16 Post by Monsie »

Thank you jamesbond and pemasu for the clarification.

So Wary Puppy does include glibc2 by default --just not the version needed to run OpenOffice?

It may be that I am most confused by the file names and versioning... Hmm... it wouldn't be the first time I was confused... :? :roll: That said, I owe simargl an apology for having misunderstood what he was trying to tell me.

In the readme file for OpenOffice 3.4 here are the system requirements:

* Linux Kernel version 2.6.18 or higher
* glibc2 version 2.5 or higher
* gtk version 2.10.4 or higher
* Pentium compatible PC (Pentium III or Athlon recommended)
* 256 MB RAM (512 MB RAM recommended)
* Up to 1.55 GB available hard disk space
* X Server with 1024x768 resolution (higher resolution recommended), with at least 256 colors
* Window Manager
* Gnome 2.16 or higher, with the gail 1.8.6 and the at-spi 1.7 packages, required for support of assistive technology tools (AT tools)
Notice that it refers to glibc2 yet in Wary Puppy I can only find reference to glibc in Puppy Package Manager and when I do a file search of my system. (By the way, PPM shows glibc -2.6.1.-1 in the repos as the latest version.) So my conclusion was that Wary Puppy does not have glibc2, hence the confusion. In short, "it's all in the languaging" so-to-speak.

While I have installed the glibc2 package from the download link provided by Tman and it appears to have not caused any problems, yet, I will heed your warnings that this upgrade could be risky and advise everyone to make sure they have backed up their important files before doing this update so as to try running Apache OpenOffice.

Monsie
My [u]username[/u] is pronounced: "mun-see". Derived from my surname, it was my nickname throughout high school.

jamesbond
Posts: 3433
Joined: Mon 26 Feb 2007, 05:02
Location: The Blue Marble

Re: glibc upgrade

#17 Post by jamesbond »

Monsie wrote:Thank you jamesbond and pemasu for the clarification.
No worries, we're helping each other here.
So Wary Puppy does include glibc2 by default just not the version needed to run OpenOffice?
Correct. glibc, glibc2, libc6 - all those are just packaging names. I just pulled out my copy of Wary 5.0 (the first ever Wary) and it came with glibc 2.10.1 - the same as the pet pointed by pemasu above.
In the readme file for OpenOffice 3.4 here are the system requirements:

* Linux Kernel version 2.6.18 or higher
* glibc2 version 2.5 or higher
* gtk version 2.10.4 or higher
* Pentium compatible PC (Pentium III or Athlon recommended)
* 256 MB RAM (512 MB RAM recommended)
* Up to 1.55 GB available hard disk space
* X Server with 1024x768 resolution (higher resolution recommended), with at least 256 colors
* Window Manager
* Gnome 2.16 or higher, with the gail 1.8.6 and the at-spi 1.7 packages, required for support of assistive technology tools (AT tools)
It said it requires glibc 2.5 - so by logic it should work with Wary's glibc, which is 2.10.1 (newer than 2.5). Why it doesn't work, I have no idea :shock:
Notice that it refers to glibc2 yet in Wary Puppy I can only find reference to glibc in Puppy Package Manager and when I do a file search of my system.
Yes, it's just packaging names.
(By the way, PPM shows glibc -2.6.1.-1 in the repos as the latest version.) So my conclusion was that Wary Puppy does not have glibc2, hence the confusion. In short, "it's all in the languaging" so-to-speak.
Not your fault. The names have changed a couple of times, and to make it more confusing every distro may package / name them differently. Look at Barry's exasperation with Ubuntu's package splitting (and naming) :lol: But Wary does have "glibc2". In fact, it is better to state the version - Wary has glibc 2.10.1. Now, why PPM only shows glibc 2.6.1, I believe that's another problem as pemasu has pointed out that glibc-2.10.1-1-w5c.pet is in fact available in Wary's PPM repository.
While I have installed the glibc2 package from the download link provided by Tman and it appears to have not caused any problems, yet, I will heed your warnings that this upgrade could be risky and advise everyone to make sure they have backed up their important files before doing this update so as to try running Apache OpenOffice.
I think the practice of replacing glibc is quite popular in Puppy community. As long as people are aware of the consequences (and hopefully able to undo the damage if it happens), then that's fine.

cheers!
Fatdog64 forum links: [url=http://murga-linux.com/puppy/viewtopic.php?t=117546]Latest version[/url] | [url=https://cutt.ly/ke8sn5H]Contributed packages[/url] | [url=https://cutt.ly/se8scrb]ISO builder[/url]

amigo
Posts: 2629
Joined: Mon 02 Apr 2007, 06:52

#18 Post by amigo »

There is no such thing as 'glibc2'. libc is a generic name for any of the c-lib alternatives. libc5 was the old original (circa Slackware 8.0 and older). When the glibc(GNU libc) project was started, they used the alternate name 'libc6' since it was not binary-compatrible with libc5.

I'm wondering if someone hasn't been confusing glibc2 with glib2??

Anyway, the whole idea of upgrading glibc without doing a complete upgrade is bound to fail -at some point. Nerly everything on your system uses glibc -fully-statically-linked programs being the exception (like /sbin/init -the real one, which Puppy does not have).
If you simply upgrade glibc and not all the rest, then you run the risk of having old programs not be compatible with the new glibc -resulting in hard-to-diagnose failures.

If you need a newer glibc for a certain program, then place the newer glibc in some out-of-the-way path and write a wrapper for the program which adds LD_LIBRARY_PATH to point to the newer library. This avoids all conflicts.

Dewbie

#19 Post by Dewbie »

amigo wrote:
If you need a newer glibc for a certain program, then place the newer glibc in some out-of-the-way path and write a wrapper for the program which adds LD_LIBRARY_PATH to point to the newer library. This avoids all conflicts.

Can anyone demonstrate how to do this, in steps?

User avatar
01micko
Posts: 8741
Joined: Sat 11 Oct 2008, 13:39
Location: qld
Contact:

#20 Post by 01micko »

Put the updated glibc libraries in a folder, lets say $HOME/newer-glibc

Now, let's say the program you want to run is google-chrome.

Write a script called google-chrome.sh:

Code: Select all

#!/bin/bash
LD_LIBRARY_PATH=$HOME/newer-glibc:$LD_LIBRARY_PATH
exec google-chrome "$@"
Put that script in your executable path and call it however you like.

NOTE: just an example for demo purposes
Puppy Linux Blog - contact me for access

Dewbie

#21 Post by Dewbie »

01micko wrote:
Put that script in your executable path and call it however you like.
Thanks, Mick. :)
Does this mean I can open a Window / Terminal Here in the folder, then write the script?

Edit:
(See below)
Thanks, amigo. :)
Last edited by Dewbie on Mon 07 Jan 2013, 09:37, edited 1 time in total.

amigo
Posts: 2629
Joined: Mon 02 Apr 2007, 06:52

#22 Post by amigo »

Browse with the filer to a place in your PATH, then right-click on the filer window and choose New -> File. Then open the new file with an editor and compose/paste your script and save. Be sure to make the file executable so it can be run.

watchdog
Posts: 2021
Joined: Fri 28 Sep 2012, 18:04
Location: Italy

Glibc or glibc2?

#23 Post by watchdog »

The Debian packages site reported that glibc is a virtual package of what you name glibc2 or libc6. I tried the 01micko suggestion in wary. With peazip I put the content of libc6 in a DIR. With the script launching Firefox I used the command LD_LIBRARY_PATH indicating the paths of the subdirectories of DIR with libc6 and I tried to install a recent google-talkplugin which needs glibc >= 2.11. I did have not success: error in the terminal "file too short" with a library of the debian libc6 package. Perhaps we should compile for wary glibc source:

http://ftp.gnu.org/gnu/glibc/

I don't have the skill to do this. With the compiled glibc (make install DESTDIR=DIR...) we should try the 01micko suggestion.

User avatar
Monsie
Posts: 631
Joined: Thu 01 Dec 2011, 07:37
Location: Kamloops BC Canada

Re: Glibc or glibc2?

#24 Post by Monsie »

watchdog wrote:Perhaps we should compile for wary glibc source:

http://ftp.gnu.org/gnu/glibc/

I don't have the skill to do this. With the compiled glibc (make install DESTDIR=DIR...) we should try the 01micko suggestion.
Compiling glibc from source is no easy feat... it could be called: The mother of all compilations :lol: An easier approach might be to re-work the debian package for libc6-2.11.3-4 It turns out that the debian package overwrites the existing libc files in Puppy. While it appears to work at first, attempts to un-install this package will break my Wary system... as I later found out... so be sure to have a backup in place.

I have re-packaged the debian files for libc6 using the local pathway. (In fact, the developers recommend compiling the source to the local directory so as not to risk breaking your existing configuration). While I have installed and un-installed my re-packaged Pet numerous times without any apparent repercussions, I cannot confirm that it works because I am having difficulties writing a workable script to test Apache OpenOffice.

Here is the script I wrote and put in /opt/openoffice.org3/program directory while following Mick's example:

Code: Select all

#!/bin/sh
LD_LIBRARY_PATH=$usr/local/lib:$LD_LIBRARY_PATH
exec soffice.bin "$@"
The script is executable, and the new libc files have full permissions also.

Here is an excerpt from my xerrors.log
/opt/openoffice.org3/program/soffice.bin: /lib/libc.so.6: version `GLIBC_2.11' not found (required by /opt/openoffice.org3/program/../basis-link/program/libsvt.so)
So it shows that OpenOffice does need libc6-2.11 or better... which means the system requirements in the documentation need to be updated.... but also, that OpenOffice is not able to detect the path to the newer libc6 files...

At this point, I have worked on this for two days, and now I feel stuck --ideas anyone?

Thanks,
Monsie
My [u]username[/u] is pronounced: "mun-see". Derived from my surname, it was my nickname throughout high school.

postfs1

Re: Glibc or glibc2?

#25 Post by postfs1 »

Monsie wrote:...
At this point, I have worked on this for two days, and now I feel stuck --ideas anyone?
...
Maybe there are some tools which will give statistics about realization of paths, which new version of library does require.

:arrow: http://www.graphviz.org/

:arrow: http://en.wikipedia.org/wiki/Strace
Information about the Internet page: Text is available under the Creative Commons Attribution-ShareAlike License; additional terms may apply. See Terms of Use for details.

User avatar
Semme
Posts: 8399
Joined: Sun 07 Aug 2011, 20:07
Location: World_Hub

#26 Post by Semme »

For examples sake, how would this poster pipe something like freshclam via script?

Code: Select all

#!/bin/bash 
LD_LIBRARY_PATH=$HOME/glibc-2.15:$LD_LIBRARY_PATH 
exec ???

jamesbond
Posts: 3433
Joined: Mon 26 Feb 2007, 05:02
Location: The Blue Marble

#27 Post by jamesbond »

Monsie,

I'm assuming you put the copy of debian's glibc in /usr/local/lib (is this what you call as the "local pathway"?).

Your code was:
#!/bin/sh
LD_LIBRARY_PATH=$usr/local/lib:$LD_LIBRARY_PATH
exec soffice.bin "$@"
It should be
#!/bin/sh
LD_LIBRARY_PATH=/usr/local/lib:$LD_LIBRARY_PATH
exec soffice.bin "$@"
Note: no dollar-sign in front of /usr/local/lib
Fatdog64 forum links: [url=http://murga-linux.com/puppy/viewtopic.php?t=117546]Latest version[/url] | [url=https://cutt.ly/ke8sn5H]Contributed packages[/url] | [url=https://cutt.ly/se8scrb]ISO builder[/url]

User avatar
Monsie
Posts: 631
Joined: Thu 01 Dec 2011, 07:37
Location: Kamloops BC Canada

glibc upgrade

#28 Post by Monsie »

jamesbond wrote:Monsie,

I'm assuming you put the copy of debian's glibc in /usr/local/lib (is this what you call as the "local pathway"?)

Your code was:
#!/bin/sh
LD_LIBRARY_PATH=$usr/local/lib:$LD_LIBRARY_PATH
exec soffice.bin "$@"
It should be
#!/bin/sh
LD_LIBRARY_PATH=/usr/local/lib:$LD_LIBRARY_PATH
exec soffice.bin "$@"
Note: no dollar-sign in front of /usr/local/lib
Thanks, jamesbond

Yes, that is what I refer to as the local pathway... and that small change to the script that I overlooked makes a lot of sense. :)

Unfortunately, I still cannot get the script to work. I think the script is okay, in and of itself so-to-speak, but just not quite what is needed here. OpenOffice looks for the libc files in the main /lib folder by default, and I suspect one or more of its (OpenOffice) existing files needs to be changed in order to point OpenOffice in the right direction... So far, I am unable to find such file(s) or related code.

I went to the Apache OpenOffice forums and found that indeed other users are having a problem with older libc files who want to run OpenOffice 3.4 --especially the Redhat folks. While I wasn't able to find the kind of answer to the problem here, I did find out that the Apache developers also compiled OpenOffice 3.4 for distros with glibc 2.5 -- i.e. older than glibc 2.11.1 the latter of which is a system requirement for the regular download of OpenOffice 3.4 --hope this isn't too confusing. So, it turns out that there is another easier solution for Wary Puppy users and OpenOffice 3.4 and I will post more about this in Mick's thread re: OpenOffice when I've had a chance to test this alternate version further.... hopefully, later today.

In the mean time, it would still be useful to resolve this issue of putting an upgraded glibc package in a safe location along with a working script to point where to load the necessary libc6 files...

Monsie
My [u]username[/u] is pronounced: "mun-see". Derived from my surname, it was my nickname throughout high school.

jamesbond
Posts: 3433
Joined: Mon 26 Feb 2007, 05:02
Location: The Blue Marble

#29 Post by jamesbond »

Actually, there was this large elephant sitting in my eye but I can't see (that is, I gave your incomplete not working advice :oops: ) ... the script should have been this:
#!/bin/sh
export LD_LIBRARY_PATH=/usr/local/lib:$LD_LIBRARY_PATH
exec soffice.bin "$@"
Note the "export" in blue colour :oops:
Fatdog64 forum links: [url=http://murga-linux.com/puppy/viewtopic.php?t=117546]Latest version[/url] | [url=https://cutt.ly/ke8sn5H]Contributed packages[/url] | [url=https://cutt.ly/se8scrb]ISO builder[/url]

User avatar
01micko
Posts: 8741
Joined: Sat 11 Oct 2008, 13:39
Location: qld
Contact:

#30 Post by 01micko »

Nah.. I'll take that one,triple :oops: :oops: :oops:
Puppy Linux Blog - contact me for access

darry1966

#31 Post by darry1966 »

on Puppy 4.12 I downloaded libc6_2.11.3-4_i386.deb and using deb2pet converted it to a .pet and have only had VLC grumble about not being able to set locale otherwise everything works especailly what I wanted Opera 12.15 with flash.

darry1966

Glibc upgrade

#32 Post by darry1966 »

Whoops has stuffed up pmount but can still mount by clicking on desktop icon of usb drive. Back to the drawing board.

watchdog
Posts: 2021
Joined: Fri 28 Sep 2012, 18:04
Location: Italy

#33 Post by watchdog »

darry1966 wrote:on Puppy 4.12 I downloaded libc6_2.11.3-4_i386.deb and using deb2pet converted it to a .pet and have only had VLC grumble about not being able to set locale otherwise everything works especailly what I wanted Opera 12.15 with flash.
About locale I have solved in wary 5.5 putting at the end of /etc/profile

Code: Select all

export LC_ALL=C

darry1966

Pmount and Glibc 2.11

#34 Post by darry1966 »

O.S. puppy linux 4.12.

Does anybody know why when installing Glibc 2.11 and 2.11 Glibc-bin that you can mount drives from the desktop. However mounting from Pmount proper (That is not clicking desktop icon - it dies??????).

Also is there a fix for this????????? anyone ???????

Dewbie

#35 Post by Dewbie »

(See amigo's warning earlier in this thread.)
With 4.1.2, Glibc 2.11 also causes usb-drive icons to pile up in the corner and breaks sGmixer.

However, the benefits still outweigh the costs...at least so far. 8)

Post Reply