mirror of
https://git.code.sf.net/p/libpng/code.git
synced 2025-07-10 18:04:09 +02:00
Imported from libpng-1.2.3rc5.tar
This commit is contained in:
@@ -29,7 +29,7 @@ ZLIBINC=../zlib
|
||||
# read libpng.txt or png.h to see why PNGMAJ is 0. You should not
|
||||
# have to change it.
|
||||
PNGMAJ = 0
|
||||
PNGMIN = 1.2.3rc4
|
||||
PNGMIN = 1.2.3rc5
|
||||
PNGVER = $(PNGMAJ).$(PNGMIN)
|
||||
LIBNAME = libpng12
|
||||
|
||||
@@ -44,7 +44,7 @@ OBJS = png.o pngset.o pngget.o pngrutil.o pngtrans.o pngwutil.o \
|
||||
pngread.o pngrio.o pngwio.o pngwrite.o pngrtran.o \
|
||||
pngwtran.o pngmem.o pngerror.o pngpread.o
|
||||
|
||||
all: $(LIBNAME).so libpng.a pngtest libpng.pc
|
||||
all: $(LIBNAME).so libpng.a pngtest
|
||||
|
||||
libpng.a: $(OBJS)
|
||||
ar rc $@ $(OBJS)
|
||||
@@ -53,6 +53,20 @@ libpng.a: $(OBJS)
|
||||
libpng.pc:
|
||||
cat scripts/libpng.pc.in | sed -e s\!@PREFIX@!$(prefix)! > libpng.pc
|
||||
|
||||
libpng-config:
|
||||
( cat scripts/libpng-config-head.in; \
|
||||
echo prefix=\"$(prefix)\"; \
|
||||
echo cppflags=\"-I$(INCPATH)/libpng12"; \
|
||||
echo cflags=\"-std\"; \
|
||||
echo ldflags=\"-L$(LIBPATH)\"; \
|
||||
echo libs=\"-lpng12 -lz -lm\"; \
|
||||
cat scripts/libpng-config-body.in ) > libpng-config
|
||||
chmod +x libpng-config
|
||||
|
||||
cat scripts/libpng-config.in | sed -e s\!@PREFIX@!$(prefix)! > \
|
||||
-e s!\#LIBS!-lm! > libpng-config
|
||||
chmod +x libpng-config
|
||||
|
||||
$(LIBNAME).so: $(LIBNAME).so.$(PNGMAJ)
|
||||
ln -f -s $(LIBNAME).so.$(PNGMAJ) $(LIBNAME).so
|
||||
|
||||
@@ -103,11 +117,11 @@ install-shared: install-headers $(LIBNAME).so.$(PNGVER) libpng.pc
|
||||
ln -sf $(LIBNAME).so.$(PNGMAJ) $(LIBNAME).so)
|
||||
-@if [ ! -d $(DESTDIR)$(LIBPATH)/pkgconfig ]; then \
|
||||
mkdir $(DESTDIR)$(LIBPATH)/pkgconfig; fi
|
||||
-@/bin/rm -f $(DESTDIR)$(LIBPATH)/pkgconfig/libpng12.pc
|
||||
-@/bin/rm -f $(DESTDIR)$(LIBPATH)/pkgconfig/$(LIBNAME).pc
|
||||
-@/bin/rm -f $(DESTDIR)$(LIBPATH)/pkgconfig/libpng.pc
|
||||
cp libpng.pc $(DESTDIR)$(LIBPATH)/pkgconfig/libpng12.pc
|
||||
chmod 644 $(DESTDIR)$(LIBPATH)/pkgconfig/libpng12.pc
|
||||
(cd $(DESTDIR)$(LIBPATH)/pkgconfig; ln -sf libpng12.pc libpng.pc)
|
||||
cp libpng.pc $(DESTDIR)$(LIBPATH)/pkgconfig/$(LIBNAME).pc
|
||||
chmod 644 $(DESTDIR)$(LIBPATH)/pkgconfig/$(LIBNAME).pc
|
||||
(cd $(DESTDIR)$(LIBPATH)/pkgconfig; ln -sf $(LIBNAME).pc libpng.pc)
|
||||
|
||||
install-man: libpng.3 libpngpf.3 png.5
|
||||
-@if [ ! -d $(DESTDIR)$(MANPATH) ]; then mkdir $(DESTDIR)$(MANPATH); fi
|
||||
@@ -122,14 +136,14 @@ install-man: libpng.3 libpngpf.3 png.5
|
||||
-@/bin/rm -f $(DESTDIR)$(MANPATH)/man5/png.5
|
||||
cp png.5 $(DESTDIR)$(MANPATH)/man5
|
||||
|
||||
install-config: scripts/libpng-config
|
||||
install-config: libpng-config
|
||||
-@if [ ! -d $(DESTDIR)$(BINPATH) ]; then \
|
||||
mkdir $(DESTDIR)$(BINPATH); fi
|
||||
-@/bin/rm -f $(DESTDIR)$(BINPATH)/libpng-config
|
||||
-@/bin/rm -f $(DESTDIR)$(BINPATH)/libpng12-config
|
||||
cp scripts/libpng-config $(DESTDIR)$(BINPATH)/libpng12-config
|
||||
chmod 755 $(DESTDIR)$(BINPATH)/libpng12-config
|
||||
(cd $(DESTDIR)$(BINPATH); ln -sf libpng12-config libpng-config)
|
||||
-@/bin/rm -f $(DESTDIR)$(BINPATH)/$(LIBNAME)-config
|
||||
cp libpng-config $(DESTDIR)$(BINPATH)/$(LIBNAME)-config
|
||||
chmod 755 $(DESTDIR)$(BINPATH)/$(LIBNAME)-config
|
||||
(cd $(DESTDIR)$(BINPATH); ln -sf $(LIBNAME)-config libpng-config)
|
||||
|
||||
install: install-static install-shared install-man install-config
|
||||
|
||||
|
||||
Reference in New Issue
Block a user