1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-11-19 00:13:33 +00:00

games/critterding: prepare for freetype2 update

- freetype2 will no longer ship freetype-config (which was a pkg-config
  wrapper) in the near future -- use pkg-config to gather the required
  flags.

- while here, convert to USES=localbase

PR:		251512
This commit is contained in:
Tobias C. Berner 2021-08-06 14:43:41 +02:00
parent b69b6e55f0
commit 197e928ffb
2 changed files with 27 additions and 3 deletions

View File

@ -9,12 +9,10 @@ COMMENT= Evolving Artificial Life
LIB_DEPENDS= libfreetype.so:print/freetype2
USES= autoreconf gl libtool ncurses pkgconfig sdl tar:bzip2
USES= autoreconf gl libtool localbase:ldflags ncurses pkgconfig sdl tar:bzip2
GNU_CONFIGURE= yes
USE_SDL= sdl
USE_GL= gl
CPPFLAGS+= -I${LOCALBASE}/include -I${LOCALBASE}/include/freetype2
LDFLAGS+= -L${LOCALBASE}/lib
CONFIGURE_ARGS= --disable-system-ftgl
USE_GCC= yes
@ -24,6 +22,8 @@ PORTDOCS= README AUTHORS Changelog
OPTIONS_DEFINE= DOCS
BINARY_ALIAS= freetype-config=true
post-patch:
@${REINPLACE_CMD} -e 's|../share/critterding|${DATADIR}|' \
${WRKSRC}/src/gui/textprinter.cpp ${WRKSRC}/src/gl/glwindow.cpp

View File

@ -0,0 +1,24 @@
--- configure.in.orig 2010-02-19 13:26:47 UTC
+++ configure.in
@@ -77,8 +77,8 @@ AC_SUBST(SDLMAIN)
AC_MSG_CHECKING(for Freetype)
AC_CHECK_PROG([FREETYPE_CONFIG],[freetype-config],yes,no)
if test "$FREETYPE_CONFIG" = yes; then
- FT2_CFLAGS=`freetype-config --cflags`
- FT2_LIBS=`freetype-config --libs`
+ FT2_CFLAGS=`pkg-config freetype2 --cflags`
+ FT2_LIBS=`pkg-config freetype2 --libs`
AC_MSG_RESULT($FT2_CFLAGS)
CPPFLAGS="$CPPFLAGS $FT2_CFLAGS"
HOST_LIBS="$HOST_LIBS $FT2_LIBS"
@@ -94,8 +94,8 @@ AC_SUBST(SDLMAIN)
AC_MSG_CHECKING(for Freetype)
AC_CHECK_PROG([FREETYPE_CONFIG],[freetype-config],yes,no)
if test "$FREETYPE_CONFIG" = yes; then
- FT2_CFLAGS=`freetype-config --cflags`
- FT2_LIBS=`freetype-config --libs`
+ FT2_CFLAGS=`pkg-config freetype2 --cflags`
+ FT2_LIBS=`pkg-config freetype2 --libs`
AC_MSG_RESULT($FT2_CFLAGS)
CPPFLAGS="$CPPFLAGS $FT2_CFLAGS"
HOST_LIBS="$HOST_LIBS $FT2_LIBS"