1
0
mirror of https://github.com/clementine-player/Clementine synced 2024-12-18 12:28:31 +01:00

Make installing the projectm presets optional too - useful for if you want to use the ones from a system package instead.

Update issue #391
Status: Fixed
I've made installing the presets optional too, the cmake flag is BUNDLE_PROJECTM_PRESETS
This commit is contained in:
David Sansome 2010-06-10 23:01:22 +00:00
parent f04e4bb6ea
commit 6da08410e9
4 changed files with 21 additions and 16 deletions

View File

@ -152,17 +152,18 @@ endif(BUILD_PROJECTM_STATIC)
CONFIGURE_FILE("${CMAKE_CURRENT_SOURCE_DIR}/libprojectM.pc.in" "${CMAKE_CURRENT_SOURCE_DIR}/libprojectM.pc" @ONLY) CONFIGURE_FILE("${CMAKE_CURRENT_SOURCE_DIR}/libprojectM.pc.in" "${CMAKE_CURRENT_SOURCE_DIR}/libprojectM.pc" @ONLY)
CONFIGURE_FILE("${CMAKE_CURRENT_SOURCE_DIR}/config.inp.in" "${CMAKE_CURRENT_SOURCE_DIR}/config.inp" @ONLY) CONFIGURE_FILE("${CMAKE_CURRENT_SOURCE_DIR}/config.inp.in" "${CMAKE_CURRENT_SOURCE_DIR}/config.inp" @ONLY)
if(BUNDLE_PROJECTM_PRESETS)
FILE(GLOB presets "presets/*.milk" "presets/*.prjm" "presets/*.tga") FILE(GLOB presets "presets/*.milk" "presets/*.prjm" "presets/*.tga")
if (APPLE) if (APPLE)
foreach (preset ${presets}) foreach (preset ${presets})
get_filename_component(PRESET_NAME ${preset} NAME) get_filename_component(PRESET_NAME ${preset} NAME)
configure_file( configure_file(
"${preset}" "${preset}"
"${CMAKE_BINARY_DIR}/clementine.app/Contents/Resources/projectm-presets/${PRESET_NAME}" "${CMAKE_BINARY_DIR}/clementine.app/Contents/Resources/projectm-presets/${PRESET_NAME}"
COPY_ONLY COPY_ONLY
) )
endforeach (preset) endforeach (preset)
else (APPLE) else (APPLE)
INSTALL(FILES ${presets} DESTINATION ${CMAKE_INSTALL_PREFIX}/share/clementine/projectm-presets) INSTALL(FILES ${presets} DESTINATION ${CMAKE_INSTALL_PREFIX}/share/clementine/projectm-presets)
endif (APPLE) endif (APPLE)
endif(BUNDLE_PROJECTM_PRESETS)

View File

@ -109,6 +109,7 @@ endif(NOT GETTEXT_XGETTEXT_EXECUTABLE)
# Optional bits # Optional bits
option(ENABLE_VISUALISATIONS "Use libprojectm visualisations" ON) option(ENABLE_VISUALISATIONS "Use libprojectm visualisations" ON)
option(BUNDLE_PROJECTM_PRESETS "Install Clementine's own copies of libprojectm presets - disable this if you want to use a system package instead" ON)
if(ENABLE_VISUALISATIONS) if(ENABLE_VISUALISATIONS)
add_subdirectory(3rdparty/libprojectm) add_subdirectory(3rdparty/libprojectm)
endif(ENABLE_VISUALISATIONS) endif(ENABLE_VISUALISATIONS)

3
debian/control vendored
View File

@ -26,7 +26,8 @@ Depends: ${shlibs:Depends}, ${misc:Depends},
gstreamer0.10-plugins-base, gstreamer0.10-plugins-base,
gstreamer0.10-plugins-good, gstreamer0.10-plugins-good,
gstreamer0.10-alsa | gstreamer0.10-audiosink, gstreamer0.10-alsa | gstreamer0.10-audiosink,
gstreamer0.10-plugins-ugly gstreamer0.10-plugins-ugly,
libprojectm-data
Description: Clementine is a modern music player and library organiser. Description: Clementine is a modern music player and library organiser.
It is largely a port of Amarok 1.4, with some features rewritten to take It is largely a port of Amarok 1.4, with some features rewritten to take
advantage of Qt4. advantage of Qt4.

4
debian/rules vendored
View File

@ -4,7 +4,9 @@
configure: configure-stamp configure: configure-stamp
configure-stamp: configure-stamp:
dh_testdir dh_testdir
cd bin && cmake .. -DCMAKE_INSTALL_PREFIX=$(CURDIR)/debian/clementine/usr cd bin && cmake .. \
-DCMAKE_INSTALL_PREFIX=$(CURDIR)/debian/clementine/usr \
-DBUNDLE_PROJECTM_PRESETS=OFF
touch configure-stamp touch configure-stamp
build: build-stamp build: build-stamp