1 # makefile for libpng under FreeBSD
2 # Copyright (C) 2002, 2007, 2009 Glenn Randers-Pehrson and Andrey A. Chernov
4 # This code is released under the libpng license.
5 # For conditions of distribution and use, see the disclaimer
12 SHLIB_MAJOR= ${SHLIB_VER}
17 # where make install puts libpng.a and png.h
21 INCSDIR= /include/libpng
22 INCDIR= ${INCSDIR} # for 4.x bsd.lib.mk
23 MAN= libpng.3 libpngpf.3 png.5
25 SYMLINKS= libpng/png.h ${INCSDIR}/../png.h \
26 libpng/pngconf.h ${INCSDIR}/../pngconf.h
28 DPADD+= ${LIBM} ${LIBZ}
31 .if (${MACHINE_ARCH} != "i386")
32 CFLAGS+= -DPNG_CONFIGURE_LIBPNG -DPNG_NO_MMX_CODE
35 SRCS= png.c pngset.c pngget.c pngrutil.c pngtrans.c pngwutil.c \
36 pngread.c pngrio.c pngwio.c pngwrite.c pngrtran.c \
37 pngwtran.c pngmem.c pngerror.c pngpread.c
39 pngtest: pngtest.o libpng.a
40 ${CC} ${CFLAGS} -L. -static -o pngtest pngtest.o -lpng -lz -lm
42 CLEANFILES= pngtest pngtest.o pngout.png
47 DOCS = ANNOUNCE CHANGES INSTALL KNOWNBUG LICENSE README TODO Y2KINFO
49 chmod a-w *.[ch35] $(DOCS) scripts/*