mirror of
https://git.FreeBSD.org/ports.git
synced 2024-11-06 22:51:41 +00:00
4e86acd9b3
PR: 7690 Submitted by: maintainer
42 lines
1.4 KiB
Bash
42 lines
1.4 KiB
Bash
#!/bin/sh
|
|
|
|
cd ${WRKSRC}
|
|
|
|
${MV} GP GP.bak
|
|
if [ X"${LANGUAGE}" = "XEnglish" ]; then
|
|
${SED} \
|
|
-e 's@^\(set[ ]*PRINTER_LIST[ ]*\)"[^"]*"\(.*\)$@\1"%%PREFIX%%/lib/GP/printer"\2@' \
|
|
-e 's@^\(set[ ]*FILETYPE_LIST[ ]*\)"[^"]*"\(.*\)$@\1"%%PREFIX%%/lib/GP/filetype"\2@' \
|
|
-e 's@^\(set[ ]*FILTERS_DIR[ ]*\)"[^"]*"\(.*\)$@\1"%%PREFIX%%/lib/GP/filters"\2@' \
|
|
-e 's@^\(set[ ]*ICONS_PATH[ ]*\)"[^"]*"\(.*\)$@\1"%%PREFIX%%/lib/GP/icons"\2@' \
|
|
< GP.bak > GP
|
|
elif [ X"${LANGUAGE}" = "XJapanese" ]; then
|
|
${SED} \
|
|
-e 's@^\(set[ ]*PRINTER_LIST[ ]*\)"[^"]*"\(.*\)$@\1"%%PREFIX%%/lib/GP/ja/printer"\2@' \
|
|
-e 's@^\(set[ ]*FILETYPE_LIST[ ]*\)"[^"]*"\(.*\)$@\1"%%PREFIX%%/lib/GP/ja/filetype"\2@' \
|
|
-e 's@^\(set[ ]*FILTERS_DIR[ ]*\)"[^"]*"\(.*\)$@\1"%%PREFIX%%/lib/GP/ja/filters"\2@' \
|
|
-e 's@^\(set[ ]*ICONS_PATH[ ]*\)"[^"]*"\(.*\)$@\1"%%PREFIX%%/lib/GP/ja/icons"\2@' \
|
|
< GP.bak > GP
|
|
fi
|
|
${MV} GP GP.bak
|
|
${SED} \
|
|
-e "s@%%PREFIX%%@${PREFIX}@g" \
|
|
-e 's@^\(set[ ]*PS_PREVIEWER[ ]*\)"[^"]*"\(.*\)$@\1"/usr/X11R6/bin/gv"\2@' \
|
|
< GP.bak > GP
|
|
|
|
cd ${WRKSRC}/filters
|
|
|
|
if [ X"${LANGUAGE}" = "XEnglish" ]; then
|
|
for f in a2ps dvips; do
|
|
${MV} ${f} ${f}.bak
|
|
${SED} -e 's@^\(NUMBER[ ]*=\).*$@\1 1@' < ${f}.bak > ${f}
|
|
${RM} -f ${f}.bak
|
|
done
|
|
elif [ X"${LANGUAGE}" = "XJapanese" ]; then
|
|
for f in a2ps-j dvi2ps-j; do
|
|
${MV} ${f} ${f}.bak
|
|
${SED} -e 's@^\(NUMBER[ ]*=\).*$@\1 1@' < ${f}.bak > ${f}
|
|
${RM} -f ${f}.bak
|
|
done
|
|
fi
|