aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoredwin <edwin@FreeBSD.org>2005-05-28 08:14:36 +0800
committeredwin <edwin@FreeBSD.org>2005-05-28 08:14:36 +0800
commit5153cf0a8f70d58cc42442b56a95744f6ce7b9f3 (patch)
tree9322bbd2e8a81e207c26303810b78c49f016aad7
parent044a4f2368177f44150c1d3b0b8f7aede24c54f5 (diff)
downloadfreebsd-ports-gnome-5153cf0a8f70d58cc42442b56a95744f6ce7b9f3.tar.gz
freebsd-ports-gnome-5153cf0a8f70d58cc42442b56a95744f6ce7b9f3.tar.zst
freebsd-ports-gnome-5153cf0a8f70d58cc42442b56a95744f6ce7b9f3.zip
Some archives have a html/ prefix, some don't. Make sure this is
handled correctly.
-rw-r--r--lang/php_doc/Makefile23
1 files changed, 18 insertions, 5 deletions
diff --git a/lang/php_doc/Makefile b/lang/php_doc/Makefile
index 70c087fdb47b..ce3002611720 100644
--- a/lang/php_doc/Makefile
+++ b/lang/php_doc/Makefile
@@ -7,6 +7,7 @@
PORTNAME= php_doc
PORTVERSION= 20050521
+PORTREVISION= 1
CATEGORIES?= lang
MASTER_SITES= http://www.mavetju.org/download/adopted/
DISTNAME= php_manual_${PHP_LANG}-${PORTVERSION}
@@ -33,6 +34,17 @@ PHP_LANG?= en
PHPDOCDIR= ${PREFIX}/share/doc/php-${PHP_LANG}
PLIST= ${WRKDIR}/pkg-plist
+.for lang in hk ja kr
+.if ${PHP_LANG} == ${lang}
+WRK_SRC= ${WRKDIR}
+.endif
+.endfor
+.for lang in ar br de en fr hu pl ru tw zh
+.if ${PHP_LANG} == ${lang}
+WRK_SRC= ${WRKDIR}/html
+.endif
+.endfor
+
PKGNAMESUFFIX= -${PHP_LANG}
PLIST_SUB= PHPDOCDIR=${PHPDOCDIR:S/^${PREFIX}\///}
@@ -44,6 +56,7 @@ pre-fetch:
@${ECHO} " ar (arabic),"
@${ECHO} " br (brazillian),"
@${ECHO} " de (german),"
+ @${ECHO} " en (english),"
@${ECHO} " fr (french) or"
@${ECHO} " hu (hungarian) or"
@${ECHO} " ja (japanese)"
@@ -58,14 +71,14 @@ pre-fetch:
.endif
pre-install:
- ${FIND} ${WRKDIR} -type f ! -name '.*' ! -name pkg-plist | ${SED} -e "s,${WRKDIR},%%PHPDOCDIR%%," > ${PLIST}
- ${FIND} ${WRKDIR} -type d | ${SORT} -r | ${SED} -e "s,${WRKDIR},@dirrm %%PHPDOCDIR%%," >> ${PLIST}
+ ${FIND} ${WRK_SRC} -type f ! -name '.*' ! -name pkg-plist | ${SED} -e "s,${WRK_SRC},%%PHPDOCDIR%%," > ${PLIST}
+ ${FIND} ${WRK_SRC} -type d | ${SORT} -r | ${SED} -e "s,${WRK_SRC},@dirrm %%PHPDOCDIR%%," >> ${PLIST}
do-install:
@${MKDIR} ${PHPDOCDIR}
- ${FIND} ${WRKDIR} -type d | ${SED} -e "s,${WRKDIR},${PHPDOCDIR}/," | ${XARGS} ${MKDIR}
- for f in `${FIND} ${WRKDIR} -type f ! -name '.*' ! -name pkg-plist | ${SED} -e "s,${WRKDIR}/,,"`; do \
- ${INSTALL_DATA} ${WRKDIR}/$$f ${PHPDOCDIR}/$$f; \
+ ${FIND} ${WRK_SRC} -type d | ${SED} -e "s,${WRK_SRC},${PHPDOCDIR}/," | ${XARGS} ${MKDIR}
+ for f in `${FIND} ${WRK_SRC} -type f ! -name '.*' ! -name pkg-plist | ${SED} -e "s,${WRK_SRC}/,,"`; do \
+ ${INSTALL_DATA} ${WRK_SRC}/$$f ${PHPDOCDIR}/$$f; \
done
# this is for the maintainer only