On Tue, 10 May 2016 09:48:15 +0100, Edd Barrett <e...@theunixzoo.co.uk>
wrote:

> Hey,
> 
> ---8<---
> Frozen-Flask freezes a Flask application into a set of static files.
> The result can be hosted without any server-side software other than a
> traditional web server.
> --->8---  
> 
> We need this on our OpenBSD servers for an in-house app. We are using
> it with Python 2, but I've included the Python 3 flavour for
> completeness.
> 
> OK?
> 

Hi,

New makefile attached (as I didn't touch anything else). I shuffled it
so it follows the order of Makefile.template (thus easier to read).
I also added a missed BDEP (sphinx).

Are you sure the chown in post-install is needed? I installed it
without and it looked fine, did I miss something?

Cheers,
Daniel
# $OpenBSD: Makefile,v 1.1.1.1 2015/12/01 22:33:08 edd Exp $

COMMENT =		freezes a Flask application into a set of static files

MODPY_EGG_VERSION =	0.12
DISTNAME =		Frozen-Flask-${MODPY_EGG_VERSION}
PKGNAME =		py-frozen-flask-${MODPY_EGG_VERSION}

CATEGORIES =		www

HOMEPAGE =		https://github.com/SimonSapin/Frozen-Flask

# BSD
PERMIT_PACKAGE_CDROM =	Yes

MODULES =		lang/python
MODPY_PI =		Yes
MODPY_SETUPTOOLS =	Yes

FLAVORS =		python3
FLAVOR ?=

BUILD_DEPENDS =		textproc/py-sphinx${MODPY_FLAVOR}
RUN_DEPENDS +=		www/py-flask${MODPY_FLAVOR}
TEST_DEPENDS =		${RUN_DEPENDS}

post-build:
	cd ${WRKBUILD}/docs && ${MODPY_BIN} -m sphinx . html

DOCS_DIR =	${PREFIX}/share/doc/${MODPY_PY_PREFIX}frozen-flask
post-install:
	${INSTALL_DATA_DIR} ${DOCS_DIR}
	cp -r ${WRKSRC}/docs/html/* ${DOCS_DIR}
	chown -R ${SHAREOWN}:${SHAREGRP} ${DOCS_DIR}

do-test:
	cd ${WRKSRC} && ${MODPY_BIN} -m unittest discover

.include <bsd.port.mk>

Reply via email to