Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 27 Dec 2013 14:06:00 +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: r337731 - in head/graphics/gsculpt: . files
Message-ID:  <201312271406.rBRE60V1060077@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: pawel
Date: Fri Dec 27 14:05:59 2013
New Revision: 337731
URL: http://svnweb.freebsd.org/changeset/ports/337731

Log:
  - Fix build with clang
  - Remove leading article from COMMENT
  - Add desktop entry file
  - Strip library objects
  - Support staging
  
  Yes, I use prefix=${STAGEDIR}${PREFIX} here, after a long while it was
  5 lines of REINPLACE_CMD vs rewriting scons install script.
  
  <badmouthing of scons goes here>
  
  PR:		ports/184868
  Submitted by:	KATO Tsuguru <tkato432@yahoo.com>

Added:
  head/graphics/gsculpt/files/patch-cpp__Util__Pool.h   (contents, props changed)
Modified:
  head/graphics/gsculpt/Makefile
  head/graphics/gsculpt/pkg-plist   (contents, props changed)

Modified: head/graphics/gsculpt/Makefile
==============================================================================
--- head/graphics/gsculpt/Makefile	Fri Dec 27 13:17:27 2013	(r337730)
+++ head/graphics/gsculpt/Makefile	Fri Dec 27 14:05:59 2013	(r337731)
@@ -3,13 +3,13 @@
 
 PORTNAME=	gsculpt
 PORTVERSION=	0.99.47
-PORTREVISION=	3
+PORTREVISION=	4
 CATEGORIES=	graphics
 MASTER_SITES=	SF/${PORTNAME}/${PORTNAME}/${DISTNAME:S,-src,,}
 DISTNAME=	gSculpt-${PORTVERSION}-alpha-src
 
 MAINTAINER=	ports@FreeBSD.org
-COMMENT=	An Opensource 3D modelling application
+COMMENT=	Opensource 3D modelling application
 
 LICENSE=	GPLv2
 
@@ -19,18 +19,19 @@ RUN_DEPENDS=	${PYTHON_PKGNAMEPREFIX}open
 
 WRKSRC=		${WRKDIR}/${DISTNAME:S,-src,,}
 
-USES=		pkgconfig
+USES=		pkgconfig scons
 USE_GNOME=	pygtk2
 USE_GL=		glu
 USE_XORG=	x11
-USE_PYTHON=	2.4+
-USE_SCONS=	yes
-SCONS_BUILDENV=	${SCONS_ENV}
+USE_PYTHON=	2
 USE_LDCONFIG=	${PREFIX}/lib/gSculpt
 
 DATADIR=	${PREFIX}/share/gSculpt
 
-NO_STAGE=	yes
+DESKTOP_ENTRIES="gSculpt" "" \
+		"${DATADIR}/gsimages/gSculpt_Glass_Master_by_Gary_Rose.png" \
+		"${PORTNAME}" "Graphics;GTK;" ""
+
 .include <bsd.port.pre.mk>
 
 .if ${ARCH} == "ia64" || ${ARCH} == "powerpc" || ${ARCH} == "sparc64"
@@ -53,11 +54,21 @@ post-patch:
 		 /^cppLibs/s|BackgroundModel|BackgroundMesh|" \
 		${WRKSRC}/SConstruct
 	@${REINPLACE_CMD} -e \
-		"/^prefix/s|=.*|= '${PREFIX}'| ; \
+		"/^prefix/s|=.*|= '${STAGEDIR}${PREFIX}'| ; \
 		 /^gSculptStartDir/s|=.*|= os.path.join( pysitelibdir )|" \
 		${WRKSRC}/SConstruct-install
+	@${REINPLACE_CMD} -e \
+		"s|#GSCULPT_LIBRARY_PATH#|${LOCALBASE}/lib/gSculpt|; \
+		 s|python|${PYTHON_CMD}|; \
+		 s|#GSCULPT_START#|${PYTHONPREFIX_SITELIBDIR}/gsculpt.py|" \
+		${WRKSRC}/posixbuild/gsculpt
 
 do-install:
-	@cd ${WRKSRC} && ${SCONS_BIN} -f SConstruct-install ${PREFIX}
+	@(cd ${WRKSRC} && ${SCONS} -f SConstruct-install install)
+	@(cd ${STAGEDIR}${PREFIX} && ${PYTHON_CMD} -m compileall \
+		-d ${PREFIX} -f ${PYTHONPREFIX_SITELIBDIR:S;${PREFIX}/;;})
+	@${FIND} ${STAGEDIR}${PYTHONPREFIX_SITELIBDIR}/Britefury \
+		-name "*.so" -exec ${STRIP_CMD} {} \;
+	@${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/gSculpt/*.so
 
 .include <bsd.port.post.mk>

Added: head/graphics/gsculpt/files/patch-cpp__Util__Pool.h
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/graphics/gsculpt/files/patch-cpp__Util__Pool.h	Fri Dec 27 14:05:59 2013	(r337731)
@@ -0,0 +1,10 @@
+--- cpp/Util/Pool.h.orig
++++ cpp/Util/Pool.h
+@@ -8,6 +8,7 @@
+ #ifndef POOL_H__
+ #define POOL_H__
+ 
++#include <cstdlib>
+ #include <memory.h>
+ 
+ #include <Util/Array.h>

Modified: head/graphics/gsculpt/pkg-plist
==============================================================================
--- head/graphics/gsculpt/pkg-plist	Fri Dec 27 13:17:27 2013	(r337730)
+++ head/graphics/gsculpt/pkg-plist	Fri Dec 27 14:05:59 2013	(r337731)
@@ -486,6 +486,7 @@ lib/gSculpt/libView.so
 %%PYTHON_SITELIBDIR%%/Britefury/gSculptConfig/gSculptConfig.pyc
 %%PYTHON_SITELIBDIR%%/Britefury/gSculptConfig/gSculptUserConfig.pyc
 %%PYTHON_SITELIBDIR%%/gsculpt.py
+%%PYTHON_SITELIBDIR%%/gsculpt.pyc
 %%DATADIR%%/gsimages/background_images.png
 %%DATADIR%%/gsimages/background_models.png
 %%DATADIR%%/gsimages/draw_backg_transparent.png



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