Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 12 Apr 2014 08:03:15 +0000 (UTC)
From:      Pawel Pekala <pawel@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r351076 - head/astro/nightfall
Message-ID:  <201404120803.s3C83FpS020014@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: pawel
Date: Sat Apr 12 08:03:14 2014
New Revision: 351076
URL: http://svnweb.freebsd.org/changeset/ports/351076
QAT: https://qat.redports.org/buildarchive/r351076/

Log:
  - Fix build with clang34 (unrecognized option -fforce-addr)
  - Use options helpers and subs
  - Set correct plist subs for GNOME option

Modified:
  head/astro/nightfall/Makefile
  head/astro/nightfall/pkg-plist

Modified: head/astro/nightfall/Makefile
==============================================================================
--- head/astro/nightfall/Makefile	Sat Apr 12 07:56:55 2014	(r351075)
+++ head/astro/nightfall/Makefile	Sat Apr 12 08:03:14 2014	(r351076)
@@ -10,48 +10,47 @@ MASTER_SITES=	http://www.la-samhna.de/ni
 MAINTAINER=	ports@FreeBSD.org
 COMMENT=	Interactive binary star application
 
-OPTIONS_DEFINE=	GNOME PGPLOT OPENGL
-OPTIONS_DEFAULT=	PGPLOT OPENGL
-PGPLOT_DESC=	Enable PGPLOT support
-
-USES=		gmake pathfix gettext perl5
+USES=		compiler gettext gmake pathfix perl5 pkgconfig
 USE_GNOME=	gnomehier gtk20
 GNU_CONFIGURE=	yes
 CPPFLAGS+=	-I${LOCALBASE}/include
 LDFLAGS+=	-L${LOCALBASE}/lib
 CONFIGURE_ARGS=	--with-locale-prefix=${PREFIX}/share/locale
 
-.include <bsd.port.options.mk>
+OPTIONS_DEFINE=		GNOME PGPLOT OPENGL
+OPTIONS_DEFAULT=	PGPLOT OPENGL
+OPTIONS_SUB=		yes
+
+GNOME_CONFIGURE_ON=	--with-gnomedoc-prefix=${PREFIX}/share
+GNOME_CONFIGURE_OFF=	--disable-gnome
+GNOME_USE=		GNOME=gnomeprefix,libgnomeui
+
+OPENGL_CONFIGURE_ON=	--with-lib-GL
+OPENGL_CONFIGURE_OFF=	--disable-opengl
+OPENGL_LIB_DEPENDS=	libgtkgl-2.0.so:${PORTSDIR}/x11-toolkits/gtkglarea2
+OPENGL_USE=		GL=glut
+
+PGPLOT_DESC=		PGPLOT support
+PGPLOT_CONFIGURE_ON=	--with-pgplot-include=${LOCALBASE}/include \
+			--with-pgplot-lib=${LOCALBASE}/lib
+PGPLOT_CONFIGURE_OFF=	--with-gnuplot
+PGPLOT_LIB_DEPENDS=	libpgplot.so:${PORTSDIR}/graphics/pgplot
+PGPLOT_USES=		fortran
+
+.include <bsd.port.pre.mk>
 
 .if ${PORT_OPTIONS:MGNOMEUI}
-USE_GNOME+=	gnomeprefix libgnomeui
-CONFIGURE_ARGS+=	--with-gnomedoc-prefix=${PREFIX}/share
 INSTALLS_OMF=	yes
-PLIST_SUB+=	GNOMEUI=""
-.else
-CONFIGURE_ARGS+=	--disable-gnome
-PLIST_SUB+=	GNOMEUI="@comment "
 .endif
 
-.if ${PORT_OPTIONS:MPGPLOT}
-LIB_DEPENDS+=	libpgplot.so:${PORTSDIR}/graphics/pgplot
-USES+=		fortran
-CONFIGURE_ARGS+=	--with-pgplot-include=${LOCALBASE}/include \
-			--with-pgplot-lib=${LOCALBASE}/lib
-.else
+.if ! ${PORT_OPTIONS:MPGPLOT}
 RUN_DEPENDS+=	gnuplot:${PORTSDIR}/math/gnuplot
