diff options
author | Michele Calgaro <[email protected]> | 2024-03-08 12:19:55 +0900 |
---|---|---|
committer | Michele Calgaro <[email protected]> | 2024-03-08 15:35:51 +0900 |
commit | f2a469f1538cbed7cb9b8076eb2d5eee3d7ae358 (patch) | |
tree | ba0ee0fc23834c603de9d6f14e8b6af628eb6f78 | |
parent | 471a729c334818d9d240e7d90ae7070516c801fa (diff) | |
download | rosegarden-f2a469f1538cbed7cb9b8076eb2d5eee3d7ae358.tar.gz rosegarden-f2a469f1538cbed7cb9b8076eb2d5eee3d7ae358.zip |
cmake files: change keywords to lower case
Signed-off-by: Michele Calgaro <[email protected]>
-rw-r--r-- | CMakeLists.txt | 40 | ||||
-rw-r--r-- | ConfigureChecks.cmake | 340 | ||||
-rw-r--r-- | data/CMakeLists.txt | 106 | ||||
-rw-r--r-- | src/CMakeLists.txt | 46 |
4 files changed, 266 insertions, 266 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index ab94939..9d633e8 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -31,21 +31,21 @@ include( FindPkgConfig ) ##### set up versioning ######################### # Mark as advanced -MARK_AS_ADVANCED(EXECUTABLE_OUTPUT_PATH +mark_as_advanced(EXECUTABLE_OUTPUT_PATH LIBRARY_OUTPUT_PATH CMAKE_BACKWARDS_COMPATIBILITY) # Rosegarden version string -SET (VERSION_MAJOR "1") -SET (VERSION_MINOR "7") -SET (VERSION_PATCH "0") +set (VERSION_MAJOR "1") +set (VERSION_MINOR "7") +set (VERSION_PATCH "0") # comment out the next line for a public release -#SET (VERSION_SUFFIX "svn") -SET (PACKAGE_VERSION ${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}) -IF(VERSION_SUFFIX) - SET (PACKAGE_VERSION "${PACKAGE_VERSION}-${VERSION_SUFFIX}") -ENDIF(VERSION_SUFFIX) -ADD_DEFINITIONS(-D'VERSION="${PACKAGE_VERSION}"') +#set (VERSION_SUFFIX "svn") +set (PACKAGE_VERSION ${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}) +if(VERSION_SUFFIX) + set (PACKAGE_VERSION "${PACKAGE_VERSION}-${VERSION_SUFFIX}") +endif(VERSION_SUFFIX) +add_definitions(-D'VERSION="${PACKAGE_VERSION}"') ##### include our cmake modules ################# @@ -78,15 +78,15 @@ option( WANT_LIRC "Include LIRC (Linux Infrared Remote Control) support" OFF option( WANT_PCH "Use precompiled headers" OFF ) option( WANT_TEST "Perform unit tests" OFF ) -IF(WANT_TEST) - ENABLE_TESTING() -ENDIF(WANT_TEST) +if(WANT_TEST) + enable_testing() +endif(WANT_TEST) -IF(NOT WANT_SOUND) - SET(WANT_JACK OFF) - SET(WANT_DSSI OFF) - ADD_DEFINITIONS(-DNO_SOUND) -ENDIF(NOT WANT_SOUND) +if(NOT WANT_SOUND) + set(WANT_JACK OFF) + set(WANT_DSSI OFF) + add_definitions(-DNO_SOUND) +endif(NOT WANT_SOUND) ##### configure checks ########################## @@ -117,5 +117,5 @@ tde_conditional_add_project_translations( BUILD_TRANSLATIONS ) configure_file( config.h.cmake config.h @ONLY ) # create and install the version file -FILE(WRITE "${CMAKE_BINARY_DIR}/version.txt" "${PACKAGE_VERSION}\n") -INSTALL( FILES "${CMAKE_BINARY_DIR}/version.txt" DESTINATION ${DATA_INSTALL_DIR}/rosegarden ) +file(WRITE "${CMAKE_BINARY_DIR}/version.txt" "${PACKAGE_VERSION}\n") +install( FILES "${CMAKE_BINARY_DIR}/version.txt" DESTINATION ${DATA_INSTALL_DIR}/rosegarden ) diff --git a/ConfigureChecks.cmake b/ConfigureChecks.cmake index e364866..a5eb605 100644 --- a/ConfigureChecks.cmake +++ b/ConfigureChecks.cmake @@ -30,93 +30,93 @@ endif( ) # Initialize some variables -SET(HAVE_XFT FALSE) -SET(HAVE_ALSA FALSE) -SET(HAVE_JACK FALSE) -SET(HAVE_DSSI FALSE) -SET(HAVE_LIBLO FALSE) -SET(HAVE_LIBLRDF FALSE) -SET(HAVE_LADSPA FALSE) -SET(HAVE_LIRC FALSE) -SET(HAVE_FFTW3F FALSE) +set(HAVE_XFT FALSE) +set(HAVE_ALSA FALSE) +set(HAVE_JACK FALSE) +set(HAVE_DSSI FALSE) +set(HAVE_LIBLO FALSE) +set(HAVE_LIBLRDF FALSE) +set(HAVE_LADSPA FALSE) +set(HAVE_LIRC FALSE) +set(HAVE_FFTW3F FALSE) # Check for Xft -PKG_CHECK_MODULES(XFT xft>=2.1.0) -IF(XFT_FOUND) - ADD_DEFINITIONS(-DHAVE_XFT) - SET(HAVE_XFT TRUE) - SET(XFT_LIBS ${XFT_LIBRARIES}) - #MESSAGE("XFT_LIBS: ${XFT_LIBS}") - LIST(APPEND XFT_LIB_DIR ${XFT_LIBRARY_DIRS} ${XFT_LIBDIR}) - #MESSAGE("XFT_LIB_DIR: ${XFT_LIB_DIR}") - LIST(APPEND XFT_INC_DIR ${XFT_INCLUDE_DIRS} ${XFT_INCLUDEDIR}) - #MESSAGE("XFT_INC_DIR: ${XFT_INC_DIR}") -ENDIF(XFT_FOUND) - -IF(WANT_SOUND) +pkg_check_modules(XFT xft>=2.1.0) +if(XFT_FOUND) + add_definitions(-DHAVE_XFT) + set(HAVE_XFT TRUE) + set(XFT_LIBS ${XFT_LIBRARIES}) + #message("XFT_LIBS: ${XFT_LIBS}") + list(APPEND XFT_LIB_DIR ${XFT_LIBRARY_DIRS} ${XFT_LIBDIR}) + #message("XFT_LIB_DIR: ${XFT_LIB_DIR}") + list(APPEND XFT_INC_DIR ${XFT_INCLUDE_DIRS} ${XFT_INCLUDEDIR}) + #message("XFT_INC_DIR: ${XFT_INC_DIR}") +endif(XFT_FOUND) + +if(WANT_SOUND) # Check for ALSA 1.0 - PKG_CHECK_MODULES(ALSA REQUIRED alsa>=1.0) - IF(ALSA_FOUND) - SET(HAVE_ALSA TRUE) - ADD_DEFINITIONS(-DHAVE_ALSA) - SET(ALSA_LIBS ${ALSA_LIBRARIES}) - #MESSAGE("ALSA_LIBS: ${ALSA_LIBS}") - LIST(APPEND ALSA_LIB_DIR ${ALSA_LIBRARY_DIRS} ${ALSA_LIBDIR} ) - #MESSAGE("ALSA_LIB_DIR: ${ALSA_LIB_DIR}") - LIST(APPEND ALSA_INC_DIR ${ALSA_INCLUDE_DIRS} ${ALSA_INCLUDEDIR}) - #MESSAGE("ALSA_INC_DIR: ${ALSA_INC_DIR}") - ELSE(ALSA_FOUND) - MESSAGE(FATAL_ERROR "Please install the required package. Aborting") - ENDIF(ALSA_FOUND) - - IF(WANT_JACK) - PKG_CHECK_MODULES(JACK jack>=0.77) - IF(JACK_FOUND) - ADD_DEFINITIONS(-DHAVE_LIBJACK) - SET(HAVE_JACK TRUE) - SET(JACK_LIBS ${JACK_LIBRARIES}) - #MESSAGE("JACK_LIBS: ${JACK_LIBS}") - LIST(APPEND JACK_LIB_DIR ${JACK_LIBDIR} ${JACK_LIBRARY_DIRS}) - #MESSAGE("JACK_LIB_DIR: ${JACK_LIB_DIR}") - LIST(APPEND JACK_INC_DIR ${JACK_INCLUDEDIR} ${JACK_INCLUDE_DIRS}) - #MESSAGE("JACK_INC_DIR: ${JACK_INC_DIR}") - ENDIF(JACK_FOUND) - ENDIF(WANT_JACK) - - IF(WANT_DSSI) - PKG_CHECK_MODULES(DSSI dssi>=0.4) - IF(DSSI_FOUND) - ADD_DEFINITIONS(-DHAVE_DSSI) - SET(HAVE_DSSI TRUE) - LIST(APPEND DSSI_INC_DIR ${DSSI_INCLUDE_DIRS} ${DSSI_INCLUDEDIR}) - #MESSAGE("DSSI_INC_DIR: ${DSSI_INC_DIR}") - ENDIF(DSSI_FOUND) - ENDIF(WANT_DSSI) - - PKG_CHECK_MODULES(LIBLO liblo>=0.7) - IF(LIBLO_FOUND) - ADD_DEFINITIONS(-DHAVE_LIBLO) - SET(HAVE_LIBLO TRUE) - SET(LIBLO_LIBS ${LIBLO_LIBRARIES}) - #MESSAGE("LIBLO_LIBS: ${LIBLO_LIBS}") - LIST(APPEND LIBLO_LIB_DIR ${LIBLO_LIBDIR} ${LIBLO_LIBRARY_DIRS}) - #MESSAGE("LIBLO_LIB_DIR: ${LIBLO_LIB_DIR}") - LIST(APPEND LIBLO_INC_DIR ${LIBLO_INCLUDEDIR} ${LIBLO_INCLUDE_DIRS}) - #MESSAGE("LIBLO_INC_DIR: ${LIBLO_INC_DIR}") - ENDIF(LIBLO_FOUND) - - PKG_CHECK_MODULES(LRDF lrdf>=0.3) - IF(LRDF_FOUND) - SET(HAVE_LIBLRDF TRUE) - ADD_DEFINITIONS(-DHAVE_LIBLRDF) - SET(LRDF_LIBS ${LRDF_LIBRARIES}) - #MESSAGE("LRDF_LIBS: ${LRDF_LIBS}") - LIST(APPEND LRDF_LIB_DIR ${LRDF_LIBDIR} ${LRDF_LIBRARY_DIRS}) - #MESSAGE("LRDF_LIB_DIR: ${LRDF_LIB_DIR}") - LIST(APPEND LRDF_INC_DIR ${LRDF_INCLUDEDIR} ${LRDF_INCLUDE_DIRS}) - #MESSAGE("LRDF_INC_DIR: ${LRDF_INC_DIR}") - ENDIF(LRDF_FOUND) + pkg_check_modules(ALSA REQUIRED alsa>=1.0) + if(ALSA_FOUND) + set(HAVE_ALSA TRUE) + add_definitions(-DHAVE_ALSA) + set(ALSA_LIBS ${ALSA_LIBRARIES}) + #message("ALSA_LIBS: ${ALSA_LIBS}") + list(APPEND ALSA_LIB_DIR ${ALSA_LIBRARY_DIRS} ${ALSA_LIBDIR} ) + #message("ALSA_LIB_DIR: ${ALSA_LIB_DIR}") + list(APPEND ALSA_INC_DIR ${ALSA_INCLUDE_DIRS} ${ALSA_INCLUDEDIR}) + #message("ALSA_INC_DIR: ${ALSA_INC_DIR}") + else(ALSA_FOUND) + message(FATAL_ERROR "Please install the required package. Aborting") + endif(ALSA_FOUND) + + if(WANT_JACK) + pkg_check_modules(JACK jack>=0.77) + if(JACK_FOUND) + add_definitions(-DHAVE_LIBJACK) + set(HAVE_JACK TRUE) + set(JACK_LIBS ${JACK_LIBRARIES}) + #message("JACK_LIBS: ${JACK_LIBS}") + list(APPEND JACK_LIB_DIR ${JACK_LIBDIR} ${JACK_LIBRARY_DIRS}) + #message("JACK_LIB_DIR: ${JACK_LIB_DIR}") + list(APPEND JACK_INC_DIR ${JACK_INCLUDEDIR} ${JACK_INCLUDE_DIRS}) + #message("JACK_INC_DIR: ${JACK_INC_DIR}") + endif(JACK_FOUND) + endif(WANT_JACK) + + if(WANT_DSSI) + pkg_check_modules(DSSI dssi>=0.4) + if(DSSI_FOUND) + add_definitions(-DHAVE_DSSI) + set(HAVE_DSSI TRUE) + list(APPEND DSSI_INC_DIR ${DSSI_INCLUDE_DIRS} ${DSSI_INCLUDEDIR}) + #message("DSSI_INC_DIR: ${DSSI_INC_DIR}") + endif(DSSI_FOUND) + endif(WANT_DSSI) + + pkg_check_modules(LIBLO liblo>=0.7) + if(LIBLO_FOUND) + add_definitions(-DHAVE_LIBLO) + set(HAVE_LIBLO TRUE) + set(LIBLO_LIBS ${LIBLO_LIBRARIES}) + #message("LIBLO_LIBS: ${LIBLO_LIBS}") + list(APPEND LIBLO_LIB_DIR ${LIBLO_LIBDIR} ${LIBLO_LIBRARY_DIRS}) + #message("LIBLO_LIB_DIR: ${LIBLO_LIB_DIR}") + list(APPEND LIBLO_INC_DIR ${LIBLO_INCLUDEDIR} ${LIBLO_INCLUDE_DIRS}) + #message("LIBLO_INC_DIR: ${LIBLO_INC_DIR}") + endif(LIBLO_FOUND) + + pkg_check_modules(LRDF lrdf>=0.3) + if(LRDF_FOUND) + set(HAVE_LIBLRDF TRUE) + add_definitions(-DHAVE_LIBLRDF) + set(LRDF_LIBS ${LRDF_LIBRARIES}) + #message("LRDF_LIBS: ${LRDF_LIBS}") + list(APPEND LRDF_LIB_DIR ${LRDF_LIBDIR} ${LRDF_LIBRARY_DIRS}) + #message("LRDF_LIB_DIR: ${LRDF_LIB_DIR}") + list(APPEND LRDF_INC_DIR ${LRDF_INCLUDEDIR} ${LRDF_INCLUDE_DIRS}) + #message("LRDF_INC_DIR: ${LRDF_INC_DIR}") + endif(LRDF_FOUND) ################################################################## # - Try to find LADSPA header @@ -124,115 +124,115 @@ IF(WANT_SOUND) # # LADSPA_FOUND - system has LADSPA # LADSPA_INCLUDE_DIR - LADSPA header path - IF(LADSPA_INCLUDE_DIR) - SET(LADSPA_FIND_QUIETLY TRUE) - ENDIF(LADSPA_INCLUDE_DIR) - FIND_PATH(LADSPA_INCLUDE_DIR "ladspa.h" + if(LADSPA_INCLUDE_DIR) + set(LADSPA_FIND_QUIETLY TRUE) + endif(LADSPA_INCLUDE_DIR) + find_path(LADSPA_INCLUDE_DIR "ladspa.h" /usr/include /usr/local/include ) - IF(LADSPA_INCLUDE_DIR) - SET(LADSPA_FOUND TRUE) - ELSE(LADSPA_INCLUDE_DIR) - SET(LADSPA_FOUND FALSE) - SET(LADSPA_INCLUDE_DIR "") - ENDIF(LADSPA_INCLUDE_DIR) - IF(LADSPA_FOUND) - IF(NOT LADSPA_FIND_QUIETLY) - MESSAGE(STATUS "Found LADSPA: ${LADSPA_INCLUDE_DIR}") - ENDIF(NOT LADSPA_FIND_QUIETLY) - ELSE(LADSPA_FOUND) - IF(LADSPA_FIND_REQUIRED) - MESSAGE(FATAL_ERROR "Could not find LADSPA") - ENDIF(LADSPA_FIND_REQUIRED) - ENDIF(LADSPA_FOUND) - MARK_AS_ADVANCED(LADSPA_INCLUDE_DIR) + if(LADSPA_INCLUDE_DIR) + set(LADSPA_FOUND TRUE) + else(LADSPA_INCLUDE_DIR) + set(LADSPA_FOUND FALSE) + set(LADSPA_INCLUDE_DIR "") + endif(LADSPA_INCLUDE_DIR) + if(LADSPA_FOUND) + if(NOT LADSPA_FIND_QUIETLY) + message(STATUS "Found LADSPA: ${LADSPA_INCLUDE_DIR}") + endif(NOT LADSPA_FIND_QUIETLY) + else(LADSPA_FOUND) + if(LADSPA_FIND_REQUIRED) + message(FATAL_ERROR "Could not find LADSPA") + endif(LADSPA_FIND_REQUIRED) + endif(LADSPA_FOUND) + mark_as_advanced(LADSPA_INCLUDE_DIR) ################################################################## - IF(LADSPA_FOUND) - SET(HAVE_LADSPA TRUE) - ADD_DEFINITIONS(-DHAVE_LADSPA) - SET(LADSPA_INC_DIR ${LADSPA_INCLUDE_DIR}) - ENDIF(LADSPA_FOUND) - -ENDIF(WANT_SOUND) - -PKG_CHECK_MODULES(FFTW3F REQUIRED fftw3f>=3.0.0) -IF(FFTW3F_FOUND) - ADD_DEFINITIONS(-DHAVE_FFTW3F) - SET(HAVE_FFTW3F TRUE) - SET(FFTW3F_LIBS ${FFTW3F_LIBRARIES}) - #MESSAGE("FFTW3F_LIBS: ${FFTW3F_LIBS}") - LIST(APPEND FFTW3F_LIB_DIR ${FFTW3F_LIBDIR} ${FFTW3F_LIBRARY_DIRS}) - #MESSAGE("FFTW3F_LIB_DIR: ${FFTW3F_LIB_DIR}") - LIST(APPEND FFTW3F_INC_DIR ${FFTW3F_INCLUDEDIR} ${FFTW3F_INCLUDE_DIRS}) - #MESSAGE("FFTW3F_INC_DIR: ${FFTW3F_INC_DIR}") -ELSE(FFTW3F_FOUND) - MESSAGE(FATAL_ERROR "Please install the required package. Aborting") -ENDIF(FFTW3F_FOUND) - -IF(WANT_LIRC) - FIND_PACKAGE(LIRC QUIET) - IF(LIRC_FOUND) - SET(HAVE_LIRC TRUE) - ADD_DEFINITIONS(-DHAVE_LIRC) - MESSAGE(STATUS "Found LIRC (${LIRC_LIBRARY})") - SET(LIRC_LIBS ${LIRC_LIBRARY}) - SET(LIRC_INC_DIR ${LIRC_INCLUDE_DIR}) - SET(LIRC_LIB_DIR ${LIRC_LIBRARY_DIR}) - #MESSAGE("LIRC_LIBS: ${LIRC_LIBS}") - #MESSAGE("LIRC_LIB_DIR: ${LIRC_LIB_DIR}") - #MESSAGE("LIRC_INC_DIR: ${LIRC_INC_DIR}") - ENDIF(LIRC_FOUND) -ENDIF(WANT_LIRC) + if(LADSPA_FOUND) + set(HAVE_LADSPA TRUE) + add_definitions(-DHAVE_LADSPA) + set(LADSPA_INC_DIR ${LADSPA_INCLUDE_DIR}) + endif(LADSPA_FOUND) + +endif(WANT_SOUND) + +pkg_check_modules(FFTW3F REQUIRED fftw3f>=3.0.0) +if(FFTW3F_FOUND) + add_definitions(-DHAVE_FFTW3F) + set(HAVE_FFTW3F TRUE) + set(FFTW3F_LIBS ${FFTW3F_LIBRARIES}) + #message("FFTW3F_LIBS: ${FFTW3F_LIBS}") + list(APPEND FFTW3F_LIB_DIR ${FFTW3F_LIBDIR} ${FFTW3F_LIBRARY_DIRS}) + #message("FFTW3F_LIB_DIR: ${FFTW3F_LIB_DIR}") + list(APPEND FFTW3F_INC_DIR ${FFTW3F_INCLUDEDIR} ${FFTW3F_INCLUDE_DIRS}) + #message("FFTW3F_INC_DIR: ${FFTW3F_INC_DIR}") +else(FFTW3F_FOUND) + message(FATAL_ERROR "Please install the required package. Aborting") +endif(FFTW3F_FOUND) + +if(WANT_LIRC) + find_package(LIRC QUIET) + if(LIRC_FOUND) + set(HAVE_LIRC TRUE) + add_definitions(-DHAVE_LIRC) + message(STATUS "Found LIRC (${LIRC_LIBRARY})") + set(LIRC_LIBS ${LIRC_LIBRARY}) + set(LIRC_INC_DIR ${LIRC_INCLUDE_DIR}) + set(LIRC_LIB_DIR ${LIRC_LIBRARY_DIR}) + #message("LIRC_LIBS: ${LIRC_LIBS}") + #message("LIRC_LIB_DIR: ${LIRC_LIB_DIR}") + #message("LIRC_INC_DIR: ${LIRC_INC_DIR}") + endif(LIRC_FOUND) +endif(WANT_LIRC) # Check GCC for PCH support -SET(USE_PCH FALSE) -IF(WANT_PCH) - FIND_PACKAGE(PCHSupport) - IF(PCHSupport_FOUND) - SET(USE_PCH TRUE) - ADD_DEFINITIONS(-DUSE_PCH) - MESSAGE(STATUS "Enabling precompiled headers for GCC ${gcc_compiler_version}") - ENDIF(PCHSupport_FOUND) -ENDIF(WANT_PCH) +set(USE_PCH FALSE) +if(WANT_PCH) + find_package(PCHSupport) + if(PCHSupport_FOUND) + set(USE_PCH TRUE) + add_definitions(-DUSE_PCH) + message(STATUS "Enabling precompiled headers for GCC ${gcc_compiler_version}") + endif(PCHSupport_FOUND) +endif(WANT_PCH) # Check PTHREAD_MUTEX_RECURSIVE -INCLUDE(CheckCSourceCompiles) -CHECK_C_SOURCE_COMPILES( +include(CheckCSourceCompiles) +check_c_source_compiles( "#include <pthread.h> int main(int argc, char **argv) { pthread_mutexattr_t attr; pthread_mutexattr_settype(&attr, PTHREAD_MUTEX_RECURSIVE); return 0; }" PTHREAD_HAS_MUTEX_RECURSIVE) -IF(PTHREAD_HAS_MUTEX_RECURSIVE) - ADD_DEFINITIONS(-DHAVE_PTHREAD_MUTEX_RECURSIVE) -ENDIF(PTHREAD_HAS_MUTEX_RECURSIVE) +if(PTHREAD_HAS_MUTEX_RECURSIVE) + add_definitions(-DHAVE_PTHREAD_MUTEX_RECURSIVE) +endif(PTHREAD_HAS_MUTEX_RECURSIVE) # End of PTHREAD_MUTEX_RECURSIVE Test -SET(CMAKE_CXX_FLAGS_RELEASE "-O2 -w -fexceptions -DNDEBUG -include tqt.h") -SET(CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O2 -g -Wall -fexceptions -DDEBUG -include tqt.h") -SET(CMAKE_CXX_FLAGS_DEBUG "-O0 -g3 -Wall -fexceptions -DDEBUG -include tqt.h") +set(CMAKE_CXX_FLAGS_RELEASE "-O2 -w -fexceptions -DNDEBUG -include tqt.h") +set(CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O2 -g -Wall -fexceptions -DDEBUG -include tqt.h") +set(CMAKE_CXX_FLAGS_DEBUG "-O0 -g3 -Wall -fexceptions -DDEBUG -include tqt.h") -MESSAGE(STATUS "Rosegarden ${PACKAGE_VERSION} will be built for install into ${CMAKE_INSTALL_PREFIX}") +message(STATUS "Rosegarden ${PACKAGE_VERSION} will be built for install into ${CMAKE_INSTALL_PREFIX}") -IF(WANT_DEBUG) - IF(WANT_FULLDBG) - MESSAGE(STATUS "Configured to compile including full debug information in the executables") - SET(CMAKE_BUILD_TYPE Debug CACHE STRING +if(WANT_DEBUG) + if(WANT_FULLDBG) + message(STATUS "Configured to compile including full debug information in the executables") + set(CMAKE_BUILD_TYPE Debug CACHE STRING "Choose the type of build, options are: Debug Release RelWithDebInfo" FORCE) - ELSE(WANT_FULLDBG) - MESSAGE(STATUS "Configured to compile including debug information in the executables") - SET(CMAKE_BUILD_TYPE RelWithDebInfo CACHE STRING + else(WANT_FULLDBG) + message(STATUS "Configured to compile including debug information in the executables") + set(CMAKE_BUILD_TYPE RelWithDebInfo CACHE STRING "Choose the type of build, options are: Debug Release RelWithDebInfo" FORCE) - ENDIF(WANT_FULLDBG) -ELSE(WANT_DEBUG) - MESSAGE(STATUS "Configured to compile for release without debug information") - SET(CMAKE_BUILD_TYPE Release CACHE STRING + endif(WANT_FULLDBG) +else(WANT_DEBUG) + message(STATUS "Configured to compile for release without debug information") + set(CMAKE_BUILD_TYPE Release CACHE STRING "Choose the type of build, options are: Debug Release RelWithDebInfo" FORCE) -ENDIF(WANT_DEBUG) -MARK_AS_ADVANCED(CMAKE_BUILD_TYPE) +endif(WANT_DEBUG) +mark_as_advanced(CMAKE_BUILD_TYPE) check_type_size( "int" SIZEOF_INT BUILTIN_TYPES_ONLY ) check_type_size( "long" SIZEOF_LONG BUILTIN_TYPES_ONLY ) diff --git a/data/CMakeLists.txt b/data/CMakeLists.txt index 41d02ef..76850db 100644 --- a/data/CMakeLists.txt +++ b/data/CMakeLists.txt @@ -1,13 +1,13 @@ # Data directory -SET(DATADIR ${DATA_INSTALL_DIR}/rosegarden) -SET(ICONDIR ${ICON_INSTALL_DIR}) -SET(MIMEDIR ${MIME_INSTALL_DIR}/audio) -SET(MENUDIR ${XDG_MENU_INSTALL_DIR}) +set(DATADIR ${DATA_INSTALL_DIR}/rosegarden) +set(ICONDIR ${ICON_INSTALL_DIR}) +set(MIMEDIR ${MIME_INSTALL_DIR}/audio) +set(MENUDIR ${XDG_MENU_INSTALL_DIR}) # Guitar chord files -FILE(GLOB CHORD_FILES chords/*.xml) -INSTALL(FILES ${CHORD_FILES} DESTINATION ${DATADIR}/chords) +file(GLOB CHORD_FILES chords/*.xml) +install(FILES ${CHORD_FILES} DESTINATION ${DATADIR}/chords) # Desktop file tde_create_translated_desktop( desktop/rosegarden.desktop ) @@ -24,70 +24,70 @@ tde_create_translated_desktop( ) # Icons -INSTALL(FILES pixmaps/icons/cc-hi16-rosegarden.xpm DESTINATION ${ICONDIR}/locolor/16x16/apps RENAME rosegarden.xpm) -INSTALL(FILES pixmaps/icons/rg-rwb-rose3-16x16.png DESTINATION ${ICONDIR}/hicolor/16x16/apps RENAME rosegarden.png) -INSTALL(FILES pixmaps/icons/cc-hi32-rosegarden.xpm DESTINATION ${ICONDIR}/locolor/32x32/apps RENAME rosegarden.xpm) -INSTALL(FILES pixmaps/icons/rg-rwb-rose3-32x32.png DESTINATION ${ICONDIR}/hicolor/32x32/apps RENAME rosegarden.png) -INSTALL(FILES pixmaps/icons/rg-rwb-rose3-48x48.png DESTINATION ${ICONDIR}/hicolor/48x48/apps RENAME rosegarden.png) -INSTALL(FILES pixmaps/icons/rg-rwb-rose3-64x64.png DESTINATION ${ICONDIR}/hicolor/64x64/apps RENAME rosegarden.png) -INSTALL(FILES pixmaps/icons/rg-rwb-rose3-128x128.png DESTINATION ${ICONDIR}/hicolor/128x128/apps RENAME rosegarden.png) - -INSTALL(FILES pixmaps/icons/mm-mime-hi16-rosegarden.png DESTINATION ${ICONDIR}/hicolor/16x16/mimetypes RENAME x-rosegarden.png) -INSTALL(FILES pixmaps/icons/mm-mime-hi16-rosegarden.png DESTINATION ${ICONDIR}/locolor/16x16/mimetypes RENAME x-rosegarden.png) -INSTALL(FILES pixmaps/icons/mm-mime-hi32-rosegarden.png DESTINATION ${ICONDIR}/hicolor/32x32/mimetypes RENAME x-rosegarden.png) -INSTALL(FILES pixmaps/icons/mm-mime-hi32-rosegarden.png DESTINATION ${ICONDIR}/locolor/32x32/mimetypes RENAME x-rosegarden.png) +install(FILES pixmaps/icons/cc-hi16-rosegarden.xpm DESTINATION ${ICONDIR}/locolor/16x16/apps RENAME rosegarden.xpm) +install(FILES pixmaps/icons/rg-rwb-rose3-16x16.png DESTINATION ${ICONDIR}/hicolor/16x16/apps RENAME rosegarden.png) +install(FILES pixmaps/icons/cc-hi32-rosegarden.xpm DESTINATION ${ICONDIR}/locolor/32x32/apps RENAME rosegarden.xpm) +install(FILES pixmaps/icons/rg-rwb-rose3-32x32.png DESTINATION ${ICONDIR}/hicolor/32x32/apps RENAME rosegarden.png) +install(FILES pixmaps/icons/rg-rwb-rose3-48x48.png DESTINATION ${ICONDIR}/hicolor/48x48/apps RENAME rosegarden.png) +install(FILES pixmaps/icons/rg-rwb-rose3-64x64.png DESTINATION ${ICONDIR}/hicolor/64x64/apps RENAME rosegarden.png) +install(FILES pixmaps/icons/rg-rwb-rose3-128x128.png DESTINATION ${ICONDIR}/hicolor/128x128/apps RENAME rosegarden.png) + +install(FILES pixmaps/icons/mm-mime-hi16-rosegarden.png DESTINATION ${ICONDIR}/hicolor/16x16/mimetypes RENAME x-rosegarden.png) +install(FILES pixmaps/icons/mm-mime-hi16-rosegarden.png DESTINATION ${ICONDIR}/locolor/16x16/mimetypes RENAME x-rosegarden.png) +install(FILES pixmaps/icons/mm-mime-hi32-rosegarden.png DESTINATION ${ICONDIR}/hicolor/32x32/mimetypes RENAME x-rosegarden.png) +install(FILES pixmaps/icons/mm-mime-hi32-rosegarden.png DESTINATION ${ICONDIR}/locolor/32x32/mimetypes RENAME x-rosegarden.png) # styles -FILE(GLOB STYLES_FILES styles/*.xml) -INSTALL(FILES ${STYLES_FILES} DESTINATION ${DATADIR}/styles) +file(GLOB STYLES_FILES styles/*.xml) +install(FILES ${STYLES_FILES} DESTINATION ${DATADIR}/styles) # presets -FILE(GLOB PRESETS_FILES presets/*.xml) -INSTALL(FILES ${PRESETS_FILES} DESTINATION ${DATADIR}/presets) +file(GLOB PRESETS_FILES presets/*.xml) +install(FILES ${PRESETS_FILES} DESTINATION ${DATADIR}/presets) # fonts -FILE(GLOB PFA_FILES fonts/*.pfa) -INSTALL(FILES ${PFA_FILES} DESTINATION ${DATADIR}/fonts) +file(GLOB PFA_FILES fonts/*.pfa) +install(FILES ${PFA_FILES} DESTINATION ${DATADIR}/fonts) -FILE(GLOB XML_FILES fonts/mappings/*.xml) -INSTALL(FILES ${XML_FILES} DESTINATION ${DATADIR}/fonts/mappings) +file(GLOB XML_FILES fonts/mappings/*.xml) +install(FILES ${XML_FILES} DESTINATION ${DATADIR}/fonts/mappings) -FILE(GLOB XPM_FILES pixmaps/rg21/4/*.xpm) -INSTALL(FILES ${XPM_FILES} DESTINATION ${DATADIR}/fonts/rg21/4) +file(GLOB XPM_FILES pixmaps/rg21/4/*.xpm) +install(FILES ${XPM_FILES} DESTINATION ${DATADIR}/fonts/rg21/4) -FILE(GLOB XPM_FILES pixmaps/rg21/8/*.xpm) -INSTALL(FILES ${XPM_FILES} DESTINATION ${DATADIR}/fonts/rg21/8) +file(GLOB XPM_FILES pixmaps/rg21/8/*.xpm) +install(FILES ${XPM_FILES} DESTINATION ${DATADIR}/fonts/rg21/8) -FILE(GLOB XPM_FILES pixmaps/feta/4/*.xpm) -INSTALL(FILES ${XPM_FILES} DESTINATION ${DATADIR}/fonts/feta/4) +file(GLOB XPM_FILES pixmaps/feta/4/*.xpm) +install(FILES ${XPM_FILES} DESTINATION ${DATADIR}/fonts/feta/4) -FILE(GLOB XPM_FILES pixmaps/feta/6/*.xpm) -INSTALL(FILES ${XPM_FILES} DESTINATION ${DATADIR}/fonts/feta/6) +file(GLOB XPM_FILES pixmaps/feta/6/*.xpm) +install(FILES ${XPM_FILES} DESTINATION ${DATADIR}/fonts/feta/6) -FILE(GLOB XPM_FILES pixmaps/feta/8/*.xpm) -INSTALL(FILES ${XPM_FILES} DESTINATION ${DATADIR}/fonts/feta/8) +file(GLOB XPM_FILES pixmaps/feta/8/*.xpm) +install(FILES ${XPM_FILES} DESTINATION ${DATADIR}/fonts/feta/8) -FILE(GLOB XPM_FILES pixmaps/feta/10/*.xpm) -INSTALL(FILES ${XPM_FILES} DESTINATION ${DATADIR}/fonts/feta/10) +file(GLOB XPM_FILES pixmaps/feta/10/*.xpm) +install(FILES ${XPM_FILES} DESTINATION ${DATADIR}/fonts/feta/10) -FILE(GLOB XPM_FILES pixmaps/feta/12/*.xpm) -INSTALL(FILES ${XPM_FILES} DESTINATION ${DATADIR}/fonts/feta/12) +file(GLOB XPM_FILES pixmaps/feta/12/*.xpm) +install(FILES ${XPM_FILES} DESTINATION ${DATADIR}/fonts/feta/12) # pixmaps -FILE(GLOB PIXMAP_FILES pixmaps/misc/*.xpm pixmaps/misc/*.png) -INSTALL(FILES ${PIXMAP_FILES} DESTINATION ${DATADIR}/pixmaps/misc) +file(GLOB PIXMAP_FILES pixmaps/misc/*.xpm pixmaps/misc/*.png) +install(FILES ${PIXMAP_FILES} DESTINATION ${DATADIR}/pixmaps/misc) -FILE(GLOB PIXMAP_FILES pixmaps/toolbar/*.xpm pixmaps/toolbar/*.png) -INSTALL(FILES ${PIXMAP_FILES} DESTINATION ${DATADIR}/pixmaps/toolbar) +file(GLOB PIXMAP_FILES pixmaps/toolbar/*.xpm pixmaps/toolbar/*.png) +install(FILES ${PIXMAP_FILES} DESTINATION ${DATADIR}/pixmaps/toolbar) -FILE(GLOB PIXMAP_FILES pixmaps/transport/*.xpm pixmaps/transport/*.png) -INSTALL(FILES ${PIXMAP_FILES} DESTINATION ${DATADIR}/pixmaps/transport) +file(GLOB PIXMAP_FILES pixmaps/transport/*.xpm pixmaps/transport/*.png) +install(FILES ${PIXMAP_FILES} DESTINATION ${DATADIR}/pixmaps/transport) # Splash -INSTALL(FILES pixmaps/splash.png DESTINATION ${DATADIR}/pixmaps) +install(FILES pixmaps/splash.png DESTINATION ${DATADIR}/pixmaps) # Examples -SET(EXAMPLE_FILES +set(EXAMPLE_FILES examples/aveverum.rg examples/aylindaamiga.rg examples/bogus-surf-jam.rg @@ -117,12 +117,12 @@ SET(EXAMPLE_FILES examples/vivaldi-cs3mv2.rg examples/vivaldi_op44_11_1.rg ) -INSTALL(FILES ${EXAMPLE_FILES} DESTINATION ${DATADIR}/examples) -INSTALL(FILES examples/autoload.rg DESTINATION ${DATADIR}) +install(FILES ${EXAMPLE_FILES} DESTINATION ${DATADIR}/examples) +install(FILES examples/autoload.rg DESTINATION ${DATADIR}) # Library -FILE(GLOB RGD_FILES library/*.rgd) -INSTALL(FILES ${RGD_FILES} DESTINATION ${DATADIR}/library) +file(GLOB RGD_FILES library/*.rgd) +install(FILES ${RGD_FILES} DESTINATION ${DATADIR}/library) # KDE LIRC Profile -INSTALL(FILES profile/rosegarden.profile.xml DESTINATION ${DATA_INSTALL_DIR}/profiles) +install(FILES profile/rosegarden.profile.xml DESTINATION ${DATA_INSTALL_DIR}/profiles) diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index ab52cdd..92faf28 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -96,7 +96,7 @@ tde_add_executable( rosegardensequencer AUTOMOC target_link_libraries( rosegardensequencer dl ) -ADD_DEPENDENCIES(rosegardensequencer RosegardenCommon-static) +add_dependencies(rosegardensequencer RosegardenCommon-static) ##### RosegardenExtended ############################ @@ -136,19 +136,19 @@ tde_add_executable( rosegarden AUTOMOC target_link_libraries( rosegarden dl ) target_link_libraries( rosegarden tdeprint-shared ) -ADD_DEPENDENCIES(rosegarden RosegardenExtended-static) -ADD_DEPENDENCIES(rosegarden RosegardenSegmentCanvas-static) -ADD_DEPENDENCIES(rosegarden RosegardenCommands-static) -ADD_DEPENDENCIES(rosegarden RosegardenCommon-static) -ADD_DEPENDENCIES(rosegarden RosegardenExtended-static) -ADD_DEPENDENCIES(rosegarden RosegardenSegmentCanvas-static) -ADD_DEPENDENCIES(rosegarden RosegardenCommands-static) -ADD_DEPENDENCIES(rosegarden RosegardenCommon-static) +add_dependencies(rosegarden RosegardenExtended-static) +add_dependencies(rosegarden RosegardenSegmentCanvas-static) +add_dependencies(rosegarden RosegardenCommands-static) +add_dependencies(rosegarden RosegardenCommon-static) +add_dependencies(rosegarden RosegardenExtended-static) +add_dependencies(rosegarden RosegardenSegmentCanvas-static) +add_dependencies(rosegarden RosegardenCommands-static) +add_dependencies(rosegarden RosegardenCommon-static) if( WANT_TEST ) include( TestFileList.txt ) - CREATE_TEST_SOURCELIST(RosegardenTest + create_test_sourcelist(RosegardenTest RosegardenTestDriver.cpp ${tests_SRCS} # base/test/transpose.cpp @@ -161,18 +161,18 @@ if( WANT_TEST ) DESTINATION ${BIN_INSTALL_DIR} ) - ADD_DEPENDENCIES(RosegardenTestDriver RosegardenExtended-static) - ADD_DEPENDENCIES(RosegardenTestDriver RosegardenSegmentCanvas-static) - ADD_DEPENDENCIES(RosegardenTestDriver RosegardenCommands-static) - ADD_DEPENDENCIES(RosegardenTestDriver RosegardenCommon-static) - ADD_DEPENDENCIES(RosegardenTestDriver RosegardenExtended-static) - ADD_DEPENDENCIES(RosegardenTestDriver RosegardenSegmentCanvas-static) - ADD_DEPENDENCIES(RosegardenTestDriver RosegardenCommands-static) - ADD_DEPENDENCIES(RosegardenTestDriver RosegardenCommon-static) - - FOREACH(currenttest ${tests_SRCS}) - GET_FILENAME_COMPONENT(TestName ${currenttest} NAME_WE) - ADD_TEST(test/${TestName} RosegardenTestDriver test/${TestName}) - ENDFOREACH(currenttest ${tests_SRCS}) + add_dependencies(RosegardenTestDriver RosegardenExtended-static) + add_dependencies(RosegardenTestDriver RosegardenSegmentCanvas-static) + add_dependencies(RosegardenTestDriver RosegardenCommands-static) + add_dependencies(RosegardenTestDriver RosegardenCommon-static) + add_dependencies(RosegardenTestDriver RosegardenExtended-static) + add_dependencies(RosegardenTestDriver RosegardenSegmentCanvas-static) + add_dependencies(RosegardenTestDriver RosegardenCommands-static) + add_dependencies(RosegardenTestDriver RosegardenCommon-static) + + foreach(currenttest ${tests_SRCS}) + get_filename_component(TestName ${currenttest} NAME_WE) + add_test(test/${TestName} RosegardenTestDriver test/${TestName}) + endforeach(currenttest ${tests_SRCS}) endif( WANT_TEST ) |