blob: 63d04f7837a22a357be4de05f743bbf017760e97 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
|
# Created by: wenheping@gmail.com
# $FreeBSD$
PORTNAME= psychopy
PORTVERSION= 1.83.04
CATEGORIES= science python
MAINTAINER= ports@FreeBSD.org
COMMENT= Psychophysics toolkit for Python
LICENSE= GPLv3+
RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}lxml>0:${PORTSDIR}/devel/py-lxml \
${PYTHON_PKGNAMEPREFIX}pillow>0:${PORTSDIR}/graphics/py-pillow \
${PYTHON_PKGNAMEPREFIX}matplotlib>=0.90.1:${PORTSDIR}/math/py-matplotlib \
${PYTHON_PKGNAMEPREFIX}pandas>0:${PORTSDIR}/math/py-pandas \
${PYTHON_PKGNAMEPREFIX}scipy>=0.6.0:${PORTSDIR}/science/py-scipy \
${PYTHON_PKGNAMEPREFIX}openpyxl>0:${PORTSDIR}/textproc/py-openpyxl \
dejavu>0:${PORTSDIR}/x11-fonts/dejavu \
${PYGAME} \
${PYNUMPY}
NO_ARCH= yes
USE_GITHUB= yes
USES= fortran python
USE_PYTHON= autoplist distutils
USE_WX= 2.8
WX_COMPS= python
PLIST_FILES= bin/psychopy
DESKTOP_ENTRIES="PsychoPy" \
"" \
"${PYTHONPREFIX_SITELIBDIR}/psychopy/app/Resources/psychopy.png" \
"psychopy" \
"" \
""
OPTIONS_DEFINE_i386= PYGLET
OPTIONS_DEFAULT_i386= PYGLET
PYGLET_DESC= Drawing support via Pyglet
PYGLET_RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}pyglet>=1.1.2:${PORTSDIR}/graphics/py-pyglet
.include <bsd.port.options.mk>
post-patch:
# https://github.com/psychopy/psychopy/issues/982
@${REINPLACE_CMD} -e \
's|str(,id_dict)|str(id_dict)|' \
${WRKSRC}/psychopy/demos/coder/iohub/elotouchscreen/run.py
post-build:
@${ECHO_CMD} -n > ${WRKDIR}/psychopy
@${ECHO_CMD} "#!${SH}" \
>> ${WRKDIR}/psychopy
.if ${OPSYS} == FreeBSD
@${ECHO_CMD} "LD_LIBRARY_PATH=${LOCALBASE}/lib/${FC:S/fortran/cc/}:\$$LD_LIBRARY_PATH" \
>> ${WRKDIR}/psychopy
@${ECHO_CMD} "export LD_LIBRARY_PATH" \
>> ${WRKDIR}/psychopy
.endif
@${ECHO_CMD} \
>> ${WRKDIR}/psychopy
@${ECHO_CMD} "${PYTHON_CMD} ${PREFIX}/bin/psychopyApp.py" \
>> ${WRKDIR}/psychopy
post-install:
(cd ${WRKDIR} && ${INSTALL_SCRIPT} psychopy \
${STAGEDIR}${PREFIX}/bin)
@${RM} ${STAGEDIR}${PYTHONPREFIX_SITELIBDIR}/psychopy/app/Resources/DejaVuSerif.ttf
@${LN} -sf ${LOCALBASE}/share/fonts/dejavu/DejaVuSerif.ttf \
${STAGEDIR}${PYTHONPREFIX_SITELIBDIR}/psychopy/app/Resources
.include <bsd.port.mk>
|