summaryrefslogtreecommitdiffstats
path: root/kopete/plugins
diff options
context:
space:
mode:
authorgregory guy <gregory-tde@laposte.net>2020-04-08 11:35:45 +0200
committergregory guy <gregory-tde@laposte.net>2020-04-08 11:35:45 +0200
commite05372302d307e186c017e8f1f2f1f63dc670f7a (patch)
treef54e7b82cc94e45b1aece0b6b2ebebeedda41b0a /kopete/plugins
parent3af27a421c88e9fd0bb636d00187009bb883d38c (diff)
downloadtdenetwork-e05372302d307e186c017e8f1f2f1f63dc670f7a.tar.gz
tdenetwork-e05372302d307e186c017e8f1f2f1f63dc670f7a.zip
Should bring back xmms support in kopete's plugins.
Signed-off-by: gregory guy <gregory-tde@laposte.net>
Diffstat (limited to 'kopete/plugins')
-rw-r--r--kopete/plugins/nowlistening/CMakeLists.txt87
-rw-r--r--kopete/plugins/nowlistening/ConfigureChecks.cmake58
2 files changed, 97 insertions, 48 deletions
diff --git a/kopete/plugins/nowlistening/CMakeLists.txt b/kopete/plugins/nowlistening/CMakeLists.txt
index 29c1e03e..733e6e48 100644
--- a/kopete/plugins/nowlistening/CMakeLists.txt
+++ b/kopete/plugins/nowlistening/CMakeLists.txt
@@ -1,13 +1,13 @@
-#################################################
-#
-# (C) 2010-2011 Serghei Amelian
-# serghei (DOT) amelian (AT) gmail.com
-#
-# Improvements and feedback are welcome
-#
-# This file is released under GPL >= 2
-#
-#################################################
+###########################################
+# #
+# (C) 2010-2011 Serghei Amelian #
+# serghei (DOT) amelian (AT) gmail.com #
+# #
+# Improvements and feedback are welcome #
+# #
+# This file is released under GPL >= 2 #
+# #
+###########################################
include( ConfigureChecks.cmake )
@@ -18,7 +18,7 @@ include_directories(
${CMAKE_SOURCE_DIR}/kopete/libkopete/ui
${TDE_INCLUDE_DIR}
${TQT_INCLUDE_DIRS}
- ${XMMS_INCLUDES}
+ ${XMMS_INCLUDE_DIRS}
)
link_directories(
@@ -26,32 +26,61 @@ link_directories(
)
-##### other data ################################
+##### kopete_nowlistening (module)
-install( FILES kopete_nowlistening.desktop DESTINATION ${SERVICES_INSTALL_DIR} )
-install( FILES kopete_nowlistening_config.desktop DESTINATION ${SERVICES_INSTALL_DIR}/tdeconfiguredialog )
-install( FILES nowlisteningconfig.kcfg DESTINATION ${KCFG_INSTALL_DIR} )
-install( FILES nowlisteningui.rc nowlisteningchatui.rc DESTINATION ${DATA_INSTALL_DIR}/kopete )
+tde_add_kpart( kopete_nowlistening MODULE AUTOMOC
-
-##### kopete_nowlistening (module) ##############
-
-tde_add_kpart( kopete_nowlistening AUTOMOC
SOURCES
- nowlisteningconfig.kcfgc nowlisteningplugin.cpp nlkscd.cpp
- nlnoatun.cpp nlxmms.cpp nowlisteningguiclient.cpp nljuk.cpp
- nlamarok.cpp nlkaffeine.cpp
- LINK kopete-shared ${XMMS_LIBS}
+ nowlisteningconfig.kcfgc
+ nowlisteningplugin.cpp
+ nlkscd.cpp
+ nlnoatun.cpp
+ nlxmms.cpp
+ nowlisteningguiclient.cpp
+ nljuk.cpp
+ nlamarok.cpp
+ nlkaffeine.cpp
+ LINK
+ kopete-shared
+ ${XMMS_LIBRARIES}
+
DESTINATION ${PLUGIN_INSTALL_DIR}
)
-##### kcm_kopete_nowlistening (module) ##########
+##### kcm_kopete_nowlistening (module)
+
+tde_add_kpart( kcm_kopete_nowlistening MODULE AUTOMOC
-tde_add_kpart( kcm_kopete_nowlistening AUTOMOC
SOURCES
- nowlisteningprefs.ui nowlisteningpreferences.cpp
- nowlisteningconfig.kcfgc
- LINK tdeutils-shared
+ nowlisteningprefs.ui
+ nowlisteningpreferences.cpp
+ nowlisteningconfig.kcfgc
+ LINK
+ tdeutils-shared
+
DESTINATION ${PLUGIN_INSTALL_DIR}
)
+
+
+##### other data
+
+install(
+ FILES kopete_nowlistening.desktop
+ DESTINATION ${SERVICES_INSTALL_DIR}
+)
+
+install(
+ FILES kopete_nowlistening_config.desktop
+ DESTINATION ${SERVICES_INSTALL_DIR}/tdeconfiguredialog
+)
+
+install(
+ FILES nowlisteningconfig.kcfg
+ DESTINATION ${KCFG_INSTALL_DIR}
+)
+
+install(
+ FILES nowlisteningui.rc nowlisteningchatui.rc
+ DESTINATION ${DATA_INSTALL_DIR}/kopete
+)
diff --git a/kopete/plugins/nowlistening/ConfigureChecks.cmake b/kopete/plugins/nowlistening/ConfigureChecks.cmake
index c1780d68..b1f98548 100644
--- a/kopete/plugins/nowlistening/ConfigureChecks.cmake
+++ b/kopete/plugins/nowlistening/ConfigureChecks.cmake
@@ -1,22 +1,42 @@
-#################################################
-#
-# (C) 2012 Slavek Banko
-# slavek (DOT) banko (AT) axis.cz
-#
-# Improvements and feedback are welcome
-#
-# This file is released under GPL >= 2
-#
-#################################################
+###########################################
+# #
+# (C) 2012 Slavek Banko #
+# slavek (DOT) banko (AT) axis.cz #
+# #
+# Improvements and feedback are welcome #
+# #
+# This file is released under GPL >= 2 #
+# #
+###########################################
+
+##### xmms
-# xmms
if( WITH_XMMS )
- find_program( XMMS_CONFIG xmms-config )
- if( XMMS_CONFIG )
+find_program( XMMS_CONFIG xmms-config )
+
+if( NOT XMMS_CONFIG )
+ tde_message_fatal( "xmms support has been requested but was not found on your system" )
+ else()
+ execute_process(
+ COMMAND ${XMMS_CONFIG} --cflags
+ OUTPUT_VARIABLE XMMS_INCLUDES
+ ERROR_VARIABLE XMMS_INCLUDES
+ OUTPUT_STRIP_TRAILING_WHITESPACE
+ ERROR_STRIP_TRAILING_WHITESPACE
+ )
+ string( REGEX MATCHALL "-I([^ ]*)" XMMS_INCLUDES "${XMMS_INCLUDES}" )
+ string( REGEX REPLACE "-I" "" XMMS_INCLUDES "${XMMS_INCLUDES}" )
+ set( XMMS_INCLUDE_DIRS "${XMMS_INCLUDES}" CACHE INTERNAL "" )
+
+ execute_process(
+ COMMAND ${XMMS_CONFIG} --libs
+ OUTPUT_VARIABLE XMMS_LIBS
+ ERROR_VARIABLE XMMS_LIBS
+ OUTPUT_STRIP_TRAILING_WHITESPACE
+ ERROR_STRIP_TRAILING_WHITESPACE
+ )
+ set( XMMS_LIBRARIES "${XMMS_LIBS}" CACHE INTERNAL "" )
+
set( HAVE_XMMS 1 CACHE INTERNAL "" )
- EXECUTE_PROCESS( COMMAND ${XMMS_CONFIG} '--cflags' OUTPUT_VARIABLE XMMS_INCLUDES )
- EXECUTE_PROCESS( COMMAND ${XMMS_CONFIG} '--libs' OUTPUT_VARIABLE XMMS_LIBS )
- else( )
- tde_message_fatal( "xmms is required, but was not found on your system" )
- endif( )
-endif( )
+endif()
+endif( WITH_XMMS )