From cb858a0eec5490690b1a25222930a752965f24a8 Mon Sep 17 00:00:00 2001 From: Matthias Hochsteger Date: Thu, 14 Sep 2017 12:32:14 +0200 Subject: [PATCH 1/2] Build tkdnd on MacOS --- cmake/external_projects/tcltk.cmake | 20 +++++++++++++++++++ .../tkdnd_macosx.patch | 0 2 files changed, 20 insertions(+) rename cmake/{ => external_projects}/tkdnd_macosx.patch (100%) diff --git a/cmake/external_projects/tcltk.cmake b/cmake/external_projects/tcltk.cmake index 7a939539..fda9becb 100644 --- a/cmake/external_projects/tcltk.cmake +++ b/cmake/external_projects/tcltk.cmake @@ -53,6 +53,26 @@ if(APPLE) # set(TK_LIBRARY ${CMAKE_INSTALL_PREFIX}/../Frameworks/Tk.framework) # set(TK_INCLUDE_PATH ${CMAKE_INSTALL_PREFIX}/../Frameworks/Tk.framework/Headers) # + + + +ExternalProject_Add(project_tkdnd + URL "http://sourceforge.net/projects/tkdnd/files/TkDND/TkDND%202.8/tkdnd2.8-src.tar.gz" + URL_MD5 a6d47a996ea957416469b12965d4db91 + DOWNLOAD_DIR ${CMAKE_CURRENT_SOURCE_DIR}/external_dependencies + PATCH_COMMAND patch -p1 < ${CMAKE_CURRENT_LIST_DIR}/tkdnd_macosx.patch + UPDATE_COMMAND "" # Disable update + BUILD_IN_SOURCE 1 + CONFIGURE_COMMAND ./configure --prefix=${CMAKE_INSTALL_PREFIX}/../MacOS --libdir=${CMAKE_INSTALL_PREFIX}/../MacOS + BUILD_COMMAND make + INSTALL_COMMAND make install + LOG_DOWNLOAD 1 + LOG_CONFIGURE 1 + LOG_BUILD 1 + LOG_INSTALL 1 +) +list(APPEND NETGEN_DEPENDENCIES project_tkdnd) + elseif(WIN32) ExternalProject_Add(project_win_extlibs diff --git a/cmake/tkdnd_macosx.patch b/cmake/external_projects/tkdnd_macosx.patch similarity index 100% rename from cmake/tkdnd_macosx.patch rename to cmake/external_projects/tkdnd_macosx.patch From 385ea4b06d6561bc02233bd2ff3350181aa7e060 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Joachim=20Sch=C3=B6berl?= Date: Thu, 14 Sep 2017 14:04:29 +0200 Subject: [PATCH 2/2] fix path for installing tkdnd on MacOS --- cmake/external_projects/tcltk.cmake | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmake/external_projects/tcltk.cmake b/cmake/external_projects/tcltk.cmake index fda9becb..4f173787 100644 --- a/cmake/external_projects/tcltk.cmake +++ b/cmake/external_projects/tcltk.cmake @@ -63,7 +63,7 @@ ExternalProject_Add(project_tkdnd PATCH_COMMAND patch -p1 < ${CMAKE_CURRENT_LIST_DIR}/tkdnd_macosx.patch UPDATE_COMMAND "" # Disable update BUILD_IN_SOURCE 1 - CONFIGURE_COMMAND ./configure --prefix=${CMAKE_INSTALL_PREFIX}/../MacOS --libdir=${CMAKE_INSTALL_PREFIX}/../MacOS + CONFIGURE_COMMAND ./configure --prefix=${CMAKE_INSTALL_PREFIX}/Contents/MacOS --libdir=${CMAKE_INSTALL_PREFIX}/Contents/MacOS BUILD_COMMAND make INSTALL_COMMAND make install LOG_DOWNLOAD 1