aboutsummaryrefslogtreecommitdiffstats
path: root/lib/odbc
diff options
context:
space:
mode:
authorAlexey Lebedeff <[email protected]>2016-04-21 18:11:58 +0300
committerAlexey Lebedeff <[email protected]>2016-04-21 18:45:23 +0300
commit98b8650d22e94a5ff839170833f691294f6276d0 (patch)
treea2efdc4e9fb8e072a4d7604d8661745bf4c2b7b6 /lib/odbc
parent523e048754f5086a6cc4fd9a250e1b495fc5b9b8 (diff)
downloadotp-98b8650d22e94a5ff839170833f691294f6276d0.tar.gz
otp-98b8650d22e94a5ff839170833f691294f6276d0.tar.bz2
otp-98b8650d22e94a5ff839170833f691294f6276d0.zip
Fix program paths used in build process
Not every OS has '/bin/rm' or '/bin/pwd' at exactly that location. In some places in configure scripts result of AC_PATH_PROG was already correctly used, this patch makes this usage more consistent. As for `/bin/pwd` in `otp_build`, shell built-in one is already used in mingw parts - so it should cause no harm to use it everywhere. Difference is only in symlinks resolution - non-builtin `pwd` always returns absolute path, and builtin-one could take into account what sequence of user actions lead to current value of $PWD.
Diffstat (limited to 'lib/odbc')
-rw-r--r--lib/odbc/configure.in12
1 files changed, 11 insertions, 1 deletions
diff --git a/lib/odbc/configure.in b/lib/odbc/configure.in
index 4b05050ef6..aa9cb0c140 100644
--- a/lib/odbc/configure.in
+++ b/lib/odbc/configure.in
@@ -73,6 +73,16 @@ AC_CHECK_TOOL(LD, ld, '$(CC)')
AC_SUBST(LD)
+_search_path=/bin:/usr/bin:/usr/local/bin:$PATH
+
+AC_PATH_PROG(RM, rm, false, $_search_path)
+if test "$ac_cv_path_RM" = false; then
+ AC_MSG_ERROR([No 'rm' command found])
+fi
+
+_search_path=
+
+
# Sockets
#--------------------------------------------------------------------
# Check for the existence of the -lsocket and -lnsl libraries.
@@ -128,7 +138,7 @@ dnl Checks for library functions.
AC_CHECK_FUNCS([memset socket])
# ODBC
-/bin/rm -f "$ERL_TOP/lib/odbc/SKIP"
+$RM -f "$ERL_TOP/lib/odbc/SKIP"
LM_CHECK_THR_LIB
AC_SUBST(THR_DEFS)