diff options
author | ache <ache@FreeBSD.org> | 2002-05-17 20:39:49 +0800 |
---|---|---|
committer | ache <ache@FreeBSD.org> | 2002-05-17 20:39:49 +0800 |
commit | 87cd6714e100e9654a4fb59a65c5e70515dffde8 (patch) | |
tree | 91b37fe032123c5158d42ae3487b65e787b1afcc /graphics/png | |
parent | 7a5f7696345b68f5a8eed081fbbe120366cd4edc (diff) | |
download | freebsd-ports-gnome-87cd6714e100e9654a4fb59a65c5e70515dffde8.tar.gz freebsd-ports-gnome-87cd6714e100e9654a4fb59a65c5e70515dffde8.tar.zst freebsd-ports-gnome-87cd6714e100e9654a4fb59a65c5e70515dffde8.zip |
Use <bsd.lib.mk>
Submitted by: ru
Diffstat (limited to 'graphics/png')
-rw-r--r-- | graphics/png/Makefile | 9 | ||||
-rw-r--r-- | graphics/png/files/makefile.freebsd | 47 | ||||
-rw-r--r-- | graphics/png/files/patch-aa | 37 |
3 files changed, 55 insertions, 38 deletions
diff --git a/graphics/png/Makefile b/graphics/png/Makefile index fc5a7ef252c2..775906fb01d8 100644 --- a/graphics/png/Makefile +++ b/graphics/png/Makefile @@ -7,7 +7,7 @@ PORTNAME= png PORTVERSION= 1.2.2 -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES= graphics MASTER_SITES= http://www.libpng.org/pub/png/src/ \ ftp://swrinde.nde.swri.edu/pub/png/src/ \ @@ -29,6 +29,7 @@ PLIST_SUB= SHLIB_VER="${SHLIB_VER}" MAN3= libpng.3 libpngpf.3 MAN5= png.5 +MANCOMPRESSED= maybe .include <bsd.port.pre.mk> @@ -36,4 +37,10 @@ post-extract: # Please don't delete the following line - this link used by ghostscript* ports @${LN} -sf ${WRKSRC} ${WRKDIR}/libpng +post-patch: + ${CP} ${FILESDIR}/makefile.freebsd ${WRKSRC}/scripts/ + +pre-install: + @[ -d ${PREFIX}/include/libpng ] || ${MKDIR} ${PREFIX}/include/libpng + .include <bsd.port.post.mk> diff --git a/graphics/png/files/makefile.freebsd b/graphics/png/files/makefile.freebsd new file mode 100644 index 000000000000..4ce6a2170b2c --- /dev/null +++ b/graphics/png/files/makefile.freebsd @@ -0,0 +1,47 @@ +# makefile for libpng under FreeBSD +# Copyright (C) 2002 Glenn Randers-Pehrson and Andrey A. Chernov +# Copyright (C) 1995 Guy Eric Schalnat, Group 42, Inc. +# For conditions of distribution and use, see copyright notice in png.h + +PREFIX?= /usr/local +SHLIB_VER?= 5 + +LIB= png +SHLIB_MAJOR= ${SHLIB_VER} +SHLIB_MINOR= 0 +NOPROFILE= YES +NOOBJ= YES + +# where make install puts libpng.a and png.h +DESTDIR= ${PREFIX} +LIBDIR= /lib +INCS= png.h pngconf.h +INCSDIR= /include/libpng +INCDIR= ${INCSDIR} # for 4.x bsd.lib.mk +MAN= libpng.3 libpngpf.3 png.5 +MANDIR= /man/man +SYMLINKS= libpng/png.h ${INCSDIR}/../png.h \ + libpng/pngconf.h ${INCSDIR}/../pngconf.h + +CFLAGS+= -I. -DPNG_USE_PNGGCCRD +.if (${ARCH} != "i386") +CFLAGS+= -DPNG_NO_ASSEMBLER_CODE +.endif + +SRCS= png.c pngset.c pngget.c pngrutil.c pngtrans.c pngwutil.c \ + pngread.c pngrio.c pngwio.c pngwrite.c pngrtran.c \ + pngwtran.c pngmem.c pngerror.c pngpread.c pnggccrd.c + +pngtest: pngtest.o libpng.a + ${CC} ${CFLAGS} -L. -static -o pngtest pngtest.o -lpng -lz -lm + +CLEANFILES= pngtest pngtest.o pngout.png + +test: pngtest + ./pngtest + +DOCS = ANNOUNCE CHANGES INSTALL KNOWNBUG LICENSE README TODO Y2KINFO +writelock: + chmod a-w *.[ch35] $(DOCS) scripts/* + +.include <bsd.lib.mk> diff --git a/graphics/png/files/patch-aa b/graphics/png/files/patch-aa deleted file mode 100644 index 77f9e454ca43..000000000000 --- a/graphics/png/files/patch-aa +++ /dev/null @@ -1,37 +0,0 @@ ---- scripts/makefile.freebsd.orig Mon Apr 15 18:11:36 2002 -+++ scripts/makefile.freebsd Sun Apr 21 20:03:05 2002 -@@ -3,11 +3,13 @@ - # Copyright (C) 1995 Guy Eric Schalnat, Group 42, Inc. - # For conditions of distribution and use, see copyright notice in png.h - -+.include <bsd.own.mk> -+ - # where make install puts libpng.a and png.h --prefix=/usr/local -+prefix=${PREFIX} - --PNGMAJ= 5 --.if (${OBJFORMAT} == "elf") -+PNGMAJ= $(SHLIB_VER) -+.if (${PORTOBJFORMAT} == "elf") - PNGVER= $(PNGMAJ) - .else - PNGMIN= 0 -@@ -15,7 +17,7 @@ - .endif - - CFLAGS+= -I. -DPNG_USE_PNGGCCRD --.if (${MACHINE_ARCH} != "i386") -+.if (${ARCH} != "i386") - CFLAGS+= -DPNG_NO_ASSEMBLER_CODE - .endif - LDFLAGS+=-L. -lpng -lz -lm -static -@@ -36,7 +38,7 @@ - $(RANLIB) $@ - - libpng.so.${PNGVER}: $(OBJS:S/o$/so/g) --.if (${OBJFORMAT} == "elf") -+.if (${PORTOBJFORMAT} == "elf") - ${CC} -shared -Wl,-x,-soname,$@ -o $@ $(OBJS:S/o$/so/g) -lz -lm - .else - ${CC} -shared -Wl,-x -o $@ $(OBJS:S/o$/so/g) -lz -lm |