1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-12-25 04:43:33 +00:00

o avoid conflict with locale_base's pkg-plist.

o fix ${ECHO} to ${ECHO_CMD}
o integrate ${PREFIX}(%D) to ${LINUXBASE}(%%LINUXBASE%%)

Reviewed by:	knu (mentor)
This commit is contained in:
Norikatsu Shigemura 2002-04-28 17:55:00 +00:00
parent f99b430f55
commit 54e864e97e
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=58271
2 changed files with 14 additions and 8 deletions

View File

@ -27,9 +27,9 @@ REPERTOIRE_MAP= ${LINUXBASE}/usr/share/i18n/repertoiremaps/charids.894
LCDEF_CMD= ${LINUXBASE}/usr/bin/localedef
LCDEF_ARGS= --repertoire-map=${REPERTOIRE_MAP} \
-c -f ${CHARMAPS} -i ${SRCDEF}
LCDIR= ${PREFIX}/usr/share/locale/ja_JP
COMPAT_LC= ${PREFIX}/usr/share/locale/ja_JP.EUC
DOCDIR= ${PREFIX}/usr/doc/locale-ja-${VERSION}
LCDIR= ${LINUXBASE}/usr/share/locale/ja_JP
COMPAT_LC= ${LINUXBASE}/usr/share/locale/ja_JP.EUC
DOCDIR= ${LINUXBASE}/usr/doc/locale-ja-${VERSION}
LOCALE_ADD= ja_JP.EUC
LOCALE_DEF_ja_JP.EUC= ja_JP.eucJP
@ -38,8 +38,8 @@ LOCALE_DEF_ja_JP.EUC= ja_JP.eucJP
LOCALE_GREP= ${GREP} -q
.for locale in ${LOCALE_ADD}
LOCALE_ALIASES!= ${ECHO} ${LOCALE_ALIASES} ${locale}:${LOCALE_DEF_${locale}}
LOCALE_GREP!= ${ECHO} "${LOCALE_GREP} -e '^${locale}'"
LOCALE_ALIASES!= ${ECHO_CMD} ${LOCALE_ALIASES} ${locale}:${LOCALE_DEF_${locale}}
LOCALE_GREP!= ${ECHO_CMD} "${LOCALE_GREP} -e '^${locale}'"
.endfor
PLIST_SUB+= LOCALE_ALIASES="${LOCALE_ALIASES}" LOCALE_GREP="${LOCALE_GREP}"
@ -56,9 +56,13 @@ do-install:
${LN} -sf ja_JP ${COMPAT_LC}
${MKDIR} ${DOCDIR}
${INSTALL_DATA} ${WRKSRC}/debian/* ${DOCDIR}
if [ ! -f ${LINUXBASE}/usr/share/locale/locale.alias.orig ]; then \
${CP} -p ${LINUXBASE}/usr/share/locale/locale.alias \
${LINUXBASE}/usr/share/locale/locale.alias.orig \
fi
.for locale in ${LOCALE_ADD}
${GREP} -q -e ^${locale} ${LINUXBASE}/usr/share/locale/locale.alias \
|| ${ECHO} "${locale} ${LOCALE_DEF_${locale}}" \
|| ${ECHO_CMD} "${locale} ${LOCALE_DEF_${locale}}" \
>> ${LINUXBASE}/usr/share/locale/locale.alias
.endfor

View File

@ -9,9 +9,11 @@ usr/share/locale/ja_JP/LC_MESSAGES/SYS_LC_MESSAGES
usr/share/locale/ja_JP/LC_MONETARY
usr/share/locale/ja_JP/LC_NUMERIC
usr/share/locale/ja_JP/LC_TIME
@exec ln -sf ja_JP %D/usr/share/locale/ja_JP.EUC
@exec ln -sf ja_JP %%LINUXBASE%%/usr/share/locale/ja_JP.EUC
@exec [ -f %%LINUXBASE%%/usr/share/locale/locale.alias.orig ] || cp -p %%LINUXBASE%%/usr/share/locale/locale.alias %%LINUXBASE%%/usr/share/locale/locale.alias.orig
@exec echo %%LOCALE_GREP%% %%LINUXBASE%%/usr/share/locale/locale.alias | sh || echo -n %%LOCALE_ALIASES%% | awk -F: 'BEGIN{RS=" "}{print $1" "$2}' >> %%LINUXBASE%%/usr/share/locale/locale.alias
@unexec rm -f %D/usr/share/locale/ja_JP.EUC
@unexec rm -f %%LINUXBASE%%/usr/share/locale/ja_JP.EUC
@unexec mv -f %%LINUXBASE%%/usr/share/locale/locale.alias.orig %%LINUXBASE%%/usr/share/locale/locale.alias
@dirrm usr/share/locale/ja_JP/LC_MESSAGES
@dirrm usr/share/locale/ja_JP
@dirrm usr/doc/locale-ja-%%VER%%