From owner-freebsd-ports Tue Oct 23 4:30:27 2001 Delivered-To: freebsd-ports@hub.freebsd.org Received: from freefall.freebsd.org (freefall.FreeBSD.org [216.136.204.21]) by hub.freebsd.org (Postfix) with ESMTP id 4ABC737B403 for ; Tue, 23 Oct 2001 04:30:06 -0700 (PDT) Received: (from gnats@localhost) by freefall.freebsd.org (8.11.4/8.11.4) id f9NBU6W35992; Tue, 23 Oct 2001 04:30:06 -0700 (PDT) (envelope-from gnats) Received: from freefall.freebsd.org (freefall.FreeBSD.org [216.136.204.21]) by hub.freebsd.org (Postfix) with ESMTP id 21C6437B406 for ; Tue, 23 Oct 2001 04:25:45 -0700 (PDT) Received: (from nobody@localhost) by freefall.freebsd.org (8.11.4/8.11.4) id f9NBPjn35502; Tue, 23 Oct 2001 04:25:45 -0700 (PDT) (envelope-from nobody) Message-Id: <200110231125.f9NBPjn35502@freefall.freebsd.org> Date: Tue, 23 Oct 2001 04:25:45 -0700 (PDT) From: KATO Tsuguru To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-1.0 Subject: ports/31451: Update port: graphics/gd Sender: owner-freebsd-ports@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org >Number: 31451 >Category: ports >Synopsis: Update port: graphics/gd >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Tue Oct 23 04:30:06 PDT 2001 >Closed-Date: >Last-Modified: >Originator: KATO Tsuguru >Release: 4.4-RELEASE i386 >Organization: >Environment: >Description: - Support CFLAGS properly - Fix compilation error when both FreeType and FreeType2 exist - Fix Xpm support - Use freetype-config to find include path and library path >How-To-Repeat: >Fix: diff -urN /usr/ports/graphics/gd/Makefile graphics/gd/Makefile --- /usr/ports/graphics/gd/Makefile Tue Oct 23 18:57:23 2001 +++ graphics/gd/Makefile Tue Oct 23 20:16:15 2001 @@ -7,7 +7,7 @@ PORTNAME= gd PORTVERSION= 1.8.4 -PORTREVISION= 3 +PORTREVISION= 4 CATEGORIES+= graphics MASTER_SITES= http://www.boutell.com/gd/http/ \ ftp://ftp.boutell.com/pub/boutell/gd/ \ @@ -19,29 +19,32 @@ MAINTAINER?= ports@FreeBSD.org +BUILD_DEPENDS= freetype-config:${PORTSDIR}/print/freetype2 # XXX +LIB_DEPENDS= jpeg.9:${PORTSDIR}/graphics/jpeg \ + png.5:${PORTSDIR}/graphics/png \ + freetype.7:${PORTSDIR}/print/freetype2 .if !exists(/usr/bin/bzip2) BUILD_DEPENDS+= bzip2:${PORTSDIR}/archivers/bzip2 .endif -LIB_DEPENDS= png.5:${PORTSDIR}/graphics/png \ - jpeg.9:${PORTSDIR}/graphics/jpeg \ - freetype:${PORTSDIR}/print/freetype2 -USE_FREETYPE2= yes +FREETYPE_CONFIG?= ${LOCALBASE}/bin/freetype-config + +MAKE_ENV= FREETYPE_CONFIG="${FREETYPE_CONFIG}" +INSTALLS_SHLIB= yes .if defined(WITH_X11) -USE_XLIB= yes USE_XPM= yes .endif -INSTALLS_SHLIB= yes - -post-extract: - bzip2 -d < ${_DISTDIR}/gd_gif_in.c.bz2 > ${WRKSRC}/gd_gif_in.c - pre-everything: .if !defined(WITH_X11) - @${ECHO_MSG} "If you want to compile in X support use " - @${ECHO_MSG} "'make -DWITH_X11' instead" + @${ECHO_MSG} + @${ECHO_MSG} "If you want to compile with Xpm support," + @${ECHO_MSG} "hist Ctrl-C right now and use \"make -DWITH_X11=yes\"" + @${ECHO_MSG} .endif + +post-extract: + bzip2 -dc ${DISTDIR}/${DIST_SUBDIR}/gd_gif_in.c.bz2 > ${WRKSRC}/gd_gif_in.c .include diff -urN /usr/ports/graphics/gd/files/patch-ac graphics/gd/files/patch-ac --- /usr/ports/graphics/gd/files/patch-ac Tue Aug 21 10:30:32 2001 +++ graphics/gd/files/patch-ac Tue Oct 23 20:08:09 2001 @@ -1,6 +1,6 @@ ---- Makefile.orig Thu Feb 22 09:03:43 2001 -+++ Makefile Sat Feb 24 16:25:23 2001 -@@ -3,11 +3,11 @@ +--- Makefile.orig Fri Feb 23 02:03:43 2001 ++++ Makefile Tue Oct 23 19:47:37 2001 +@@ -3,21 +3,28 @@ #If you do not have gcc, change the setting for COMPILER, but you must #use an ANSI standard C compiler (NOT the old SunOS 4.1.3 cc #compiler; get gcc if you are still using it). @@ -14,15 +14,18 @@ #If you don't have FreeType, libjpeg and/or Xpm installed, including the #header files, uncomment this (default). You really must install -@@ -16,8 +16,14 @@ + #libpng and zlib to get anywhere if you wish to create PNG images. +-CFLAGS=-O -DHAVE_LIBPNG -DHAVE_LIBJPEG ++#CFLAGS=-O -DHAVE_LIBPNG -DHAVE_LIBJPEG #If you do have FreeType, libjpeg and/or Xpm fully installed, uncomment a #variation of this and comment out the line above. See also LIBS below. -#CFLAGS=-O -DHAVE_LIBXPM -DHAVE_LIBPNG -DHAVE_LIBJPEG \ -# -DHAVE_LIBFREETYPE -DHAVE_LIBTTF -+CFLAGS=-O -DHAVE_LIBPNG -DHAVE_LIBJPEG -DHAVE_LIBFREETYPE ++CFLAGS+=-DHAVE_LIBPNG -DHAVE_LIBJPEG -DHAVE_LIBFREETYPE ++ +.if defined(WITH_X11) -+CFLAGS+=-DHAVE_LIBXPM ++CFLAGS+=-DHAVE_XPM +.endif + +.if defined(JISX0208) @@ -31,12 +34,12 @@ #To use the old FreeType 1.x library, add this additional #define #to the line above -@@ -30,13 +36,15 @@ +@@ -30,13 +37,15 @@ #Some systems are very picky about link order. They don't all agree #on the right order, either. -LIBS=-lgd -lpng -lz -lm -+LIBS=-lgd -lpng -lz -ljpeg -lfreetype -lm ++LIBS=-lgd -lpng -lz -ljpeg -lm `$(FREETYPE_CONFIG) --libs` #If you do have FreeType, JPEG and/or Xpm fully installed, uncomment a #variation of this and comment out the line above. Note that @@ -49,23 +52,29 @@ #Note: for Freetype 1.x, use DHAVE_LIBTTF and -lttf instead. -@@ -45,7 +53,8 @@ +@@ -45,7 +54,11 @@ #ensure that the version of gd you are installing is used, and not an #older release in your directory tree somewhere. -INCLUDEDIRS=-I. -I/usr/include/freetype2 -I/usr/include/X11 -I/usr/X11R6/include/X11 -I/usr/local/include -+INCLUDEDIRS=-I. -I${LOCALBASE}/include/freetype2 -I${LOCALBASE}/include -+INCLUDEDIRS+=-I${X11BASE}/include/X11 -I${X11BASE}/include/freetype2 -I${X11BASE}/include ++INCLUDEDIRS=-I. `$(FREETYPE_CONFIG) --cflags` -I${LOCALBASE}/include ++ ++.if defined(WITH_X11) ++INCLUDEDIRS+=-I${X11BASE}/include/X11 -I${X11BASE}/include ++.endif #Typical install locations for freetype, zlib, xpm and libpng libraries. #If yours are somewhere else, other than a standard location -@@ -55,16 +66,17 @@ +@@ -55,16 +68,20 @@ #on your system can't cause conflicts while building a new one. #This line shouldn't hurt if you don't actually have some of the #optional libraries and directories. -LIBDIRS=-L. -L/usr/local/lib -L/usr/lib/X11 -L/usr/X11R6/lib +LIBDIRS=-L. -L${LOCALBASE}/lib -Wl,--rpath,${LOCALBASE}/lib ++ ++.if defined(WITH_X11) +LIBDIRS+=-L${X11BASE}/lib -Wl,--rpath,${X11BASE}/lib ++.endif #Location where libgd.a should be installed by "make install". -INSTALL_LIB=/usr/local/lib @@ -81,13 +90,13 @@ # # -@@ -74,34 +88,44 @@ +@@ -74,34 +91,44 @@ VERSION=1.8.4 -CC=$(COMPILER) $(INCLUDEDIRS) -LINK=$(CC) $(LIBDIRS) $(LIBS) -+CC+=$(INCLUDEDIRS) ++CFLAGS+=$(INCLUDEDIRS) +#LINK=$(CC) $(LIBDIRS) $(LIBS) PROGRAMS=$(BIN_PROGRAMS) $(TEST_PROGRAMS) @@ -97,6 +106,8 @@ -all: libgd.a $(PROGRAMS) +SOVER=2 ++ ++.SUFFIXES: .c .so .o -install: libgd.a $(BIN_PROGRAMS) - sh ./install-item 644 libgd.a $(INSTALL_LIB)/libgd.a @@ -116,8 +127,6 @@ - sh ./install-item 644 gdfontmb.h $(INSTALL_INCLUDE)/gdfontmb.h - sh ./install-item 644 gdfonts.h $(INSTALL_INCLUDE)/gdfonts.h - sh ./install-item 644 gdfontt.h $(INSTALL_INCLUDE)/gdfontt.h -+.SUFFIXES: .c .so .o -+ +.c.so: + $(CC) -fpic -DPIC $(CFLAGS) -o $@ -c $< + @@ -147,7 +156,7 @@ gddemo: gddemo.o libgd.a $(CC) gddemo.o -o gddemo $(LIBDIRS) $(LIBS) -@@ -138,18 +162,21 @@ +@@ -138,18 +165,21 @@ gdtestttf: gdtestttf.o libgd.a $(CC) --verbose gdtestttf.o -o gdtestttf $(LIBDIRS) $(LIBS) >Release-Note: >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-ports" in the body of the message