Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 8 Feb 2016 19:15:59 +0000 (UTC)
From:      Dmitry Marakasov <amdmi3@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r408502 - in head/science/avogadro: . files
Message-ID:  <201602081915.u18JFxx7001759@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: amdmi3
Date: Mon Feb  8 19:15:59 2016
New Revision: 408502
URL: https://svnweb.freebsd.org/changeset/ports/408502

Log:
  - Fix build with boost 1.60
  - Switch to options helpers
  - Add LICENSE_FILE
  
  PR:		199601

Added:
  head/science/avogadro/files/patch-libavogadro_src_pythonengine__p.h   (contents, props changed)
  head/science/avogadro/files/patch-libavogadro_src_pythonextension__p.h   (contents, props changed)
  head/science/avogadro/files/patch-libavogadro_src_pythoninterpreter.h   (contents, props changed)
  head/science/avogadro/files/patch-libavogadro_src_pythonscript.h   (contents, props changed)
  head/science/avogadro/files/patch-libavogadro_src_pythontool__p.h   (contents, props changed)
Modified:
  head/science/avogadro/Makefile

Modified: head/science/avogadro/Makefile
==============================================================================
--- head/science/avogadro/Makefile	Mon Feb  8 19:13:01 2016	(r408501)
+++ head/science/avogadro/Makefile	Mon Feb  8 19:15:59 2016	(r408502)
@@ -11,14 +11,11 @@ MAINTAINER=	ports@FreeBSD.org
 COMMENT=	Advanced molecular editor and viewer
 
 LICENSE=	GPLv2+
+LICENSE_FILE=	${WRKSRC}/COPYING
 
 BUILD_DEPENDS=	eigen2>2:${PORTSDIR}/math/eigen2
 LIB_DEPENDS=	libopenbabel.so:${PORTSDIR}/science/openbabel
 
-OPTIONS_DEFINE=	PYTHON
-OPTIONS_DEFAULT=PYTHON
-OPTIONS_SUB=	yes
-
 USES=		cmake desktop-file-utils pkgconfig tar:bzip2
 USE_GL=		glu gl
 USE_QT4=	gui network opengl \
@@ -32,20 +29,19 @@ CFLAGS+=	-idirafter ${LOCALBASE}/include
 		-I${LOCALBASE}/include
 LDFLAGS+=	-L${LOCALBASE}/lib
 
-.include <bsd.port.options.mk>
+OPTIONS_DEFINE=	PYTHON
+OPTIONS_DEFAULT=PYTHON
+OPTIONS_SUB=	yes
 
-.if ${PORT_OPTIONS:MPYTHON}
-USES+=		python:2
-BUILD_DEPENDS+=	${PYNUMPY} \
-		${PYTHON_PKGNAMEPREFIX}sip>0:${PORTSDIR}/devel/py-sip
-LIB_DEPENDS+=	libboost_python.so:${PORTSDIR}/devel/boost-python-libs
-RUN_DEPENDS+=	${PYNUMPY} \
-		${PYTHON_PKGNAMEPREFIX}sip>0:${PORTSDIR}/devel/py-sip
-CMAKE_ARGS+=	-DENABLE_PYTHON=ON \
-		-DPYTHON_INCLUDE_DIR:PATH=${WRKDIR}/include/${PYTHON_VERSION}
-.else
-CMAKE_ARGS+=	-DENABLE_PYTHON=OFF
-.endif
+PYTHON_USES=		python:2
+PYTHON_BUILD_DEPENDS=	${PYNUMPY} \
+			${PYTHON_PKGNAMEPREFIX}sip>0:${PORTSDIR}/devel/py-sip
+PYTHON_LIB_DEPENDS=	libboost_python.so:${PORTSDIR}/devel/boost-python-libs
+PYTHON_RUN_DEPENDS=	${PYNUMPY} \
+			${PYTHON_PKGNAMEPREFIX}sip>0:${PORTSDIR}/devel/py-sip
+PYTHON_CMAKE_ON=	-DENABLE_PYTHON=ON \
+			-DPYTHON_INCLUDE_DIR:PATH=${WRKDIR}/include/${PYTHON_VERSION}
+PYTHON_CMAKE_OFF=	-DENABLE_PYTHON=OFF
 
 post-patch:
 	@${REINPLACE_CMD} -e \
@@ -54,8 +50,7 @@ post-patch:
 	@${REINPLACE_CMD} -e \
 		's|share/man|man|' ${WRKSRC}/doc/CMakeLists.txt
 
