[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-buildsystem
Subject:    Please review: cmake check for Cagibi
From:       "Friedrich W. H. Kossebau" <kossebau () kde ! org>
Date:       2010-08-23 19:53:47
Message-ID: 201008232153.48283.kossebau () kde ! org
[Download RAW message or body]

Hi,

following up to my and your emails on "How to test for a D-Bus run-time 
dependency?" last tuesday here please find and then comment on my proposal to 
test for the existance of cagibi during the build, so there is some hint at 
every build of kdebase on this optional dependency.

The patch adds to kdebase/runtime/CMakeLists.txt the test of Cagibi, the file 
FindCagibi.cmake should end up in kdebase/runtime/cmake/modules.

There are currently only two versions of Cagibi released, 0.1.0 and 0.1.1. The 
problem is that the version cannot really be checked at the moment, as the 
version string is nowhere noted in the install.
But as Cagibi may not be spread that much currently, most people will see the 
demand for the version 0.1.1 at least. And this is better than the current 
situation.

Okay to commit both to trunk and 4.5 branch?

Cheers
Friedrich
-- 
KDE Okteta - a simple hex editor - http://utils.kde.org/projects/okteta

["findCagibi.patch" (text/x-patch)]

Index: runtime/CMakeLists.txt
===================================================================
--- runtime/CMakeLists.txt	(Revision 1167176)
+++ runtime/CMakeLists.txt	(Arbeitskopie)
@@ -37,6 +37,12 @@
   "OpenSLP" "SLP (Service Location Protocol) implementation" \
"http://www.openslp.org/" FALSE  "" "Provides SLP support in the network:/ kioslave."
 )
+set(CAGIBI_MIN_VERSION "0.1.1")
+macro_optional_find_package(Cagibi)
+macro_log_feature( CAGIBI_FOUND
+  "Cagibi" "SSDP (Simple Service Discovery Protocol, used by UPnP) cache/proxy \
daemon" "http://websvn.kde.org/trunk/kdesupport/cagibi/" FALSE +  \
${CAGIBI_MIN_VERSION} "Provides UPnP device/service listing in the network:/ \
kioslave." +)
 
 set(LIBATTICA_MIN_VERSION "0.1.4")
 find_package(LibAttica)


["FindCagibi.cmake" (text/x-cmake)]

#
# This module looks for the Cagibi daemon,
# a SSDP (Simple Service Discovery Protocol, used by UPnP) cache/proxy daemon
# http://websvn.kde.org/trunk/kdesupport/cagibi/

# It will define the following values
#
# CAGIBI_DAEMON     = the executable of the daemon
# CAGIBI_FOUND      = set to 1 if cagibi is found
#

if (CAGIBI_DAEMON)

    # Already in cache
    set(CAGIBI_FOUND TRUE)

else (CAGIBI_DAEMON)

    if (NOT CAGIBI_MIN_VERSION)
        set(CAGIBI_MIN_VERSION "0.1.1")
    endif (NOT CAGIBI_MIN_VERSION)

    # TODO: add possibility to cagibi to query version
    # detection is impossible for 0.1.0 (if patched like needed) and 0.1.1
    FIND_PROGRAM(CAGIBI_DAEMON NAMES cagibid)

    if (CAGIBI_DAEMON)
        set(CAGIBI_FOUND TRUE)
    endif (CAGIBI_DAEMON)

    if (CAGIBI_FOUND)
        if (NOT CAGIBI_FIND_QUIETLY)
            message(STATUS "Found Cagibi daemon: ${CAGIBI_DAEMON}")
        endif (NOT CAGIBI_FIND_QUIETLY)
    else (CAGIBI_FOUND)
        if (CAGIBI_FIND_REQUIRED)
            message(FATAL_ERROR "Could NOT find Cagibi daemon. Please install \
${CAGIBI_MIN_VERSION} or newer.")  else (CAGIBI_FIND_REQUIRED)
            message(STATUS "Please install Cagibi ${CAGIBI_MIN_VERSION} or newer.")
        endif (CAGIBI_FIND_REQUIRED)
    endif (CAGIBI_FOUND)

    MARK_AS_ADVANCED(CAGIBI_FOUND CAGIBI_DAEMON)
endif (CAGIBI_DAEMON)



_______________________________________________
Kde-buildsystem mailing list
Kde-buildsystem@kde.org
https://mail.kde.org/mailman/listinfo/kde-buildsystem


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic