View | Details | Raw Unified | Return to bug 236507 | Differences between
and this patch

Collapse All | Expand All

(-)science/py-mcstas-tools/Makefile (+76 lines)
Line 0 Link Here
1
# $FreeBSD$
2
3
PORTNAME=	mcstas-tools
4
PORTVERSION=	2.5
5
CATEGORIES=	science python
6
MASTER_SITES=	http://download.mcstas.org/mcstas-${PORTVERSION}/unix/
7
PKGNAMEPREFIX=	${PYTHON_PKGNAMEPREFIX}
8
DISTFILES=	${PORTNAME}-python-mccodelib-${PORTVERSION}-src.tar.gz \
9
		${PORTNAME}-python-mcdisplay-pyqtgraph-${PORTVERSION}-src.tar.gz \
10
		${PORTNAME}-python-mcdoc-${PORTVERSION}-src.tar.gz \
11
		${PORTNAME}-python-mcgui-${PORTVERSION}-src.tar.gz \
12
		${PORTNAME}-python-mcplot-pyqtgraph-${PORTVERSION}-src.tar.gz \
13
		${PORTNAME}-python-mcrun-${PORTVERSION}-src.tar.gz
14
15
MAINTAINER=	erkn@fysik.dtu.dk
16
COMMENT=	Python based tools for the McStas neutron ray tracing package
17
18
LICENSE=	GPLv2
19
20
RUN_DEPENDS=	${PYTHON_PKGNAMEPREFIX}yaml>=0:devel/py-yaml@${PY_FLAVOR} \
21
		${PYTHON_PKGNAMEPREFIX}ply>=0:devel/py-ply@${PY_FLAVOR} \
22
		${PYTHON_PKGNAMEPREFIX}numpy>=0:math/py-numpy@${PY_FLAVOR} \
23
		${PYTHON_PKGNAMEPREFIX}pyqtgraph>=0:graphics/py-pyqtgraph@${PY_FLAVOR} \
24
		mcstas:science/mcstas \
25
		mcpl2ssw:science/mcstas-comps
