| View previous topic :: View next topic |
| Author |
Message |
sadrok n00b


Joined: 21 Feb 2003 Posts: 21 Location: Infront of this stupid PC
|
Posted: Sat May 31, 2003 5:56 pm Post subject: Need to compile program linked to earlier version of a lib |
|
|
I wish to compile a program used for CGI
Currently it links to libpng-1.2.5-r4 (/usr/lib/libpng.so.3)
But I want it to run on a webhost that only has (/usr/lib/libpng.so.2)
How can this be done? |
|
| Back to top |
|
 |
Pythonhead Developer


Joined: 16 Dec 2002 Posts: 1801 Location: Redondo Beach, Republic of Calif.
|
Posted: Sat May 31, 2003 6:41 pm Post subject: |
|
|
I'm assuming you don't have root access on that system, so you can't upgrade?
You could compile the new libpng you need and keep it in your home directory and point to that version (libpng-1.2.5-r4) in the CGI program's Makefile. |
|
| Back to top |
|
 |
sadrok n00b


Joined: 21 Feb 2003 Posts: 21 Location: Infront of this stupid PC
|
Posted: Sun Jun 01, 2003 4:40 am Post subject: |
|
|
| Pythonhead wrote: | | I'm assuming you don't have root access on that system, so you can't upgrade? |
Unfortunately, you're correct.
| Quote: |
You could compile the new libpng you need and keep it in your home directory and point to that version (libpng-1.2.5-r4) in the CGI program's Makefile. |
I would like to know how? This could help me a whole lot. I'm using gcc-3 but I couldn't find out how to point to a library that's not in the usual locations. |
|
| Back to top |
|
 |
Pythonhead Developer


Joined: 16 Dec 2002 Posts: 1801 Location: Redondo Beach, Republic of Calif.
|
Posted: Sun Jun 01, 2003 7:53 am Post subject: |
|
|
Compile libpng.so.3 but don't do 'make install', unless you've already configured your Makefile to install it in your home directory somewhere.
Go to your CGI program's Makefile and look for a line that has something like:
LIBS = -L/usr/lib -llibpng etc.
You'll want to add the directory where your new copy of libpng.so.3 is then compile it. |
|
| Back to top |
|
 |
|