summaryrefslogtreecommitdiffstats
path: root/src/configure.ac
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2017-03-16 15:13:45 +0100
committerBram Moolenaar <Bram@vim.org>2017-03-16 15:13:45 +0100
commitf3757f0c87bbd52c7989c85dcbd21511bffcbdd6 (patch)
tree498b5670475fcb798fb3a2a3231333192005f4f6 /src/configure.ac
parent0f39a82b07b285e0c54162e1038348b2988a715c (diff)
patch 8.0.0464: can't find executable name on Solaris and FreeBSDv8.0.0464
Problem: Can't find executable name on Solaris and FreeBSD. Solution: Check for "/proc/self/path/a.out". (Danek Duvall) And for "/proc/curproc/file".
Diffstat (limited to 'src/configure.ac')
-rw-r--r--src/configure.ac17
1 files changed, 13 insertions, 4 deletions
diff --git a/src/configure.ac b/src/configure.ac
index 4445cf5bfe..6251681e4a 100644
--- a/src/configure.ac
+++ b/src/configure.ac
@@ -3020,12 +3020,21 @@ dnl ---------------------------------------------------------------------------
dnl end of GUI-checking
dnl ---------------------------------------------------------------------------
-AC_MSG_CHECKING([for /proc/self/exe])
+AC_MSG_CHECKING([for /proc link to executable])
if test -L "/proc/self/exe"; then
- AC_MSG_RESULT(yes)
- AC_DEFINE(HAVE_PROC_SELF_EXE)
+ dnl Linux
+ AC_MSG_RESULT([/proc/self/exe])
+ AC_DEFINE(PROC_EXE_LINK, "/proc/self/exe")
+elif test -L "/proc/self/path/a.out"; then
+ dnl Solaris
+ AC_MSG_RESULT([/proc/self/path/a.out])
+ AC_DEFINE(PROC_EXE_LINK, "/proc/self/path/a.out")
+elif test -L "/proc/curproc/file"; then
+ dnl FreeBSD
+ AC_MSG_RESULT([/proc/curproc/file])
+ AC_DEFINE(PROC_EXE_LINK, "/proc/curproc/file")
else
- AC_MSG_RESULT(no)
+ AC_MSG_RESULT(no)
fi
dnl Check for Cygwin, which needs an extra source file if not using X11