summaryrefslogtreecommitdiffstats
path: root/Source/cmTarget.h
diff options
context:
space:
mode:
authorClinton Stimpson <clinton@elemtech.com>2013-04-27 04:04:44 (GMT)
committerBrad King <brad.king@kitware.com>2013-06-03 13:42:05 (GMT)
commit94e7fef2268ba9d31bd31834f05f6d0c2ffe5a18 (patch)
tree4676709c61c7f1d8352f5e9729bb875cb2816e34 /Source/cmTarget.h
parentcbe3f2072bdd181660bc4f9174a73febd3ed5230 (diff)
downloadCMake-94e7fef2268ba9d31bd31834f05f6d0c2ffe5a18.zip
CMake-94e7fef2268ba9d31bd31834f05f6d0c2ffe5a18.tar.gz
CMake-94e7fef2268ba9d31bd31834f05f6d0c2ffe5a18.tar.bz2
OS X: Add RPATH support for Mac.
RPATH support is activated on targets that have the MACOSX_RPATH property turned on. For install time, it is also useful to set INSTALL_RPATH to help find dependent libraries with an @rpath in their install name. Also adding detection of rpath conflicts when using frameworks.
Diffstat (limited to 'Source/cmTarget.h')
-rw-r--r--Source/cmTarget.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/Source/cmTarget.h b/Source/cmTarget.h
index 4264e76..9d25919 100644
--- a/Source/cmTarget.h
+++ b/Source/cmTarget.h
@@ -362,6 +362,9 @@ public:
/** Get the soname of the target. Allowed only for a shared library. */
std::string GetSOName(const char* config);
+ /** Whether this library has @rpath and platform supports it. */
+ bool HasMacOSXRpath(const char* config);
+
/** Test for special case of a third-party shared library that has
no soname at all. */
bool IsImportedSharedLibWithoutSOName(const char* config);
@@ -407,7 +410,13 @@ public:
/** Return true if builtin chrpath will work for this target */
bool IsChrpathUsed(const char* config);
+ /** Return the install name directory for the target in the
+ * build tree. For example: "@rpath/", "@loader_path/",
+ * or "/full/path/to/library". */
std::string GetInstallNameDirForBuildTree(const char* config);
+
+ /** Return the install name directory for the target in the
+ * install tree. For example: "@rpath/" or "@loader_path/". */
std::string GetInstallNameDirForInstallTree();
cmComputeLinkInformation* GetLinkInformation(const char* config,