|
|
@ -32,6 +32,13 @@ function( add_dbus_xml option basename classname namespace xmlfile )
|
|
|
|
add_custom_command( OUTPUT ${basename}.cpp ${basename}.h
|
|
|
|
add_custom_command( OUTPUT ${basename}.cpp ${basename}.h
|
|
|
|
COMMAND ${DBUSXML2QT3_EXECUTABLE} -${option} ${basename} ${classname} -N ${namespace} ${INTROSPECTIONPATH}/${xmlfile} 2>/dev/null
|
|
|
|
COMMAND ${DBUSXML2QT3_EXECUTABLE} -${option} ${basename} ${classname} -N ${namespace} ${INTROSPECTIONPATH}/${xmlfile} 2>/dev/null
|
|
|
|
DEPENDS ${INTROSPECTIONPATH}/${xmlfile} )
|
|
|
|
DEPENDS ${INTROSPECTIONPATH}/${xmlfile} )
|
|
|
|
|
|
|
|
if( "${option}" STREQUAL "p" )
|
|
|
|
|
|
|
|
add_custom_command( OUTPUT ${basename}.moc
|
|
|
|
|
|
|
|
COMMAND ${TMOC_EXECUTABLE} ${basename}.h -o ${basename}.moc
|
|
|
|
|
|
|
|
DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/${basename}.h )
|
|
|
|
|
|
|
|
set_property( SOURCE ${CMAKE_CURRENT_BINARY_DIR}/${basename}.cpp APPEND
|
|
|
|
|
|
|
|
PROPERTY OBJECT_DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/${basename}.moc )
|
|
|
|
|
|
|
|
endif( )
|
|
|
|
endfunction( )
|
|
|
|
endfunction( )
|
|
|
|
|
|
|
|
|
|
|
|
add_dbus_xml( p networkmanagerproxy NetworkManagerProxy DBus nm-manager.xml )
|
|
|
|
add_dbus_xml( p networkmanagerproxy NetworkManagerProxy DBus nm-manager.xml )
|
|
|
@ -46,33 +53,15 @@ add_dbus_xml( p activeconnectionproxy ActiveConnectionProxy DBus nm-active-conne
|
|
|
|
add_dbus_xml( p vpnconnectionproxy VPNConnectionProxy DBus nm-vpn-connection-only.xml )
|
|
|
|
add_dbus_xml( p vpnconnectionproxy VPNConnectionProxy DBus nm-vpn-connection-only.xml )
|
|
|
|
add_dbus_xml( p vpnpluginproxy VPNPluginProxy DBus nm-vpn-plugin.xml )
|
|
|
|
add_dbus_xml( p vpnpluginproxy VPNPluginProxy DBus nm-vpn-plugin.xml )
|
|
|
|
add_dbus_xml( i networkmanagersettings SettingsInterface DBus nm-settings.xml )
|
|
|
|
add_dbus_xml( i networkmanagersettings SettingsInterface DBus nm-settings.xml )
|
|
|
|
add_dbus_xml( i connection "" DBus nm-exported-connection.xml )
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
add_custom_command( OUTPUT connectionnode.cpp connectionnode.h introspectableinterface.cpp introspectableinterface.h
|
|
|
|
|
|
|
|
COMMAND ${DBUSXML2QT3_EXECUTABLE} -n connectionnode -c ConnectionNode -N DBus ${INTROSPECTIONPATH}/nm-exported-connection.xml 2>/dev/null
|
|
|
|
|
|
|
|
COMMAND sed s/\#include\\ \\"secrets.h\\"// connectionnode.cpp > connectionnode.cpp_tmp
|
|
|
|
|
|
|
|
COMMAND sed s/\#include\\ \\"introspectable.h\\"/\#include\\ \\"introspectableinterface.h\\"/ connectionnode.cpp_tmp > connectionnode.cpp
|
|
|
|
|
|
|
|
COMMAND rm -f connectionnode.cpp_tmp
|
|
|
|
|
|
|
|
DEPENDS ${INTROSPECTIONPATH}/nm-exported-connection.xml )
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# generate moc files
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
set( MOCHEADERS accesspointproxy.h deviceproxy.h networkmanagerproxy.h networkmanagervpnproxy.h wiredproxy.h
|
|
|
|
add_custom_command(
|
|
|
|
wirelessproxy.h activeconnectionproxy.h vpnconnectionproxy.h vpnpluginproxy.h gsmproxy.h cdmaproxy.h )
|
|
|
|
OUTPUT
|
|
|
|
|
|
|
|
connection.cpp connection.h
|
|
|
|
foreach( _header_file ${MOCHEADERS} )
|
|
|
|
connectionnode.cpp connectionnode.h
|
|
|
|
get_filename_component( _basename "${_header_file}" NAME_WE )
|
|
|
|
introspectableInterface.cpp introspectableInterface.h
|
|
|
|
set( _moc_file ${_basename}.moc )
|
|
|
|
COMMAND ${DBUSXML2QT3_EXECUTABLE} -i connection -n connectionnode -c ConnectionNode -N DBus ${INTROSPECTIONPATH}/nm-exported-connection.xml 2>/dev/null
|
|
|
|
list( APPEND _moc_files ${_moc_file} )
|
|
|
|
DEPENDS ${INTROSPECTIONPATH}/nm-exported-connection.xml
|
|
|
|
add_custom_command( OUTPUT ${_moc_file}
|
|
|
|
)
|
|
|
|
COMMAND ${TMOC_EXECUTABLE} ${_header_file} -o ${_moc_file}
|
|
|
|
|
|
|
|
DEPENDS ${_header_file} )
|
|
|
|
|
|
|
|
endforeach( )
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
add_custom_command( OUTPUT mocfiles.cpp
|
|
|
|
|
|
|
|
COMMAND cat ${_moc_files} > mocfiles.cpp
|
|
|
|
|
|
|
|
DEPENDS ${_moc_files} )
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# build the library
|
|
|
|
# build the library
|
|
|
@ -82,7 +71,7 @@ tde_add_library( knm_dbus STATIC_PIC
|
|
|
|
networkmanagerproxy.cpp networkmanagervpnproxy.cpp
|
|
|
|
networkmanagerproxy.cpp networkmanagervpnproxy.cpp
|
|
|
|
deviceproxy.cpp wiredproxy.cpp wirelessproxy.cpp
|
|
|
|
deviceproxy.cpp wiredproxy.cpp wirelessproxy.cpp
|
|
|
|
accesspointproxy.cpp networkmanagersettings.cpp
|
|
|
|
accesspointproxy.cpp networkmanagersettings.cpp
|
|
|
|
connection.cpp connectionnode.cpp introspectableinterface.cpp
|
|
|
|
connection.cpp connectionnode.cpp introspectableInterface.cpp
|
|
|
|
mocfiles.cpp activeconnectionproxy.cpp vpnconnectionproxy.cpp
|
|
|
|
activeconnectionproxy.cpp vpnconnectionproxy.cpp
|
|
|
|
vpnpluginproxy.cpp gsmproxy.cpp cdmaproxy.cpp
|
|
|
|
vpnpluginproxy.cpp gsmproxy.cpp cdmaproxy.cpp
|
|
|
|
)
|
|
|
|
)
|
|
|
|