aboutsummaryrefslogtreecommitdiffstats
path: root/java/eclipse-pydev
diff options
context:
space:
mode:
authornivit <nivit@FreeBSD.org>2012-07-21 20:45:13 +0800
committernivit <nivit@FreeBSD.org>2012-07-21 20:45:13 +0800
commit0fb669bf752948042991aa1a21b2ce1be609921b (patch)
treed341f08450bdb54fd8b56acbcdc1aaca070cde70 /java/eclipse-pydev
parent3b682f2be6bd152e54e94ef5195d17c3eb948f42 (diff)
downloadfreebsd-ports-gnome-0fb669bf752948042991aa1a21b2ce1be609921b.tar.gz
freebsd-ports-gnome-0fb669bf752948042991aa1a21b2ce1be609921b.tar.zst
freebsd-ports-gnome-0fb669bf752948042991aa1a21b2ce1be609921b.zip
- Simplify code of files/pkg-install.in, and post-install target
Buildlog: http://goo.gl/4U6wb
Diffstat (limited to 'java/eclipse-pydev')
-rw-r--r--java/eclipse-pydev/Makefile21
-rw-r--r--java/eclipse-pydev/files/pkg-install.in13
2 files changed, 14 insertions, 20 deletions
diff --git a/java/eclipse-pydev/Makefile b/java/eclipse-pydev/Makefile
index a01be32821c5..4a80dd706ec3 100644
--- a/java/eclipse-pydev/Makefile
+++ b/java/eclipse-pydev/Makefile
@@ -37,8 +37,7 @@ USE_ZIP= yes
DISTDATE= 2012062818
SUB_FILES= pkg-install
-SUB_LIST= BUNDLES_INFO=${BUNDLES_INFO} DISTDATE=${DISTDATE} \
- PLUGINDIR=${PLUGINDIR} PORTVERSION=${PORTVERSION}
+SUB_LIST= BUNDLES_INFO=${BUNDLES_INFO} PLUGINDIR=${PLUGINDIR}
pre-install:
@# ignore javashell.py file, because there is a syntax error
@@ -46,21 +45,19 @@ pre-install:
${PYTHON_CMD} -m compileall -x javashell.py -f ${WRKSRC}/plugins
${PYTHON_CMD} -O -m compileall -x javashell.py -f ${WRKSRC}
-REVDOM= python.pydev
-PLUGINDIR= ../../share/eclipse/dropins/pydev/eclipse/plugins
+PLUGINDIR= share/eclipse/dropins/pydev/eclipse/plugins
BUNDLES_INFO= ${PREFIX}/lib/eclipse/configuration/org.eclipse.equinox.simpleconfigurator/bundles.info
-COMPONENTS= com com.analysis com.codecompletion com.debug com.fastparser com.refactoring \
- org org.ast org.core org.customizations org.debug org.django org.help org.jython org.parser org.red_core org.refactoring
+
post-install:
@${ECHO_MSG} "===> Updating ${BUNDLES_INFO}"
-.for d in com org
-. for c in ${COMPONENTS:M${d}*}
- @${ECHO_CMD} "${d}.${REVDOM}${c:S,${d},,},${PORTVERSION}.${DISTDATE},${PLUGINDIR}/${d}.${REVDOM}${c:S,${d},,}_${PORTVERSION}.${DISTDATE}/,4,false" >> ${BUNDLES_INFO}
-. endfor
-.endfor
+ @PLUGINS=$$(ls -1 ${PREFIX}/${PLUGINDIR}); \
+ for d in $${PLUGINS}; do \
+ (${ECHO_CMD} "$${d},../../${PLUGINDIR}/$${d}/,4,false" | \
+ ${SED} -e 's/_\([0-9]\)/,\1/1' -e '/templates/d') >> ${BUNDLES_INFO}; \
+ done
@(${SORT} ${BUNDLES_INFO} > ${BUNDLES_INFO}.sort) && \
${MV} ${BUNDLES_INFO}.sort ${BUNDLES_INFO}
- ${CAT} ${PKGMESSAGE}
+ @${CAT} ${PKGMESSAGE}
add-plist-post:
@${ECHO_CMD} "@exec ${MKDIR} %D/share/eclipse/dropins/${PORTNAME}/eclipse/plugins/com.python.pydev.codecompletion_${PORTVERSION}.${DISTDATE}/icons" >> ${TMPPLIST}
diff --git a/java/eclipse-pydev/files/pkg-install.in b/java/eclipse-pydev/files/pkg-install.in
index a0f826dacdcf..3c5c2d73b759 100644
--- a/java/eclipse-pydev/files/pkg-install.in
+++ b/java/eclipse-pydev/files/pkg-install.in
@@ -8,18 +8,15 @@ fi
PATH="/bin:/sbin:/usr/bin:/usr/sbin"
BUNDLES_INFO=%%BUNDLES_INFO%%
-DISTDATE=%%DISTDATE%%
PLUGINDIR=%%PLUGINDIR%%
-PORTVERSION=%%PORTVERSION%%
-REVDOM=python.pydev
+PREFIX=%%PREFIX%%
if [ "$2" = "POST-INSTALL" ]; then
echo "===> Updating ${BUNDLES_INFO}"
- for c in '' '.analysis' '.codecompletion' '.debug' '.fastparser' '.refactoring'; do
- echo "com.${REVDOM}${c},${PORTVERSION}.${DISTDATE},${PLUGINDIR}/com.${REVDOM}${c}_${PORTVERSION}.${DISTDATE}/,4,false" >> ${BUNDLES_INFO}
- done
- for c in '' '.ast' '.core' '.customizations' '.debug' '.django' '.help' '.jython' '.parser' '.red_core' '.refactoring'; do
- echo "org.${REVDOM}${c},${PORTVERSION}.${DISTDATE},${PLUGINDIR}/org.${REVDOM}${c}_${PORTVERSION}.${DISTDATE}/,4,false" >> ${BUNDLES_INFO}
+ for d in $(ls -1 ${PREFIX}/${PLUGINDIR})
+ do
+ (echo "${d},../../${PLUGINDIR}/${d}/,4,false" | \
+ sed -e 's/_\([0-9]\)/,\1/1' -e '/templates/d') >> ${BUNDLES_INFO}
done
sort ${BUNDLES_INFO} > ${BUNDLES_INFO}.sort && \
mv ${BUNDLES_INFO}.sort ${BUNDLES_INFO}