1997-06-24 13:16:00 +00:00
|
|
|
*** makefile.orig Fri May 16 10:53:30 1997
|
|
|
|
--- makefile Tue Jun 24 16:53:47 1997
|
1995-12-05 02:48:19 +00:00
|
|
|
***************
|
1997-06-24 13:16:00 +00:00
|
|
|
*** 5,33 ****
|
|
|
|
# Where the zlib library and include files are located
|
|
|
|
#ZLIBLIB=/usr/local/lib
|
|
|
|
#ZLIBINC=/usr/local/include
|
|
|
|
! ZLIBLIB=../zlib
|
|
|
|
! ZLIBINC=../zlib
|
1995-12-05 02:48:19 +00:00
|
|
|
|
|
|
|
! CC=cc
|
1997-06-24 13:16:00 +00:00
|
|
|
! CFLAGS=-I$(ZLIBINC) -O # -g -DPNG_DEBUG=1
|
|
|
|
! LDFLAGS=-L. -L$(ZLIBLIB) -lpng -lz -lm
|
1995-12-05 02:48:19 +00:00
|
|
|
|
1997-06-24 13:16:00 +00:00
|
|
|
#RANLIB=echo
|
|
|
|
RANLIB=ranlib
|
1995-12-05 02:48:19 +00:00
|
|
|
|
|
|
|
# where make install puts libpng.a and png.h
|
|
|
|
! prefix=/usr/local
|
|
|
|
|
1997-06-24 13:16:00 +00:00
|
|
|
OBJS = png.o pngset.o pngget.o pngrutil.o pngtrans.o pngwutil.o \
|
1996-07-17 20:08:06 +00:00
|
|
|
pngread.o pngrio.o pngwio.o pngwrite.o pngrtran.o \
|
|
|
|
pngwtran.o pngmem.o pngerror.o pngpread.o
|
1995-12-05 02:48:19 +00:00
|
|
|
|
|
|
|
! all: libpng.a pngtest
|
|
|
|
|
|
|
|
libpng.a: $(OBJS)
|
|
|
|
ar rc $@ $(OBJS)
|
|
|
|
$(RANLIB) $@
|
|
|
|
|
|
|
|
pngtest: pngtest.o libpng.a
|
|
|
|
$(CC) -o pngtest $(CCFLAGS) pngtest.o $(LDFLAGS)
|
|
|
|
|
1997-06-24 13:16:00 +00:00
|
|
|
--- 5,42 ----
|
|
|
|
# Where the zlib library and include files are located
|
|
|
|
#ZLIBLIB=/usr/local/lib
|
|
|
|
#ZLIBINC=/usr/local/include
|
|
|
|
! #ZLIBLIB=../zlib
|
|
|
|
! #ZLIBINC=../zlib
|
1995-12-05 02:48:19 +00:00
|
|
|
|
1997-06-24 13:16:00 +00:00
|
|
|
! VER=0.96
|
1995-12-05 02:48:19 +00:00
|
|
|
! #CC=cc
|
1997-06-24 13:16:00 +00:00
|
|
|
! #CFLAGS=-I$(ZLIBINC) -O # -g -DPNG_DEBUG=1
|
|
|
|
! LDFLAGS=-L. -lpng -lz -lm -static
|
1995-12-05 02:48:19 +00:00
|
|
|
|
1997-06-24 13:16:00 +00:00
|
|
|
#RANLIB=echo
|
|
|
|
RANLIB=ranlib
|
1995-12-05 02:48:19 +00:00
|
|
|
|
|
|
|
# where make install puts libpng.a and png.h
|
|
|
|
! prefix=${PREFIX}
|
|
|
|
|
1997-06-24 13:16:00 +00:00
|
|
|
OBJS = png.o pngset.o pngget.o pngrutil.o pngtrans.o pngwutil.o \
|
1996-07-17 20:08:06 +00:00
|
|
|
pngread.o pngrio.o pngwio.o pngwrite.o pngrtran.o \
|
|
|
|
pngwtran.o pngmem.o pngerror.o pngpread.o
|
1995-12-05 02:48:19 +00:00
|
|
|
|
|
|
|
! .SUFFIXES: .c .so .o
|
1997-06-24 13:16:00 +00:00
|
|
|
!
|
1996-07-17 20:08:06 +00:00
|
|
|
! .c.so:
|
|
|
|
! ${CC} -fpic -DPIC ${CFLAGS} -c ${.IMPSRC} -o ${.TARGET}
|
|
|
|
!
|
|
|
|
! all: libpng.a libpng.so.${VER}
|
1995-12-05 02:48:19 +00:00
|
|
|
|
|
|
|
libpng.a: $(OBJS)
|
|
|
|
ar rc $@ $(OBJS)
|
|
|
|
$(RANLIB) $@
|
|
|
|
|
1996-02-19 22:17:46 +00:00
|
|
|
+ libpng.so.${VER}: $(OBJS:S/o$/so/g)
|
1997-06-24 13:16:00 +00:00
|
|
|
+ ${CC} -shared -Wl,-x -Wl,-assert -Wl,pure-text -o $@ $(OBJS:S/o$/so/g)
|
1995-12-05 02:48:19 +00:00
|
|
|
+
|
|
|
|
pngtest: pngtest.o libpng.a
|
|
|
|
$(CC) -o pngtest $(CCFLAGS) pngtest.o $(LDFLAGS)
|
|
|
|
|
|
|
|
***************
|
1997-06-24 13:16:00 +00:00
|
|
|
*** 37,48 ****
|
1995-12-05 02:48:19 +00:00
|
|
|
install: libpng.a
|
|
|
|
-@mkdir $(prefix)/include
|
|
|
|
-@mkdir $(prefix)/lib
|
|
|
|
! cp png.h $(prefix)/include
|
|
|
|
! cp pngconf.h $(prefix)/include
|
|
|
|
! chmod 644 $(prefix)/include/png.h
|
|
|
|
! chmod 644 $(prefix)/include/pngconf.h
|
|
|
|
! cp libpng.a $(prefix)/lib
|
|
|
|
! chmod 644 $(prefix)/lib/libpng.a
|
|
|
|
|
|
|
|
clean:
|
|
|
|
rm -f *.o libpng.a pngtest pngout.png
|
1997-06-24 13:16:00 +00:00
|
|
|
--- 46,54 ----
|
1995-12-05 02:48:19 +00:00
|
|
|
install: libpng.a
|
|
|
|
-@mkdir $(prefix)/include
|
|
|
|
-@mkdir $(prefix)/lib
|
|
|
|
! ${INSTALL} -c -m 644 -o ${BINOWN} -g ${BINGRP} png.h pngconf.h $(prefix)/include
|
1996-02-19 22:17:46 +00:00
|
|
|
! ${INSTALL} -c -m 644 -o ${BINOWN} -g ${BINGRP} libpng.a libpng.so.${VER} $(prefix)/lib
|
1995-12-05 02:48:19 +00:00
|
|
|
! ranlib $(prefix)/lib/libpng.a
|
|
|
|
|
|
|
|
clean:
|
|
|
|
rm -f *.o libpng.a pngtest pngout.png
|