summaryrefslogtreecommitdiffstats
path: root/Source/kwsys/SharedForward.h.in
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2009-12-16 19:25:46 (GMT)
committerBrad King <brad.king@kitware.com>2009-12-16 19:25:46 (GMT)
commit56fe170043548e42728105ada644941fc3ae978b (patch)
treee47475b00b70602388102bdd8ae783a60987f9f1 /Source/kwsys/SharedForward.h.in
parente800604f347aa2d803bec34a5fb924a8d63fcb34 (diff)
downloadCMake-56fe170043548e42728105ada644941fc3ae978b.zip
CMake-56fe170043548e42728105ada644941fc3ae978b.tar.gz
CMake-56fe170043548e42728105ada644941fc3ae978b.tar.bz2
KWSys: Improve SharedForward platform table
The SharedForward header contains a preprocessor table mapping from platform to equivalents for ldd and LD_LIBRARY_PATH. This commit fixes the table preprocessor directives to guarantee at most one platform. This generalizes the commit "Fix compilation of VTK on debian/sparc".
Diffstat (limited to 'Source/kwsys/SharedForward.h.in')
-rw-r--r--Source/kwsys/SharedForward.h.in24
1 files changed, 8 insertions, 16 deletions
diff --git a/Source/kwsys/SharedForward.h.in b/Source/kwsys/SharedForward.h.in
index 53b74c6..a5f3a4d 100644
--- a/Source/kwsys/SharedForward.h.in
+++ b/Source/kwsys/SharedForward.h.in
@@ -194,31 +194,27 @@ static const char kwsys_shared_forward_path_slash[2] = {KWSYS_SHARED_FORWARD_PAT
# define KWSYS_SHARED_FORWARD_LDD "ldd"
# define KWSYS_SHARED_FORWARD_LDD_N 1
# define KWSYS_SHARED_FORWARD_LDPATH "LD_LIBRARY_PATH"
-#endif
/* FreeBSD */
-#if defined(__FreeBSD__)
+#elif defined(__FreeBSD__)
# define KWSYS_SHARED_FORWARD_LDD "ldd"
# define KWSYS_SHARED_FORWARD_LDD_N 1
# define KWSYS_SHARED_FORWARD_LDPATH "LD_LIBRARY_PATH"
-#endif
/* OSX */
-#if defined(__APPLE__)
+#elif defined(__APPLE__)
# define KWSYS_SHARED_FORWARD_LDD "otool", "-L"
# define KWSYS_SHARED_FORWARD_LDD_N 2
# define KWSYS_SHARED_FORWARD_LDPATH "DYLD_LIBRARY_PATH"
-#endif
/* AIX */
-#if defined(_AIX)
+#elif defined(_AIX)
# define KWSYS_SHARED_FORWARD_LDD "dump", "-H"
# define KWSYS_SHARED_FORWARD_LDD_N 2
# define KWSYS_SHARED_FORWARD_LDPATH "LIBPATH"
-#endif
/* SUN */
-#if defined(__sparc) && !defined(__linux)
+#elif defined(__sun)
# define KWSYS_SHARED_FORWARD_LDD "ldd"
# define KWSYS_SHARED_FORWARD_LDD_N 1
# include <sys/isa_defs.h>
@@ -227,10 +223,9 @@ static const char kwsys_shared_forward_path_slash[2] = {KWSYS_SHARED_FORWARD_PAT
# elif defined(_LP64)
# define KWSYS_SHARED_FORWARD_LDPATH "LD_LIBRARY_PATH_64"
# endif
-#endif
/* HP-UX */
-#if defined(__hpux)
+#elif defined(__hpux)
# define KWSYS_SHARED_FORWARD_LDD "chatr"
# define KWSYS_SHARED_FORWARD_LDD_N 1
# if defined(__LP64__)
@@ -238,10 +233,9 @@ static const char kwsys_shared_forward_path_slash[2] = {KWSYS_SHARED_FORWARD_PAT
# else
# define KWSYS_SHARED_FORWARD_LDPATH "SHLIB_PATH"
# endif
-#endif
/* SGI MIPS */
-#if defined(__sgi) && defined(_MIPS_SIM)
+#elif defined(__sgi) && defined(_MIPS_SIM)
# define KWSYS_SHARED_FORWARD_LDD "ldd"
# define KWSYS_SHARED_FORWARD_LDD_N 1
# if _MIPS_SIM == _ABIO32
@@ -251,19 +245,17 @@ static const char kwsys_shared_forward_path_slash[2] = {KWSYS_SHARED_FORWARD_PAT
# elif _MIPS_SIM == _ABI64
# define KWSYS_SHARED_FORWARD_LDPATH "LD_LIBRARY64_PATH"
# endif
-#endif
/* Windows */
-#if defined(_WIN32)
+#elif defined(_WIN32)
# if defined(__CYGWIN__)
# define KWSYS_SHARED_FORWARD_LDD "cygcheck"
# define KWSYS_SHARED_FORWARD_LDD_N 1
# endif
# define KWSYS_SHARED_FORWARD_LDPATH "PATH"
-#endif
/* Guess on this unknown system. */
-#if !defined(KWSYS_SHARED_FORWARD_LDPATH)
+#else
# define KWSYS_SHARED_FORWARD_LDD "ldd"
# define KWSYS_SHARED_FORWARD_LDD_N 1
# define KWSYS_SHARED_FORWARD_LDPATH "LD_LIBRARY_PATH"