svn commit: r332287 - in head/sysutils: . py-halite py-halite/files

Nicola Vitale nivit at FreeBSD.org
Thu Oct 31 23:45:28 UTC 2013


Hi,

> [2013/10/31 William Grzybowski <william88 at gmail.com>]
> Yes, easy_install does not support staging.

I have just tried the following solution with a couple of my ports,
and it seems to work:

MAKE_ENV=       PYTHONUSERBASE=${STAGEDIR}${PYTHONBASE}

# the next two lines are necessary to override the definition in <bsd.python.mk>
.include <bsd.port.pre.mk>
.undef PYDISTUTILS_INSTALLARGS

# the first option is not necessary for staging
PYDISTUTILS_INSTALLARGS=        --always-unzip \
                                --install-dir
${STAGEDIR}${PYEASYINSTALL_SITELIBDIR} \
                                --no-deps \
                                --quiet \
                                --script-dir
${STAGEDIR}${PYEASYINSTALL_BINDIR} \
                                --site-dir
${STAGEDIR}${PYEASYINSTALL_SITELIBDIR} \
                                --user \
                                ${WRKSRC}/dist/${PYEASYINSTALL_EGG}

#post-stage-dir:
post-build:
        @${MKDIR} ${STAGEDIR}${PYEASYINSTALL_BINDIR} \
        ${STAGEDIR}${PYEASYINSTALL_SITELIBDIR}

#  see https://wiki.freebsd.org/ports/StageDir
post-install:
       (cd ${STAGEDIR}${PREFIX} && \
        ${PYTHON_CMD} ${PYTHON_LIBDIR}/compileall.py \
                -d ${PREFIX} -f ${PYTHONPREFIX_SITELIBDIR:S;${PREFIX}/;;})

.include <bsd.port.post.mk>

It may have some drawbacks?


More information about the svn-ports-all mailing list