aboutsummaryrefslogtreecommitdiffstats
path: root/cad/pythoncad/Makefile
blob: 0828d4e1b077ed287717a49734147cfbd193f784 (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
# Created by: ijliao
# $FreeBSD$

PORTNAME=   pythoncad
PORTVERSION=    37
PORTREVISION=   1
CATEGORIES= cad
MASTER_SITES=   SF/${PORTNAME}/${PORTNAME}/R${PORTVERSION}%20PyGtk/Source
DISTNAME=   PythonCAD-DS1-R${PORTVERSION}

MAINTAINER= ports@FreeBSD.org
COMMENT=    Open-source CAD package built designed around Python

LICENSE=    GPLv2
LICENSE_FILE=   ${WRKSRC}/COPYING

RUN_DEPENDS=    ${PYTHON_SITELIBDIR}/gtk-2.0/gtk/__init__.py:${PORTSDIR}/x11-toolkits/py-gtk2

USES=           python
USE_PYTHON=     distutils
PYDISTUTILS_PKGNAME=    PythonCAD
PYDISTUTILS_PKGVERSION= DS1-R${PORTVERSION}
NO_ARCH=        yes

post-patch:
    @${REINPLACE_CMD} -e 's|/usr/local|${PREFIX}|' \
        ${WRKSRC}/PythonCAD/Generic/preferences.py \
        ${WRKSRC}/PythonCAD/Interface/Gtk/gtkimage.py

post-install:
    ${INSTALL_SCRIPT} ${WRKSRC}/gtkpycad.py ${STAGEDIR}${PREFIX}/bin/gtkpycad
    ${INSTALL_DATA} ${WRKSRC}/gtkpycad.png ${STAGEDIR}${PREFIX}/share/pixmaps
    ${MKDIR} ${STAGEDIR}${PREFIX}/etc/pythoncad
    ${INSTALL_DATA} ${WRKSRC}/prefs.py ${STAGEDIR}${PREFIX}/etc/pythoncad/prefs.py.sample

.include <bsd.port.mk>