-CONFIGURE_ARGS+=	--with-gnuplot
-.endif
-
-.if ${PORT_OPTIONS:MOPENGL}
-LIB_DEPENDS+=	libgtkgl-2.0.so:${PORTSDIR}/x11-toolkits/gtkglarea2
-USE_GL=		glut
-CONFIGURE_ARGS+=	--with-lib-GL
-.else
-CONFIGURE_ARGS+=	--disable-opengl
 .endif
 
 post-patch:
+.if ${COMPILER_TYPE} == clang
+	@${REINPLACE_CMD} -e 's|-fforce-addr||' ${WRKSRC}/configure
+.endif
 	@${REINPLACE_CMD} -e 's|CFLAGS -O3|CFLAGS|g' ${WRKSRC}/configure
 	@${REINPLACE_CMD} -e 's|^Icon=gnome|Icon=${DATADIR}/pixmaps|g' \
 		${WRKSRC}/nightfall.desktop
@@ -60,4 +59,4 @@ post-install:
 	${INSTALL_DATA} ${WRKSRC}/nightfall.desktop \
 		${STAGEDIR}${PREFIX}/share/applications
 
-.include <bsd.port.mk>
+.include <bsd.port.post.mk>

Modified: head/astro/nightfall/pkg-plist
==============================================================================
--- head/astro/nightfall/pkg-plist	Sat Apr 12 07:56:55 2014	(r351075)
+++ head/astro/nightfall/pkg-plist	Sat Apr 12 08:03:14 2014	(r351076)
@@ -1,8 +1,8 @@
 bin/nightfall
 man/man1/nightfall.1.gz
 share/applications/nightfall.desktop
-%%GNOMEUI%%share/gnome/help/nightfall/C/nightfall.xml
-%%GNOMEUI%%share/gnome/help/nightfall/de/nightfall.xml
+%%GNOME%%share/gnome/help/nightfall/C/nightfall.xml
+%%GNOME%%share/gnome/help/nightfall/de/nightfall.xml
 share/locale/de/LC_MESSAGES/nightfall.mo
 share/locale/it/LC_MESSAGES/nightfall.mo
 %%DATADIR%%/cfg/51_peg.cfg
@@ -90,9 +90,9 @@ share/locale/it/LC_MESSAGES/nightfall.mo
 %%DATADIR%%/pixmaps/starp_256.jpg
 %%DATADIR%%/pixmaps/stars_128.jpg
 %%DATADIR%%/pixmaps/stars_256.jpg
-%%GNOMEUI%%share/omf/nightfall/nightfall-C.omf
-%%GNOMEUI%%share/omf/nightfall/nightfall-de.omf
-%%GNOMEUI%%@dirrm share/omf/nightfall
+%%GNOME%%share/omf/nightfall/nightfall-C.omf
+%%GNOME%%share/omf/nightfall/nightfall-de.omf
+%%GNOME%%@dirrm share/omf/nightfall
 @dirrm %%DATADIR%%/pixmaps
 @dirrm %%DATADIR%%/doc/de/edu
 @dirrm %%DATADIR%%/doc/de
@@ -102,6 +102,6 @@ share/locale/it/LC_MESSAGES/nightfall.mo
 @dirrm %%DATADIR%%/data
 @dirrm %%DATADIR%%/cfg
 @dirrm %%DATADIR%%
-%%GNOMEUI%%@dirrm share/gnome/help/nightfall/de
-%%GNOMEUI%%@dirrm share/gnome/help/nightfall/C
-%%GNOMEUI%%@dirrm share/gnome/help/nightfall
+%%GNOME%%@dirrm share/gnome/help/nightfall/de
+%%GNOME%%@dirrm share/gnome/help/nightfall/C
+%%GNOME%%@dirrm share/gnome/help/nightfall



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201404120803.s3C83FpS020014>