diff options
author | axis <qt-info@nokia.com> | 2009-04-24 11:34:15 (GMT) |
---|---|---|
committer | axis <qt-info@nokia.com> | 2009-04-24 11:34:15 (GMT) |
commit | 8f427b2b914d5b575a4a7c0ed65d2fb8f45acc76 (patch) | |
tree | a17e1a767a89542ab59907462206d7dcf2e504b2 /mkspecs/features/dbusinterfaces.prf | |
download | Qt-8f427b2b914d5b575a4a7c0ed65d2fb8f45acc76.zip Qt-8f427b2b914d5b575a4a7c0ed65d2fb8f45acc76.tar.gz Qt-8f427b2b914d5b575a4a7c0ed65d2fb8f45acc76.tar.bz2 |
Long live Qt for S60!
Diffstat (limited to 'mkspecs/features/dbusinterfaces.prf')
-rw-r--r-- | mkspecs/features/dbusinterfaces.prf | 45 |
1 files changed, 45 insertions, 0 deletions
diff --git a/mkspecs/features/dbusinterfaces.prf b/mkspecs/features/dbusinterfaces.prf new file mode 100644 index 0000000..c32597a --- /dev/null +++ b/mkspecs/features/dbusinterfaces.prf @@ -0,0 +1,45 @@ +load(moc) + +isEmpty(QMAKE_QDBUSXML2CPP) { + win32:QMAKE_QDBUSXML2CPP = $$[QT_INSTALL_BINS]\qdbusxml2cpp.exe + else:QMAKE_QDBUSXML2CPP = $$[QT_INSTALL_BINS]/qdbusxml2cpp +} + +for(DBUS_INTERFACE, $$list($$unique(DBUS_INTERFACES))) { + + !contains(DBUS_INTERFACE, .*\w\.xml$) { + warning("Invalid D-BUS interface : '$${DBUS_INTERFACE}', please use 'com.mydomain.myinterface.xml' instead.") + next() + } + + DBUS_INTERFACE_LIST += $${DBUS_INTERFACE} +} + +dbus_interface_header.commands = $$QMAKE_QDBUSXML2CPP -p ${QMAKE_FILE_OUT}: ${QMAKE_FILE_IN} +dbus_interface_header.output_function = dbus_interface_header_output +dbus_interface_header.name = DBUSXML2CPP INTERFACE HEADER ${QMAKE_FILE_IN} +dbus_interface_header.variable_out = DBUS_INTERFACE_HEADERS +dbus_interface_header.input = DBUS_INTERFACE_LIST + +defineReplace(dbus_interface_header_output) { + return("$$lower($$section($$list($$basename(1)),.,-2,-2))_interface.h") +} + +dbus_interface_source.commands = $$QMAKE_QDBUSXML2CPP -i ${QMAKE_FILE_OUT_BASE}.h -p :${QMAKE_FILE_OUT} ${QMAKE_FILE_IN} +dbus_interface_source.output_function = dbus_interface_source_output +dbus_interface_source.name = DBUSXML2CPP INTERFACE SOURCE ${QMAKE_FILE_IN} +dbus_interface_source.variable_out = SOURCES +dbus_interface_source.input = DBUS_INTERFACE_LIST + +dbus_interface_moc.commands = $$moc_header.commands +dbus_interface_moc.output = $$moc_header.output +dbus_interface_moc.depends = $$dbus_interface_header.output +dbus_interface_moc.input = DBUS_INTERFACE_HEADERS +dbus_interface_moc.variable_out = GENERATED_SOURCES +dbus_interface_moc.name = $$moc_header.name + +defineReplace(dbus_interface_source_output) { + return("$$lower($$section($$list($$basename(1)),.,-2,-2))_interface.cpp") +} + +QMAKE_EXTRA_COMPILERS += dbus_interface_header dbus_interface_source dbus_interface_moc |