Changeset View
Changeset View
Standalone View
Standalone View
devel/eric6/Makefile.inc
# Created by: Boris Samorodov <bsam@FreeBSD.org> | # Created by: Boris Samorodov <bsam@FreeBSD.org> | ||||
# $FreeBSD: head/devel/eric6/Makefile.inc 455210 2017-11-30 15:50:30Z mat $ | # $FreeBSD: head/devel/eric6/Makefile.inc 455210 2017-11-30 15:50:30Z mat $ | ||||
# | # | ||||
# This is a set of Makefile macros which allow to build the core and | # This is a set of Makefile macros which allow to build the | ||||
# localized language packages for devel/eric6: | # localized language packages for devel/eric6: | ||||
# french/eric6, german/eric6, russian/eric6 | # chinese/eric6, french/eric6, german/eric6, portuguese/eric6, russian/eric6 | ||||
# devel/cs-eric6, devel/es-eric6, devel/it-eric6, devel/tr-eric6 | |||||
PORTNAME= eric6 | .include "${.CURDIR}/../../devel/eric6/bsd.eric6.mk" | ||||
PORTVERSION= 17.10 | |||||
MASTER_SITES= SF/eric-ide/${PORTNAME}/stable/${PORTVERSION} | |||||
DISTNAME?= ${PORTNAME}-i18n-${I18N_LANG}-${PORTVERSION} | |||||
WRKSRC= ${WRKDIR}/${PORTNAME}-${PORTVERSION} | |||||
MAINTAINER?= dbn@FreeBSD.org | PKGNAMEPREFIX= ${I18N_LANG}- | ||||
COMMENT= Full featured Python and Ruby editor and IDE based on Qt | DISTNAME= ${PORTNAME}-i18n-${I18N_LANG}-${PORTVERSION} | ||||
LICENSE= GPLv3 | INSTALL_CMD= install-i18n.py -p ${STAGEDIR} | ||||
RUN_DEPENDS?= ${LOCALBASE}/bin/eric6:devel/eric6 | |||||
I18N_LANG?= ru | |||||
INSTALL_CMD?= install-i18n.py -p ${STAGEDIR} | |||||
MAKE_ENV+= "HOME=${WRKDIR}" | |||||
USES+= python:2.7 | |||||
NO_BUILD= yes | |||||
PLIST_FILES?= %%DATADIR%%/i18n/${PORTNAME}_${I18N_LANG}.qm | |||||
EXTRA_PATCHES?= ${.CURDIR}/../../devel/eric6/files/extra-patch-install-i18n.py | |||||
.if ! defined(MASTERPORT) | |||||
NO_ARCH= yes | NO_ARCH= yes | ||||
mat: This should probably be in the MASTERPORT as it is only used there. | |||||
.endif | PLIST_FILES= ${DATADIR}/i18n/${PORTNAME}_${I18N_LANG}.qm | ||||
Done Inline ActionsPLIST_FILES= ${DATADIR}/i18n/${PORTNAME}_${I18N_LANG}.qm mat: ```
PLIST_FILES= ${DATADIR}/i18n/${PORTNAME}_${I18N_LANG}.qm
``` | |||||
Done Inline ActionsUSES=python already does that, remove. mat: USES=python already does that, remove. | |||||
.include <bsd.port.pre.mk> | |||||
.if ${PYTHON_VER} <= 2.7 | |||||
PLIST_SUB+= PYTHON2= | |||||
.else | |||||
PLIST_SUB+= PYTHON2="@comment " | |||||
.endif | |||||
do-install: | do-install: | ||||
@(cd ${WRKSRC}; \ | ${MKDIR} ${STAGEDIR}${DATADIR}/i18n | ||||
${SETENV} ${MAKE_ENV} ${PYTHON_CMD} ${INSTALL_CMD}) | ${INSTALL_DATA} ${WRKSRC}/eric/i18n/${PORTNAME}_${I18N_LANG}.qm ${STAGEDIR}${DATADIR}/i18n/ | ||||
Done Inline ActionsI am not sure what this is doing, it is never used. Also, if it is only used in the MASTERPORT, it should probably be in the MASTERPORT. mat: I am not sure what this is doing, it is never used. Also, if it is only used in the MASTERPORT… | |||||
Done Inline ActionsIt was a carry over from options. It should read RUN_DEPENDS+=... dbn: It was a carry over from options. It should read RUN_DEPENDS+=... | |||||
Done Inline ActionsIn this case, PYQRVER is only defined after the includes and so cannot be in MASTERPORT. dbn: In this case, PYQRVER is only defined after the includes and so cannot be in MASTERPORT. | |||||
Done Inline ActionsIt is defined line 20 of the Makefile. mat: It is defined line 20 of the Makefile. | |||||
DESCR= ${.CURDIR}/../../devel/eric6/pkg-descr | .include <bsd.port.mk> | ||||
Done Inline ActionsThat is not needed. mat: That is not needed. | |||||
Done Inline ActionsIt could be written in an easier way as: PY_FLAVORS= py${PYTHON_DEFAULT:S/.//} py${PYTHON2_DEFAULT:S/.//} py${PYTHON3_DEFAULT:S/.//} .for flavor in ${PY_FLAVORS} . if empty(FLAVORS:M${flavor}_qt4) FLAVORS:= ${FLAVORS} ${flavor}_qt4 ${flavor}_qt5 . endif .endfor mat: It could be written in an easier way as:
```
PY_FLAVORS= py${PYTHON_DEFAULT:S/.//}… | |||||
Done Inline ActionsIs this needed ? mat: Is this needed ? | |||||
.include <bsd.port.post.mk> |
This should probably be in the MASTERPORT as it is only used there.