source: patches/libpng-1.2.7-link_to_proper_libs-1.patch@ b67b7ca

clfs-1.2 clfs-2.1 clfs-3.0.0-systemd clfs-3.0.0-sysvinit systemd sysvinit
Last change on this file since b67b7ca was 617118d, checked in by Jim Gifford <clfs@…>, 19 years ago

r561@server (orig r559): root | 2005-06-05 02:38:49 -0700
Fixed Directory Structure

  • Property mode set to 100644
File size: 2.2 KB
RevLine 
[617118d]1Submitted By: Bruce Dubbs <bdubbs@linuxfromscratch.org>
2Date: 2004-08-05
3Initial Package Version: 1.2.6
4Origin: http://blfs-bugs.linuxfromscratch.org/show_bug.cgi?id=644
5Description: libpng is not linked against libz and libm. This causes problems
6for packages that try to link against libpng without including "-lz -lm" in
7the linker flags.
8
9$LastChangedBy: igor $
10$Date: 2004-10-06 03:32:45 +0200 (Wed, 06 Oct 2004) $
11
12diff -ur libpng-1.2.6rc1.orig/scripts/libpng.pc.in libpng-1.2.6rc1/scripts/libpng.pc.in
13--- libpng-1.2.6rc1.orig/scripts/libpng.pc.in 2002-10-03 06:32:33.000000000 -0500
14+++ libpng-1.2.6rc1/scripts/libpng.pc.in 2004-03-14 10:29:13.000000000 -0600
15@@ -7,5 +7,5 @@
16 Name: libpng12
17 Description: Loads and saves PNG files
18 Version: 1.2.7
19-Libs: -L${libdir} -lpng12 -lz -lm
20+Libs: -L${libdir} -lpng12
21 Cflags: -I${includedir}/libpng12
22diff -ur libpng-1.2.6rc1.orig/scripts/makefile.linux libpng-1.2.6rc1/scripts/makefile.linux
23--- libpng-1.2.6rc1.orig/scripts/makefile.linux 2002-10-03 06:32:34.000000000 -0500
24+++ libpng-1.2.6rc1/scripts/makefile.linux 2004-03-14 10:31:21.000000000 -0600
25@@ -34,8 +34,9 @@
26 CFLAGS=-I$(ZLIBINC) -Wall -O3 -funroll-loops \
27 $(ALIGN) # $(WARNMORE) -g -DPNG_DEBUG=5
28
29-LDFLAGS=-L. -Wl,-rpath,. -L$(ZLIBLIB) -Wl,-rpath,$(ZLIBLIB) -lpng12 -lz -lm
30-LDFLAGS_A=-L$(ZLIBLIB) -Wl,-rpath,$(ZLIBLIB) libpng.a -lz -lm
31+LIBS=-lz -lm
32+LDFLAGS=-L. -Wl,-rpath,. -L$(ZLIBLIB) -Wl,-rpath,$(ZLIBLIB) -lpng12
33+LDFLAGS_A=-L$(ZLIBLIB) -Wl,-rpath,$(ZLIBLIB) libpng.a $(LIBS)
34
35 RANLIB=ranlib
36 #RANLIB=echo
37@@ -86,7 +87,7 @@
38 echo I_opts=\"-I$(INCPATH)/$(LIBNAME)\"; \
39 echo L_opts=\"-L$(LIBPATH)\"; \
40 echo R_opts=\"-Wl,-rpath,$(LIBPATH)\"; \
41- echo libs=\"-lpng12 -lz -lm\"; \
42+ echo libs=\"-lpng12\"; \
43 cat scripts/libpng-config-body.in ) > libpng-config
44 chmod +x libpng-config
45
46@@ -99,12 +100,12 @@
47 $(LIBNAME).so.$(PNGVER): $(OBJSDLL)
48 $(CC) -shared -Wl,-soname,$(LIBNAME).so.$(PNGMAJ) \
49 -o $(LIBNAME).so.$(PNGVER) \
50- $(OBJSDLL)
51+ $(OBJSDLL) $(LIBS)
52
53 libpng.so.3.$(PNGMIN): $(OBJSDLL)
54 $(CC) -shared -Wl,-soname,libpng.so.3 \
55 -o libpng.so.3.$(PNGMIN) \
56- $(OBJSDLL)
57+ $(OBJSDLL) $(LIBS)
58
59 pngtest: pngtest.o $(LIBNAME).so
60 $(CC) -o pngtest $(CFLAGS) pngtest.o $(LDFLAGS)
Note: See TracBrowser for help on using the repository browser.