home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!ferkel.ucsb.edu!taco!rock!stanford.edu!agate!doc.ic.ac.uk!uknet!sersun1!plasparc3!ajn
- From: ajn@essex.ac.uk (Alastair Neil)
- Newsgroups: comp.sys.sun.misc
- Subject: Re: Installing a shared library without screwin
- Message-ID: <6500@sersun1.essex.ac.uk>
- Date: 19 Nov 92 00:01:31 GMT
- References: <mark.722062866@coombs>
- Sender: news@sersun1.essex.ac.uk
- Reply-To: ajn@essex.ac.uk
- Organization: Dept. of Physics, University of Essex
- Lines: 47
-
- In article 722062866@coombs, mark@coombs.anu.edu.au (Mark) writes:
- ->On SunOS 4.x.x:
- ->I've heard a lot of horror stories about mistakes with libc.so replacing and
- ->how dynamic library loading programs die real quick if you tamper with their
- ->library.
- ->
- ->What is the right/best way to replace a libc.so with your site customised
- ->version? I dont want to have to go find the installation tape everytime
- ->I attempt it. Do I use 'cp' or 'cat mylib > /usr/lib/libc.so' or what? Im a
- ->bit worried that a context switch will happen halfway through it and bugger
- ->it all up.
-
- having hosed my system once by careless instalation of a libc, I now
- 1) first test the lib in a safe environment eg:
- setenv LD_LIBRARY_PATH /users/staff/ajn/newlibdir:/users/X11R5/lib:/usr/lib
-
- now all dynamically linked executables will find the new lib first, if it is
- bad just do
-
- setenv LD_LIBRARY_PATH /users/X11R5/lib:/usr/lib
-
- (back to normal)
-
- when things are right
-
- 2) copy the new shared library to a higher revision number, i.e.
-
- old libc: /usr/lib/libc.so.1.6
-
- cp ~ajn/newlibdirlibc.so /usr/lib/libc.so.1.6.1
-
- (now make sure the permissions are the same between libc.so.1.6 and libc.so.1.6.1)
-
- cp ~ajn/newlibdir/libc.sa /usr/lib/libc.sa.1.6.1
- (or link old .sa lib to new revision number)
-
- cd /usr/lib
-
- ldconfig
-
- you are off yehaa!!
- good luck
- ---
- +-----------------------------------------------------------------------------+
- |..Alastair Neil......0206-872861...............| |
- |..44-206-872861......[ajn@essex.ac.uk].........| None Shall Sleep |
- +-----------------------------------------------------------------------------+
-