26
27
USES=		cmake python:3.6+ pyqt:5 shebangfix
28
USE_PYQT=	core sip widgets gui printsupport qscintilla2
29
30
SHEBANG_GLOB=	*.py
31
32
CMAKE_ARGS=	-Denable_mcstas=1
33
34
MANDIRS=	${PREFIX}/mcstas/${PORTVERSION}/doc/man/man1
35
NO_ARCH=	yes
36
NO_WRKSUBDIR=	yes
37
38
PLIST_SUB=	PORTVERSION=${PORTVERSION}
39
40
_EXECS=			mcrun mcdoc mcdisplay mcdisplay-pyqtgraph mcgui mcplot mcplot-pyqtgraph
41
_WRKSRC_SUBDIRS=	${DISTFILES:S/.tar.gz$//}
42
43
# Patch the shell script wrappers so that they'll use the actual Python binary.
44
# Also add the '-f' flag to the invocations of readlink(1) otherwise it will fail.
45
post-patch:
46
	@${REINPLACE_CMD} -Ee 's|python3|${PYTHON_CMD}|; \
47
				s|(readlink)|\1 -f|' \
48
		${WRKSRC}/mcstas-tools-python-mcdisplay-pyqtgraph-${PORTVERSION}-src/mcdisplay.in \
49
		${WRKSRC}/mcstas-tools-python-mcdoc-${PORTVERSION}-src/mcdoc.in \
50
		${WRKSRC}/mcstas-tools-python-mcgui-${PORTVERSION}-src/mcgui.in \
51
		${WRKSRC}/mcstas-tools-python-mcplot-pyqtgraph-${PORTVERSION}-src/mcplot.in \
52
		${WRKSRC}/mcstas-tools-python-mcrun-${PORTVERSION}-src/mcrun.in
53
54
do-configure:
55
.for f in ${_WRKSRC_SUBDIRS}
56
	 @${ECHO_MSG} ${_CMAKE_MSG}
57
	 @${MKDIR} ${WRKSRC}/${f}/.build
58
	 @cd ${WRKSRC}/${f}/.build; ${SETENV} ${CONFIGURE_ENV} ${CMAKE_BIN} ${CMAKE_ARGS} ..
59
.endfor
60
61
do-build:
62
.for f in ${_WRKSRC_SUBDIRS}
63
	 @cd ${WRKSRC}/${f}/.build; ${DO_MAKE_BUILD} ${ALL_TARGET}
64
.endfor
65
66
do-install:
67
.for f in ${_WRKSRC_SUBDIRS}
68
	cd ${WRKSRC}/${f}/.build && ${SETENV} ${MAKE_ENV} ${FAKEROOT} ${MAKE_CMD} ${MAKE_FLAGS} ${MAKEFILE} ${MAKE_ARGS} ${INSTALL_TARGET}
69
.endfor
70
71
# Link the executable files
72
.for e in ${_EXECS}
73
	${RLN} ${STAGEDIR}${PREFIX}/mcstas/${PORTVERSION}/bin/${e} ${STAGEDIR}${PREFIX}/bin/${e}
74
.endfor
75
76
.include <bsd.port.mk>
(-)science/py-mcstas-tools/distinfo (+13 lines)
Line 0 Link Here
1
TIMESTAMP = 1551866209
2
SHA256 (mcstas-tools-python-mccodelib-2.5-src.tar.gz) = 63c199fc8c5b0826b3c9f2caeb7a56d8a49f9d3b0fb953f14cef8d1e8f61edf2
3
SIZE (mcstas-tools-python-mccodelib-2.5-src.tar.gz) = 73691
4
SHA256 (mcstas-tools-python-mcdisplay-pyqtgraph-2.5-src.tar.gz) = fb57d5e0cc40ba78166fb21b77f6d972ca01cc668e9ce5e1c48c49945d50cd3d
5
SIZE (mcstas-tools-python-mcdisplay-pyqtgraph-2.5-src.tar.gz) = 42178
6
SHA256 (mcstas-tools-python-mcdoc-2.5-src.tar.gz) = c9101ef64bb7aa3cef935a90bc28add439e2bab58460831f1ed566d7840b1c7e
7
SIZE (mcstas-tools-python-mcdoc-2.5-src.tar.gz) = 42959
8
SHA256 (mcstas-tools-python-mcgui-2.5-src.tar.gz) = 20818b7614d0668190191ecd995edcd3ed1399ab25fa88093d339f551340e9e9
9
SIZE (mcstas-tools-python-mcgui-2.5-src.tar.gz) = 110347
10
SHA256 (mcstas-tools-python-mcplot-pyqtgraph-2.5-src.tar.gz) = d4f119bb39371d8b38f303ee97f16b25b7f65db107d174807d95afd42c5c6790
11
SIZE (mcstas-tools-python-mcplot-pyqtgraph-2.5-src.tar.gz) = 46910
12
SHA256 (mcstas-tools-python-mcrun-2.5-src.tar.gz) = 91997c3f4843431bbfe3c14c6b34bd97b3f37d3a50d1e734650bf1e7284cea83
13
SIZE (mcstas-tools-python-mcrun-2.5-src.tar.gz) = 45362
(-)science/py-mcstas-tools/files/patch-mcstas-tools-python-mcdoc-2.5-src_CMakeLists.txt (+18 lines)
Line 0 Link Here
1
--- mcstas-tools-python-mcdoc-2.5-src/CMakeLists.txt.orig	2018-12-12 15:57:17 UTC
2
+++ mcstas-tools-python-mcdoc-2.5-src/CMakeLists.txt
3
@@ -106,15 +106,6 @@ if(NOT WINDOWS)
4
     WORLD_READ WORLD_EXECUTE
5
   )
6
 
7
-  # Symlink to main
8
-  add_custom_command(
9
-    OUTPUT "${WORK}/${P}doc"
10
-    COMMAND "${CMAKE_COMMAND}" -E make_directory "${WORK}"
11
-    COMMAND "${CMAKE_COMMAND}" -E remove "${WORK}/${P}doc"
12
-    COMMAND "${CMAKE_COMMAND}" -E create_symlink
13
-    "${TOOLS_LIB}/mcdoc" "${WORK}/${P}doc"
14
-    )
15
-
16
   add_custom_target(
17
     "CREATE_SYMLINK" ALL DEPENDS "${WORK}/${P}doc"
18
     )
(-)science/py-mcstas-tools/pkg-descr (+18 lines)
Line 0 Link Here
1
McStas perl tools to aid in running neutron ray tracing simulations.
2
3
McStas is a tool for simulating neutron instrumentation and experiments using
4
a ray-tracing formalism. Currently the main use of McStas is in the field of
5
instrumentation design.
6
7
This port contains a few python-based helper tools (including a GUI) to aid the
8
user in setting up and running simulations. The tools are:
9
mcgui: A python qt5 based GUI.
10
mcrun: A script that makes it easy to run sims and perform
11
  point scans and simple optimizations.
