diff options
author | Jim Meyering <meyering@redhat.com> | 2011-04-02 18:25:40 +0200 |
---|---|---|
committer | Jim Meyering <meyering@redhat.com> | 2011-04-04 18:21:31 +0200 |
commit | 6227c8e8dea8c02bc0ef30e2bf286c2be2adb52f (patch) | |
tree | 75b6374cb0615ddad82b2db6905f564ab152b75d /src | |
parent | 8d0b79afa54a5a0a7afcef415eb62fa0c8a33451 (diff) | |
download | coreutils-6227c8e8dea8c02bc0ef30e2bf286c2be2adb52f.tar.xz |
tests: minor improvement of sc_tight_scope rule
* src/Makefile.am (sc_tight_scope): Adjust rule to use an eval-based
trap-setting for-loop rather than 4x hard-coded 128+N constants.
Also catch SIGQUIT (3). Tweak comments.
Diffstat (limited to 'src')
-rw-r--r-- | src/Makefile.am | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/Makefile.am b/src/Makefile.am index 5bd71d258..1727d6718 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -707,8 +707,8 @@ sc_check-AUTHORS: $(all_programs) # Most functions in src/*.c should have static scope. # Any that don't must be marked with `extern', but `main' -# and `usage' are exceptions. They're always extern, but -# don't need to be marked. Also functions starting with __ +# and `usage' are exceptions: they're always extern, but +# do not need to be marked. Also functions starting with __ # are exempted due to possibly being added by the compiler # (when compiled as a shared library for example). # @@ -717,9 +717,9 @@ sc_check-AUTHORS: $(all_programs) sc_tight_scope: $(bin_PROGRAMS) @t=exceptions-$$$$; \ trap 's=$$?; rm -f $$t; exit $$s' 0; \ - am__exit='(exit $s); exit $s'; \ - trap "s=129; $$am__exit" 1; trap "s=130; $$am__exit" 2; \ - trap "s=141; $$am__exit" 13; trap "s=143; $$am__exit" 15; \ + for sig in 1 2 3 13 15; do \ + eval "trap 'v=`expr $$sig + 128`; (exit $$v); exit $$v' $$sig"; \ + done; \ src=`for f in $(SOURCES); do \ test -f $$f && d= || d=$(srcdir)/; echo $$d$$f; done`; \ hdr=`for f in $(noinst_HEADERS); do \ |