summaryrefslogtreecommitdiffstats
path: root/konsolekalendar/CMakeLists.txt
blob: cf920b7d5c8ee0850b71c6319fc4f12767601254 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
#################################################
#
#  (C) 2010-2011 Serghei Amelian
#  serghei (DOT) amelian (AT) gmail.com
#
#  Improvements and feedback are welcome
#
#  This file is released under GPL >= 2
#
#################################################

tde_import( libkmime )
tde_import( ktnef )
tde_import( libkcal )
tde_import( libkdepim )

add_subdirectory( pixmaps )

include_directories(
  ${CMAKE_CURRENT_BINARY_DIR}
  ${CMAKE_BINARY_DIR}
  ${CMAKE_SOURCE_DIR}
  ${CMAKE_SOURCE_DIR}/libkdepim
  ${TDE_INCLUDE_DIR}
  ${TQT_INCLUDE_DIRS}
)

link_directories(
  ${TQT_LIBRARY_DIRS}
)


##### other data ################################

install( FILES konsolekalendar.desktop DESTINATION ${XDG_APPS_INSTALL_DIR} )


##### helper ####################################

macro( process_kcfg _who _out _path _kcfg _kcfgc )
  add_custom_command( OUTPUT ${CMAKE_BINARY_DIR}/${_path}/${_out}
    COMMAND
      mkdir -p ${CMAKE_BINARY_DIR}/${_path}
    COMMAND ${KDE3_KCFGC_EXECUTABLE}
      -d ${CMAKE_BINARY_DIR}/${_path}
      ${CMAKE_SOURCE_DIR}/${_path}/${_kcfg}
      ${CMAKE_SOURCE_DIR}/${_path}/${_kcfgc}
    DEPENDS
      ${CMAKE_SOURCE_DIR}/${_path}/${_kcfg}
      ${CMAKE_SOURCE_DIR}/${_path}/${_kcfgc} )
  set_property( SOURCE ${_who} APPEND
    PROPERTY OBJECT_DEPENDS ${CMAKE_BINARY_DIR}/${_path}/${_out} )
endmacro( )


##### konsolekalendar (executable) ##############

process_kcfg( konsolekalendar.cpp htmlexportsettings.h libkcal
  htmlexportsettings.kcfg htmlexportsettings.kcfgc )

tde_add_executable( konsolekalendar AUTOMOC
  SOURCES
    konsolekalendarepoch.cpp konsolekalendardelete.cpp
    konsolekalendarchange.cpp konsolekalendarvariables.cpp
    konsolekalendaradd.cpp konsolekalendarexports.cpp konsolekalendar.cpp
    stdcalendar.cpp main.cpp
  LINK kdepim-shared
  DESTINATION ${BIN_INSTALL_DIR}
)