[ale] upgrading glibcx to glibc2.2.4...........

Dow Hurst dhurst at kennesaw.edu
Sat Sep 20 00:50:26 EDT 2003


Ken,
If this fixes my email or is the broken email, I'd like to know. I am
curious about FreeBSD now that you've sparked my interest with the Linux
module.  Does this work under OS/X and also will all Linux apps run or
are their caveats to using the module?  Thanks,
Dow


>>> kwc at world.std.com 09/20/03 00:25 AM >>>
>Date: Fri, 19 Sep 2003 23:11:27 -0500
>From: Courtney Thomas <ccthomas at joimail.com>
>To: Atlanta Linux Enthusiasts <ale at ale.org>
>Subject: Re: [ale] upgrading glibcx to glibc2.2.4...........
>
>Thanks so much for the wise words.
>
>I've not upgraded anything so momentous as glibc on FreeBSD so am 
>gratified to learn of it's power and flexibility.
>
>If you wouldn't mind providing a bit more precise synopsis of  the 
>process  to which you prefer I'd be most grateful.
>
>Cordially,
>Courtney

What version/release of FreeBSD are you running?
Are its add-ons installed as packages or were they built
from ports?  (Packages are precompiles ports, ports are
built from source.)

Commands you need to know about:

pkg_version
pkg_info (especially "pkginfo -R")
pkg_delete
pkg_add
kldload
kldunload
kldstat

Also, knowing how to use the Ports Collection would be a Good Thing(tm).

Installed ports/packages are "registered" in /var/db/pkg/*
Warning - do *not* fiddle with stuff in that directory
hierarchy except with the pkg_* commands (e.g. look but
don't touch ;).

FreeBSD has a port/package called "linux_base" (which
contains *lots* of stuff, glibc being only a part of it) and
a package for Netscape7.  Sinnce ns7 runs under Linux
emulation, it requires linux_base & Linux support in the
kernel (usually loaded/enabled as a kernel module).

So, your steps will be (perhaps roughly) as follows:
0.  Make sure no Linux applications are running.
(remove things)
1.  Make sure the linux support is unloaded from your running kernel.
    kldstat tells you what modules are loaded.
    "kldunload linux.ko" unloads the Linux module.
2.  pkg_version tells you the version of your linux_base.
3.  pkg_info -R will tell you the dependencies of that
    package.  pkg_info also has a switch that lists the files
    comprising an installed port/package.
    For example:  "pkg_info -R linux_base-7.1_5" will output
    a list of the installed packages/ports that depend on
    linux_base-7.1_5.
4.  "pkg_delete" will delete things, naturally ;)
    You need to pkg_delete everything that depends on linux_base-x.y_z.
5.  Then pkg_delete linux_base-x.y_z (the version *must*
    match, i.e. you need to completely specify the package name
    on the command line).
(add things)
6.  pkg_add your new (updated?) linux_base.
7.  pkg_add whatever things depend on linux_base.

Note that you might need to "kldload linux.ko" after step 6,
in case the install script(s) for the Linux applications
need to run something in Linux-mode.

The pkg_* commands (or make install in ports) will take care
of things like the runtime linker & ld things.

This process is explained in fairly elaborate detail in the
FreeBSD Handbook, available at http://www.freebsd.org/

Having done this several times before, this entire process
takes me about 5 minutes, & on a running system & requiring
no reboots, etc. :)  But I do this via ports instead of
packages & that's different.  :)  (Instead of pkg_add, it's
cd /usr/ports/foo && make && make install)

And fwiw, Mozilla & Mozilla-Firebird available for FreeBSD
in native-mode & buildable from source.  :)  I use them; on
a pIII/667, they take about an hour each to build.

-kc

>Kenneth W Cochran wrote:
>
>>>Date: Fri, 19 Sep 2003 20:23:26 -0500
>>>From: Courtney Thomas <ccthomas at joimail.com>
>>>To: Atlanta Linux Enthusiasts <ale at ale.org>
>>>Subject: Re: [ale] upgrading glibcx to glibc2.2.4...........
>>>
>>>Thanks so much James.
>>>
>>>What you recommend is what I plan, i.e. to unfurl the the whole mess
in
>>>an 'isolated' directory and merely link what I hope is the only
missing
>>>link, i.e. the requisite shared lib.
>>>
>>>Or maybe I should say I think that's what you recommend   :- )
>>>
>>>My env is FreeBSD running under linux compatibility mode and the
calling
>>>app is Netscape7.1.
>>
>>Aaaah, in that case, then you should use the FreeBSD

>>toolset/package management system to delete &
>>re-add/upgrade that. :)  In case of FreeBSD, glibc is not
>>required by the OS itself & is only required by the Linux
>>emulation "layer" and any Linux executables.  As long as
>>you delete its dependencies first (or use portupgrade I
>>think {shrug}) you can even update/replace glibc on a
>>running system (I've done it a couple of times).
>>
>>-kc
_______________________________________________
Ale mailing list
Ale at ale.org
http://www.ale.org/mailman/listinfo/ale



More information about the Ale mailing list