summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorH.Merijn Brand <h.m.brand@xs4all.nl>2016-12-09 15:22:06 +0100
committerRaphael Manfredi <Raphael_Manfredi@pobox.com>2016-12-09 15:22:06 +0100
commit774944e8132ad42466f4c93f29294eeed090a138 (patch)
tree2aff1ab65ad270ac02356ed105c227ab0cf58f9b
parent9f910d66c936dfdff953e212376f1943af479509 (diff)
First flurry of using $rm_try to clean op (#8)
-rw-r--r--mcon/U/Unix.U9
-rw-r--r--mcon/U/byteorder.U4
-rw-r--r--mcon/U/ccflags.U4
-rw-r--r--mcon/U/charsize.U4
-rw-r--r--mcon/U/d_casti32.U4
-rw-r--r--mcon/U/d_castneg.U4
-rw-r--r--mcon/U/d_gconvert.U4
-rw-r--r--mcon/U/d_gnulibc.U4
-rw-r--r--mcon/U/d_sanemcmp.U4
-rw-r--r--mcon/U/d_stdstdio.U8
-rw-r--r--mcon/U/d_strctcpy.U4
-rw-r--r--mcon/U/d_volatile.U4
-rw-r--r--mcon/U/doublesize.U4
-rw-r--r--mcon/U/ebcdic.U4
-rw-r--r--mcon/U/i_db.U6
-rw-r--r--mcon/U/i_dirent.U6
-rw-r--r--mcon/U/i_neterrno.U4
-rw-r--r--mcon/U/i_time.U4
-rw-r--r--mcon/U/intsize.U4
-rw-r--r--mcon/U/nblock_io.U6
-rw-r--r--mcon/U/ptrsize.U4
-rw-r--r--mcon/U/voidflags.U4
22 files changed, 54 insertions, 49 deletions
diff --git a/mcon/U/Unix.U b/mcon/U/Unix.U
index 5ab7fc3..122c21e 100644
--- a/mcon/U/Unix.U
+++ b/mcon/U/Unix.U
@@ -19,7 +19,7 @@
?X: environment, then some of the following variables can be redefined in hint
?X: files.
?X:
-?MAKE:Unix _a _o firstmakefile archobjs: Oldconfig
+?MAKE:Unix _a _o firstmakefile archobjs rm_try: Oldconfig rm
?MAKE: -pick add $@ %<
?S:_a (lib_ext):
?S: This variable defines the extension used for ordinary libraries.
@@ -44,7 +44,10 @@
?S: or other facilities. For perl on OS/2, for example, this would
?S: include os2/os2.obj.
?S:.
-?INIT:: Extra object files, if any, needed on this platform.
+?S:rm_try:
+?S: This is a cleanup variable for try test programs.
+?S: Internal Configure use only.
+?S:.?INIT:: Extra object files, if any, needed on this platform.
?INIT:archobjs=''
: Define several unixisms.
: Hints files or command line option can be used to override them.
@@ -55,6 +58,8 @@ case "$_o" in
'') _o='.o';;
esac
+rm_try="$rm -f try try$_exe a.out .out try.[cho] try.$_o core core.try* try.core*"
+
@if firstmakefile
: Which makefile gets called first. This is used by make depend.
case "$firstmakefile" in
diff --git a/mcon/U/byteorder.U b/mcon/U/byteorder.U
index ef2050a..9bd2467 100644
--- a/mcon/U/byteorder.U
+++ b/mcon/U/byteorder.U
@@ -7,7 +7,7 @@
?RCS: that same Artistic License; a copy of which may be found at the root
?RCS: of the source tree for dist 4.0.
?RCS:
-?MAKE:byteorder: cat contains echo n c Myread Oldconfig Loc +cc +ccflags rm _o
+?MAKE:byteorder: cat contains echo n c Myread Oldconfig Loc +cc +ccflags rm_try _o
?MAKE: -pick add $@ %<
?S:byteorder:
?S: This variable holds the byte order. In the following, larger digits
@@ -64,5 +64,5 @@ case "$order" in
4321) echo " big-endian." >&4;;
esac
byteorder=$order
-$rm -f try.c try$_o
+$rm_try
diff --git a/mcon/U/ccflags.U b/mcon/U/ccflags.U
index 32b040e..942e462 100644
--- a/mcon/U/ccflags.U
+++ b/mcon/U/ccflags.U
@@ -47,7 +47,7 @@
?RCS:
?MAKE:ccflags ldflags lkflags cppflags optimize pthread locincpth: test cat \
Myread Guess Options Oldconfig gccversion mips_type +usrinc \
- package contains rm +cc cppstdin cppminus cpprun cpplast libpth \
+ package contains rm rm_try +cc cppstdin cppminus cpprun cpplast libpth \
loclibpth hint
?MAKE: -pick add $@ %<
?S:ccflags:
@@ -453,5 +453,5 @@ y)
;;
n) echo "OK, that should do.";;
esac
-$rm -f try try.* core
+$rm_try
diff --git a/mcon/U/charsize.U b/mcon/U/charsize.U
index f69fea7..ae3cd8b 100644
--- a/mcon/U/charsize.U
+++ b/mcon/U/charsize.U
@@ -15,7 +15,7 @@
?RCS: Revision 3.0 1993/08/18 12:05:34 ram
?RCS: Baseline for dist 3.0 netwide release.
?RCS:
-?MAKE:charsize: Assert Myread cat rm +cc +ccflags echo n c
+?MAKE:charsize: Assert Myread cat rm_try +cc +ccflags echo n c
?MAKE: -pick add $@ %<
?S:charsize:
?S: This variable contains the value of the CHARSIZE symbol, which
@@ -60,5 +60,5 @@ error)
charsize=$size
;;
esac
-$rm -f try.*
+$rm_try
diff --git a/mcon/U/d_casti32.U b/mcon/U/d_casti32.U
index 7641da8..6363761 100644
--- a/mcon/U/d_casti32.U
+++ b/mcon/U/d_casti32.U
@@ -23,7 +23,7 @@
?X:
?X: Can the compiler cast large floats to 32-bit integers?
?X:
-?MAKE:d_casti32: cat +cc +ccflags rm intsize Setvar test signal_t
+?MAKE:d_casti32: cat +cc +ccflags rm_try intsize Setvar test signal_t
?MAKE: -pick add $@ %<
?S:d_casti32:
?S: This variable conditionally defines CASTI32, which indicates
@@ -83,5 +83,5 @@ case "$yyy" in
esac
set d_casti32
eval $setvar
-$rm -f try try.*
+$rm_try
diff --git a/mcon/U/d_castneg.U b/mcon/U/d_castneg.U
index be8ae0e..517ac1c 100644
--- a/mcon/U/d_castneg.U
+++ b/mcon/U/d_castneg.U
@@ -23,7 +23,7 @@
?X:
?X: Can the compiler cast negative / odd floats to unsigned values.
?X:
-?MAKE:d_castneg castflags: cat +cc +ccflags rm Setvar signal_t
+?MAKE:d_castneg castflags: cat +cc +ccflags rm_try Setvar signal_t
?MAKE: -pick add $@ %<
?S:d_castneg:
?S: This variable conditionally defines CASTNEG, which indicates
@@ -139,5 +139,5 @@ case "$castflags" in
esac
set d_castneg
eval $setvar
-$rm -f try.*
+$rm_try
diff --git a/mcon/U/d_gconvert.U b/mcon/U/d_gconvert.U
index efd24f0..af79327 100644
--- a/mcon/U/d_gconvert.U
+++ b/mcon/U/d_gconvert.U
@@ -21,7 +21,7 @@
?RCS: Revision 3.0.1.1 1994/10/29 16:12:51 ram
?RCS: patch36: created by ADO
?RCS:
-?MAKE:d_Gconvert: cat cc ccflags ldflags libs rm _o
+?MAKE:d_Gconvert: cat cc ccflags ldflags libs rm_try _o
?MAKE: -pick add $@ %<
?S:d_Gconvert:
?S: This variable holds what Gconvert is defined as to convert
@@ -124,7 +124,7 @@ esac
for xxx_convert in $xxx_list; do
echo "Trying $xxx_convert"
- $rm -f try try$_o
+ $rm_try
if $cc $ccflags -DTRY_$xxx_convert $ldflags -o try \
try.c $libs > /dev/null 2>&1 ; then
echo "$xxx_convert" found. >&4
diff --git a/mcon/U/d_gnulibc.U b/mcon/U/d_gnulibc.U
index 12b1fef..a839def 100644
--- a/mcon/U/d_gnulibc.U
+++ b/mcon/U/d_gnulibc.U
@@ -10,7 +10,7 @@
?RCS: that same Artistic License; a copy of which may be found at the root
?RCS: of the source tree for dist 4.0.
?RCS:
-?MAKE:d_gnulibc gnulibc_version: Myread Oldconfig Setvar rm \
+?MAKE:d_gnulibc gnulibc_version: Myread Oldconfig Setvar rm_try \
cat Compile run
?MAKE: -pick add $@ %<
?S:d_gnulibc:
@@ -92,7 +92,7 @@ else
gnulibc_version=''
echo "You are not using the GNU C Library"
fi
-$rm -f try try.* glibc.ver
+$rm_try glibc.ver
set d_gnulibc
eval $setvar
diff --git a/mcon/U/d_sanemcmp.U b/mcon/U/d_sanemcmp.U
index f87652c..f2dc7d9 100644
--- a/mcon/U/d_sanemcmp.U
+++ b/mcon/U/d_sanemcmp.U
@@ -13,7 +13,7 @@
?RCS: patch61: created
?RCS:
?RCS:
-?MAKE:d_sanemcmp: cat d_memcmp +cc +optimize +ccflags +libs +ldflags rm \
+?MAKE:d_sanemcmp: cat d_memcmp +cc +optimize +ccflags +libs +ldflags rm_try \
i_memory i_stdlib i_string i_unistd Oldconfig Setvar
?MAKE: -pick add $@ %<
?S:d_sanemcmp:
@@ -82,7 +82,7 @@ EOCP
fi
;;
esac
-$rm -f foo.* sanemcmp core
+$rm_try foo.* sanemcmp
set d_sanemcmp
eval $setvar
diff --git a/mcon/U/d_stdstdio.U b/mcon/U/d_stdstdio.U
index e46cee1..fe3a853 100644
--- a/mcon/U/d_stdstdio.U
+++ b/mcon/U/d_stdstdio.U
@@ -27,7 +27,7 @@
?RCS:
?MAKE:d_stdstdio d_stdiobase stdio_ptr stdio_cnt stdio_base \
stdio_bufsiz d_stdio_cnt_lval d_stdio_ptr_lval stdio_filbuf: cat \
- +cc +ccflags contains +ldflags +libs rm \
+ +cc +ccflags contains +ldflags +libs rm_try \
Setvar Findhdr Oldconfig
?MAKE: -pick add $@ %<
?S:d_stdstdio:
@@ -218,7 +218,7 @@ if $cc $ccflags $ldflags -o try try.c $libs >/dev/null 2>&1; then
else
echo "Your stdio doesn't appear very std."
fi
-$rm -f try.c try
+$rm_try
set d_stdstdio
eval $setvar
@@ -274,7 +274,7 @@ EOP
else
echo "Hmm. $filbuf doesn't seem to work."
fi
- $rm -f try.c try
+ $rm_try
done
case "$xxx" in
notok) echo "I can't figure out how to access _filbuf"
@@ -316,7 +316,7 @@ EOP
else
echo "However, it seems to be lacking the _base field."
fi
- $rm -f try.c try
+ $rm_try
;;
esac
set d_stdiobase
diff --git a/mcon/U/d_strctcpy.U b/mcon/U/d_strctcpy.U
index 5fbe8c9..c5e9c40 100644
--- a/mcon/U/d_strctcpy.U
+++ b/mcon/U/d_strctcpy.U
@@ -12,7 +12,7 @@
?RCS: Revision 3.0 1993/08/18 12:07:34 ram
?RCS: Baseline for dist 3.0 netwide release.
?RCS:
-?MAKE:d_strctcpy: cat rm cc Setvar
+?MAKE:d_strctcpy: cat rm_try cc Setvar
?MAKE: -pick add $@ %<
?S:d_strctcpy:
?S: This variable conditionally defines the USE_STRUCT_COPY symbol, which
@@ -49,5 +49,5 @@ else
fi
set d_strctcpy
eval $setvar
-$rm -f try.*
+$rm_try
diff --git a/mcon/U/d_volatile.U b/mcon/U/d_volatile.U
index be17638..542f512 100644
--- a/mcon/U/d_volatile.U
+++ b/mcon/U/d_volatile.U
@@ -18,7 +18,7 @@
?RCS: Revision 3.0 1993/08/18 12:07:57 ram
?RCS: Baseline for dist 3.0 netwide release.
?RCS:
-?MAKE:d_volatile: cat +cc +ccflags rm Setvar
+?MAKE:d_volatile: cat +cc +ccflags rm_try Setvar
?MAKE: -pick add $@ %<
?S:d_volatile:
?S: This variable conditionally defines the HASVOLATILE symbol, which
@@ -75,5 +75,5 @@ else
fi
set d_volatile
eval $setvar
-$rm -f try.*
+$rm_try
diff --git a/mcon/U/doublesize.U b/mcon/U/doublesize.U
index 15fc4cf..2fc5724 100644
--- a/mcon/U/doublesize.U
+++ b/mcon/U/doublesize.U
@@ -15,7 +15,7 @@
?RCS: Revision 3.0 1993/08/18 12:08:06 ram
?RCS: Baseline for dist 3.0 netwide release.
?RCS:
-?MAKE:doublesize: cat rm Myread +cc +ccflags
+?MAKE:doublesize: cat rm_try Myread +cc +ccflags
?MAKE: -pick add $@ %<
?S:doublesize:
?S: This variable contains the value of the DOUBLESIZE symbol, which
@@ -54,5 +54,5 @@ esac
rp="What is the size of a double precision number (in bytes)?"
. ./myread
doublesize="$ans"
-$rm -f try.c try
+$rm_try
diff --git a/mcon/U/ebcdic.U b/mcon/U/ebcdic.U
index 87e875a..6a1dda3 100644
--- a/mcon/U/ebcdic.U
+++ b/mcon/U/ebcdic.U
@@ -13,7 +13,7 @@
?RCS: Original author Jarkko Hietaniemi <jhi@iki.fi>
?RCS: Merged into dist by Andy Dougherty July 13, 1998
?RCS:
-?MAKE:ebcdic: Compile Setvar cat rm run
+?MAKE:ebcdic: Compile Setvar cat rm_try run
?MAKE: -pick add $@ %<
?S:ebcdic:
?S: This variable conditionally defines EBCDIC if this
@@ -52,7 +52,7 @@ else
echo "I'm unable to compile the test program." >&4
echo "I'll assume ASCII or some ISO Latin. Or UTF8." >&4
fi
-$rm -f try try.*
+$rm_try
set ebcdic
eval $setvar
diff --git a/mcon/U/i_db.U b/mcon/U/i_db.U
index df11bbc..dad068e 100644
--- a/mcon/U/i_db.U
+++ b/mcon/U/i_db.U
@@ -20,7 +20,7 @@
?RCS: Revision 3.0.1.1 1994/08/29 16:21:50 ram
?RCS: patch32: created by ADO
?RCS:
-?MAKE:i_db db_hashtype db_prefixtype: Inhdr +cc +ccflags rm contains cat \
+?MAKE:i_db db_hashtype db_prefixtype: Inhdr +cc +ccflags rm_try contains cat \
d_const
?MAKE: -pick add $@ %<
?S:i_db:
@@ -94,7 +94,7 @@ EOCP
echo "I can't seem to compile the test program." >&4
db_hashtype=int
fi
- $rm -f try.*
+ $rm_try
echo "Your version of Berkeley DB uses $db_hashtype for hash."
;;
*) db_hashtype=int
@@ -136,7 +136,7 @@ EOCP
echo "I can't seem to compile the test program." >&4
db_prefixtype='int'
fi
- $rm -f try.*
+ $rm_try
echo "Your version of Berkeley DB uses $db_prefixtype for prefix."
;;
*) db_prefixtype='int'
diff --git a/mcon/U/i_dirent.U b/mcon/U/i_dirent.U
index 16836dc..9a4b017 100644
--- a/mcon/U/i_dirent.U
+++ b/mcon/U/i_dirent.U
@@ -29,7 +29,7 @@
?X: This unit looks whether there is a dirent system or not
?X:
?MAKE:i_dirent d_dirnamlen direntrytype: test contains Setvar \
- Myread Findhdr cppstdin cppflags cppminus rm
+ Myread Findhdr cppstdin cppflags cppminus rm_try
?MAKE: -pick add $@ %<
?S:i_dirent:
?S: This variable conditionally defines I_DIRENT, which indicates
@@ -124,7 +124,7 @@ else
. ./myread
direntrytype="$ans"
fi
-$rm -f try.c
+$rm_try
@end
@@ -141,6 +141,6 @@ else
fi
set d_dirnamlen
eval $setvar
-$rm -f try.c
+$rm_try
@end
diff --git a/mcon/U/i_neterrno.U b/mcon/U/i_neterrno.U
index a0003e6..7bc231d 100644
--- a/mcon/U/i_neterrno.U
+++ b/mcon/U/i_neterrno.U
@@ -20,7 +20,7 @@
?RCS: Revision 3.0.1.1 1994/06/20 07:02:05 ram
?RCS: patch30: created by ADO
?RCS:
-?MAKE:i_neterrno: Inhdr +cc +ccflags rm Setvar
+?MAKE:i_neterrno: Inhdr +cc +ccflags rm_try Setvar
?MAKE: -pick add $@ %<
?S:i_neterrno:
?S: This variable conditionally defines the I_NET_ERRNO symbol, which
@@ -57,7 +57,7 @@ EOM
echo "We won't be including <net/errno.h>." >&4
val="$undef"
fi
- $rm -f try.* try
+ $rm_try
;;
esac
set i_neterrno
diff --git a/mcon/U/i_time.U b/mcon/U/i_time.U
index 78448e5..cd7ec6d 100644
--- a/mcon/U/i_time.U
+++ b/mcon/U/i_time.U
@@ -17,7 +17,7 @@
?X: program, we also try to find which header should be included. Eventually,
?X: we look for <sys/select.h> if I_SYSSELECT is used, to get struct timeval.
?X:
-?MAKE:i_time i_systime i_systimek timeincl: cat cc ccflags contains rm \
+?MAKE:i_time i_systime i_systimek timeincl: cat cc ccflags contains rm_try \
echo n c +i_sysselct Findhdr
?MAKE: -pick add $@ %<
?S:i_time:
@@ -167,5 +167,5 @@ case "$flags" in
esac
esac
@end
-$rm -f try.c try
+$rm_try
diff --git a/mcon/U/intsize.U b/mcon/U/intsize.U
index 6ec3c8b..d5135db 100644
--- a/mcon/U/intsize.U
+++ b/mcon/U/intsize.U
@@ -8,7 +8,7 @@
?RCS: that same Artistic License; a copy of which may be found at the root
?RCS: of the source tree for dist 4.0.
?RCS:
-?MAKE:intsize longsize shortsize: Assert Myread cat rm +cc +ccflags echo n c
+?MAKE:intsize longsize shortsize: Assert Myread cat rm_try +cc +ccflags echo n c
?MAKE: -pick add $@ %<
?S:intsize:
?S: This variable contains the value of the INTSIZE symbol, which
@@ -85,5 +85,5 @@ EOCP
;;
esac
done
-$rm -f try.*
+$rm_try
diff --git a/mcon/U/nblock_io.U b/mcon/U/nblock_io.U
index 1bbaf3d..58dd845 100644
--- a/mcon/U/nblock_io.U
+++ b/mcon/U/nblock_io.U
@@ -21,7 +21,7 @@
?X: Simplify here document for shells that can't handle them well.
?X: (Problem reported on FreeBSD; it's unclear if this helps.) --AD
?X:
-?MAKE:o_nonblock eagain rd_nodata d_eofnblk: cat rm +cc +ccflags +ldflags \
+?MAKE:o_nonblock eagain rd_nodata d_eofnblk: cat rm_try +cc +ccflags +ldflags \
d_open3 h_sysfile h_fcntl signal_t hint Oldconfig Setvar startsh Warn
?MAKE: -pick add $@ %<
?S:o_nonblock:
@@ -127,7 +127,7 @@ EOCP
;;
*) echo "Using $hint value $o_nonblock.";;
esac
-$rm -f try try.* .out core
+$rm_try
echo " "
echo "Let's see what value errno gets from read() on a $o_nonblock file..." >&4
@@ -257,5 +257,5 @@ EOCP
esac
;;
esac
-$rm -f try try.* .out core head.c mtry
+$rm_try head.c mtry
diff --git a/mcon/U/ptrsize.U b/mcon/U/ptrsize.U
index ccefbfe..ed77a4a 100644
--- a/mcon/U/ptrsize.U
+++ b/mcon/U/ptrsize.U
@@ -8,7 +8,7 @@
?RCS: that same Artistic License; a copy of which may be found at the root
?RCS: of the source tree for dist 4.0.
?RCS:
-?MAKE:ptrsize: Assert Myread cat rm +cc +ccflags echo n c
+?MAKE:ptrsize: Assert Myread cat rm_try +cc +ccflags echo n c
?MAKE: -pick add $@ %<
?S:ptrsize:
?S: This variable contains the value of the PTRSIZE symbol, which
@@ -49,5 +49,5 @@ error)
ptrsize=$size
;;
esac
-$rm -f try.*
+$rm_try
diff --git a/mcon/U/voidflags.U b/mcon/U/voidflags.U
index 619aa14..0e0f49c 100644
--- a/mcon/U/voidflags.U
+++ b/mcon/U/voidflags.U
@@ -18,7 +18,7 @@
?RCS: Revision 3.0 1993/08/18 12:10:01 ram
?RCS: Baseline for dist 3.0 netwide release.
?RCS:
-?MAKE:voidflags defvoidused: cat sed rm contains +cc +ccflags package \
+?MAKE:voidflags defvoidused: cat sed rm rm_try contains +cc +ccflags package \
Oldconfig Myread
?MAKE: -pick add $@ %<
?S:voidflags:
@@ -176,5 +176,5 @@ case "$voidflags" in
voidflags="$ans"
;;
esac
-$rm -f try.* .out flags
+$rm_try flags