1999-10-23 09:39:18 -04:00
|
|
|
# Makefile for PngMinus (png2pnm and pnm2png)
|
|
|
|
# Linux / Unix
|
|
|
|
|
2011-07-12 07:11:42 -04:00
|
|
|
#CC=cc
|
|
|
|
CC=gcc
|
|
|
|
LD=$(CC)
|
2001-10-18 21:55:13 -04:00
|
|
|
|
|
|
|
RM=rm -f
|
|
|
|
|
|
|
|
#PNGPATH = /usr/local
|
2011-11-24 15:40:36 -05:00
|
|
|
#PNGINC = -I$(PNGPATH)/include/libpng16
|
|
|
|
#PNGLIB = -L$(PNGPATH)/lib -lpng16
|
|
|
|
#PNGLIBS = $(PNGPATH)/lib/libpng16.a
|
2001-10-18 21:55:13 -04:00
|
|
|
PNGINC = -I../..
|
|
|
|
PNGLIB = -L../.. -lpng
|
|
|
|
PNGLIBS = ../../libpng.a
|
|
|
|
|
|
|
|
#ZPATH = /usr/local
|
|
|
|
#ZINC = -I$(ZPATH)/include
|
|
|
|
#ZLIB = -L$(ZPATH)/lib -lz
|
|
|
|
#ZLIBS = $(ZPATH)/lib/libz.a
|
|
|
|
ZINC = -I../../../zlib
|
|
|
|
ZLIB = -L../../../zlib -lz
|
|
|
|
ZLIBS = ../../../zlib/libz.a
|
|
|
|
|
2011-07-12 07:11:42 -04:00
|
|
|
CFLAGS=$(PNGINC) $(ZINC)
|
2011-07-11 18:52:05 -04:00
|
|
|
LDLIBS=$(PNGLIB) $(ZLIB)
|
|
|
|
LDLIBSS=$(PNGLIBS) $(ZLIBS)
|
1999-10-23 09:39:18 -04:00
|
|
|
C=.c
|
|
|
|
O=.o
|
|
|
|
L=.a
|
|
|
|
E=
|
|
|
|
|
|
|
|
# dependencies
|
|
|
|
|
2001-10-18 21:55:13 -04:00
|
|
|
#all: png2pnm$(E) pnm2png$(E)
|
|
|
|
all: png2pnm$(E) pnm2png$(E) png2pnm-static$(E) pnm2png-static$(E)
|
1999-10-23 09:39:18 -04:00
|
|
|
|
|
|
|
png2pnm$(O): png2pnm$(C)
|
2001-10-18 21:55:13 -04:00
|
|
|
$(CC) -c $(CFLAGS) png2pnm$(C)
|
1999-10-23 09:39:18 -04:00
|
|
|
|
|
|
|
png2pnm$(E): png2pnm$(O)
|
2011-07-11 18:52:05 -04:00
|
|
|
$(LD) $(LDFLAGS) -o png2pnm$(E) png2pnm$(O) $(LDLIBS) -lm
|
2001-10-18 21:55:13 -04:00
|
|
|
|
|
|
|
png2pnm-static$(E): png2pnm$(O)
|
2011-07-11 18:52:05 -04:00
|
|
|
$(LD) $(LDFLAGS) -o png2pnm-static$(E) png2pnm$(O) $(LDLIBSS) -lm
|
1999-10-23 09:39:18 -04:00
|
|
|
|
|
|
|
pnm2png$(O): pnm2png$(C)
|
2001-10-18 21:55:13 -04:00
|
|
|
$(CC) -c $(CFLAGS) pnm2png$(C)
|
1999-10-23 09:39:18 -04:00
|
|
|
|
|
|
|
pnm2png$(E): pnm2png$(O)
|
2011-07-11 18:52:05 -04:00
|
|
|
$(LD) $(LDFLAGS) -o pnm2png$(E) pnm2png$(O) $(LDLIBS) -lm
|
2001-10-18 21:55:13 -04:00
|
|
|
|
|
|
|
pnm2png-static$(E): pnm2png$(O)
|
2011-07-11 18:52:05 -04:00
|
|
|
$(LD) $(LDFLAGS) -o pnm2png-static$(E) pnm2png$(O) $(LDLIBSS) -lm
|
1999-10-23 09:39:18 -04:00
|
|
|
|
|
|
|
clean:
|
|
|
|
$(RM) png2pnm$(O)
|
|
|
|
$(RM) pnm2png$(O)
|
|
|
|
$(RM) png2pnm$(E)
|
|
|
|
$(RM) pnm2png$(E)
|
2001-10-18 21:55:13 -04:00
|
|
|
$(RM) png2pnm-static$(E)
|
|
|
|
$(RM) pnm2png-static$(E)
|
1999-10-23 09:39:18 -04:00
|
|
|
|
|
|
|
# End of makefile for png2pnm / pnm2png
|