12
mcdoc: Script for viewing inline component documentation.
13
mcplot: Tool for plotting McStas-generated results (wrapper script).
14
mcplot-pyqtgraph: The underlying plotting tool based on the pyqtgraph library.
15
mcdisplay: Visual ray-tracing displaying neutron trajectories (wrapper script).
16
mcdisplay-pyqtgraph: the underlying pyqtgraph based back-end of mcdisplay.
17
18
WWW: http://www.mcstas.org
(-)science/py-mcstas-tools/pkg-plist (+52 lines)
Line 0 Link Here
1
mcstas/%%PORTVERSION%%/bin/mcdisplay
2
mcstas/%%PORTVERSION%%/bin/mcdisplay-pyqtgraph
3
mcstas/%%PORTVERSION%%/bin/mcdoc
4
mcstas/%%PORTVERSION%%/bin/mcgui
5
mcstas/%%PORTVERSION%%/bin/mcplot
6
mcstas/%%PORTVERSION%%/bin/mcplot-pyqtgraph
7
mcstas/%%PORTVERSION%%/bin/mcrun
8
mcstas/%%PORTVERSION%%/launchers/McStas-py.desktop
9
mcstas/%%PORTVERSION%%/launchers/mcstas-py.png
10
mcstas/%%PORTVERSION%%/tools/Python/mccodelib/__init__.py
11
mcstas/%%PORTVERSION%%/tools/Python/mccodelib/fcparticleparser.py
12
mcstas/%%PORTVERSION%%/tools/Python/mccodelib/flowchart.py
13
mcstas/%%PORTVERSION%%/tools/Python/mccodelib/instrgeom.py
14
mcstas/%%PORTVERSION%%/tools/Python/mccodelib/instrparser.py
15
mcstas/%%PORTVERSION%%/tools/Python/mccodelib/mccode_config.py
16
mcstas/%%PORTVERSION%%/tools/Python/mccodelib/mcdisplayutils.py
17
mcstas/%%PORTVERSION%%/tools/Python/mccodelib/mcplotloader.py
18
mcstas/%%PORTVERSION%%/tools/Python/mccodelib/nodetree.py
19
mcstas/%%PORTVERSION%%/tools/Python/mccodelib/particleparser.py
20
mcstas/%%PORTVERSION%%/tools/Python/mccodelib/pipetools.py
21
mcstas/%%PORTVERSION%%/tools/Python/mccodelib/plotgraph.py
22
mcstas/%%PORTVERSION%%/tools/Python/mccodelib/pqtgfrontend.py
23
mcstas/%%PORTVERSION%%/tools/Python/mccodelib/test.py
24
mcstas/%%PORTVERSION%%/tools/Python/mccodelib/utils.py
25
mcstas/%%PORTVERSION%%/tools/Python/mcdisplay/pyqtgraph/mcdisplay.py
26
mcstas/%%PORTVERSION%%/tools/Python/mcdoc/mcdoc
27
mcstas/%%PORTVERSION%%/tools/Python/mcdoc/mcdoc.py
28
mcstas/%%PORTVERSION%%/tools/Python/mcgui/compile-icon.png
29
mcstas/%%PORTVERSION%%/tools/Python/mcgui/mcgui
30
mcstas/%%PORTVERSION%%/tools/Python/mcgui/mcgui.py
31
mcstas/%%PORTVERSION%%/tools/Python/mcgui/mcstas-py.png
32
mcstas/%%PORTVERSION%%/tools/Python/mcgui/run-icon.png
33
mcstas/%%PORTVERSION%%/tools/Python/mcgui/viewclasses.py
34
mcstas/%%PORTVERSION%%/tools/Python/mcgui/widgets.py
35
mcstas/%%PORTVERSION%%/tools/Python/mcplot/pyqtgraph/mcdataclient.py
36
mcstas/%%PORTVERSION%%/tools/Python/mcplot/pyqtgraph/mcdataserver.py
37
mcstas/%%PORTVERSION%%/tools/Python/mcplot/pyqtgraph/mcdataservice.py
38
mcstas/%%PORTVERSION%%/tools/Python/mcplot/pyqtgraph/mcplot.py
39
mcstas/%%PORTVERSION%%/tools/Python/mcplot/pyqtgraph/plotfuncs.py
40
mcstas/%%PORTVERSION%%/tools/Python/mcrun/__init__.py
41
mcstas/%%PORTVERSION%%/tools/Python/mcrun/log.py
42
mcstas/%%PORTVERSION%%/tools/Python/mcrun/mccode.py
43
mcstas/%%PORTVERSION%%/tools/Python/mcrun/mcrun
44
mcstas/%%PORTVERSION%%/tools/Python/mcrun/mcrun.py
45
mcstas/%%PORTVERSION%%/tools/Python/mcrun/optimisation.py
46
bin/mcdisplay
47
bin/mcdisplay-pyqtgraph
48
bin/mcdoc
49
bin/mcgui
50
bin/mcplot
51
bin/mcplot-pyqtgraph
52
bin/mcrun

Return to bug 236507