aboutsummaryrefslogtreecommitdiffstats
path: root/games/pyfa/Makefile
blob: e0e896a8a9f23c96a9fb2fb402842422cde7d9f5 (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
# Created by: Andrey Fesenko <andrey@bsdnir.info>
# $FreeBSD$

PORTNAME=   pyfa
PORTVERSION=    1.13.1
DISTVERSIONPREFIX=  v
PORTREVISION=   1
CATEGORIES= games python

MAINTAINER= andrey@bsdnir.info
COMMENT=    Fitting tool for EVE Online

LICENSE=    GPLv3 # or later
LICENSE_FILE=   ${WRKSRC}/gpl.txt

RUN_DEPENDS=    ${PYTHON_PKGNAMEPREFIX}dateutil>0:${PORTSDIR}/devel/py-dateutil \
        ${PYTHON_PKGNAMEPREFIX}sqlalchemy>0:${PORTSDIR}/databases/py-sqlalchemy

USE_GITHUB= yes
GH_ACCOUNT= DarkFenX

USES=       python:2 dos2unix
DOS2UNIX_GLOB=  *.py
WRKSRC=     ${WRKDIR}/Pyfa-${PORTVERSION}

PLIST_FILES=    bin/pyfa
PORTDATA=   *

USE_WX=     2.8
WX_COMPS=   python:run
WX_UNICODE= yes

OPTIONS_DEFINE=     DPSGRAPHING
DPSGRAPHING_DESC=   DPS graphing (requires NumPy and matplotlib. need fix)

DPSGRAPHING_RUN_DEPENDS=    ${PYTHON_PKGNAMEPREFIX}matplotlib>0:${PORTSDIR}/math/py-matplotlib \
        ${PYTHON_PKGNAMEPREFIX}numpy>0:${PORTSDIR}/math/py-numpy \
        ${PYTHON_PKGNAMEPREFIX}more-itertools>0:${PORTSDIR}/devel/py-more-itertools

do-build:
    @${PYTHON_CMD} -m compileall ${WRKSRC}
    @${PYTHON_CMD} -O -m compileall ${WRKSRC}

post-build:
    @${PRINTF} "#!/bin/sh\nexec ${PYTHON_CMD} ${DATADIR}/pyfa.py\n" \
        > ${WRKDIR}/pyfa.sh

do-install:
    @${MKDIR} ${STAGEDIR}${DATADIR}
    @cd ${WRKSRC} && ${COPYTREE_SHARE} . ${STAGEDIR}${DATADIR}
    ${INSTALL_SCRIPT} ${WRKDIR}/pyfa.sh ${STAGEDIR}${PREFIX}/bin/pyfa

.include <bsd.port.mk>