From f2586846661fd2ef1a999765108298ca41b57256 Mon Sep 17 00:00:00 2001 From: Alexander Neundorf Date: Sat, 14 Jan 2006 20:15:30 +0000 Subject: -simple cmake modules for detecting libart, OpenSSL, FAM, jasper and PCRE -major improvement of am2cmake: add libtool .la files found in LIBADD to TARGET_LINK_LIBRARIES and fix the loop for adding the libs Alex svn path=/trunk/KDE/kdesdk/cmake/; revision=498154 --- modules/FindFAM.cmake | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 modules/FindFAM.cmake (limited to 'modules/FindFAM.cmake') diff --git a/modules/FindFAM.cmake b/modules/FindFAM.cmake new file mode 100644 index 00000000..1ac64251 --- /dev/null +++ b/modules/FindFAM.cmake @@ -0,0 +1,27 @@ + +FIND_PATH(FAM_INCLUDE_DIR fam.h +/usr/include +/usr/local/include +) + +FIND_LIBRARY(FAM_LIBRARY NAMES fam +PATHS +/usr/lib +/usr/local/lib +) + + +IF(FAM_INCLUDE_DIR) + SET(FAM_FOUND TRUE) +ENDIF(FAM_INCLUDE_DIR) + + +IF(FAM_FOUND) + IF(NOT FAM_FIND_QUIETLY) + MESSAGE(STATUS "Found fam: ${FAM_LIBRARY}") + ENDIF(NOT FAM_FIND_QUIETLY) +ELSE(FAM_FOUND) + IF(FAM_FIND_REQUIRED) + MESSAGE(SEND_ERROR "Could not find fam library") + ENDIF(FAM_FIND_REQUIRED) +ENDIF(FAM_FOUND) -- cgit v1.2.1 From 1d78fb83f0d0c05d0d0bd8b4bbb53747fc55778d Mon Sep 17 00:00:00 2001 From: Alexander Neundorf Date: Wed, 25 Jan 2006 20:41:54 +0000 Subject: add the stuff moved from kdesdk, maybe... Alex svn path=/trunk/KDE/kdelibs/; revision=502383 --- modules/FindFAM.cmake | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'modules/FindFAM.cmake') diff --git a/modules/FindFAM.cmake b/modules/FindFAM.cmake index 1ac64251..bfc553fe 100644 --- a/modules/FindFAM.cmake +++ b/modules/FindFAM.cmake @@ -22,6 +22,6 @@ IF(FAM_FOUND) ENDIF(NOT FAM_FIND_QUIETLY) ELSE(FAM_FOUND) IF(FAM_FIND_REQUIRED) - MESSAGE(SEND_ERROR "Could not find fam library") + MESSAGE(FATAL_ERROR "Could not find fam library") ENDIF(FAM_FIND_REQUIRED) ENDIF(FAM_FOUND) -- cgit v1.2.1 From 75a07dd38b4a491a9d16d24492bea5c6ba90a8ff Mon Sep 17 00:00:00 2001 From: Alexander Neundorf Date: Sun, 12 Feb 2006 14:38:04 +0000 Subject: -moved the cmake code to find kdewin32 out of FindKDE4.cmake and into its own FindKDEWIN32.cmake file -added a new FindGNUWIN32.cmake file, which tries to find the gnuwin32 base directory -changed all "FOO_LIBRARY" variable names to "FOO_LIBRARIES" to be more consistent with the other cmake modules -added a macro_getenv_win_path() which replaces all backslahes with slashes from environment variables -modified the kde4_add_kcfg_files() command, so that the generated header is also processed by moc -all tests compile and link Alex CCMAIL:kde-buildsystem@kde.org The changes to the windows stuff are untested, since I don't have a windows box. Please check that everything still works. Please have a look at FindGNUWIN32.cmake, there are probably ways to improve this. The resulting GNUWIN32_DIR variable is used in other cmake modules as default path to search for headers and libraries. svn path=/trunk/KDE/kdelibs/; revision=508648 --- modules/FindFAM.cmake | 27 ++++++++++++++++++--------- 1 file changed, 18 insertions(+), 9 deletions(-) (limited to 'modules/FindFAM.cmake') diff --git a/modules/FindFAM.cmake b/modules/FindFAM.cmake index bfc553fe..0479bc8f 100644 --- a/modules/FindFAM.cmake +++ b/modules/FindFAM.cmake @@ -1,27 +1,36 @@ +# - Try to find the FAM directory notification library +# Once done this will define +# +# FAM_FOUND - system has FAM +# FAM_INCLUDE_DIR - the FAM include directory +# FAM_LIBRARIES - The libraries needed to use FAM FIND_PATH(FAM_INCLUDE_DIR fam.h -/usr/include -/usr/local/include + /usr/include + /usr/local/include ) -FIND_LIBRARY(FAM_LIBRARY NAMES fam -PATHS -/usr/lib -/usr/local/lib +FIND_LIBRARY(FAM_LIBRARIES NAMES fam + PATHS + /usr/lib + /usr/local/lib ) -IF(FAM_INCLUDE_DIR) +IF(FAM_INCLUDE_DIR AND FAM_LIBRARIES) SET(FAM_FOUND TRUE) -ENDIF(FAM_INCLUDE_DIR) +ENDIF(FAM_INCLUDE_DIR AND FAM_LIBRARIES) IF(FAM_FOUND) IF(NOT FAM_FIND_QUIETLY) - MESSAGE(STATUS "Found fam: ${FAM_LIBRARY}") + MESSAGE(STATUS "Found fam: ${FAM_LIBRARIES}") ENDIF(NOT FAM_FIND_QUIETLY) ELSE(FAM_FOUND) IF(FAM_FIND_REQUIRED) MESSAGE(FATAL_ERROR "Could not find fam library") ENDIF(FAM_FIND_REQUIRED) ENDIF(FAM_FOUND) + +MARK_AS_ADVANCED(FAM_INCLUDE_DIR FAM_LIBRARIES) + -- cgit v1.2.1 From ffc69376dc591eae7b0ed2e974a599fb1b8b2aa8 Mon Sep 17 00:00:00 2001 From: David Faure Date: Wed, 15 Feb 2006 10:47:36 +0000 Subject: Lowercase some common keywords to improve readability svn path=/trunk/KDE/kdelibs/; revision=509624 --- modules/FindFAM.cmake | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) (limited to 'modules/FindFAM.cmake') diff --git a/modules/FindFAM.cmake b/modules/FindFAM.cmake index 0479bc8f..b61fc4e7 100644 --- a/modules/FindFAM.cmake +++ b/modules/FindFAM.cmake @@ -17,20 +17,20 @@ FIND_LIBRARY(FAM_LIBRARIES NAMES fam ) -IF(FAM_INCLUDE_DIR AND FAM_LIBRARIES) - SET(FAM_FOUND TRUE) -ENDIF(FAM_INCLUDE_DIR AND FAM_LIBRARIES) - - -IF(FAM_FOUND) - IF(NOT FAM_FIND_QUIETLY) - MESSAGE(STATUS "Found fam: ${FAM_LIBRARIES}") - ENDIF(NOT FAM_FIND_QUIETLY) -ELSE(FAM_FOUND) - IF(FAM_FIND_REQUIRED) - MESSAGE(FATAL_ERROR "Could not find fam library") - ENDIF(FAM_FIND_REQUIRED) -ENDIF(FAM_FOUND) +if(FAM_INCLUDE_DIR AND FAM_LIBRARIES) + set(FAM_FOUND TRUE) +endif(FAM_INCLUDE_DIR AND FAM_LIBRARIES) + + +if(FAM_FOUND) + if(not FAM_FIND_QUIETLY) + message(STATUS "Found fam: ${FAM_LIBRARIES}") + endif(not FAM_FIND_QUIETLY) +else(FAM_FOUND) + if(FAM_FIND_REQUIRED) + message(FATAL_ERROR "Could not find fam library") + endif(FAM_FIND_REQUIRED) +endif(FAM_FOUND) MARK_AS_ADVANCED(FAM_INCLUDE_DIR FAM_LIBRARIES) -- cgit v1.2.1 From eaad615ee85800bedbf2088326399027c95d0740 Mon Sep 17 00:00:00 2001 From: David Faure Date: Wed, 15 Feb 2006 10:49:53 +0000 Subject: Hmm, "NOT" can't be lowercased. I tested before lowercasing that last one, of course... svn path=/trunk/KDE/kdelibs/; revision=509625 --- modules/FindFAM.cmake | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'modules/FindFAM.cmake') diff --git a/modules/FindFAM.cmake b/modules/FindFAM.cmake index b61fc4e7..225a2e29 100644 --- a/modules/FindFAM.cmake +++ b/modules/FindFAM.cmake @@ -23,12 +23,12 @@ endif(FAM_INCLUDE_DIR AND FAM_LIBRARIES) if(FAM_FOUND) - if(not FAM_FIND_QUIETLY) + if(NOT FAM_FIND_QUIETLY) message(STATUS "Found fam: ${FAM_LIBRARIES}") - endif(not FAM_FIND_QUIETLY) + endif(NOT FAM_FIND_QUIETLY) else(FAM_FOUND) if(FAM_FIND_REQUIRED) - message(FATAL_ERROR "Could not find fam library") + message(FATAL_ERROR "Could NOT find fam library") endif(FAM_FIND_REQUIRED) endif(FAM_FOUND) -- cgit v1.2.1 From 191846e3e21c697c28bd5c8a166edeb4072161e3 Mon Sep 17 00:00:00 2001 From: Allen Winter Date: Mon, 20 Mar 2006 21:05:37 +0000 Subject: minor cleanups: indenting, adding newline to end of file, etc. svn path=/trunk/KDE/kdelibs/; revision=520790 --- modules/FindFAM.cmake | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'modules/FindFAM.cmake') diff --git a/modules/FindFAM.cmake b/modules/FindFAM.cmake index 225a2e29..164841c8 100644 --- a/modules/FindFAM.cmake +++ b/modules/FindFAM.cmake @@ -17,20 +17,20 @@ FIND_LIBRARY(FAM_LIBRARIES NAMES fam ) -if(FAM_INCLUDE_DIR AND FAM_LIBRARIES) +if (FAM_INCLUDE_DIR AND FAM_LIBRARIES) set(FAM_FOUND TRUE) -endif(FAM_INCLUDE_DIR AND FAM_LIBRARIES) +endif (FAM_INCLUDE_DIR AND FAM_LIBRARIES) -if(FAM_FOUND) - if(NOT FAM_FIND_QUIETLY) +if (FAM_FOUND) + if (NOT FAM_FIND_QUIETLY) message(STATUS "Found fam: ${FAM_LIBRARIES}") - endif(NOT FAM_FIND_QUIETLY) -else(FAM_FOUND) - if(FAM_FIND_REQUIRED) + endif (NOT FAM_FIND_QUIETLY) +else (FAM_FOUND) + if (FAM_FIND_REQUIRED) message(FATAL_ERROR "Could NOT find fam library") - endif(FAM_FIND_REQUIRED) -endif(FAM_FOUND) + endif (FAM_FIND_REQUIRED) +endif (FAM_FOUND) MARK_AS_ADVANCED(FAM_INCLUDE_DIR FAM_LIBRARIES) -- cgit v1.2.1 From cf37d2b2f602910dbd5ad7bf3e4532e90a009840 Mon Sep 17 00:00:00 2001 From: Allen Winter Date: Sat, 13 May 2006 02:58:18 +0000 Subject: shhh! if FAM found in cache. svn path=/trunk/KDE/kdelibs/; revision=540331 --- modules/FindFAM.cmake | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'modules/FindFAM.cmake') diff --git a/modules/FindFAM.cmake b/modules/FindFAM.cmake index 164841c8..e0a92b72 100644 --- a/modules/FindFAM.cmake +++ b/modules/FindFAM.cmake @@ -5,6 +5,11 @@ # FAM_INCLUDE_DIR - the FAM include directory # FAM_LIBRARIES - The libraries needed to use FAM +if (FAM_INCLUDE_DIR) + # Already in cache, be silent + set(FAM_FIND_QUIETLY TRUE) +endif (FAM_INCLUDE_DIR) + FIND_PATH(FAM_INCLUDE_DIR fam.h /usr/include /usr/local/include -- cgit v1.2.1 From c778596920e0d5357f216c885e35b4f97d371a23 Mon Sep 17 00:00:00 2001 From: Alexander Neundorf Date: Sat, 9 Sep 2006 10:18:35 +0000 Subject: added copyright notice everywhere. Now they all are BSD-licensed, as copyright holder I inserted everywhere the one who added it to svn (or Kitware if it is an enhanced copy from taken cmake) Some developers committed quite often but were not the ones who added the file, if you feel you have also copyright on the file add your name in the specific file. Copyright holders: CCMAIL: montel@kde.org CCMAIL: toscano.pino@tiscali.it CCMAIL: adymo@kdevelop.org CCMAIL: ranger@befunk.com CCMAIL: zack@kde.org CCMAIL: caslav.ilic@gmx.net CCMAIL: syntheticpp@yahoo.com CCMAIL: js@iidea.pl CCMAIL: michael.larouche@kdemail.net CCMAIL: ossi@kde.org CCMAIL: faure@kde.org Committers, but no files added so that they are not listed as copyright holders: CCMAIL: ch.ehrlicher@gmx.de CCMAIL: winter@kde.org CCMAIL: ralf.habacker@freenet.de CCMAIL: moura@kdewebdev.org CCMAIL: kde-buildsystem@kde.org Alex svn path=/trunk/KDE/kdelibs/; revision=582410 --- modules/FindFAM.cmake | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'modules/FindFAM.cmake') diff --git a/modules/FindFAM.cmake b/modules/FindFAM.cmake index e0a92b72..bdfa0e03 100644 --- a/modules/FindFAM.cmake +++ b/modules/FindFAM.cmake @@ -4,6 +4,12 @@ # FAM_FOUND - system has FAM # FAM_INCLUDE_DIR - the FAM include directory # FAM_LIBRARIES - The libraries needed to use FAM +# +# Copyright (c) 2006, Alexander Neundorf, +# +# Redistribution and use is allowed according to the terms of the BSD license. +# For details see the accompanying COPYING-CMAKE-SCRIPTS file. + if (FAM_INCLUDE_DIR) # Already in cache, be silent -- cgit v1.2.1 From b934aae5f61f38183cd62a459c61b2625e71b52c Mon Sep 17 00:00:00 2001 From: Alexander Neundorf Date: Fri, 3 Aug 2007 01:13:21 +0000 Subject: remove unnecessary default search paths Alex svn path=/trunk/KDE/kdelibs/; revision=695813 --- modules/FindFAM.cmake | 13 +++---------- 1 file changed, 3 insertions(+), 10 deletions(-) (limited to 'modules/FindFAM.cmake') diff --git a/modules/FindFAM.cmake b/modules/FindFAM.cmake index bdfa0e03..d7144d52 100644 --- a/modules/FindFAM.cmake +++ b/modules/FindFAM.cmake @@ -16,16 +16,9 @@ if (FAM_INCLUDE_DIR) set(FAM_FIND_QUIETLY TRUE) endif (FAM_INCLUDE_DIR) -FIND_PATH(FAM_INCLUDE_DIR fam.h - /usr/include - /usr/local/include -) - -FIND_LIBRARY(FAM_LIBRARIES NAMES fam - PATHS - /usr/lib - /usr/local/lib -) +FIND_PATH(FAM_INCLUDE_DIR fam.h) + +FIND_LIBRARY(FAM_LIBRARIES NAMES fam ) if (FAM_INCLUDE_DIR AND FAM_LIBRARIES) -- cgit v1.2.1 From 9d32d67f6a70cb867a26400b6107f3ed7600c3eb Mon Sep 17 00:00:00 2001 From: Laurent Montel Date: Tue, 7 Aug 2007 20:03:40 +0000 Subject: Use FIND_PACKAGE_HANDLE_STANDARD_ARGS svn path=/trunk/KDE/kdelibs/; revision=697445 --- modules/FindFAM.cmake | 17 ++--------------- 1 file changed, 2 insertions(+), 15 deletions(-) (limited to 'modules/FindFAM.cmake') diff --git a/modules/FindFAM.cmake b/modules/FindFAM.cmake index d7144d52..62e34e15 100644 --- a/modules/FindFAM.cmake +++ b/modules/FindFAM.cmake @@ -20,21 +20,8 @@ FIND_PATH(FAM_INCLUDE_DIR fam.h) FIND_LIBRARY(FAM_LIBRARIES NAMES fam ) - -if (FAM_INCLUDE_DIR AND FAM_LIBRARIES) - set(FAM_FOUND TRUE) -endif (FAM_INCLUDE_DIR AND FAM_LIBRARIES) - - -if (FAM_FOUND) - if (NOT FAM_FIND_QUIETLY) - message(STATUS "Found fam: ${FAM_LIBRARIES}") - endif (NOT FAM_FIND_QUIETLY) -else (FAM_FOUND) - if (FAM_FIND_REQUIRED) - message(FATAL_ERROR "Could NOT find fam library") - endif (FAM_FIND_REQUIRED) -endif (FAM_FOUND) +include(FindPackageHandleStandardArgs) +FIND_PACKAGE_HANDLE_STANDARD_ARGS(FAM DEFAULT_MSG FAM_INCLUDE_DIR FAM_LIBRARIES ) MARK_AS_ADVANCED(FAM_INCLUDE_DIR FAM_LIBRARIES) -- cgit v1.2.1 From 814455b7ad321c88e730662fda58261087b72e72 Mon Sep 17 00:00:00 2001 From: Alexander Neundorf Date: Mon, 18 Feb 2008 19:06:32 +0000 Subject: some improvements to the docs: -some modules were not at all documented, only few are left now -the copyright message doesn't have to be printed for every module in the docs -fix FindKorundom.cmake, it didn't follow the style guide and had typos (e.g. Korumdum_FOUND instead of KORUNDUM_FOUND) Alex (will commit modified FindKDE4Internal.cmake after Christians commit) svn path=/trunk/KDE/kdelibs/; revision=776742 --- modules/FindFAM.cmake | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'modules/FindFAM.cmake') diff --git a/modules/FindFAM.cmake b/modules/FindFAM.cmake index 62e34e15..8ebb3ab6 100644 --- a/modules/FindFAM.cmake +++ b/modules/FindFAM.cmake @@ -4,7 +4,7 @@ # FAM_FOUND - system has FAM # FAM_INCLUDE_DIR - the FAM include directory # FAM_LIBRARIES - The libraries needed to use FAM -# + # Copyright (c) 2006, Alexander Neundorf, # # Redistribution and use is allowed according to the terms of the BSD license. -- cgit v1.2.1 From 4051cfa096f4fa11e6cea0950970e741140cdd0d Mon Sep 17 00:00:00 2001 From: Alexander Neundorf Date: Tue, 24 Aug 2010 20:05:51 +0000 Subject: -use consistent casing within each file, remove unnecessary checks Alex svn path=/trunk/KDE/kdelibs/; revision=1167513 --- modules/FindFAM.cmake | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) (limited to 'modules/FindFAM.cmake') diff --git a/modules/FindFAM.cmake b/modules/FindFAM.cmake index 8ebb3ab6..7a598fd0 100644 --- a/modules/FindFAM.cmake +++ b/modules/FindFAM.cmake @@ -11,16 +11,11 @@ # For details see the accompanying COPYING-CMAKE-SCRIPTS file. -if (FAM_INCLUDE_DIR) - # Already in cache, be silent - set(FAM_FIND_QUIETLY TRUE) -endif (FAM_INCLUDE_DIR) - FIND_PATH(FAM_INCLUDE_DIR fam.h) FIND_LIBRARY(FAM_LIBRARIES NAMES fam ) -include(FindPackageHandleStandardArgs) +INCLUDE(FindPackageHandleStandardArgs) FIND_PACKAGE_HANDLE_STANDARD_ARGS(FAM DEFAULT_MSG FAM_INCLUDE_DIR FAM_LIBRARIES ) MARK_AS_ADVANCED(FAM_INCLUDE_DIR FAM_LIBRARIES) -- cgit v1.2.1