]> gcc.gnu.org Git - gcc.git/blame - texinfo/aclocal.m4
aclocal.m4: Add replacement for AC_PROG_INSTALL.
[gcc.git] / texinfo / aclocal.m4
CommitLineData
6599da04
JM
1dnl aclocal.m4 generated automatically by aclocal 1.2
2
3# Check to see if we're running under Cygwin32, without using
4# AC_CANONICAL_*. If so, set output variable CYGWIN32 to "yes".
5# Otherwise set it to "no".
6
7dnl AM_CYGWIN32()
8AC_DEFUN(AM_CYGWIN32,
9[AC_CACHE_CHECK(for Cygwin32 environment, am_cv_cygwin32,
10[AC_TRY_COMPILE(,[int main () { return __CYGWIN32__; }],
11am_cv_cygwin32=yes, am_cv_cygwin32=no)
12rm -f conftest*])
13CYGWIN32=
14test "$am_cv_cygwin32" = yes && CYGWIN32=yes])
15
16# Check to see if we're running under Win32, without using
17# AC_CANONICAL_*. If so, set output variable EXEEXT to ".exe".
18# Otherwise set it to "".
19
20dnl AM_EXEEXT()
21dnl This knows we add .exe if we're building in the Cygwin32
22dnl environment. But if we're not, then it compiles a test program
23dnl to see if there is a suffix for executables.
24AC_DEFUN(AM_EXEEXT,
25dnl AC_REQUIRE([AC_PROG_CC])AC_REQUIRE([AM_CYGWIN32])
26AC_MSG_CHECKING([for executable suffix])
27[AC_CACHE_VAL(am_cv_exeext,
28[if test "$CYGWIN32" = yes; then
29am_cv_exeext=.exe
30else
31cat > am_c_test.c << 'EOF'
32int main() {
33/* Nothing needed here */
34}
35EOF
36${CC-cc} -o am_c_test $CFLAGS $CPPFLAGS $LDFLAGS am_c_test.c $LIBS 1>&5
37am_cv_exeext=`ls am_c_test.* | grep -v am_c_test.c | sed -e s/am_c_test//`
38rm -f am_c_test*])
39test x"${am_cv_exeext}" = x && am_cv_exeext=no
40fi
41EXEEXT=""
42test x"${am_cv_exeext}" != xno && EXEEXT=${am_cv_exeext}
43AC_MSG_RESULT(${am_cv_exeext})
44AC_SUBST(EXEEXT)])
45
999087f6
JL
46AC_DEFUN(EGCS_PROG_INSTALL,
47[AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl
48# Find a good install program. We prefer a C program (faster),
49# so one script is as good as another. But avoid the broken or
50# incompatible versions:
51# SysV /etc/install, /usr/sbin/install
52# SunOS /usr/etc/install
53# IRIX /sbin/install
54# AIX /bin/install
55# AFS /usr/afsws/bin/install, which mishandles nonexistent args
56# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
57# ./install, which can be erroneously created by make from ./install.sh.
58AC_MSG_CHECKING(for a BSD compatible install)
59if test -z "$INSTALL"; then
60AC_CACHE_VAL(ac_cv_path_install,
61[ IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="${IFS}:"
62 for ac_dir in $PATH; do
63 # Account for people who put trailing slashes in PATH elements.
64 case "$ac_dir/" in
65 /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
66 *)
67 # OSF1 and SCO ODT 3.0 have their own names for install.
68 for ac_prog in ginstall scoinst install; do
69 if test -f $ac_dir/$ac_prog; then
70 if test $ac_prog = install &&
71 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
72 # AIX install. It has an incompatible calling convention.
73 # OSF/1 installbsd also uses dspmsg, but is usable.
74 :
75 else
76 ac_cv_path_install="$ac_dir/$ac_prog -c"
77 break 2
78 fi
79 fi
80 done
81 ;;
82 esac
83 done
84 IFS="$ac_save_IFS"
85])dnl
86 if test "${ac_cv_path_install+set}" = set; then
87 INSTALL="$ac_cv_path_install"
88 else
89 # As a last resort, use the slow shell script. We don't cache a
90 # path for INSTALL within a source directory, because that will
91 # break other packages using the cache if that directory is
92 # removed, or if the path is relative.
93 INSTALL="$ac_install_sh"
94 fi
95fi
96dnl We do special magic for INSTALL instead of AC_SUBST, to get
97dnl relative paths right.
98AC_MSG_RESULT($INSTALL)
99
100# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
101# It thinks the first close brace ends the variable substitution.
102test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
103AC_SUBST(INSTALL_PROGRAM)dnl
104
105test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
106AC_SUBST(INSTALL_DATA)dnl
107])
This page took 0.048049 seconds and 5 git commands to generate.