Browse Source

CMake: Properly link against the proper frameworks on OS X.

Sam Edwards 11 years ago
parent
commit
0bcce442c3
1 changed files with 6 additions and 0 deletions
  1. 6 0
      dtool/src/dtoolutil/CMakeLists.txt

+ 6 - 0
dtool/src/dtoolutil/CMakeLists.txt

@@ -56,4 +56,10 @@ if(HAVE_PYTHON)
   target_link_libraries(p3dtoolutil ${PYTHON_LIBRARIES})
 endif()
 
+if(APPLE)
+  find_library(FOUNDATION_LIBRARY Foundation)
+  find_library(APPKIT_LIBRARY AppKit)
+  target_link_libraries(p3dtoolutil ${FOUNDATION_LIBRARY} ${APPKIT_LIBRARY})
+endif()
+
 install(TARGETS p3dtoolutil DESTINATION lib)