From 673172e3ffb8e345b2bbfb6596ac3d79a1e17f14 Mon Sep 17 00:00:00 2001 From: Orcan Ogetbil Date: Mon, 20 Dec 2010 04:54:36 +0000 Subject: Major cmake cleanup. Please see the ChangeLog. --- muse2/synti/CMakeLists.txt | 12 +++-- muse2/synti/deicsonze/CMakeLists.txt | 83 ++++++++++++++++++++++++--------- muse2/synti/deicsonze/deicsonze.cpp | 9 +--- muse2/synti/deicsonze/deicsonzegui.cpp | 9 +--- muse2/synti/fluid/CMakeLists.txt | 65 +++++++++++++++++++------- muse2/synti/fluidsynth/CMakeLists.txt | 80 ++++++++++++++++++++++--------- muse2/synti/libsynti/CMakeLists.txt | 36 ++++++++++---- muse2/synti/organ/CMakeLists.txt | 53 ++++++++++++++++----- muse2/synti/s1/CMakeLists.txt | 44 +++++++++++++---- muse2/synti/simpledrums2/CMakeLists.txt | 65 ++++++++++++++++++++------ muse2/synti/vam/CMakeLists.txt | 62 ++++++++++++++++++------ 11 files changed, 381 insertions(+), 137 deletions(-) (limited to 'muse2/synti') diff --git a/muse2/synti/CMakeLists.txt b/muse2/synti/CMakeLists.txt index d4e558d5..73e6d349 100644 --- a/muse2/synti/CMakeLists.txt +++ b/muse2/synti/CMakeLists.txt @@ -27,9 +27,15 @@ include_directories( ${PROJECT_SOURCE_DIR}/synti ) -# set (SubDirs libsynti organ deicsonze deicsonze2 simpledrums vam) -# set (SubDirs libsynti organ deicsonze simpledrums vam) -set (SubDirs libsynti organ deicsonze simpledrums2 vam) +set (SubDirs + deicsonze + # deicsonze2 + libsynti + organ + # simpledrums + simpledrums2 + vam + ) if (ENABLE_EXPERIMENTAL) set (SubDirs ${SubDirs} s1 ) diff --git a/muse2/synti/deicsonze/CMakeLists.txt b/muse2/synti/deicsonze/CMakeLists.txt index 05546081..c311b05a 100644 --- a/muse2/synti/deicsonze/CMakeLists.txt +++ b/muse2/synti/deicsonze/CMakeLists.txt @@ -18,54 +18,91 @@ # Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. #============================================================================= -include(${PROJECT_SOURCE_DIR}/pch.txt) - -QT4_WRAP_CPP ( deicsonze_mocs deicsonzegui.h ) +## +## Expand Qt macros in source files +## +QT4_WRAP_CPP ( deicsonze_mocs + deicsonzegui.h + ) -file (GLOB UI_FILES deicsonzegui.ui ) -QT4_WRAP_UI ( deicsonze_uis ${UI_FILES} ) +## +## UI files +## +file (GLOB deicsonze_ui_files + deicsonzegui.ui + ) +QT4_WRAP_UI ( deicsonze_uis ${deicsonze_ui_files} ) +## +## Resource files +## QT4_ADD_RESOURCES (deicsonze_qrc_files - deicsonze.qrc - ) + deicsonze.qrc + ) -file (GLOB SOURCE_FILES +## +## List of source files to compile +## +file (GLOB deicsonze_source_files deicsonze.cpp deicsonzepreset.cpp deicsonzeplugin.cpp deicsonzefilter.cpp deicsonzegui.cpp - deicsonzegui.h ) +## +## Define target +## add_library ( deicsonze SHARED - ${SOURCE_FILES} - ${PROJECT_BINARY_DIR}/all.h - ${PROJECT_BINARY_DIR}/all-pic.h.pch + ${deicsonze_source_files} ${deicsonze_mocs} ${deicsonze_uis} ${deicsonze_qrc_files} ) -set (FILES_TO_TRANSLATE ${FILES_TO_TRANSLATE} ${SOURCE_FILES} ${UI_FILES} CACHE INTERNAL "") - -target_link_libraries( deicsonze synti ) +## +## Append to the list of translations +## +set (FILES_TO_TRANSLATE + ${FILES_TO_TRANSLATE} + ${deicsonze_source_files} + ${deicsonze_ui_files} + CACHE INTERNAL "" + ) +## +## Compilation flags and target name +## # - tell cmake to name target deicsonze.so instead of # libdeicsonze.so # - use precompiled header files # set_target_properties ( deicsonze - PROPERTIES PREFIX "" - #COMPILE_FLAGS "-O2 -include ${PROJECT_BINARY_DIR}/all-pic.h" - COMPILE_FLAGS "-fvisibility=hidden -include ${PROJECT_BINARY_DIR}/all-pic.h" - ) + PROPERTIES PREFIX "" + #COMPILE_FLAGS "-O2 -include ${PROJECT_BINARY_DIR}/all-pic.h" + COMPILE_FLAGS "-fvisibility=hidden -include ${PROJECT_BINARY_DIR}/all-pic.h" + ) +## +## Linkage +## target_link_libraries(deicsonze - al awl synti + al + awl + synti ${QT_LIBRARIES} ) -install_targets ( /${CMAKE_INSTALL_LIBDIR}/${MusE_INSTALL_NAME}/synthi/ deicsonze ) - -install_files ( /share/${MusE_INSTALL_NAME}/presets/deicsonze SutulaBank.dei ) +## +## Install location +## +install( TARGETS deicsonze + DESTINATION ${MusE_SYNTHI_DIR} + ) +install( FILES SutulaBank.dei + DESTINATION ${MusE_SHARE_DIR}/presets/deicsonze + ) +install( FILES README TODO + DESTINATION ${MusE_DOC_DIR}/deicsonze + ) diff --git a/muse2/synti/deicsonze/deicsonze.cpp b/muse2/synti/deicsonze/deicsonze.cpp index 6d86eda9..049daeed 100644 --- a/muse2/synti/deicsonze/deicsonze.cpp +++ b/muse2/synti/deicsonze/deicsonze.cpp @@ -121,13 +121,7 @@ DeicsOnze::DeicsOnze() : Mess(2) { _saveConfig = true; _isInitSet = true; //false if an initial bank must be download - ///_initSetPath = INSTPREFIX "/share/muse-" VERSION "/presets/deicsonze/SutulaBank.dei"; - //"/usr/local/share/muse-1.0pre1/presets/deicsonze/SutulaBank.dei"; - - // Tim. - QString sharePath(QString(INSTPREFIX) + QString("/") + - QString(SHAREINSTPREFIX) + QString("/") + // This has no prefix. Default is "share", set in top cmake script. - QString(INSTALL_NAME)); + QString sharePath(SHAREDIR); _initSetPath = sharePath + QString("/presets/deicsonze/SutulaBank.dei"); @@ -135,7 +129,6 @@ DeicsOnze::DeicsOnze() : Mess(2) { //INSTPREFIX + "/share/" + PACKAGEVERSION + "/presets/deicsonze/ARCH_ALIN"; _isBackgroundPix = true; //false if an initial bank must be download - ///_backgroundPixPath = INSTPREFIX "/share/muse-" VERSION "/wallpapers/paper2.jpg"; //"/usr/local/share/muse-1.0pre1/wallpapers/abstractdeicsonze1.jpg"; _backgroundPixPath = sharePath + QString("/wallpapers/paper2.jpg"); // Tim. diff --git a/muse2/synti/deicsonze/deicsonzegui.cpp b/muse2/synti/deicsonze/deicsonzegui.cpp index 8f9fafd0..84cf4d22 100644 --- a/muse2/synti/deicsonze/deicsonzegui.cpp +++ b/muse2/synti/deicsonze/deicsonzegui.cpp @@ -440,18 +440,11 @@ DeicsOnzeGui::DeicsOnzeGui(DeicsOnze* deicsOnze) setEnabledPreset(false); // Tim. - QString sharePath(QString(INSTPREFIX) + QString("/") + - QString(SHAREINSTPREFIX) + QString("/") + // This has no prefix. Default is "share", set in top cmake script. - QString(INSTALL_NAME)); - + QString sharePath(SHAREDIR); updateInitSetPath - ///(INSTPREFIX "/share/muse-" VERSION "/presets/deicsonze/SutulaBank.dei"); (sharePath + QString("/presets/deicsonze/SutulaBank.dei")); // Tim. - //"/usr/local/share/muse-1.0pre1/presets/deicsonze/SutulaBank.dei") - //); updateBackgroundPixPath - ///(INSTPREFIX "/share/muse-" VERSION "/wallpapers/paper2.jpg"); (sharePath + QString("/wallpapers/paper2.jpg")); // Tim. updateBackgroundPixCheckBox(true); diff --git a/muse2/synti/fluid/CMakeLists.txt b/muse2/synti/fluid/CMakeLists.txt index 6a99c3f0..1367436a 100644 --- a/muse2/synti/fluid/CMakeLists.txt +++ b/muse2/synti/fluid/CMakeLists.txt @@ -18,45 +18,78 @@ # Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. #============================================================================= -QT4_WRAP_CPP ( fluid_mocs fluidgui.h ) +## +## Expand Qt macros in source files +## +QT4_WRAP_CPP ( fluid_mocs + fluidgui.h + ) -file (GLOB UI_FILES fluidguibase.ui ) -QT4_WRAP_UI ( fluid_uis ${UI_FILES} ) +## +## UI files +## +file (GLOB fluid_ui_files + fluidguibase.ui + ) +QT4_WRAP_UI ( fluid_uis ${fluid_ui_files} ) -file (GLOB SOURCE_FILES +## +## List of source files to compile +## +file (GLOB fluid_source_files fluid.cpp fluidgui.cpp - fluidgui.h ) +## +## Define target +## add_library ( fluid SHARED - ${SOURCE_FILES} + ${fluid_source_files} ${fluid_mocs} ${fluid_uis} ) -set (FILES_TO_TRANSLATE ${FILES_TO_TRANSLATE} ${SOURCE_FILES} ${UI_FILES} CACHE INTERNAL "") - -# target_link_libraries( fluid synti ) +## +## Append to the list of translations +## +set (FILES_TO_TRANSLATE + ${FILES_TO_TRANSLATE} + ${fluid_source_files} + ${fluid_ui_files} + CACHE INTERNAL "" + ) +## +## Compilation flags and target name +## # - tell cmake to name target fluid.so instead of # libfluid.so # - use precompiled header files # set_target_properties ( fluid - PROPERTIES PREFIX "" - COMPILE_FLAGS "-fvisibility=hidden -include ${PROJECT_BINARY_DIR}/all-pic.h" - LINK_FLAGS "${FLUIDSYN_LDFLAGS}" # "-lfluidsynth" - ) + PROPERTIES PREFIX "" + COMPILE_FLAGS "-fvisibility=hidden -include ${PROJECT_BINARY_DIR}/all-pic.h" + LINK_FLAGS "${FLUIDSYN_LDFLAGS}" # "-lfluidsynth" + ) + +## +## Linkage +## target_link_libraries(fluid synti ${QT_LIBRARIES} - # Can't do this. FLUIDSYN_LIBRARIES = fluidsynth, which is the name of our fluidsynth.so shared synthesizer library. + # Can't do this. FLUIDSYN_LIBRARIES = fluidsynth, which is the name + # of our fluidsynth.so shared synthesizer library. # This caused ../fluidsynth/fluidsynth.so to appear in the link line. # ${FLUIDSYN_LIBRARIES} # Try giving full path: Nope, path is empty! # ${FLUIDSYN_LIBRARY_DIRS}/${FLUIDSYN_LIBRARIES} ) -install_targets ( /${CMAKE_INSTALL_LIBDIR}/${MusE_INSTALL_NAME}/synthi/ fluid ) - +## +## Install location +## +install( TARGETS fluid + DESTINATION ${MusE_SYNTHI_DIR} + ) diff --git a/muse2/synti/fluidsynth/CMakeLists.txt b/muse2/synti/fluidsynth/CMakeLists.txt index 41aef6a9..930d12d5 100644 --- a/muse2/synti/fluidsynth/CMakeLists.txt +++ b/muse2/synti/fluidsynth/CMakeLists.txt @@ -18,55 +18,89 @@ # Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. #============================================================================= -QT4_WRAP_CPP ( fluidsynth_mocs fluidsynthgui.h ) +## +## Expand Qt macros in source files +## +QT4_WRAP_CPP ( fluidsynth_mocs + fluidsynthgui.h + ) -file (GLOB UI_FILES fluidsynthguibase.ui ) -QT4_WRAP_UI ( fluidsynth_uis ${UI_FILES} ) +## +## UI files +## +file (GLOB fluidsynth_ui_files + fluidsynthguibase.ui + ) +QT4_WRAP_UI ( fluidsynth_uis ${fluidsynth_ui_files} ) +## +## Resource files +## QT4_ADD_RESOURCES (fluidsynth_qrc_files - fluidsynth.qrc - ) + fluidsynth.qrc + ) -file (GLOB SOURCE_FILES +## +## List of source files to compile +## +file (GLOB fluidsynth_source_files fluidsynti.cpp fluidsynthgui.cpp - fluidsynthgui.h ) +## +## Define target +## add_library ( fluidsynth SHARED - ${SOURCE_FILES} + ${fluidsynth_source_files} ${fluidsynth_mocs} ${fluidsynth_uis} ${fluidsynth_qrc_files} ) -set (FILES_TO_TRANSLATE ${FILES_TO_TRANSLATE} ${SOURCE_FILES} ${UI_FILES} CACHE INTERNAL "") - -# target_link_libraries( fluidsynth synti ) +## +## Append to the list of translations +## +set (FILES_TO_TRANSLATE + ${FILES_TO_TRANSLATE} + ${fluidsynth_source_files} + ${fluidsynth_ui_files} + CACHE INTERNAL "" + ) +## +## Compilation flags and target name +## # - tell cmake to name target fluidsynth.so instead of # libfluidsynth.so # - use precompiled header files # set_target_properties ( fluidsynth - PROPERTIES PREFIX "" - COMPILE_FLAGS "-fvisibility=hidden -include ${PROJECT_BINARY_DIR}/all-pic.h" - LINK_FLAGS "${FLUIDSYN_LDFLAGS}" # "-lfluidsynth" - ) + PROPERTIES PREFIX "" + COMPILE_FLAGS "-fvisibility=hidden -include ${PROJECT_BINARY_DIR}/all-pic.h" + LINK_FLAGS "${FLUIDSYN_LDFLAGS}" # "-lfluidsynth" + ) + +## +## Linkage +## target_link_libraries(fluidsynth synti ${QT_LIBRARIES} - # Can't do this here, since FLUIDSYN_LIBRARIES evaluates to 'fluidsynth', the same name as our target. + # Can't do this here, since FLUIDSYN_LIBRARIES evaluates + # to 'fluidsynth', the same name as our target. # ${FLUIDSYN_LIBRARIES} # Try giving full path: Nope, path is empty! #${FLUIDSYN_LIBRARY_DIRS}/${FLUIDSYN_LIBRARIES} ) -install_targets ( /${CMAKE_INSTALL_LIBDIR}/${MusE_INSTALL_NAME}/synthi/ fluidsynth ) - -# FIXME: Won't work -# install_files ( /${MusE_INSTALL_NAME}/synthi TODO README.txt ) - -install_files ( /${SHARE_INSTALL_PREFIX}/${MusE_INSTALL_NAME}/synthi/fluidsynth TODO ) -install_files ( /${SHARE_INSTALL_PREFIX}/${MusE_INSTALL_NAME}/synthi/fluidsynth README.txt ) +## +## Install location +## +install( TARGETS fluidsynth + DESTINATION ${MusE_SYNTHI_DIR} + ) +install( FILES README.txt TODO + DESTINATION ${MusE_DOC_DIR}/fluidsynth/ + ) diff --git a/muse2/synti/libsynti/CMakeLists.txt b/muse2/synti/libsynti/CMakeLists.txt index 0b257249..8b7a662b 100644 --- a/muse2/synti/libsynti/CMakeLists.txt +++ b/muse2/synti/libsynti/CMakeLists.txt @@ -20,7 +20,10 @@ include(${PROJECT_SOURCE_DIR}/pch.txt) -file (GLOB SOURCE_FILES +## +## List of source files to compile +## +file (GLOB synti_source_files mess.cpp # mess2.cpp gui.cpp @@ -31,20 +34,37 @@ file (GLOB SOURCE_FILES ## mpevent.cpp ) +## +## Define target +## add_library(synti SHARED ${PROJECT_BINARY_DIR}/all-pic.h.pch - ${SOURCE_FILES} + ${synti_source_files} ) -set (FILES_TO_TRANSLATE ${FILES_TO_TRANSLATE} ${SOURCE_FILES} CACHE INTERNAL "") - -install(TARGETS synti DESTINATION ${MUSE_MODULES_DIR}) +## +## Append to the list of translations +## +set (FILES_TO_TRANSLATE + ${FILES_TO_TRANSLATE} + ${synti_source_files} + CACHE INTERNAL "" + ) +## +## Compilation flags and target name +## # # -fPIC is necessary for 64 bit systems # set_target_properties( synti - PROPERTIES COMPILE_FLAGS "-fPIC -include ${PROJECT_BINARY_DIR}/all-pic.h" - OUTPUT_NAME muse_synti - ) + PROPERTIES COMPILE_FLAGS "-fPIC -include ${PROJECT_BINARY_DIR}/all-pic.h" + OUTPUT_NAME muse_synti + ) +## +## Install location +## +install(TARGETS synti + DESTINATION ${MusE_MODULES_DIR} + ) diff --git a/muse2/synti/organ/CMakeLists.txt b/muse2/synti/organ/CMakeLists.txt index 92ffebee..0d8dda90 100644 --- a/muse2/synti/organ/CMakeLists.txt +++ b/muse2/synti/organ/CMakeLists.txt @@ -18,42 +18,73 @@ # Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. #============================================================================= -QT4_WRAP_CPP ( organ_mocs organgui.h ) +## +## Expand Qt macros in source files +## +QT4_WRAP_CPP ( organ_mocs + organgui.h + ) -file (GLOB UI_FILES organguibase.ui ) -QT4_WRAP_UI ( organ_uis ${UI_FILES} ) +## +## UI files +## +file (GLOB organ_ui_files + organguibase.ui + ) +QT4_WRAP_UI ( organ_uis ${organ_ui_files} ) -file (GLOB SOURCE_FILES +## +## List of source files to compile +## +file (GLOB organ_source_files organ.cpp organgui.cpp # reverb.cpp # routing.cpp - # organgui.h ) +## +## Define target +## add_library ( organ SHARED ${PROJECT_SOURCE_DIR}/muse/xml.cpp - ${SOURCE_FILES} + ${organ_source_files} ${organ_mocs} ${organ_uis} ) -set (FILES_TO_TRANSLATE ${FILES_TO_TRANSLATE} ${SOURCE_FILES} ${UI_FILES} CACHE INTERNAL "") +## +## Append to the list of translations +## +set (FILES_TO_TRANSLATE + ${FILES_TO_TRANSLATE} + ${organ_source_files} + ${organ_ui_files} + CACHE INTERNAL "" + ) # - tell cmake to name target organ.so instead of # liborgan.so # - use precompiled header files # set_target_properties ( organ - PROPERTIES PREFIX "" - COMPILE_FLAGS "-fvisibility=hidden -O2 -include ${PROJECT_BINARY_DIR}/all-pic.h" - ) + PROPERTIES PREFIX "" + COMPILE_FLAGS "-fvisibility=hidden -O2 -include ${PROJECT_BINARY_DIR}/all-pic.h" + ) +## +## Linkage +## target_link_libraries(organ synti # awl ${QT_LIBRARIES} ) -install_targets ( /${CMAKE_INSTALL_LIBDIR}/${MusE_INSTALL_NAME}/synthi/ organ ) +## +## Install location +## +install( TARGETS organ + DESTINATION ${MusE_SYNTHI_DIR} + ) diff --git a/muse2/synti/s1/CMakeLists.txt b/muse2/synti/s1/CMakeLists.txt index c1e74c03..93c62961 100644 --- a/muse2/synti/s1/CMakeLists.txt +++ b/muse2/synti/s1/CMakeLists.txt @@ -18,23 +18,51 @@ # Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. #============================================================================= -file (GLOB SOURCE_FILES s1.cpp ) -add_library ( s1 SHARED ${SOURCE_FILES} ) +## +## List of source files to compile +## +file (GLOB s1_source_files + s1.cpp + ) -set (FILES_TO_TRANSLATE ${FILES_TO_TRANSLATE} ${SOURCE_FILES} CACHE INTERNAL "") +## +## Define target +## +add_library ( s1 SHARED + ${s1_source_files} + ) -# target_link_libraries( s1 synti ) +## +## Append to the list of translations +## +set (FILES_TO_TRANSLATE + ${FILES_TO_TRANSLATE} + ${s1_source_files} + CACHE INTERNAL "" + ) +## +## Compilation flags and target name +## # tell cmake to name target s1.so instead of # libs1.so # set_target_properties ( s1 - PROPERTIES PREFIX "" - COMPILE_FLAGS "-fvisibility=hidden" - ) + PROPERTIES PREFIX "" + COMPILE_FLAGS "-fvisibility=hidden" + ) +## +## Linkage +## target_link_libraries(s1 synti ) -install_targets ( /${CMAKE_INSTALL_LIBDIR}/${MusE_INSTALL_NAME}/synthi/ s1 ) + +## +## Install location +## +install( TARGETS s1 + DESTINATION ${MusE_SYNTHI_DIR} + ) diff --git a/muse2/synti/simpledrums2/CMakeLists.txt b/muse2/synti/simpledrums2/CMakeLists.txt index 26d6b096..41fb8da5 100644 --- a/muse2/synti/simpledrums2/CMakeLists.txt +++ b/muse2/synti/simpledrums2/CMakeLists.txt @@ -18,43 +18,78 @@ # Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. #============================================================================= -QT4_WRAP_CPP ( simpledrums_mocs simpledrumsgui.h ssplugingui.h ) +## +## Expand Qt macros in source files +## +QT4_WRAP_CPP ( simpledrums_mocs + simpledrumsgui.h + ssplugingui.h + ) -file (GLOB UI_FILES simpledrumsguibase.ui sspluginchooserbase.ui ) -QT4_WRAP_UI ( simpledrums_uis ${UI_FILES} ) +## +## UI files +## +file (GLOB simpledrums_ui_files + simpledrumsguibase.ui + sspluginchooserbase.ui + ) +QT4_WRAP_UI ( simpledrums_uis ${simpledrums_ui_files} ) -file (GLOB SOURCE_FILES +## +## List of source files to compile +## +file (GLOB simpledrums_source_files simpledrums.cpp simpledrumsgui.cpp - simpledrums.h ssplugin.cpp ssplugingui.cpp - ssplugin.h - common.h ) +## +## Define target +## add_library ( simpledrums SHARED - ${SOURCE_FILES} + ${simpledrums_source_files} ${simpledrums_mocs} ${simpledrums_uis} ) -set (FILES_TO_TRANSLATE ${FILES_TO_TRANSLATE} ${SOURCE_FILES} ${UI_FILES} CACHE INTERNAL "") +## +## Append to the list of translations +## +set (FILES_TO_TRANSLATE + ${FILES_TO_TRANSLATE} + ${simpledrums_source_files} + ${simpledrums_ui_files} + CACHE INTERNAL "" + ) +## +## Compilation flags and target name +## # - tell cmake to name target simpledrums.so instead of # libsimpledrums.so # - use precompiled header files # set_target_properties ( simpledrums - PROPERTIES PREFIX "" - COMPILE_FLAGS "-O6 -fvisibility=hidden -include ${PROJECT_BINARY_DIR}/all-pic.h" - ) + PROPERTIES PREFIX "" + COMPILE_FLAGS "-O6 -fvisibility=hidden -include ${PROJECT_BINARY_DIR}/all-pic.h" + ) +## +## Linkage +## target_link_libraries(simpledrums synti -# awl ${QT_LIBRARIES} ) -install_targets ( /${CMAKE_INSTALL_LIBDIR}/${MusE_INSTALL_NAME}/synthi/ simpledrums ) - +## +## Install location +## +install( TARGETS simpledrums + DESTINATION ${MusE_SYNTHI_DIR} + ) +install( FILES COPYING README ReleaseNotes.txt + DESTINATION ${MusE_DOC_DIR}/simpledrums + ) diff --git a/muse2/synti/vam/CMakeLists.txt b/muse2/synti/vam/CMakeLists.txt index d63e4144..31f2a12a 100644 --- a/muse2/synti/vam/CMakeLists.txt +++ b/muse2/synti/vam/CMakeLists.txt @@ -18,41 +18,75 @@ # Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. #============================================================================= -QT4_WRAP_CPP ( vam_mocs vamgui.h ) +## +## Expand Qt macros in source files +## +QT4_WRAP_CPP ( vam_mocs + vamgui.h + ) -file (GLOB UI_FILES vamguibase.ui ) -QT4_WRAP_UI ( vam_uis ${UI_FILES} ) +## +## UI files +## +file (GLOB vam_ui_files + vamguibase.ui + ) +QT4_WRAP_UI ( vam_uis ${vam_ui_files} ) -file (GLOB SOURCE_FILES +## +## List of source files to compile +## +file (GLOB vam_source_files vam.cpp vamgui.cpp - vamgui.h ) +## +## Define target +## add_library ( vam SHARED - ${SOURCE_FILES} + ${vam_source_files} ${vam_mocs} ${vam_uis} ) -set (FILES_TO_TRANSLATE ${FILES_TO_TRANSLATE} ${SOURCE_FILES} ${UI_FILES} CACHE INTERNAL "") - -# target_link_libraries( vam synti ) +## +## Append to the list of translations +## +set (FILES_TO_TRANSLATE + ${FILES_TO_TRANSLATE} + ${vam_source_files} + ${vam_ui_files} + CACHE INTERNAL "" + ) +## +## Compilation flags and target name +## # - tell cmake to name target vam.so instead of # libvam.so # - use precompiled header files # set_target_properties ( vam - PROPERTIES PREFIX "" - COMPILE_FLAGS "-fvisibility=hidden -include ${PROJECT_BINARY_DIR}/all-pic.h" - ) + PROPERTIES PREFIX "" + COMPILE_FLAGS "-fvisibility=hidden -include ${PROJECT_BINARY_DIR}/all-pic.h" + ) +## +## Linkage +## target_link_libraries(vam # al synti ${QT_LIBRARIES} ) -install_targets ( /${CMAKE_INSTALL_LIBDIR}/${MusE_INSTALL_NAME}/synthi/ vam ) - +## +## Install location +## +install( TARGETS vam + DESTINATION ${MusE_SYNTHI_DIR} + ) +install( FILES ChangeLog COPYING README TODO + DESTINATION ${MusE_DOC_DIR}/vam + ) -- cgit v1.2.3