1
# Copyright (C) 2011 Ivan Cukic <ivan.cukic(at)kde.org>
3
# This program is free software; you can redistribute it and/or modify
4
# it under the terms of the GNU General Public License version 2,
5
# or (at your option) any later version, as published by the Free
8
# This program is distributed in the hope that it will be useful,
9
# but WITHOUT ANY WARRANTY; without even the implied warranty of
10
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11
# GNU General Public License for more details
13
# You should have received a copy of the GNU General Public
14
# License along with this program; if not, write to the
15
# Free Software Foundation, Inc.,
16
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
18
# cmake macro to see if we have libKActivities
20
# KACTIVITIES_INCLUDE_DIR
23
# Redistribution and use is allowed according to the terms of the BSD license.
24
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.
26
if (KACTIVITIES_INCLUDE_DIR AND KACTIVITIES_LIBS)
27
# Already in cache, be silent
28
# This probably means that libKActivities is a part of the current
29
# build or that this script was already invoked
31
set(KActivities_FIND_QUIETLY TRUE)
32
message("KActivities variables already set")
33
endif (KACTIVITIES_INCLUDE_DIR AND KACTIVITIES_LIBS)
35
if (NOT KActivities_FIND_QUIETLY)
36
message("Searching for KActivities")
38
find_path(KACTIVITIES_INCLUDE_DIR NAMES kactivities/consumer.h
41
${INCLUDE_INSTALL_DIR}
44
find_library(KACTIVITIES_LIBS NAMES kactivities
50
include(FindPackageHandleStandardArgs)
51
FIND_PACKAGE_HANDLE_STANDARD_ARGS(i
52
KActivities DEFAULT_MSG KACTIVITIES_LIBS KACTIVITIES_INCLUDE_DIR )
54
mark_as_advanced(KACTIVITIES_INCLUDE_DIR KACTIVITIES_LIBS)
55
endif (NOT KActivities_FIND_QUIETLY)
57
message("-- Found KActivities include dir: ${KACTIVITIES_INCLUDE_DIR}")
58
message("-- Found KActivities lib: ${KACTIVITIES_LIBS}")