60d1a83c2a
- Replace ${MASTER_SITE_FOO} with FOO. - Merge MASTER_SITE_SUBDIR into MASTER_SITES when possible. (This means 99.9% of the time.) - Remove occurrences of MASTER_SITE_LOCAL when no subdirectory was present and no hint of what it should be was present. - Fix some logic. - And generally, make things more simple and easy to understand. While there, add magic values to the FESTIVAL, GENTOO, GIMP, GNUPG, QT and SAMBA macros. Also, replace some EXTRACT_SUFX occurences with USES=tar:*. Checked by: make fetch-urlall-list With hat: portmgr Sponsored by: Absolight
53 lines
1.4 KiB
Makefile
53 lines
1.4 KiB
Makefile
# Created by: Johann Visagie <wjv@FreeBSD.org>
|
|
# $FreeBSD$
|
|
|
|
PORTNAME= gato
|
|
PORTVERSION= 1.02
|
|
PORTREVISION= 1
|
|
CATEGORIES= math python
|
|
MASTER_SITES= http://gato.sourceforge.net/Download/
|
|
PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}
|
|
DISTNAME= Gato-${PORTVERSION}
|
|
|
|
MAINTAINER= ports@FreeBSD.org
|
|
COMMENT= Python-based toolbox to visualise algorithms on graphs
|
|
|
|
RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}tkinter>0:${PORTSDIR}/x11-toolkits/py-tkinter
|
|
|
|
WRKSRC= ${WRKDIR}/Gato
|
|
|
|
USES= python
|
|
|
|
EXAMPLESDIR= ${PREFIX}/share/examples/${PORTNAME}
|
|
|
|
post-patch:
|
|
@${REINPLACE_CMD} -e 's,^.*__future__.*$$,,' ${WRKSRC}/DataStructures.py
|
|
@${GREP} -lR "^#!" ${WRKSRC} | ${XARGS} ${REINPLACE_CMD} -e \
|
|
'/^#!/s|python.*$$|python|g'
|
|
|
|
pre-build:
|
|
@${TOUCH} ${WRKSRC}/__init__.py
|
|
|
|
do-build:
|
|
${PYTHON_CMD} ${PYTHON_LIBDIR}/compileall.py \
|
|
-d ${PYTHON_SITELIBDIR} \
|
|
-f ${WRKSRC}
|
|
${PYTHON_CMD} -O ${PYTHON_LIBDIR}/compileall.py \
|
|
-d ${PYTHON_SITELIBDIR} \
|
|
-f ${WRKSRC}
|
|
|
|
do-install:
|
|
@${MKDIR} ${STAGEDIR}${PYTHON_SITELIBDIR}/Gato
|
|
.for pyfile in *.py *.pyc *.pyo
|
|
${INSTALL_DATA} ${WRKSRC}/${pyfile} ${STAGEDIR}${PYTHON_SITELIBDIR}/Gato
|
|
.endfor
|
|
.for script in Gato Gred
|
|
@${CHMOD} ${BINMODE} ${STAGEDIR}${PYTHON_SITELIBDIR}/Gato/${script}.py
|
|
@${LN} -sf ${PYTHON_SITELIBDIR}/Gato/${script}.py ${STAGEDIR}${PREFIX}/bin/${script}
|
|
.endfor
|
|
@${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
|
|
.for egfile in *.alg *.pro *.cat
|
|
${INSTALL_DATA} ${WRKSRC}/${egfile} ${STAGEDIR}${EXAMPLESDIR}
|
|
.endfor
|
|
|
|
.include <bsd.port.mk>
|