[cmake-developers] [PATCH] Bug fix: Dylibs inside .framework folders fails in BundleUtilities.cmake.
Christian Askeland
christian.askeland at gmail.com
Thu Feb 4 13:34:46 EST 2016
The specific cause is when e.g.
/Library/Frameworks/GStreamer.framework/Versions/1.0/lib/libgio-2.0.0.dylib
is detected by fixup_bundle. BundleUtilities.cmake/set_bundle_key_values()
interprets this as a framework, thus doing a string replace that creates an
embedded_item that is equal to the original path, i.e. it is not embedded.
The fix is to rely on the correct framework detection in
GetPrerequisite.cmake/gp_item_default_embedded_path() instead.
---
Modules/BundleUtilities.cmake | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/Modules/BundleUtilities.cmake b/Modules/BundleUtilities.cmake
index 45dda40..0a92251 100644
--- a/Modules/BundleUtilities.cmake
+++ b/Modules/BundleUtilities.cmake
@@ -479,7 +479,8 @@ function(set_bundle_key_values keys_var context item
exepath dirs copyflag)
get_item_rpaths("${resolved_item}" item_rpaths)
- if(item MATCHES "[^/]+\\.framework/")
+ # Use default_embedded_path from gp_item_default_embedded_path() to
query whether the item is a framework
+ if(default_embedded_path MATCHES "/Frameworks")
# For frameworks, construct the name under the embedded path from the
# opening "${item_name}.framework/" to the closing "/${item_name}":
#
--
2.5.4 (Apple Git-61)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/cmake-developers/attachments/20160204/08cc748d/attachment.html>
More information about the cmake-developers
mailing list