[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] tests/test-xalloc-die.sh: Use $EXEEXT.
From: |
Eric Blake |
Subject: |
Re: [PATCH] tests/test-xalloc-die.sh: Use $EXEEXT. |
Date: |
Thu, 14 Jan 2010 06:31:17 -0700 |
User-agent: |
Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.23) Gecko/20090812 Thunderbird/2.0.0.23 Mnenhy/0.7.6.666 |
According to Jim Meyering on 1/14/2010 1:08 AM:
> Think of a set-up function that (when $EXEEXT is nonempty)
> iterates through the *.$EXEEXT executables in a specified directory...
>
> create_exe_shim_functions ()
> {
> case $EXEEXT in
> '') return 0 ;;
> .exe) ;;
> *) echo "$0: unexpected value of $EXEEXT" 1>&2; return 1 ;;
> esac
So we still have to pass EXEEXT through TESTS_ENVIRONMENT in
modules/*-tests for any test that uses a .sh file. But other than that,
all of our tests-*.sh no longer need to worry about EXEEXT, once they've
been converted to use init.sh. I like it.
Or go one step further, do the search for *.exe without regards to
$EXEEXT, skipping this case block, and simplifying modules/*-tests.
> # Remove the .$EXEEXT suffix.
> base=${file%.$EXEEXT}
This is not portable to Solaris /bin/sh. Unless we take the same measures
as coreutils to ensure a (mostly) POSIX-compliant shell, I think we are
better off using only features supported by common /bin/sh.
--
Don't work too hard, make some time for fun as well!
Eric Blake address@hidden
signature.asc
Description: OpenPGP digital signature
- [PATCH] tests/test-xalloc-die.sh: Use $EXEEXT., Simon Josefsson, 2010/01/12
- Re: [PATCH] tests/test-xalloc-die.sh: Use $EXEEXT., Bruno Haible, 2010/01/12
- Re: [PATCH] tests/test-xalloc-die.sh: Use $EXEEXT., Simon Josefsson, 2010/01/13
- Re: [PATCH] tests/test-xalloc-die.sh: Use $EXEEXT., Jim Meyering, 2010/01/13
- Re: [PATCH] tests/test-xalloc-die.sh: Use $EXEEXT., Eric Blake, 2010/01/13
- Re: [PATCH] tests/test-xalloc-die.sh: Use $EXEEXT., Jim Meyering, 2010/01/13
- Re: [PATCH] tests/test-xalloc-die.sh: Use $EXEEXT., Jim Meyering, 2010/01/14
- Re: [PATCH] tests/test-xalloc-die.sh: Use $EXEEXT., Simon Josefsson, 2010/01/14
- Re: [PATCH] tests/test-xalloc-die.sh: Use $EXEEXT.,
Eric Blake <=
- Re: [PATCH] tests/test-xalloc-die.sh: Use $EXEEXT., Jim Meyering, 2010/01/14
- Re: [PATCH] tests/test-xalloc-die.sh: Use $EXEEXT., Eric Blake, 2010/01/14
- Re: [PATCH] tests/test-xalloc-die.sh: Use $EXEEXT., Ralf Wildenhues, 2010/01/16
- Re: [PATCH] tests/test-xalloc-die.sh: Use $EXEEXT., Bruno Haible, 2010/01/13
- Re: [PATCH] tests/test-xalloc-die.sh: Use $EXEEXT., Simon Josefsson, 2010/01/14