aboutsummaryrefslogtreecommitdiffstats
path: root/graphics
diff options
context:
space:
mode:
authordaichi <daichi@FreeBSD.org>2003-07-11 12:37:04 +0800
committerdaichi <daichi@FreeBSD.org>2003-07-11 12:37:04 +0800
commit9a78daf9274c189da849c0f35528c683eba1f2bf (patch)
tree37a5180a607dacf2dc8fb701be87e19f96702e8f /graphics
parent752bac4f90794953571f0f161b4e2b2d2e8d81d1 (diff)
downloadfreebsd-ports-graphics-9a78daf9274c189da849c0f35528c683eba1f2bf.tar.gz
freebsd-ports-graphics-9a78daf9274c189da849c0f35528c683eba1f2bf.tar.zst
freebsd-ports-graphics-9a78daf9274c189da849c0f35528c683eba1f2bf.zip
update graphics/gd2: build fail with CFLAGS of /etc/make.conf
Submitted by: KATO Tsuguru <tkato@prontomail.com> Pointed out by: Jon Noack <noackjr@alumni.rice.edu>
Diffstat (limited to 'graphics')
-rw-r--r--graphics/gd2/Makefile17
-rw-r--r--graphics/gd2/files/Makefile.bsd7
2 files changed, 13 insertions, 11 deletions
diff --git a/graphics/gd2/Makefile b/graphics/gd2/Makefile
index deffaac075c..a8153cb5444 100644
--- a/graphics/gd2/Makefile
+++ b/graphics/gd2/Makefile
@@ -22,34 +22,29 @@ LIB_DEPENDS= jpeg.9:${PORTSDIR}/graphics/jpeg \
LATEST_LINK= gd2
-MAKE_ENV= WRKSRC="${WRKSRC}" LDADD="${LDADD}"
+MAKE_ENV= WRKSRC="${WRKSRC}" CPPFLAGS="${CPPFLAGS}" LDFLAGS="${LDFLAGS}"
MAKEFILE= ${FILESDIR}/Makefile.bsd
INSTALLS_SHLIB= yes
-CFLAGS+= -I${WRKSRC} -I${LOCALBASE}/include/freetype2/freetype \
- -I${LOCALBASE}/include/freetype2 -I${LOCALBASE}/include \
- -DHAVE_LIBPNG -DHAVE_LIBJPEG -DHAVE_LIBFREETYPE -DHAVE_LIBZ
-LDADD= -L${LOCALBASE}/lib -lpng -lz -ljpeg -lfreetype -lm
-
.include <bsd.port.pre.mk>
.if defined(WITHOUT_X11) || defined(WITHOUT_XPM)
PKGNAMESUFFIX= -nox11
.if !defined(WITHOUT_XPM)
LIB_DEPENDS+= Xpm:${PORTSDIR}/graphics/xpm
-CFLAGS+= -I${X11BASE}/include/X11 -I${X11BASE}/include -DHAVE_LIBXPM \
+CPPFLAGS+= -I${X11BASE}/include/X11 -I${X11BASE}/include -DHAVE_LIBXPM \
-DXPM_NOX
-LDADD+= -L${X11BASE}/lib -lXpm
+LDFLAGS+= -L${X11BASE}/lib -lXpm
.endif
.else
USE_XPM= yes
-CFLAGS+= -I${X11BASE}/include/X11 -I${X11BASE}/include -DHAVE_LIBXPM
-LDADD+= -L${X11BASE}/lib -lXpm -lX11
+CPPFLAGS+= -I${X11BASE}/include/X11 -I${X11BASE}/include -DHAVE_LIBXPM
+LDFLAGS+= -L${X11BASE}/lib -lXpm -lX11
.endif
.if defined(WITH_LZW) || defined(HAVE_UNISYS_LICENSE) || \
(defined(USA_RESIDENT) && ${USA_RESIDENT} == "YES")
-CFLAGS+= -DLZW_LICENSED
+CPPFLAGS+= -DLZW_LICENSED
.endif
.if defined(GD_FONTS)
diff --git a/graphics/gd2/files/Makefile.bsd b/graphics/gd2/files/Makefile.bsd
index 81bab56e93e..a6530d92a53 100644
--- a/graphics/gd2/files/Makefile.bsd
+++ b/graphics/gd2/files/Makefile.bsd
@@ -18,6 +18,13 @@ INCS= gd.h gd_io.h gdcache.h gdfontg.h gdfontl.h gdfontmb.h \
SHLIB_NAME!= ${MAKE} -V SHLIB_NAME LIB=${LIB} \
SHLIB_MAJOR=${SHLIB_MAJOR} SHLIB_MINOR=${SHLIB_MINOR} -f ${MAKEDIR}/bsd.lib.mk
+CFLAGS+= -I${.CURDIR} -I${LOCALBASE}/include/freetype2/freetype \
+ -I${LOCALBASE}/include/freetype2 -I${LOCALBASE}/include \
+ -DHAVE_LIBPNG -DHAVE_LIBJPEG -DHAVE_LIBFREETYPE -DHAVE_LIBZ \
+ ${CPPFLAGS}
+LDADD= -L${LOCALBASE}/lib -lpng -lz -ljpeg -lfreetype -lm \
+ ${LDFLAGS}
+
# The package comes with tests, but without any sort of test-harness,
# to run them all automaticly. So building tests is disabled here. -mi
all: lib${LIB}.a ${SHLIB_NAME} ${PROGS} # ${TESTS}