-pre-configure:
-.if ${PORT_OPTIONS:MPYTHON}
+pre-configure-PYTHON-on:
 	@${MKDIR} ${WRKDIR}/include/${PYTHON_VERSION}
 	@${FIND} ${PYTHON_INCLUDEDIR} ! -name "pyport.h" -type f \
 		-maxdepth 1 | ${XARGS} -J % ${LN} -sf % \
@@ -63,6 +58,5 @@ pre-configure:
 	@${SED} -e 's|^#ifdef _PY_PORT_CTYPE_UTF8_ISSUE|#if 0|' \
 		${PYTHON_INCLUDEDIR}/pyport.h > \
 		${WRKDIR}/include/${PYTHON_VERSION}/pyport.h
-.endif
 
 .include <bsd.port.mk>

Added: head/science/avogadro/files/patch-libavogadro_src_pythonengine__p.h
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/science/avogadro/files/patch-libavogadro_src_pythonengine__p.h	Mon Feb  8 19:15:59 2016	(r408502)
@@ -0,0 +1,12 @@
+--- libavogadro/src/pythonengine_p.h.orig	2013-12-06 15:50:04 UTC
++++ libavogadro/src/pythonengine_p.h
+@@ -27,7 +27,9 @@
+ 
+ #include <avogadro/global.h>
+ #include <avogadro/engine.h>
++#ifndef Q_MOC_RUN
+ #include <boost/python.hpp>
++#endif
+ 
+ namespace Avogadro {
+ 

Added: head/science/avogadro/files/patch-libavogadro_src_pythonextension__p.h
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/science/avogadro/files/patch-libavogadro_src_pythonextension__p.h	Mon Feb  8 19:15:59 2016	(r408502)
@@ -0,0 +1,12 @@
+--- libavogadro/src/pythonextension_p.h.orig	2013-12-06 15:50:04 UTC
++++ libavogadro/src/pythonextension_p.h
+@@ -29,7 +29,9 @@
+ #include <avogadro/extension.h>
+ #include <avogadro/primitive.h>
+ #include <avogadro/glwidget.h>
++#ifndef Q_MOC_RUN
+ #include <boost/python.hpp>
++#endif
+ 
+ #include <QWidget>
+ #include <QList>

Added: head/science/avogadro/files/patch-libavogadro_src_pythoninterpreter.h
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/science/avogadro/files/patch-libavogadro_src_pythoninterpreter.h	Mon Feb  8 19:15:59 2016	(r408502)
@@ -0,0 +1,12 @@
+--- libavogadro/src/pythoninterpreter.h.orig	2013-12-06 15:50:04 UTC
++++ libavogadro/src/pythoninterpreter.h
+@@ -26,7 +26,9 @@
+ #define PYTHONINTERPRETER_H
+ 
+ #include <avogadro/global.h>
++#ifndef Q_MOC_RUN
+ #include <boost/python.hpp>
++#endif
+ #include <avogadro/primitive.h>
+ #include <QString>
+ 

Added: head/science/avogadro/files/patch-libavogadro_src_pythonscript.h
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/science/avogadro/files/patch-libavogadro_src_pythonscript.h	Mon Feb  8 19:15:59 2016	(r408502)
@@ -0,0 +1,12 @@
+--- libavogadro/src/pythonscript.h.orig	2013-12-06 15:50:04 UTC
++++ libavogadro/src/pythonscript.h
+@@ -27,7 +27,9 @@
+ #define PYTHONSCRIPT_H
+ 
+ #include <avogadro/global.h>
++#ifndef Q_MOC_RUN
+ #include <boost/python.hpp>
++#endif
+ 
+ #include "pythonerror.h"
+ 

Added: head/science/avogadro/files/patch-libavogadro_src_pythontool__p.h
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/science/avogadro/files/patch-libavogadro_src_pythontool__p.h	Mon Feb  8 19:15:59 2016	(r408502)
@@ -0,0 +1,12 @@
+--- libavogadro/src/pythontool_p.h.orig	2013-12-06 15:50:04 UTC
++++ libavogadro/src/pythontool_p.h
+@@ -27,7 +27,9 @@
+ 
+ #include <avogadro/global.h>
+ #include <avogadro/tool.h>
++#ifndef Q_MOC_RUN
+ #include <boost/python.hpp>
++#endif
+ 
+ #include <QObject>
+ #include <QAction>



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