diff options
Diffstat (limited to 'graphics')
-rw-r--r-- | graphics/ruby-gd/Makefile | 19 | ||||
-rw-r--r-- | graphics/ruby-gd/distinfo | 2 | ||||
-rw-r--r-- | graphics/ruby-gd/files/patch-GD.c | 30 | ||||
-rw-r--r-- | graphics/ruby-gd/pkg-plist | 1 |
4 files changed, 42 insertions, 10 deletions
diff --git a/graphics/ruby-gd/Makefile b/graphics/ruby-gd/Makefile index a4430b66b804..28b9193128d3 100644 --- a/graphics/ruby-gd/Makefile +++ b/graphics/ruby-gd/Makefile @@ -6,16 +6,17 @@ # PORTNAME= GD -PORTVERSION= 0.7.1 +PORTVERSION= 0.7.2 CATEGORIES= graphics ruby MASTER_SITES= http://kirara.prec.kyoto-u.ac.jp/~tam/GD/ PKGNAMEPREFIX= ${RUBY_PKGNAMEPREFIX} +PKGNAMESUFFIX= ${PKGNAMESUFFIX_XPM} DISTNAME= ruby-${PORTNAME}-${PORTVERSION} DIST_SUBDIR= ruby MAINTAINER= knu@FreeBSD.org -LIB_DEPENDS= gd.1:${PORTSDIR}/graphics/gd +LIB_DEPENDS= gd.2:${PORTSDIR}/graphics/gd USE_RUBY= yes USE_RUBY_EXTCONF= yes @@ -23,7 +24,8 @@ USE_RUBY_EXTCONF= yes USE_RUBY_RD= yes .endif -CONFIGURE_ARGS= --with-gd-include="${LOCALBASE}/include/gd" --with-jpeg +CONFIGURE_ARGS= --with-gd-include="${LOCALBASE}/include/gd" --with-jpeg \ + --with-freetype INSTALL_TARGET= site-install .include <bsd.port.pre.mk> @@ -32,19 +34,17 @@ INSTALL_TARGET= site-install .if exists(${LOCALBASE}/bin/gd2topng) WITH_X11_CHECK!= ldd ${LOCALBASE}/bin/gd2topng | grep -w 'libX11\.so' || true .else -WITH_X11_CHECK= #empty +WITH_X11_CHECK= # empty .endif .if !empty(WITH_X11_CHECK) USE_XLIB= yes USE_XPM= yes -USE_FREETYPE= yes - -CONFIGURE_ARGS+= --with-x-dir="${X11BASE}" --with-xpm --with-ttf +PKGNAMESUFFIX_XPM= +xpm +CONFIGURE_ARGS+= --with-x-dir="${X11BASE}" --with-xpm .endif EXAMPLES_EN= example.rb \ - gdtestttf.png \ gdtestttf.rb \ webpng.rb DOCS_EN= Changes \ @@ -82,6 +82,9 @@ TUTORIAL_JA= gd_intro-ja.html \ imgs/top.png \ imgs/xpy.png +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 diff --git a/graphics/ruby-gd/distinfo b/graphics/ruby-gd/distinfo index b9d669b44331..b749933c3e36 100644 --- a/graphics/ruby-gd/distinfo +++ b/graphics/ruby-gd/distinfo @@ -1 +1 @@ -MD5 (ruby/ruby-GD-0.7.1.tar.gz) = ed788e4adba576b6d5fe139a92c0e9ff +MD5 (ruby/ruby-GD-0.7.2.tar.gz) = 6a514c0bd7658823e196a2b775ddd12d diff --git a/graphics/ruby-gd/files/patch-GD.c b/graphics/ruby-gd/files/patch-GD.c new file mode 100644 index 000000000000..535d9899d452 --- /dev/null +++ b/graphics/ruby-gd/files/patch-GD.c @@ -0,0 +1,30 @@ +--- GD.c.orig Tue Feb 6 15:47:42 2001 ++++ GD.c Mon Feb 12 19:39:15 2001 +@@ -1200,7 +1200,7 @@ + Check_Type(fontname, T_STRING); + Check_Type(string, T_STRING); + +- msg = gdImageStringTTF(NULL, ++ msg = gdImageStringFT(NULL, + &brect[0], + NUM2INT(fgcolor), + RSTRING(fontname)->ptr, +@@ -1232,7 +1232,7 @@ + Check_Type(string, T_STRING); + + Data_Get_Struct(img, gdImage, im); +- msg = gdImageStringTTF(im, ++ msg = gdImageStringFT(im, + &brect[0], + NUM2INT(fgcolor), + RSTRING(fontname)->ptr, +@@ -1971,7 +1971,9 @@ + #endif + + #ifdef HAVE_GDIMAGESTRINGFT ++ rb_define_singleton_method(cImage, "stringTTF", img_s_string_ft, 7); + rb_define_singleton_method(cImage, "stringFT", img_s_string_ft, 7); ++ rb_define_method(cImage, "stringTTF", img_string_ft, 7); + rb_define_method(cImage, "stringFT", img_string_ft, 7); + #endif + diff --git a/graphics/ruby-gd/pkg-plist b/graphics/ruby-gd/pkg-plist index b9f21e750721..fff5e1acbffb 100644 --- a/graphics/ruby-gd/pkg-plist +++ b/graphics/ruby-gd/pkg-plist @@ -1,6 +1,5 @@ %%RUBY_SITEARCHLIBDIR%%/GD.so %%PORTDOCS%%%%RUBY_EXAMPLESDIR%%/gd/example.rb -%%PORTDOCS%%%%RUBY_EXAMPLESDIR%%/gd/gdtestttf.png %%PORTDOCS%%%%RUBY_EXAMPLESDIR%%/gd/gdtestttf.rb %%PORTDOCS%%%%RUBY_EXAMPLESDIR%%/gd/webpng.rb %%PORTDOCS%%@dirrm %%RUBY_EXAMPLESDIR%%/gd |