CMakeLists.txt 3.2 KB
Newer Older
1

2 3 4 5 6 7 8
ADD_DEFINITIONS(
	${KDE4_DEFINITIONS} 
	${QT_DEFINITIONS} 
	-fexceptions 
	-DDATA_INSTALL_DIR="\\\"${DATA_INSTALL_DIR}\\\"" 
	-DSHARE_INSTALL_PREFIX="\\\"${SHARE_INSTALL_PREFIX}\\\""  
)
9

10
MESSAGE("CMAKE_BUILD_TYPE = ${CMAKE_BUILD_TYPE}")
11

12
IF(${CMAKE_BUILD_TYPE} MATCHES Release)
13 14 15
	MESSAGE("NO DEBUG OUTPUT")
	ADD_DEFINITIONS( -DQT_NO_DEBUG_OUTPUT )
ENDIF(${CMAKE_BUILD_TYPE} MATCHES Release)
16 17

SET ( KDE4_KABC_LIBS  -lkabc )
18

19
SET(	sflphone_client_kde_SRCS
20
	SFLPhoneView.cpp
21
	SFLPhone.cpp
22
        SFLPhoneapplication.cpp
23
	SFLPhoneTray.cpp
24 25 26 27 28
	main.cpp
	sflphone_const.h
	Account.cpp
	AccountList.cpp
	Call.cpp
29 30 31
	#CallList.cpp
	#CallTreeView.cpp
	#CallTreeModel.cpp
32
	CallTreeItem.cpp
33 34 35 36 37 38 39 40
	configurationmanager_interface_singleton.cpp
	callmanager_interface_singleton.cpp
	instance_interface_singleton.cpp
	AccountWizard.cpp
	AccountItemWidget.cpp
	ActionSetAccountFirst.cpp
	Contact.cpp
	ContactItemWidget.cpp
41 42
	conf/ConfigurationDialog.cpp
	conf/dlggeneral.cpp
43 44 45 46 47
	conf/dlgdisplay.cpp
	conf/dlgaccounts.cpp
	conf/dlgaudio.cpp
	conf/dlgaddressbook.cpp
	conf/dlghooks.cpp
48
	conf/ConfigurationSkeleton.cpp
49
	Dialpad.cpp
50
	Codec.cpp
51
	Item.cpp
52
	AccountListModel.cpp
53 54
        CallModel.cpp
        #CallTreeWidget.cpp
55 56 57 58 59 60 61 62 63
)
 

# generate rules for building source files from the resources
SET(QtApp_RCCS qrc/resources.qrc)
QT4_ADD_RESOURCES(QtApp_RCC_SRCS ${QtApp_RCCS})


# Build dbus interfaces
64
SET ( dbus_xml_introspecs_path ${CMAKE_CURRENT_SOURCE_DIR}/dbus/)
65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109

# configuration manager interface
SET ( configurationmanager_xml  ${dbus_xml_introspecs_path}/configurationmanager-introspec.xml )

SET_SOURCE_FILES_PROPERTIES(
   ${configurationmanager_xml}
   PROPERTIES 
   CLASSNAME ConfigurationManagerInterface
   INCLUDE "dbus/metatypes.h") 

QT4_ADD_DBUS_INTERFACE(
   sflphone_client_kde_SRCS 
   ${configurationmanager_xml}
   configurationmanager_dbus_interface)

# call manager interface
SET ( callmanager_xml  ${dbus_xml_introspecs_path}/callmanager-introspec.xml )

SET_SOURCE_FILES_PROPERTIES(
   ${callmanager_xml}
   PROPERTIES 
   CLASSNAME CallManagerInterface
   INCLUDE "dbus/metatypes.h") 

QT4_ADD_DBUS_INTERFACE(
   sflphone_client_kde_SRCS 
   ${callmanager_xml}
   callmanager_dbus_interface)

# instance interface
SET ( instance_xml  ${dbus_xml_introspecs_path}/instance-introspec.xml )

SET_SOURCE_FILES_PROPERTIES(
   ${instance_xml}
   PROPERTIES 
   CLASSNAME InstanceInterface
   INCLUDE "dbus/metatypes.h") 
   
QT4_ADD_DBUS_INTERFACE(
   sflphone_client_kde_SRCS 
   ${instance_xml}
   instance_dbus_interface)


# kde4_automoc(${sflphone_client_kde_SRCS})
110 111 112 113 114 115 116 117
SET(    config_ui_files
	conf/dlggeneralbase.ui
	conf/dlgdisplaybase.ui
	conf/dlgaccountsbase.ui
	conf/dlgaudiobase.ui
	conf/dlgaddressbookbase.ui
	conf/dlghooksbase.ui
)
118

119
KDE4_ADD_UI_FILES(sflphone_client_kde_SRCS ui/SFLPhoneView_base.ui  ${config_ui_files}  )
120

121
KDE4_ADD_KCFG_FILES(sflphone_client_kde_SRCS conf/kcfg_settings.kcfgc)
122
INSTALL(FILES conf/sflphone-client-kde.kcfg DESTINATION ${KCFG_INSTALL_DIR})
123

124 125 126 127 128 129 130 131 132 133
KDE4_ADD_EXECUTABLE(sflphone-client-kde ${sflphone_client_kde_SRCS} ${QtApp_RCC_SRCS})

TARGET_LINK_LIBRARIES(sflphone-client-kde ${KDE4_KDEUI_LIBS} ${KDE4_KIO_LIBS} ${KDE4_KABC_LIBS})


########### install files ###############

INSTALL(TARGETS sflphone-client-kde DESTINATION ${BIN_INSTALL_DIR})