Date: Mon, 4 May 2020 11:17:04 +0000 (UTC) From: Dirk Meyer <dinoex@FreeBSD.org> To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r533918 - in head/graphics/ruby-gd: . files Message-ID: <202005041117.044BH4s8008903@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: dinoex Date: Mon May 4 11:17:03 2020 New Revision: 533918 URL: https://svnweb.freebsd.org/changeset/ports/533918 Log: - fix gd with xpm - fix dependecies - drop xpm suffix Added: head/graphics/ruby-gd/files/patch-xpm (contents, props changed) Deleted: head/graphics/ruby-gd/files/patch-extconf.rb Modified: head/graphics/ruby-gd/Makefile Modified: head/graphics/ruby-gd/Makefile ============================================================================== --- head/graphics/ruby-gd/Makefile Mon May 4 11:15:24 2020 (r533917) +++ head/graphics/ruby-gd/Makefile Mon May 4 11:17:03 2020 (r533918) @@ -3,12 +3,11 @@ PORTNAME= gd PORTVERSION= 0.8.0 -PORTREVISION= 6 +PORTREVISION= 7 CATEGORIES= graphics ruby MASTER_SITES= ftp://ftp.jp.vim.org/pub/distfiles/ruby/ \ http://www.mmnt.net/db/0/8/ftp.jp.vim.org/pub/distfiles/ruby/ PKGNAMEPREFIX= ${RUBY_PKGNAMEPREFIX} -PKGNAMESUFFIX= ${PKGNAMESUFFIX_XPM} DISTNAME= ruby-GD-0.7.4 DIST_SUBDIR= ruby @@ -16,19 +15,21 @@ MAINTAINER= dinoex@FreeBSD.org COMMENT= Ruby extension library to use Thomas Boutell's gd library LIB_DEPENDS= libfreetype.so:print/freetype2 \ - libgd.so:graphics/gd + libgd.so:graphics/gd \ + libpng.so:graphics/png +USES= jpeg USE_RUBY= yes USE_RUBY_EXTCONF= yes RUBY_MODNAME= ${PORTNAME:tl} -CONFIGURE_ARGS= --with-gd-lib="${LOCALBASE}/lib" \ - --with-jpeg \ +CONFIGURE_ARGS= --with-jpeg \ --with-ttf \ --with-freetype \ - --enable-gd2_0 \ - --with-gd-include="${LOCALBASE}/include" + --with-z \ + --with-png \ + --enable-gd2_0 INSTALL_TARGET= site-install @@ -38,15 +39,14 @@ OPTIONS_DEFINE= DOCS EXAMPLES # 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' || ${ECHO_CMD} +GD_X11_CHECK!= ldd ${LOCALBASE}/bin/gd2topng | grep -w 'libX11\.so' || ${ECHO_CMD} .else -WITH_X11_CHECK= # empty +GD_X11_CHECK= # empty .endif -.if !empty(WITH_X11_CHECK) +.if !empty(GD_X11_CHECK) USES= xorg USE_XORG= xpm x11 -PKGNAMESUFFIX_XPM= +xpm CONFIGURE_ARGS+= --with-X11-dir="${LOCALBASE}" --with-xpm .endif @@ -65,7 +65,6 @@ DOCS_JA= readme.ja \ post-patch: ${RUBY} -i -pe 'sub %r:/win98/windows/FONTS:, "${LOCALBASE}/share/fonts/TrueType"' ${WRKSRC}/sample/gdtestttf.rb - ${RUBY} -i -pe 'sub %r:%%GD%%:, "gd"' ${WRKSRC}/extconf.rb post-configure: ${REINPLACE_CMD} -e 's|^V = 0|V = 1|' \ Added: head/graphics/ruby-gd/files/patch-xpm ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/graphics/ruby-gd/files/patch-xpm Mon May 4 11:17:03 2020 (r533918) @@ -0,0 +1,26 @@ +--- GD.c.orig 2020-04-30 23:33:14 UTC ++++ GD.c +@@ -341,9 +341,9 @@ img_from_xpm(klass, f) + rb_io_check_readable(fptr); + + /* need cast, and the argument is char* type */ +- iptr = (gdImagePtr)gdImageCreateFromXpm(fptr->path); ++ iptr = (gdImagePtr)gdImageCreateFromXpm(FPTR_PATH); + if (!iptr) +- rb_raise(rb_eArgError, "%s is not a valid XPM File", (char*)fptr->path); ++ rb_raise(rb_eArgError, "%s is not a valid XPM File", FPTR_PATH); + + return Data_Wrap_Struct(klass,0,free_img,iptr); + } +@@ -364,9 +364,9 @@ img_from_xpmfname(klass, fname) + rb_io_check_readable(fptr); + + /* need cast, and the argument is char* type */ +- iptr = (gdImagePtr)gdImageCreateFromXpm(fptr->path); ++ iptr = (gdImagePtr)gdImageCreateFromXpm(FPTR_PATH); + if (!iptr) +- rb_raise(rb_eArgError, "%s is not a valid XPM File", (char*)fptr->path); ++ rb_raise(rb_eArgError, "%s is not a valid XPM File", FPTR_PATH); + + return Data_Wrap_Struct(klass,0,free_img,iptr); + }
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202005041117.044BH4s8008903>