mirror of
https://git.FreeBSD.org/ports.git
synced 2024-12-02 01:20:54 +00:00
82 lines
1.9 KiB
Makefile
82 lines
1.9 KiB
Makefile
# New ports collection makefile for: Ruby/gd
|
|
# Date created: 27 Sep 2000
|
|
# Whom: Akinori MUSHA aka knu <knu@idaemons.org>
|
|
#
|
|
# $FreeBSD$
|
|
#
|
|
|
|
PORTNAME= GD
|
|
PORTVERSION= 0.7.4
|
|
CATEGORIES= graphics ruby
|
|
MASTER_SITES= http://www.acc.ne.jp/~tam/GD/
|
|
PKGNAMEPREFIX= ${RUBY_PKGNAMEPREFIX}
|
|
PKGNAMESUFFIX= ${PKGNAMESUFFIX_XPM}
|
|
DISTNAME= ruby-${PORTNAME}-${PORTVERSION}
|
|
DIST_SUBDIR= ruby
|
|
|
|
MAINTAINER= knu@FreeBSD.org
|
|
|
|
BUILD_DEPENDS= freetype-config:${PORTSDIR}/print/freetype2 # XXX
|
|
LIB_DEPENDS= gd.2:${PORTSDIR}/graphics/gd
|
|
|
|
USE_RUBY= yes
|
|
USE_RUBY_EXTCONF= yes
|
|
.if !defined(NOPORTDOCS)
|
|
USE_RUBY_RD= yes
|
|
.endif
|
|
|
|
CONFIGURE_ARGS= --with-gd-include="${LOCALBASE}/include/gd" \
|
|
--with-gd-lib="${LOCALBASE}/lib" \
|
|
--with-jpeg \
|
|
--with-freetype
|
|
INSTALL_TARGET= site-install
|
|
|
|
.include <bsd.port.pre.mk>
|
|
|
|
# Hmm, GREP and TRUE seem to be defined in the bsd.port.post.mk stage.
|
|
.if exists(${LOCALBASE}/bin/gd2topng)
|
|
WITH_X11_CHECK!= ldd ${LOCALBASE}/bin/gd2topng | grep -w 'libX11\.so' || true
|
|
.else
|
|
WITH_X11_CHECK= # empty
|
|
.endif
|
|
|
|
.if !empty(WITH_X11_CHECK)
|
|
USE_XLIB= yes
|
|
USE_XPM= yes
|
|
PKGNAMESUFFIX_XPM= +xpm
|
|
CONFIGURE_ARGS+= --with-X11-dir="${X11BASE}" --with-xpm
|
|
.endif
|
|
|
|
EXAMPLES_EN= example.rb \
|
|
gdtestttf.rb \
|
|
webpng.rb
|
|
DOCS_EN= Changes \
|
|
TODO \
|
|
readme.en \
|
|
doc/INSTALL.en \
|
|
doc/manual.html \
|
|
doc/manual.rd \
|
|
doc/manual_index.html
|
|
DOCS_JA= readme.ja \
|
|
doc/INSTALL.ja
|
|
|
|
post-patch:
|
|
${RUBY} -i -pe 'sub %r:/win98/windows/FONTS:, "${X11BASE}/lib/X11/fonts/TrueType"' ${WRKSRC}/sample/gdtestttf.rb
|
|
|
|
post-install:
|
|
.if !defined(NOPORTDOCS)
|
|
${MKDIR} ${RUBY_EXAMPLESDIR}/gd
|
|
.for f in ${EXAMPLES_EN}
|
|
${INSTALL_DATA} ${WRKSRC}/sample/${f} ${RUBY_EXAMPLESDIR}/gd/
|
|
.endfor
|
|
${MKDIR} ${RUBY_DOCDIR}/gd/ja
|
|
.for f in ${DOCS_EN}
|
|
${INSTALL_DATA} ${WRKSRC}/${f} ${RUBY_DOCDIR}/gd/
|
|
.endfor
|
|
.for f in ${DOCS_JA}
|
|
${INSTALL_DATA} ${WRKSRC}/${f} ${RUBY_DOCDIR}/gd/ja/
|
|
.endfor
|
|
.endif
|
|
|
|
.include <bsd.port.post.mk>
|