diff options
Diffstat (limited to 'catgets')
-rw-r--r-- | catgets/Makefile | 17 | ||||
-rwxr-xr-x | catgets/test-gencat.sh | 11 |
2 files changed, 15 insertions, 13 deletions
diff --git a/catgets/Makefile b/catgets/Makefile index ed0650807b..50d972e65d 100644 --- a/catgets/Makefile +++ b/catgets/Makefile @@ -61,19 +61,18 @@ ifeq ($(run-built-tests),yes) # This test just checks whether the program produces any error or not. # The result is not tested. $(objpfx)test1.cat: test1.msg $(objpfx)gencat - LC_ALL=hr_HR.ISO-8859-2 LOCPATH=$(common-objpfx)localedata \ - GCONV_PATH=$(common-objpfx)iconvdata \ - $(built-program-cmd) -H $(objpfx)test1.h $@ $<; \ + $(built-program-cmd-before-env) \ + $(run-program-env) LC_ALL=hr_HR.ISO-8859-2 \ + $(built-program-cmd-after-env) -H $(objpfx)test1.h $@ $<; \ $(evaluate-test) $(objpfx)test2.cat: test2.msg $(objpfx)gencat - LOCPATH=$(common-objpfx)localedata \ - GCONV_PATH=$(common-objpfx)iconvdata \ $(built-program-cmd) -H $(objpfx)test2.h $@ $<; \ $(evaluate-test) $(objpfx)de/libc.cat: $(objpfx)de.msg $(objpfx)gencat $(make-target-directory) - LC_ALL=de_DE.ISO-8859-1 LOCPATH=$(common-objpfx)localedata \ - GCONV_PATH=$(common-objpfx)iconvdata $(built-program-cmd) $@ $<; \ + $(built-program-cmd-before-env) \ + $(run-program-env) LC_ALL=de_DE.ISO-8859-1 \ + $(built-program-cmd-after-env) $@ $<; \ $(evaluate-test) $(objpfx)tst-catgets.out: $(objpfx)de/libc.cat @@ -83,11 +82,11 @@ $(objpfx)de.msg: xopen-msg.awk $(..)po/de.po $(objpfx)test-gencat.out: test-gencat.sh $(objpfx)test-gencat \ $(objpfx)sample.SJIS.cat - $(SHELL) $< $(common-objpfx) '$(test-program-cmd)'; \ + $(SHELL) $< $(common-objpfx) '$(test-program-cmd-before-env)' \ + '$(run-program-env)' '$(test-program-cmd-after-env)'; \ $(evaluate-test) $(objpfx)sample.SJIS.cat: sample.SJIS $(objpfx)gencat - GCONV_PATH=$(common-objpfx)iconvdata LC_ALL=C \ $(built-program-cmd) -H $(objpfx)test-gencat.h < $(word 1,$^) > $@; \ $(evaluate-test) endif diff --git a/catgets/test-gencat.sh b/catgets/test-gencat.sh index 08e47af24a..98ef7da6ef 100755 --- a/catgets/test-gencat.sh +++ b/catgets/test-gencat.sh @@ -20,12 +20,15 @@ set -e common_objpfx=$1 -test_program_cmd=$2 +test_program_cmd_before_env=$2 +run_program_env=$3 +test_program_cmd_after_env=$4 # Run the test program. -LOCPATH=${common_objpfx}localedata GCONV_PATH=${common_objpfx}iconvdata \ -NLSPATH=${common_objpfx}catgets/%N.%c.cat LC_ALL=ja_JP.SJIS \ - ${test_program_cmd} \ +${test_program_cmd_before_env} \ + ${run_program_env} \ + NLSPATH=${common_objpfx}catgets/%N.%c.cat LC_ALL=ja_JP.SJIS \ + ${test_program_cmd_after_env} \ > ${common_objpfx}catgets/test-gencat.out # Compare with the expected result. |