|
From: Tapio V. <aa...@us...> - 2010-08-03 11:37:24
|
Module: performous
Branch: joinmenu
Commit: d25e84aab8d0ef95cba85d0931e7f00d7a736fad
Author: Tapio Vierros <tap...@gm...>
Date: Tue Jul 27 23:08:38 2010 +0300
Attempt to work around porttime problems.
---
cmake/Modules/FindPortMidi.cmake | 8 +++++++-
1 files changed, 7 insertions(+), 1 deletions(-)
diff --git a/cmake/Modules/FindPortMidi.cmake b/cmake/Modules/FindPortMidi.cmake
index f5126d8..e3774ad 100644
--- a/cmake/Modules/FindPortMidi.cmake
+++ b/cmake/Modules/FindPortMidi.cmake
@@ -16,6 +16,12 @@ find_library(PortMidi_LIBRARY NAMES portmidi)
find_library(PortTime_LIBRARY NAMES porttime)
set(PortMidi_PROCESS_INCLUDES PortMidi_INCLUDE_DIR)
-set(PortMidi_PROCESS_LIBS PortMidi_LIBRARY PortTime_LIBRARY)
+set(PortMidi_PROCESS_LIBS PortMidi_LIBRARY)
+# Porttime library is merged to Portmidi in new versions, so
+# we work around problems by adding it only if it's present
+if (${PortTime_LIBRARY})
+ set(PortMidi_PROCESS_LIBS PortMidi_PROCESS_LIBS PortTime_LIBRARY)
+endif (${PortTime_LIBRARY})
+
libfind_process(PortMidi)
|