Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 3 Sep 2014 03:31:26 +0000 (UTC)
From:      "Vanilla I. Shu" <vanilla@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r367148 - head/graphics/megapov
Message-ID:  <201409030331.s833VQK4051157@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: vanilla
Date: Wed Sep  3 03:31:25 2014
New Revision: 367148
URL: http://svnweb.freebsd.org/changeset/ports/367148
QAT: https://qat.redports.org/buildarchive/r367148/

Log:
  Stagify.
  
  PR:		ports/193158
  Submitted by:	Ports Fury.

Deleted:
  head/graphics/megapov/pkg-plist
Modified:
  head/graphics/megapov/Makefile

Modified: head/graphics/megapov/Makefile
==============================================================================
--- head/graphics/megapov/Makefile	Wed Sep  3 03:27:41 2014	(r367147)
+++ head/graphics/megapov/Makefile	Wed Sep  3 03:31:25 2014	(r367148)
@@ -10,56 +10,49 @@ MASTER_SITES=	http://megapov.inetart.net
 MAINTAINER=	ports@FreeBSD.org
 COMMENT=	Unofficial extensions of POV-Ray
 
-RUN_DEPENDS=	povray:${PORTSDIR}/graphics/povray-meta
 LIB_DEPENDS=	libpng15.so:${PORTSDIR}/graphics/png \
 		libjpeg.so:${PORTSDIR}/graphics/jpeg \
 		libtiff.so:${PORTSDIR}/graphics/tiff
-
+#RUN_DEPENDS=	povray:${PORTSDIR}/graphics/povray-meta
 
 WRKSRC=		${WRKDIR}/${PORTNAME}-${PORTVERSION}
+INSTALL_WRKSRC=	${WRKSRC}/unix
+
 USES=		gmake tar:bzip2
 GNU_CONFIGURE=	yes
-ALL_TARGET=	# empty
-CONFIGURE_ARGS+=	COMPILED_BY="ports@FreeBSD.org"
-LDFLAGS+= -L${LOCALBASE}/lib -L${LOCALBASE}/lib
-CFLAGS+= -I${LOCALBASE}/include -I${LOCALBASE}/include/libpng15
-CXXFLAGS+= -I${LOCALBASE}/include -I${LOCALBASE}/include/libpng15
-CPPFLAGS+= -I${LOCALBASE}/include -I${LOCALBASE}/include/libpng15
-
-NO_STAGE=	yes
-.include <bsd.port.pre.mk>
-
-.if (${ARCH} == "i386")
-LIB_DEPENDS+=	libvga.so:${PORTSDIR}/graphics/svgalib
-.endif
-
-.if defined(WITH_OPTIMIZED_FLAGS)
-CFLAGS+=	-O3 -ffast-math -finline-functions -fomit-frame-pointer -funroll-loops -fexpensive-optimizations
-CXXFLAGS+=	-O3 -ffast-math -finline-functions -fomit-frame-pointer -funroll-loops -fexpensive-optimizations
-.if (${ARCH} == "i386")
-CFLAGS+=	-mcpu=i686 -march=i686 -mfancy-math-387
-CXXFLAGS+=	-mcpu=i686 -march=i686 -mfancy-math-387
-.endif # i386
-.endif
-
-pre-build:
-.if !defined(WITH_OPTIMIZED_FLAGS)
-	@${ECHO} "You can optimize by setting WITH_OPTIMIZED_FLAGS=yes."
-.endif
-
-do-install:
-	@(cd ${WRKSRC}/unix    ; ${MAKE_CMD} install)
-.if !defined(NOPORTDOCS)
-	${MKDIR} ${DOCSDIR}
-	@${TAR} -C ${WRKSRC}/doc -cf - . | \
-		${TAR} -C ${DOCSDIR} -xf -
-	@${FIND} ${DOCSDIR} | ${XARGS} ${CHOWN} ${SHAREOWN}:${SHAREGRP}
-	@${FIND} ${DOCSDIR} -type f | ${XARGS} ${CHMOD} ${SHAREMODE}
-	@${MKDIR} ${EXAMPLESDIR}
-	@${TAR} -C ${WRKSRC} -cf - include scenes  | \
-		${TAR} -C ${EXAMPLESDIR} -xf -
-	@${FIND} ${EXAMPLESDIR} | ${XARGS} ${CHOWN} ${SHAREOWN}:${SHAREGRP}
-	@${FIND} ${EXAMPLESDIR} -type f | ${XARGS} ${CHMOD} ${SHAREMODE}
-.endif
+CONFIGURE_ARGS=	COMPILED_BY="ports@FreeBSD.org"
+
+CFLAGS+=	-I${LOCALBASE}/include
+CPPFLAGS+=	$$(libpng-config --I_opts) -I${LOCALBASE}/include
+LDFLAGS+=	$$(libpng-config --L_opts) -L${LOCALBASE}/lib
+
+PORTDOCS=	*
+PORTEXAMPLES=	*
+PLIST_FILES=	bin/megapov
+
+OPTIONS_DEFINE=		DOCS EXAMPLES OPTIMIZED_CFLAGS X11
+OPTIONS_DEFINE_amd64=	SVGALIB
+OPTIONS_DEFINE_i386=	SVGALIB
+
+OPTIMIZED_CFLAGS_CFLAGS=\
+			-O3 -ffast-math -finline-functions \
+			-fomit-frame-pointer -funroll-loops \
+			-fexpensive-optimizations
+SVGALIB_LIB_DEPENDS=	libvga.so:${PORTSDIR}/graphics/svgalib
+SVGALIB_CONFIGURE_WITH=	svga
+X11_USE=		xorg=x11,xpm
+X11_CONFIGURE_WITH=	x
+
+post-patch:
+	@${REINPLACE_CMD} -e \
+		's|"-O3"|""|' ${WRKSRC}/configure
+
+post-install:
+	@${MKDIR} ${STAGEDIR}${DOCSDIR}
+	@(cd ${WRKSRC}/doc && ${COPYTREE_SHARE} . ${STAGEDIR}${DOCSDIR})
+	@${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
+.for i in include scenes
+	@(cd ${WRKSRC} && ${COPYTREE_SHARE} ${i} ${STAGEDIR}${EXAMPLESDIR})
+.endfor
 
-.include <bsd.port.post.mk>
+.include <bsd.port.mk>



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