aboutsummaryrefslogtreecommitdiffstats
path: root/graphics/skencil/Makefile
blob: 5e7336f645d80e4bad151a6d6cbda7d478823bb4 (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
# New ports collection makefile for:    skencil
# Date created:     04 November 1998
# Whom:         Thomas Gellekum <tg@FreeBSD.org>
#
# $FreeBSD$
#

PORTNAME=   skencil
PORTVERSION=    0.6.16
CATEGORIES= graphics
MASTER_SITES=   ${MASTER_SITE_SOURCEFORGE}
MASTER_SITE_SUBDIR= sketch

MAINTAINER= ports@FreeBSD.org
COMMENT=    An interactive drawing program

BUILD_DEPENDS=  ${LOCALBASE}/include/${PYTHON_VERSION}/Imaging.h:${PORTSDIR}/graphics/py-imaging
RUN_DEPENDS=    ${PYTHON_SITELIBDIR}/_tkinter.so:${PORTSDIR}/x11-toolkits/py-tkinter \
        ${PYTHON_SITELIBDIR}/PIL/_imaging.so:${PORTSDIR}/graphics/py-imaging \
        ${PYTHON_SITELIBDIR}/reportlab/__init__.py:${PORTSDIR}/print/py-reportlab \
        ${PYXML}

USE_PYTHON= yes
USE_PYDISTUTILS=    yes

CONFFLAGS=  --tk-autoconf --tk-flags="-I${X11BASE}/include -I${LOCALBASE}/include/tcl8.4 -I${LOCALBASE}/include/tk8.4 -L${LOCALBASE}/lib -ltk84 -ltcl84 -L${X11BASE}/lib -lX11"

SKETCHDOCS= BUGS Doc NEWS PROJECTS README TODO
SKETCHSCRIPTS=  finishinst.py sk2ppm.py sk2ps.py skconvert.py skencil.py \
        skshow.py

do-configure:
    @(cd ${WRKSRC} && \
        ${SETENV} ${CONFIGURE_ENV} \
        ${PYTHON_CMD} setup.py configure ${CONFFLAGS})

do-install:
    @${MKDIR} ${DATADIR}
.for dir in Filter Pax Plugins Resources Script Sketch
    (cd ${WRKSRC}; ${TAR} -cf - -X ${FILESDIR}/excludelist ${dir}) | \
        (cd ${DATADIR}; ${TAR} xf -)
.endfor
    (cd ${WRKSRC}; ${INSTALL_SCRIPT} ${SKETCHSCRIPTS} ${DATADIR})
.if !defined(NOPORTDOCS)
    @${MKDIR} ${DOCSDIR}
    (cd ${WRKSRC}; ${TAR} cf - ${SKETCHDOCS}) | (cd ${DOCSDIR}; ${TAR} xf -)
    @${MKDIR} ${EXAMPLESDIR}
    (cd ${WRKSRC}/Examples; ${TAR} cf - .) | (cd ${EXAMPLESDIR}; ${TAR} xf -)
.endif
    (cd ${DATADIR}; ${PYTHON_CMD} finishinst.py)
.for exec in sk2ppm sk2ps skconvert skencil skshow
    ${SED} -e "s|@DATADIR@|${DATADIR}|g ; \
         s|@PYTHON_CMD@|${PYTHON_CMD}|g" \
        < ${FILESDIR}/${exec}.in > ${PREFIX}/bin/${exec}
    ${CHMOD} ${BINMODE} ${PREFIX}/bin/${exec}
    ${CHOWN} ${BINOWN}:${BINGROUP} ${PREFIX}/bin/${exec}
.endfor

.include <bsd.port.mk>