summaryrefslogtreecommitdiff
path: root/graphics/gd2
diff options
context:
space:
mode:
authorMikhail Teterin <mi@FreeBSD.org>2002-07-16 18:19:27 +0000
committerMikhail Teterin <mi@FreeBSD.org>2002-07-16 18:19:27 +0000
commit2f7b4d7b2b415a379541e27d5f9f4f8c19e0da4b (patch)
tree0344efd3d5c26e4d2f68d7dc1c60c18e856bc3e9 /graphics/gd2
parentFix installation on -current. (diff)
Avoid using Perl in the default case, and BUILD_DEPEND on it if
the alternative fonts are specified. Using USE_PERL seems to cause run-time dependency as well, which is bogus in this case. Also, use explicit PATH to bsd.*.mk -- for some reasons, just make -f bsd.prog.mk no longer works... See the PR's history. PR: ports/40479
Notes
Notes: svn path=/head/; revision=63099
Diffstat (limited to 'graphics/gd2')
-rw-r--r--graphics/gd2/Makefile6
-rw-r--r--graphics/gd2/files/Makefile.bsd9
2 files changed, 10 insertions, 5 deletions
diff --git a/graphics/gd2/Makefile b/graphics/gd2/Makefile
index 731f67663b5d..8178a83252c8 100644
--- a/graphics/gd2/Makefile
+++ b/graphics/gd2/Makefile
@@ -53,7 +53,10 @@ post-extract:
post-patch:
.if !defined(WITH_LZW)
- @${PERL} -pi -e "s|#define LZW_LICENCED||g" ${WRKSRC}/gd_gif_out.c
+ ${MV} ${WRKSRC}/gd_gif_out.c ${WRKSRC}/gd_gif_out.c.gif && \
+ ${SED} -e "s|#define LZW_LICENCED||g" \
+ < ${WRKSRC}/gd_gif_out.c.nogif \
+ > ${WRKSRC}/gd_gif_out.c
.endif
post-install:
@@ -63,6 +66,7 @@ post-install:
.endif
.if defined(GD_FONTS)
+BUILD_DEPENDS= perl:${PORTSDIR}/lang/perl5
SCRIPTS_ENV+= GD_FONTS="${GD_FONTS}"
.endif
diff --git a/graphics/gd2/files/Makefile.bsd b/graphics/gd2/files/Makefile.bsd
index 8d8f201616a5..e70ac180e29b 100644
--- a/graphics/gd2/files/Makefile.bsd
+++ b/graphics/gd2/files/Makefile.bsd
@@ -1,6 +1,7 @@
PROGS!= make -V BIN_PROGRAMS -f ${WRKSRC}/Makefile
TESTS!= make -V TEST_PROGRAMS -f ${WRKSRC}/Makefile
OBJS!= make -V LIBOBJS -f ${WRKSRC}/Makefile
+MAKEDIR=/usr/share/mk
SRCS= ${OBJS:.o=.c}
LIB=gd
SHLIB_MAJOR=4
@@ -8,7 +9,7 @@ SHLIB_MINOR=0
INCS= gd.h gd_io.h gdcache.h gdfontg.h gdfontl.h gdfontmb.h \
gdfonts.h gdfontt.h
SHLIB_NAME!= make -V SHLIB_NAME LIB=${LIB} \
- SHLIB_MAJOR=${SHLIB_MAJOR} SHLIB_MINOR=${SHLIB_MINOR} -f bsd.lib.mk
+ SHLIB_MAJOR=${SHLIB_MAJOR} SHLIB_MINOR=${SHLIB_MINOR} -f ${MAKEDIR}/bsd.lib.mk
CFLAGS+=-I${.CURDIR} -I${LOCALBASE}/include/freetype2/ \
-I${LOCALBASE}/include/freetype2/freetype -I${LOCALBASE}/include \
@@ -33,17 +34,17 @@ lib${LIB}.a ${SHLIB_NAME}: ${SRCS}
make LIB=${LIB} SRCS="${SRCS}" \
SHLIB_MAJOR=${SHLIB_MAJOR} SHLIB_MINOR=${SHLIB_MINOR} \
CFLAGS="${CFLAGS}" -ECFLAGS LDADD="${LDADD}" \
- -f bsd.lib.mk ${.TARGET}
+ -f ${MAKEDIR}/bsd.lib.mk ${.TARGET}
${PROGS} ${TESTS}: ${SHLIB_NAME} lib${LIB}.a
make PROG=${.TARGET} NOMAN=1 LDADD="-L. -lgd" \
- CFLAGS="${CFLAGS}" -ECFLAGS -f bsd.prog.mk
+ CFLAGS="${CFLAGS}" -ECFLAGS -f ${MAKEDIR}/bsd.prog.mk
install:
mkdir -p ${PREFIX}/include
make LIB=${LIB} LIBDIR=${PREFIX}/lib NOPROFILE=true \
SHLIB_MAJOR=${SHLIB_MAJOR} SHLIB_MINOR=${SHLIB_MINOR} \
- -f bsd.lib.mk install
+ -f ${MAKEDIR}/bsd.lib.mk install
cd ${.CURDIR} && ${INSTALL_DATA} ${INCS} ${PREFIX}/include
cd ${.CURDIR} && ${INSTALL_PROGRAM} ${PROGS} ${PREFIX}/bin/
${INSTALL_SCRIPT} ${.CURDIR}/bdftogd ${PREFIX}/bin/