mirror of
https://bitbucket.org/librepilot/librepilot.git
synced 2024-11-29 07:24:13 +01:00
Merge branch 'parched/OP-1853_Ground_build_tidy' into rel-15.05
This commit is contained in:
commit
1f3bf070ec
33
Makefile
33
Makefile
@ -53,8 +53,6 @@ DIRS = $(DL_DIR) $(TOOLS_DIR) $(BUILD_DIR) $(PACKAGE_DIR) $(DIST_DIR)
|
|||||||
|
|
||||||
# Set up default build configurations (debug | release)
|
# Set up default build configurations (debug | release)
|
||||||
GCS_BUILD_CONF := release
|
GCS_BUILD_CONF := release
|
||||||
UAVOGEN_BUILD_CONF := release
|
|
||||||
ANDROIDGCS_BUILD_CONF := debug
|
|
||||||
GOOGLE_API_VERSION := 14
|
GOOGLE_API_VERSION := 14
|
||||||
|
|
||||||
# Clean out undesirable variables from the environment and command-line
|
# Clean out undesirable variables from the environment and command-line
|
||||||
@ -119,13 +117,13 @@ include $(ROOT_DIR)/make/tools.mk
|
|||||||
# We almost need to consider autoconf/automake instead of this
|
# We almost need to consider autoconf/automake instead of this
|
||||||
ifeq ($(UNAME), Linux)
|
ifeq ($(UNAME), Linux)
|
||||||
QT_SPEC = linux-g++
|
QT_SPEC = linux-g++
|
||||||
UAVOBJGENERATOR = "$(BUILD_DIR)/uavobjgenerator/uavobjgenerator"
|
UAVOBJGENERATOR = $(BUILD_DIR)/uavobjgenerator/uavobjgenerator
|
||||||
else ifeq ($(UNAME), Darwin)
|
else ifeq ($(UNAME), Darwin)
|
||||||
QT_SPEC = macx-g++
|
QT_SPEC = macx-g++
|
||||||
UAVOBJGENERATOR = "$(BUILD_DIR)/uavobjgenerator/uavobjgenerator"
|
UAVOBJGENERATOR = $(BUILD_DIR)/uavobjgenerator/uavobjgenerator
|
||||||
else ifeq ($(UNAME), Windows)
|
else ifeq ($(UNAME), Windows)
|
||||||
QT_SPEC = win32-g++
|
QT_SPEC = win32-g++
|
||||||
UAVOBJGENERATOR = "$(BUILD_DIR)/uavobjgenerator/$(UAVOGEN_BUILD_CONF)/uavobjgenerator.exe"
|
UAVOBJGENERATOR = $(BUILD_DIR)/uavobjgenerator/uavobjgenerator.exe
|
||||||
endif
|
endif
|
||||||
|
|
||||||
##############################
|
##############################
|
||||||
@ -152,20 +150,14 @@ clean: all_clean
|
|||||||
#
|
#
|
||||||
##############################
|
##############################
|
||||||
|
|
||||||
ifeq ($(V), 1)
|
|
||||||
UAVOGEN_SILENT :=
|
|
||||||
else
|
|
||||||
UAVOGEN_SILENT := silent
|
|
||||||
endif
|
|
||||||
|
|
||||||
UAVOBJGENERATOR_DIR = $(BUILD_DIR)/uavobjgenerator
|
UAVOBJGENERATOR_DIR = $(BUILD_DIR)/uavobjgenerator
|
||||||
DIRS += $(UAVOBJGENERATOR_DIR)
|
DIRS += $(UAVOBJGENERATOR_DIR)
|
||||||
|
|
||||||
.PHONY: uavobjgenerator
|
.PHONY: uavobjgenerator
|
||||||
uavobjgenerator: | $(UAVOBJGENERATOR_DIR)
|
uavobjgenerator $(UAVOBJGENERATOR): | $(UAVOBJGENERATOR_DIR)
|
||||||
$(V1) cd $(UAVOBJGENERATOR_DIR) && \
|
$(V1) cd $(UAVOBJGENERATOR_DIR) && \
|
||||||
$(QMAKE) $(ROOT_DIR)/ground/uavobjgenerator/uavobjgenerator.pro \
|
( [ -f Makefile ] || $(QMAKE) $(ROOT_DIR)/ground/uavobjgenerator/uavobjgenerator.pro \
|
||||||
-spec $(QT_SPEC) -r CONFIG+=$(UAVOGEN_BUILD_CONF) CONFIG+=$(UAVOGEN_SILENT) && \
|
-spec $(QT_SPEC) CONFIG+=$(GCS_BUILD_CONF) CONFIG+=$(GCS_SILENT) ) && \
|
||||||
$(MAKE) --no-print-directory -w
|
$(MAKE) --no-print-directory -w
|
||||||
|
|
||||||
UAVOBJ_TARGETS := gcs flight python matlab java wireshark
|
UAVOBJ_TARGETS := gcs flight python matlab java wireshark
|
||||||
@ -176,15 +168,14 @@ uavobjects: $(addprefix uavobjects_, $(UAVOBJ_TARGETS))
|
|||||||
UAVOBJ_XML_DIR := $(ROOT_DIR)/shared/uavobjectdefinition
|
UAVOBJ_XML_DIR := $(ROOT_DIR)/shared/uavobjectdefinition
|
||||||
UAVOBJ_OUT_DIR := $(BUILD_DIR)/uavobject-synthetics
|
UAVOBJ_OUT_DIR := $(BUILD_DIR)/uavobject-synthetics
|
||||||
|
|
||||||
DIRS += $(UAVOBJ_OUT_DIR)
|
uavobjects_%: uavobjgenerator
|
||||||
|
@$(MKDIR) -p $(UAVOBJ_OUT_DIR)/$*
|
||||||
uavobjects_%: $(UAVOBJ_OUT_DIR) uavobjgenerator
|
$(V1) ( cd $(UAVOBJ_OUT_DIR)/$* && \
|
||||||
$(V1) ( cd $(UAVOBJ_OUT_DIR) && \
|
|
||||||
$(UAVOBJGENERATOR) -$* $(UAVOBJ_XML_DIR) $(ROOT_DIR) ; \
|
$(UAVOBJGENERATOR) -$* $(UAVOBJ_XML_DIR) $(ROOT_DIR) ; \
|
||||||
)
|
)
|
||||||
|
|
||||||
uavobjects_test: $(UAVOBJ_OUT_DIR) uavobjgenerator
|
uavobjects_test: uavobjgenerator
|
||||||
$(V1) $(UAVOBJGENERATOR) -v -none $(UAVOBJ_XML_DIR) $(ROOT_DIR)
|
$(V1) $(UAVOBJGENERATOR) -v $(UAVOBJ_XML_DIR) $(ROOT_DIR)
|
||||||
|
|
||||||
uavobjects_clean:
|
uavobjects_clean:
|
||||||
@$(ECHO) " CLEAN $(call toprel, $(UAVOBJ_OUT_DIR))"
|
@$(ECHO) " CLEAN $(call toprel, $(UAVOBJ_OUT_DIR))"
|
||||||
@ -476,7 +467,7 @@ openpilotgcs_qmake $(OPENPILOTGCS_MAKEFILE): | $(OPENPILOTGCS_DIR)
|
|||||||
-spec $(QT_SPEC) -r CONFIG+=$(GCS_BUILD_CONF) CONFIG+=$(GCS_SILENT) $(GCS_QMAKE_OPTS)
|
-spec $(QT_SPEC) -r CONFIG+=$(GCS_BUILD_CONF) CONFIG+=$(GCS_SILENT) $(GCS_QMAKE_OPTS)
|
||||||
|
|
||||||
.PHONY: openpilotgcs
|
.PHONY: openpilotgcs
|
||||||
openpilotgcs: uavobjects_gcs $(OPENPILOTGCS_MAKEFILE)
|
openpilotgcs: uavobjgenerator $(OPENPILOTGCS_MAKEFILE)
|
||||||
$(V1) $(MAKE) -w -C $(OPENPILOTGCS_DIR)/$(MAKE_DIR);
|
$(V1) $(MAKE) -w -C $(OPENPILOTGCS_DIR)/$(MAKE_DIR);
|
||||||
|
|
||||||
.PHONY: openpilotgcs_clean
|
.PHONY: openpilotgcs_clean
|
||||||
|
@ -19,13 +19,6 @@
|
|||||||
# Release builds may fail because it seems that qt-creator does not
|
# Release builds may fail because it seems that qt-creator does not
|
||||||
# define QTMINGW variable used to copy MinGW DLLs in release builds.
|
# define QTMINGW variable used to copy MinGW DLLs in release builds.
|
||||||
#
|
#
|
||||||
# There is a minor problem with dependencies. qmake needs synthetic
|
|
||||||
# files when it generates GCS Makefiles. But we do not have
|
|
||||||
# uavobjgenerator built yet. So we use the following trick: at make
|
|
||||||
# stage in uavobject-synthetics we rerun qmake for openpilotgcs.pro
|
|
||||||
# and regenerate GCS Makefiles using just built synthetic files.
|
|
||||||
# It takes some extra time but solves the dependency problem.
|
|
||||||
#
|
|
||||||
# Please note that this meta-project is only intended to be used by
|
# Please note that this meta-project is only intended to be used by
|
||||||
# qt-creator users. Top level Makefile handles all dependencies itself
|
# qt-creator users. Top level Makefile handles all dependencies itself
|
||||||
# and does not use ground.pro.
|
# and does not use ground.pro.
|
||||||
@ -38,16 +31,11 @@ TEMPLATE = subdirs
|
|||||||
|
|
||||||
SUBDIRS = \
|
SUBDIRS = \
|
||||||
sub_openpilotgcs \
|
sub_openpilotgcs \
|
||||||
sub_uavobject-synthetics \
|
|
||||||
sub_uavobjgenerator
|
sub_uavobjgenerator
|
||||||
|
|
||||||
# uavobjgenerator
|
# uavobjgenerator
|
||||||
sub_uavobjgenerator.subdir = uavobjgenerator
|
sub_uavobjgenerator.subdir = uavobjgenerator
|
||||||
|
|
||||||
# uavobject-synthetics
|
|
||||||
sub_uavobject-synthetics.subdir = uavobject-synthetics
|
|
||||||
sub_uavobject-synthetics.depends = sub_uavobjgenerator
|
|
||||||
|
|
||||||
# openpilotgcs
|
# openpilotgcs
|
||||||
sub_openpilotgcs.subdir = openpilotgcs
|
sub_openpilotgcs.subdir = openpilotgcs
|
||||||
sub_openpilotgcs.depends = sub_uavobject-synthetics
|
sub_openpilotgcs.depends = sub_uavobjgenerator
|
||||||
|
@ -11,10 +11,6 @@ defineReplace(cleanPath) {
|
|||||||
return($$join(out, /, $$pfx))
|
return($$join(out, /, $$pfx))
|
||||||
}
|
}
|
||||||
|
|
||||||
defineReplace(targetPath) {
|
|
||||||
return($$replace(1, /, $$QMAKE_DIR_SEP))
|
|
||||||
}
|
|
||||||
|
|
||||||
defineReplace(addNewline) {
|
defineReplace(addNewline) {
|
||||||
return($$escape_expand(\\n\\t))
|
return($$escape_expand(\\n\\t))
|
||||||
}
|
}
|
||||||
@ -41,8 +37,8 @@ defineTest(addCopyFileTarget) {
|
|||||||
$${file}.depends = $$src
|
$${file}.depends = $$src
|
||||||
|
|
||||||
# create directory. Better would be an order only dependency
|
# create directory. Better would be an order only dependency
|
||||||
$${file}.commands = -@$(MKDIR) \"$$targetPath($$dirname(dest))\" $$addNewline()
|
$${file}.commands = -@$(MKDIR) \"$$dirname(dest)\" $$addNewline()
|
||||||
$${file}.commands += $(COPY_FILE) \"$$targetPath($$src)\" \"$$targetPath($$dest)\"
|
$${file}.commands += $(COPY_FILE) \"$$src\" \"$$dest\"
|
||||||
|
|
||||||
QMAKE_EXTRA_TARGETS += $$file
|
QMAKE_EXTRA_TARGETS += $$file
|
||||||
POST_TARGETDEPS += $$eval($${file}.target)
|
POST_TARGETDEPS += $$eval($${file}.target)
|
||||||
@ -66,10 +62,10 @@ defineTest(addCopyDirTarget) {
|
|||||||
# Windows does not update directory timestamp if files are modified
|
# Windows does not update directory timestamp if files are modified
|
||||||
win32: $${dir}.depends += FORCE
|
win32: $${dir}.depends += FORCE
|
||||||
|
|
||||||
$${dir}.commands = @rm -rf \"$$targetPath($$dest)\" $$addNewline()
|
$${dir}.commands = @rm -rf \"$$dest\" $$addNewline()
|
||||||
# create directory. Better would be an order only dependency
|
# create directory. Better would be an order only dependency
|
||||||
$${dir}.commands += -@$(MKDIR) \"$$targetPath($$dirname(dest))\" $$addNewline()
|
$${dir}.commands += -@$(MKDIR) \"$$dirname(dest)\" $$addNewline()
|
||||||
$${dir}.commands += $(COPY_DIR) \"$$targetPath($$src)\" \"$$targetPath($$dest)\"
|
$${dir}.commands += $(COPY_DIR) \"$$src\" \"$$dest\"
|
||||||
|
|
||||||
QMAKE_EXTRA_TARGETS += $$dir
|
QMAKE_EXTRA_TARGETS += $$dir
|
||||||
POST_TARGETDEPS += $$eval($${dir}.target)
|
POST_TARGETDEPS += $$eval($${dir}.target)
|
||||||
@ -168,7 +164,6 @@ macx {
|
|||||||
MESAWIN_DIR = $$(MESAWIN_DIR)
|
MESAWIN_DIR = $$(MESAWIN_DIR)
|
||||||
isEmpty(MESAWIN_DIR):MESAWIN_DIR = $${TOOLS_DIR}/mesawin
|
isEmpty(MESAWIN_DIR):MESAWIN_DIR = $${TOOLS_DIR}/mesawin
|
||||||
|
|
||||||
contains(TEMPLATE, vc.*)|contains(TEMPLATE_PREFIX, vc):vcproj = 1
|
|
||||||
GCS_APP_TARGET = openpilotgcs
|
GCS_APP_TARGET = openpilotgcs
|
||||||
|
|
||||||
GCS_QT_PLUGINS_PATH = $$GCS_APP_PATH
|
GCS_QT_PLUGINS_PATH = $$GCS_APP_PATH
|
||||||
|
@ -11,28 +11,23 @@ defineReplace(prependAll) {
|
|||||||
return($$result)
|
return($$result)
|
||||||
}
|
}
|
||||||
|
|
||||||
XMLPATTERNS = $$targetPath($$[QT_INSTALL_BINS]/xmlpatterns)
|
XMLPATTERNS = $$[QT_INSTALL_BINS]/xmlpatterns
|
||||||
LUPDATE = $$targetPath($$[QT_INSTALL_BINS]/lupdate) -locations relative -no-ui-lines -no-sort
|
LUPDATE = $$[QT_INSTALL_BINS]/lupdate -locations relative -no-ui-lines -no-sort
|
||||||
LRELEASE = $$targetPath($$[QT_INSTALL_BINS]/lrelease)
|
LRELEASE = $$[QT_INSTALL_BINS]/lrelease
|
||||||
LCONVERT = $$targetPath($$[QT_INSTALL_BINS]/lconvert)
|
LCONVERT = $$[QT_INSTALL_BINS]/lconvert
|
||||||
|
|
||||||
wd = $$replace(GCS_SOURCE_TREE, /, $$QMAKE_DIR_SEP)
|
|
||||||
|
|
||||||
TRANSLATIONS = $$prependAll(LANGUAGES, $$PWD/openpilotgcs_,.ts)
|
TRANSLATIONS = $$prependAll(LANGUAGES, $$PWD/openpilotgcs_,.ts)
|
||||||
|
|
||||||
MIME_TR_H = $$PWD/mime_tr.h
|
MIME_TR_H = $$PWD/mime_tr.h
|
||||||
|
|
||||||
contains(QT_VERSION, ^4\\.[0-5]\\..*) {
|
for(dir, $$list($$files($$GCS_SOURCE_TREE/src/plugins/*))):MIMETYPES_FILES += $$files($$dir/*.mimetypes.xml)
|
||||||
ts.commands = @echo This Qt version is too old for the ts target. Need Qt 4.6+.
|
MIMETYPES_FILES = \"$$join(MIMETYPES_FILES, \", \")\"
|
||||||
} else {
|
QMAKE_SUBSTITUTES += extract-mimetypes.xq.in
|
||||||
for(dir, $$list($$files($$GCS_SOURCE_TREE/src/plugins/*))):MIMETYPES_FILES += $$files($$dir/*.mimetypes.xml)
|
ts.commands += \
|
||||||
MIMETYPES_FILES = \"$$join(MIMETYPES_FILES, \", \")\"
|
|
||||||
QMAKE_SUBSTITUTES += extract-mimetypes.xq.in
|
|
||||||
ts.commands += \
|
|
||||||
$$XMLPATTERNS -output $$MIME_TR_H $$PWD/extract-mimetypes.xq && \
|
$$XMLPATTERNS -output $$MIME_TR_H $$PWD/extract-mimetypes.xq && \
|
||||||
(cd $$GCS_SOURCE_TREE && $$LUPDATE src $$MIME_TR_H -ts $$TRANSLATIONS) && \
|
(cd $$GCS_SOURCE_TREE && $$LUPDATE src $$MIME_TR_H -ts $$TRANSLATIONS) && \
|
||||||
$$QMAKE_DEL_FILE $$targetPath($$MIME_TR_H)
|
$$QMAKE_DEL_FILE $$MIME_TR_H
|
||||||
}
|
|
||||||
QMAKE_EXTRA_TARGETS += ts
|
QMAKE_EXTRA_TARGETS += ts
|
||||||
|
|
||||||
TEMPLATE = app
|
TEMPLATE = app
|
||||||
@ -43,27 +38,15 @@ LIBS =
|
|||||||
|
|
||||||
updateqm.input = TRANSLATIONS
|
updateqm.input = TRANSLATIONS
|
||||||
updateqm.output = $$GCS_DATA_PATH/translations/${QMAKE_FILE_BASE}.qm
|
updateqm.output = $$GCS_DATA_PATH/translations/${QMAKE_FILE_BASE}.qm
|
||||||
isEmpty(vcproj):updateqm.variable_out = PRE_TARGETDEPS
|
updateqm.variable_out = PRE_TARGETDEPS
|
||||||
updateqm.commands = $$LRELEASE ${QMAKE_FILE_IN} -qm ${QMAKE_FILE_OUT}
|
updateqm.commands = $$LRELEASE ${QMAKE_FILE_IN} -qm ${QMAKE_FILE_OUT}
|
||||||
updateqm.name = LRELEASE ${QMAKE_FILE_IN}
|
updateqm.name = LRELEASE ${QMAKE_FILE_IN}
|
||||||
updateqm.CONFIG += no_link
|
updateqm.CONFIG += no_link
|
||||||
QMAKE_EXTRA_COMPILERS += updateqm
|
QMAKE_EXTRA_COMPILERS += updateqm
|
||||||
|
|
||||||
isEmpty(vcproj) {
|
QMAKE_LINK = @: IGNORE THIS LINE
|
||||||
QMAKE_LINK = @: IGNORE THIS LINE
|
OBJECTS_DIR =
|
||||||
OBJECTS_DIR =
|
win32:CONFIG -= embed_manifest_exe
|
||||||
win32:CONFIG -= embed_manifest_exe
|
|
||||||
} else {
|
|
||||||
CONFIG += console
|
|
||||||
PHONY_DEPS = .
|
|
||||||
phony_src.input = PHONY_DEPS
|
|
||||||
phony_src.output = phony.c
|
|
||||||
phony_src.variable_out = GENERATED_SOURCES
|
|
||||||
phony_src.commands = echo int main() { return 0; } > phony.c
|
|
||||||
phony_src.name = CREATE phony.c
|
|
||||||
phony_src.CONFIG += combine
|
|
||||||
QMAKE_EXTRA_COMPILERS += phony_src
|
|
||||||
}
|
|
||||||
|
|
||||||
qmfiles.files = $$prependAll(LANGUAGES, $$OUT_PWD/openpilotgcs_,.qm)
|
qmfiles.files = $$prependAll(LANGUAGES, $$OUT_PWD/openpilotgcs_,.qm)
|
||||||
qmfiles.path = /share/openpilotgcs/translations
|
qmfiles.path = /share/openpilotgcs/translations
|
||||||
@ -82,7 +65,7 @@ QT_TRANSLATIONS = $$QtQmExists(LANGUAGES)
|
|||||||
|
|
||||||
copyQT_QMs.input = QT_TRANSLATIONS
|
copyQT_QMs.input = QT_TRANSLATIONS
|
||||||
copyQT_QMs.output = $$GCS_DATA_PATH/translations/${QMAKE_FILE_BASE}.qm
|
copyQT_QMs.output = $$GCS_DATA_PATH/translations/${QMAKE_FILE_BASE}.qm
|
||||||
isEmpty(vcproj):copyQT_QMs.variable_out = PRE_TARGETDEPS
|
copyQT_QMs.variable_out = PRE_TARGETDEPS
|
||||||
copyQT_QMs.commands = $(COPY_FILE) ${QMAKE_FILE_IN} ${QMAKE_FILE_OUT}
|
copyQT_QMs.commands = $(COPY_FILE) ${QMAKE_FILE_IN} ${QMAKE_FILE_OUT}
|
||||||
copyQT_QMs.name = Copy ${QMAKE_FILE_IN}
|
copyQT_QMs.name = Copy ${QMAKE_FILE_IN}
|
||||||
copyQT_QMs.CONFIG += no_link
|
copyQT_QMs.CONFIG += no_link
|
||||||
|
@ -26,7 +26,7 @@ SOURCES = version_info.cpp
|
|||||||
|
|
||||||
# Create custom version_info target which generates a real file
|
# Create custom version_info target which generates a real file
|
||||||
version_info.target = $$VERSION_INFO_FILE
|
version_info.target = $$VERSION_INFO_FILE
|
||||||
version_info.commands = -$(MKDIR) $$targetPath($$VERSION_INFO_DIR) $$addNewline()
|
version_info.commands = -$(MKDIR) $$VERSION_INFO_DIR $$addNewline()
|
||||||
version_info.commands += $$VERSION_INFO_COMMAND \
|
version_info.commands += $$VERSION_INFO_COMMAND \
|
||||||
--path=\"$$ROOT_DIR\" \
|
--path=\"$$ROOT_DIR\" \
|
||||||
--template=\"$$VERSION_INFO_TEMPLATE\" \
|
--template=\"$$VERSION_INFO_TEMPLATE\" \
|
||||||
|
@ -19,7 +19,7 @@ isEmpty(TARGET) {
|
|||||||
PLUGINSPECS = $${_PRO_FILE_PWD_}/$${TARGET}.pluginspec
|
PLUGINSPECS = $${_PRO_FILE_PWD_}/$${TARGET}.pluginspec
|
||||||
copy2build.input = PLUGINSPECS
|
copy2build.input = PLUGINSPECS
|
||||||
copy2build.output = $$DESTDIR/${QMAKE_FUNC_FILE_IN_stripSrcDir}
|
copy2build.output = $$DESTDIR/${QMAKE_FUNC_FILE_IN_stripSrcDir}
|
||||||
isEmpty(vcproj):copy2build.variable_out = PRE_TARGETDEPS
|
copy2build.variable_out = PRE_TARGETDEPS
|
||||||
copy2build.commands = $$QMAKE_COPY ${QMAKE_FILE_IN} ${QMAKE_FILE_OUT}
|
copy2build.commands = $$QMAKE_COPY ${QMAKE_FILE_IN} ${QMAKE_FILE_OUT}
|
||||||
copy2build.name = COPY ${QMAKE_FILE_IN}
|
copy2build.name = COPY ${QMAKE_FILE_IN}
|
||||||
copy2build.CONFIG += no_link
|
copy2build.CONFIG += no_link
|
||||||
|
@ -20,7 +20,7 @@ include(../../python.pri)
|
|||||||
|
|
||||||
# Create custom authors target which generates a real file
|
# Create custom authors target which generates a real file
|
||||||
authors.target = $$AUTHORS_FILE
|
authors.target = $$AUTHORS_FILE
|
||||||
authors.commands = -$(MKDIR) $$targetPath($$AUTHORS_DIR) $$addNewline()
|
authors.commands = -$(MKDIR) $$AUTHORS_DIR $$addNewline()
|
||||||
authors.commands += $$AUTHORS_COMMAND \
|
authors.commands += $$AUTHORS_COMMAND \
|
||||||
--infile=\"$$AUTHORS_SOURCE\" \
|
--infile=\"$$AUTHORS_SOURCE\" \
|
||||||
--template=\"$$AUTHORS_TEMPLATE\" \
|
--template=\"$$AUTHORS_TEMPLATE\" \
|
||||||
|
@ -2,5 +2,7 @@ include(uavobjects_dependencies.pri)
|
|||||||
|
|
||||||
# Add the include path to the built-in uavobject include files.
|
# Add the include path to the built-in uavobject include files.
|
||||||
INCLUDEPATH += $$PWD
|
INCLUDEPATH += $$PWD
|
||||||
|
# Add the include path to the generated uavobject include files.
|
||||||
|
INCLUDEPATH += $$shadowed($$PWD)
|
||||||
|
|
||||||
LIBS *= -l$$qtLibraryName(UAVObjects)
|
LIBS *= -l$$qtLibraryName(UAVObjects)
|
||||||
|
@ -25,229 +25,126 @@ SOURCES += \
|
|||||||
|
|
||||||
OTHER_FILES += UAVObjects.pluginspec
|
OTHER_FILES += UAVObjects.pluginspec
|
||||||
|
|
||||||
# Add in all of the synthetic/generated uavobject files
|
UAVOBJ_XML_DIR = $${ROOT_DIR}/shared/uavobjectdefinition
|
||||||
HEADERS += \
|
UAVOBJ_ROOT_DIR = $${ROOT_DIR}
|
||||||
$$UAVOBJECT_SYNTHETICS/statusgrounddrive.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/statusvtolautotakeoff.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/pidstatus.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/statusvtolland.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/vtolselftuningstats.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/accelgyrosettings.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/accessorydesired.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/barosensor.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/airspeedsensor.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/airspeedsettings.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/airspeedstate.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/attitudestate.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/attitudesimulated.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/altitudeholdsettings.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/altitudeholdstatus.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/altitudefiltersettings.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/debuglogsettings.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/debuglogcontrol.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/debuglogstatus.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/debuglogentry.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/ekfconfiguration.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/ekfstatevariance.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/revocalibration.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/revosettings.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/gcstelemetrystats.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/gyrostate.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/gyrosensor.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/accelsensor.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/accelstate.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/magsensor.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/magstate.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/camerastabsettings.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/flighttelemetrystats.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/systemstats.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/systemalarms.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/objectpersistence.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/overosyncstats.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/overosyncsettings.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/systemsettings.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/stabilizationstatus.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/stabilizationsettings.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/stabilizationsettingsbank1.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/stabilizationsettingsbank2.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/stabilizationsettingsbank3.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/stabilizationbank.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/manualcontrolsettings.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/manualcontrolcommand.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/flightmodesettings.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/stabilizationdesired.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/actuatorsettings.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/actuatordesired.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/actuatorcommand.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/gpspositionsensor.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/gpstime.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/gpssatellites.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/gpssettings.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/pathaction.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/pathdesired.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/pathplan.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/pathstatus.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/pathsummary.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/gpsvelocitysensor.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/positionstate.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/flightbatterystate.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/homelocation.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/mixersettings.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/mixerstatus.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/velocitydesired.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/velocitystate.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/groundtruth.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/fixedwingpathfollowersettings.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/fixedwingpathfollowerstatus.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/vtolpathfollowersettings.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/groundpathfollowersettings.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/ratedesired.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/firmwareiapobj.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/i2cstats.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/flightbatterysettings.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/taskinfo.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/callbackinfo.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/flightplanstatus.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/flightplansettings.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/flightplancontrol.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/watchdogstatus.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/nedaccel.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/sonaraltitude.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/flightstatus.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/hwsettings.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/gcsreceiver.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/receiveractivity.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/receiverstatus.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/attitudesettings.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/txpidsettings.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/cameradesired.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/faultsettings.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/poilearnsettings.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/poilocation.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/oplinksettings.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/oplinkstatus.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/oplinkreceiver.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/radiocombridgestats.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/osdsettings.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/waypoint.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/waypointactive.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/mpu6000settings.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/takeofflocation.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/auxmagsensor.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/auxmagsettings.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/gpsextendedstatus.h \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/perfcounter.h
|
|
||||||
|
|
||||||
SOURCES += \
|
win32 {
|
||||||
$$UAVOBJECT_SYNTHETICS/statusgrounddrive.cpp \
|
UAVOBJGENERATOR = ../../../../uavobjgenerator/uavobjgenerator.exe
|
||||||
$$UAVOBJECT_SYNTHETICS/statusvtolautotakeoff.cpp \
|
} else {
|
||||||
$$UAVOBJECT_SYNTHETICS/pidstatus.cpp \
|
UAVOBJGENERATOR = ../../../../uavobjgenerator/uavobjgenerator
|
||||||
$$UAVOBJECT_SYNTHETICS/statusvtolland.cpp \
|
}
|
||||||
$$UAVOBJECT_SYNTHETICS/vtolselftuningstats.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/accelgyrosettings.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/accessorydesired.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/barosensor.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/airspeedsensor.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/airspeedsettings.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/airspeedstate.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/attitudestate.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/attitudesimulated.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/altitudeholdsettings.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/altitudeholdstatus.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/debuglogsettings.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/debuglogcontrol.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/debuglogstatus.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/debuglogentry.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/altitudefiltersettings.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/ekfconfiguration.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/ekfstatevariance.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/revocalibration.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/revosettings.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/gcstelemetrystats.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/accelsensor.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/accelstate.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/gyrostate.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/gyrosensor.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/magsensor.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/magstate.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/camerastabsettings.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/flighttelemetrystats.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/systemstats.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/systemalarms.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/objectpersistence.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/overosyncstats.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/overosyncsettings.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/systemsettings.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/stabilizationstatus.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/stabilizationsettings.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/stabilizationsettingsbank1.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/stabilizationsettingsbank2.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/stabilizationsettingsbank3.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/stabilizationbank.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/manualcontrolsettings.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/manualcontrolcommand.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/flightmodesettings.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/stabilizationdesired.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/actuatorsettings.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/actuatordesired.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/actuatorcommand.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/gpspositionsensor.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/gpstime.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/gpssatellites.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/gpssettings.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/pathaction.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/pathdesired.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/pathplan.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/pathstatus.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/pathsummary.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/gpsvelocitysensor.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/positionstate.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/flightbatterystate.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/homelocation.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/mixersettings.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/mixerstatus.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/velocitydesired.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/velocitystate.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/groundtruth.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/fixedwingpathfollowersettings.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/fixedwingpathfollowerstatus.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/vtolpathfollowersettings.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/groundpathfollowersettings.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/ratedesired.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/firmwareiapobj.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/i2cstats.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/flightbatterysettings.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/taskinfo.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/callbackinfo.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/flightplanstatus.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/flightplansettings.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/flightplancontrol.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/watchdogstatus.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/nedaccel.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/sonaraltitude.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/uavobjectsinit.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/flightstatus.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/hwsettings.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/gcsreceiver.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/receiveractivity.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/receiverstatus.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/attitudesettings.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/txpidsettings.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/cameradesired.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/faultsettings.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/poilearnsettings.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/poilocation.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/oplinksettings.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/oplinkstatus.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/oplinkreceiver.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/radiocombridgestats.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/osdsettings.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/waypoint.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/waypointactive.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/mpu6000settings.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/takeofflocation.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/auxmagsensor.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/auxmagsettings.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/gpsextendedstatus.cpp \
|
|
||||||
$$UAVOBJECT_SYNTHETICS/perfcounter.cpp
|
|
||||||
|
|
||||||
|
# Add in all of the uavobjects
|
||||||
|
UAVOBJS = \
|
||||||
|
$${UAVOBJ_XML_DIR}/statusgrounddrive.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/statusvtolautotakeoff.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/pidstatus.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/statusvtolland.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/vtolselftuningstats.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/accelgyrosettings.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/accessorydesired.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/barosensor.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/airspeedsensor.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/airspeedsettings.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/airspeedstate.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/attitudestate.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/attitudesimulated.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/altitudeholdsettings.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/altitudeholdstatus.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/altitudefiltersettings.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/debuglogsettings.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/debuglogcontrol.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/debuglogstatus.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/debuglogentry.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/ekfconfiguration.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/ekfstatevariance.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/revocalibration.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/revosettings.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/gcstelemetrystats.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/gyrostate.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/gyrosensor.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/accelsensor.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/accelstate.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/magsensor.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/magstate.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/camerastabsettings.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/flighttelemetrystats.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/systemstats.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/systemalarms.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/objectpersistence.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/overosyncstats.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/overosyncsettings.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/systemsettings.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/stabilizationstatus.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/stabilizationsettings.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/stabilizationsettingsbank1.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/stabilizationsettingsbank2.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/stabilizationsettingsbank3.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/stabilizationbank.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/manualcontrolsettings.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/manualcontrolcommand.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/flightmodesettings.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/stabilizationdesired.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/actuatorsettings.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/actuatordesired.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/actuatorcommand.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/gpspositionsensor.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/gpstime.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/gpssatellites.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/gpssettings.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/pathaction.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/pathdesired.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/pathplan.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/pathstatus.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/pathsummary.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/gpsvelocitysensor.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/positionstate.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/flightbatterystate.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/homelocation.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/mixersettings.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/mixerstatus.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/velocitydesired.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/velocitystate.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/groundtruth.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/fixedwingpathfollowersettings.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/fixedwingpathfollowerstatus.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/vtolpathfollowersettings.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/groundpathfollowersettings.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/ratedesired.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/firmwareiapobj.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/i2cstats.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/flightbatterysettings.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/taskinfo.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/callbackinfo.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/flightplanstatus.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/flightplansettings.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/flightplancontrol.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/watchdogstatus.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/nedaccel.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/sonaraltitude.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/flightstatus.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/hwsettings.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/gcsreceiver.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/receiveractivity.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/receiverstatus.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/attitudesettings.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/txpidsettings.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/cameradesired.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/faultsettings.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/poilearnsettings.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/poilocation.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/oplinksettings.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/oplinkstatus.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/oplinkreceiver.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/radiocombridgestats.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/osdsettings.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/waypoint.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/waypointactive.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/mpu6000settings.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/takeofflocation.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/auxmagsensor.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/auxmagsettings.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/gpsextendedstatus.xml \
|
||||||
|
$${UAVOBJ_XML_DIR}/perfcounter.xml
|
||||||
|
|
||||||
|
include(uavobjgenerator.pri)
|
||||||
|
@ -1,9 +1,2 @@
|
|||||||
include(../../plugins/coreplugin/coreplugin.pri)
|
include(../../plugins/coreplugin/coreplugin.pri)
|
||||||
include(../../libs/utils/utils.pri)
|
include(../../libs/utils/utils.pri)
|
||||||
|
|
||||||
# Provide the path to the auto-generated uavobject source files for the GCS.
|
|
||||||
UAVOBJECT_SYNTHETICS=$${GCS_BUILD_TREE}/../uavobject-synthetics/gcs
|
|
||||||
#message(UAVOBJECT_SYNTHETICS is $$UAVOBJECT_SYNTHETICS)
|
|
||||||
|
|
||||||
# Add the include path to the auto-generated uavobject include files.
|
|
||||||
INCLUDEPATH += $$UAVOBJECT_SYNTHETICS
|
|
||||||
|
@ -0,0 +1,39 @@
|
|||||||
|
UAVOBJ_INIT_CPP = uavobjectsinit.cpp
|
||||||
|
UAVOBJ_INIT_CPP_TEMPLATE = $${UAVOBJ_INIT_CPP}.template
|
||||||
|
|
||||||
|
uavobjgenerator.input = UAVOBJS
|
||||||
|
uavobjgenerator.commands = $$shell_path($${UAVOBJGENERATOR}) -gcs $${UAVOBJ_XML_DIR} $${UAVOBJ_ROOT_DIR} ${QMAKE_FILE_BASE}
|
||||||
|
silent:uavobjgenerator.commands = @echo uavobjgenerator -gcs && $${uavobjgenerator.commands}
|
||||||
|
uavobjgenerator_header.depends = $${UAVOBJ_INIT_CPP_TEMPLATE}
|
||||||
|
uavobjgenerator.output = $${UAVOBJ_INIT_CPP}
|
||||||
|
uavobjgenerator.variable_out = SOURCES
|
||||||
|
uavobjgenerator.CONFIG += combine
|
||||||
|
|
||||||
|
QMAKE_EXTRA_COMPILERS += uavobjgenerator
|
||||||
|
|
||||||
|
uavobjgenerator_header.input = UAVOBJS
|
||||||
|
# We don't want any commands here because uavobjgenerator also creates .cpp, but if command is empty no rules are created
|
||||||
|
uavobjgenerator_header.commands = $$escape_expand(\\n)
|
||||||
|
uavobjgenerator_header.depends = $${UAVOBJ_INIT_CPP}
|
||||||
|
uavobjgenerator_header.output = ${QMAKE_FILE_BASE}.h # Actually generated by uavobjgenerator for this depends
|
||||||
|
uavobjgenerator_header.variable_out = UAVOBJS_HEADERS
|
||||||
|
|
||||||
|
QMAKE_EXTRA_COMPILERS += uavobjgenerator_header
|
||||||
|
|
||||||
|
uavobjgenerator_source.input = UAVOBJS
|
||||||
|
# We don't want any commands here because uavobjgenerator also creates .cpp, but if command is empty no rules are created
|
||||||
|
uavobjgenerator_source.commands = $$escape_expand(\\n)
|
||||||
|
uavobjgenerator_source.depends = $${UAVOBJ_INIT_CPP}
|
||||||
|
uavobjgenerator_source.output = ${QMAKE_FILE_BASE}.cpp # Actually generated by uavobjgenerator for this depends
|
||||||
|
uavobjgenerator_source.variable_out = SOURCES
|
||||||
|
|
||||||
|
QMAKE_EXTRA_COMPILERS += uavobjgenerator_source
|
||||||
|
|
||||||
|
# Do our own moc without moc_verify because the files aren't generated when verified
|
||||||
|
load(moc)
|
||||||
|
uavobjgenerator_moc.commands = $$moc_header.commands
|
||||||
|
uavobjgenerator_moc.output = $$moc_header.output
|
||||||
|
uavobjgenerator_moc.input = UAVOBJS_HEADERS
|
||||||
|
uavobjgenerator_moc.variable_out = GENERATED_SOURCES
|
||||||
|
|
||||||
|
QMAKE_EXTRA_COMPILERS += uavobjgenerator_moc
|
@ -1,69 +0,0 @@
|
|||||||
#
|
|
||||||
# Qmake project for UAVObjects generation.
|
|
||||||
# Copyright (c) 2009-2013, The OpenPilot Team, http://www.openpilot.org
|
|
||||||
#
|
|
||||||
|
|
||||||
TEMPLATE = aux
|
|
||||||
|
|
||||||
# Some handy defines
|
|
||||||
defineReplace(targetPath) {
|
|
||||||
return($$replace(1, /, $$QMAKE_DIR_SEP))
|
|
||||||
}
|
|
||||||
|
|
||||||
defineReplace(addNewline) {
|
|
||||||
return($$escape_expand(\\n\\t))
|
|
||||||
}
|
|
||||||
|
|
||||||
# QMAKESPEC should be defined by qmake but sometimes it is not
|
|
||||||
isEmpty(QMAKESPEC) {
|
|
||||||
win32:SPEC = win32-g++
|
|
||||||
macx-g++:SPEC = macx-g++
|
|
||||||
linux-g++:SPEC = linux-g++
|
|
||||||
linux-g++-32:SPEC = linux-g++
|
|
||||||
linux-g++-64:SPEC = linux-g++-64
|
|
||||||
} else {
|
|
||||||
SPEC = $$QMAKESPEC
|
|
||||||
}
|
|
||||||
|
|
||||||
# Some platform-dependent options
|
|
||||||
win32|unix {
|
|
||||||
CONFIG(release, debug|release) {
|
|
||||||
BUILD_CONFIG = release
|
|
||||||
} else {
|
|
||||||
BUILD_CONFIG = debug
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
win32 {
|
|
||||||
# Windows sometimes remembers working directory changed from Makefile, sometimes not.
|
|
||||||
# That's why pushd/popd is used here - to make sure that we know current directory.
|
|
||||||
|
|
||||||
uavobjects.commands += -$(MKDIR) $$targetPath(../uavobject-synthetics) $$addNewline()
|
|
||||||
uavobjects.commands += pushd $$targetPath(../uavobject-synthetics) &&
|
|
||||||
uavobjects.commands += $$targetPath(../uavobjgenerator/$${BUILD_CONFIG}/uavobjgenerator)
|
|
||||||
uavobjects.commands += $$targetPath(../../shared/uavobjectdefinition)
|
|
||||||
uavobjects.commands += $$targetPath(../..) &&
|
|
||||||
uavobjects.commands += popd $$addNewline()
|
|
||||||
|
|
||||||
uavobjects.commands += -$(MKDIR) $$targetPath(../openpilotgcs) $$addNewline()
|
|
||||||
uavobjects.commands += pushd $$targetPath(../openpilotgcs) &&
|
|
||||||
uavobjects.commands += $(QMAKE) -spec $$SPEC CONFIG+=$${BUILD_CONFIG} -r
|
|
||||||
uavobjects.commands += $$targetPath(../../ground/openpilotgcs/)openpilotgcs.pro &&
|
|
||||||
uavobjects.commands += popd $$addNewline()
|
|
||||||
}
|
|
||||||
|
|
||||||
!win32 {
|
|
||||||
uavobjects.commands += $(MKDIR) -p ../uavobject-synthetics $$addNewline()
|
|
||||||
uavobjects.commands += cd ../uavobject-synthetics &&
|
|
||||||
uavobjects.commands += ../uavobjgenerator/uavobjgenerator
|
|
||||||
uavobjects.commands += ../../shared/uavobjectdefinition ../.. &&
|
|
||||||
|
|
||||||
uavobjects.commands += $(MKDIR) -p ../openpilotgcs $$addNewline()
|
|
||||||
uavobjects.commands += cd ../openpilotgcs &&
|
|
||||||
uavobjects.commands += $(QMAKE) ../../ground/openpilotgcs/openpilotgcs.pro
|
|
||||||
uavobjects.commands += -spec $$SPEC CONFIG+=$${BUILD_CONFIG} -r $$addNewline()
|
|
||||||
}
|
|
||||||
|
|
||||||
uavobjects.depends = FORCE
|
|
||||||
QMAKE_EXTRA_TARGETS += uavobjects
|
|
||||||
PRE_TARGETDEPS += uavobjects
|
|
@ -36,7 +36,7 @@ bool UAVObjectGeneratorFlight::generate(UAVObjectParser *parser, QString templat
|
|||||||
QString flightObjInit, objInc, objFileNames, objNames;
|
QString flightObjInit, objInc, objFileNames, objNames;
|
||||||
qint32 sizeCalc;
|
qint32 sizeCalc;
|
||||||
flightCodePath = QDir(templatepath + QString(FLIGHT_CODE_DIR));
|
flightCodePath = QDir(templatepath + QString(FLIGHT_CODE_DIR));
|
||||||
flightOutputPath = QDir(outputpath + QString("flight"));
|
flightOutputPath = QDir(outputpath);
|
||||||
flightOutputPath.mkpath(flightOutputPath.absolutePath());
|
flightOutputPath.mkpath(flightOutputPath.absolutePath());
|
||||||
|
|
||||||
flightCodeTemplate = readFile(flightCodePath.absoluteFilePath("uavobject.c.template"));
|
flightCodeTemplate = readFile(flightCodePath.absoluteFilePath("uavobject.c.template"));
|
||||||
|
@ -36,7 +36,7 @@ bool UAVObjectGeneratorGCS::generate(UAVObjectParser *parser, QString templatepa
|
|||||||
<< "UINT8" << "UINT16" << "UINT32" << "FLOAT32" << "ENUM";
|
<< "UINT8" << "UINT16" << "UINT32" << "FLOAT32" << "ENUM";
|
||||||
|
|
||||||
gcsCodePath = QDir(templatepath + QString(GCS_CODE_DIR));
|
gcsCodePath = QDir(templatepath + QString(GCS_CODE_DIR));
|
||||||
gcsOutputPath = QDir(outputpath + QString("gcs"));
|
gcsOutputPath = QDir(outputpath);
|
||||||
gcsOutputPath.mkpath(gcsOutputPath.absolutePath());
|
gcsOutputPath.mkpath(gcsOutputPath.absolutePath());
|
||||||
|
|
||||||
gcsCodeTemplate = readFile(gcsCodePath.absoluteFilePath("uavobject.cpp.template"));
|
gcsCodeTemplate = readFile(gcsCodePath.absoluteFilePath("uavobject.cpp.template"));
|
||||||
|
@ -37,7 +37,7 @@ bool UAVObjectGeneratorJava::generate(UAVObjectParser *parser, QString templatep
|
|||||||
<< "UINT8" << "UINT16" << "UINT32" << "FLOAT32" << "ENUM";
|
<< "UINT8" << "UINT16" << "UINT32" << "FLOAT32" << "ENUM";
|
||||||
|
|
||||||
javaCodePath = QDir(templatepath + QString(JAVA_TEMPLATE_DIR));
|
javaCodePath = QDir(templatepath + QString(JAVA_TEMPLATE_DIR));
|
||||||
javaOutputPath = QDir(outputpath + QString("java"));
|
javaOutputPath = QDir(outputpath);
|
||||||
javaOutputPath.mkpath(javaOutputPath.absolutePath());
|
javaOutputPath.mkpath(javaOutputPath.absolutePath());
|
||||||
|
|
||||||
javaCodeTemplate = readFile(javaCodePath.absoluteFilePath("uavobject.java.template"));
|
javaCodeTemplate = readFile(javaCodePath.absoluteFilePath("uavobject.java.template"));
|
||||||
|
@ -36,7 +36,7 @@ bool UAVObjectGeneratorMatlab::generate(UAVObjectParser *parser, QString templat
|
|||||||
<< "1" << "2" << "4" << "4" << "1";
|
<< "1" << "2" << "4" << "4" << "1";
|
||||||
|
|
||||||
QDir matlabTemplatePath = QDir(templatepath + QString(MATLAB_CODE_DIR));
|
QDir matlabTemplatePath = QDir(templatepath + QString(MATLAB_CODE_DIR));
|
||||||
QDir matlabOutputPath = QDir(outputpath + QString("matlab"));
|
QDir matlabOutputPath = QDir(outputpath);
|
||||||
matlabOutputPath.mkpath(matlabOutputPath.absolutePath());
|
matlabOutputPath.mkpath(matlabOutputPath.absolutePath());
|
||||||
|
|
||||||
QString matlabCodeTemplate = readFile(matlabTemplatePath.absoluteFilePath("uavobject.m.template"));
|
QString matlabCodeTemplate = readFile(matlabTemplatePath.absoluteFilePath("uavobject.m.template"));
|
||||||
|
@ -31,7 +31,7 @@ bool UAVObjectGeneratorPython::generate(UAVObjectParser *parser, QString templat
|
|||||||
{
|
{
|
||||||
// Load template and setup output directory
|
// Load template and setup output directory
|
||||||
pythonCodePath = QDir(templatepath + QString("flight/modules/FlightPlan/lib"));
|
pythonCodePath = QDir(templatepath + QString("flight/modules/FlightPlan/lib"));
|
||||||
pythonOutputPath = QDir(outputpath + QString("python"));
|
pythonOutputPath = QDir(outputpath);
|
||||||
pythonOutputPath.mkpath(pythonOutputPath.absolutePath());
|
pythonOutputPath.mkpath(pythonOutputPath.absolutePath());
|
||||||
pythonCodeTemplate = readFile(pythonCodePath.absoluteFilePath("uavobject.pyt.template"));
|
pythonCodeTemplate = readFile(pythonCodePath.absoluteFilePath("uavobject.pyt.template"));
|
||||||
if (pythonCodeTemplate.isEmpty()) {
|
if (pythonCodeTemplate.isEmpty()) {
|
||||||
|
@ -37,7 +37,7 @@ bool UAVObjectGeneratorWireshark::generate(UAVObjectParser *parser, QString temp
|
|||||||
|
|
||||||
wiresharkCodePath = QDir(templatepath + QString("ground/openpilotgcs/src/plugins/uavobjects/wireshark"));
|
wiresharkCodePath = QDir(templatepath + QString("ground/openpilotgcs/src/plugins/uavobjects/wireshark"));
|
||||||
|
|
||||||
wiresharkOutputPath = QDir(outputpath + QString("wireshark"));
|
wiresharkOutputPath = QDir(outputpath);
|
||||||
wiresharkOutputPath.mkpath(wiresharkOutputPath.absolutePath());
|
wiresharkOutputPath.mkpath(wiresharkOutputPath.absolutePath());
|
||||||
|
|
||||||
wiresharkCodeTemplate = readFile(wiresharkCodePath.absoluteFilePath("op-uavobjects/packet-op-uavobjects.c.template"));
|
wiresharkCodeTemplate = readFile(wiresharkCodePath.absoluteFilePath("op-uavobjects/packet-op-uavobjects.c.template"));
|
||||||
|
@ -47,7 +47,7 @@ using namespace std;
|
|||||||
*/
|
*/
|
||||||
void usage()
|
void usage()
|
||||||
{
|
{
|
||||||
cout << "Usage: uavobjectgenerator [-gcs] [-flight] [-java] [-python] [-matlab] [-wireshark] [-none] [-v] xml_path template_base [UAVObj1] ... [UAVObjN]" << endl;
|
cout << "Usage: uavobjectgenerator [language] [-v] xml_path template_base [UAVObj1] ... [UAVObjN]" << endl;
|
||||||
cout << "Languages: " << endl;
|
cout << "Languages: " << endl;
|
||||||
cout << "\t-gcs build groundstation code" << endl;
|
cout << "\t-gcs build groundstation code" << endl;
|
||||||
cout << "\t-flight build flight code" << endl;
|
cout << "\t-flight build flight code" << endl;
|
||||||
@ -55,9 +55,8 @@ void usage()
|
|||||||
cout << "\t-python build python code" << endl;
|
cout << "\t-python build python code" << endl;
|
||||||
cout << "\t-matlab build matlab code" << endl;
|
cout << "\t-matlab build matlab code" << endl;
|
||||||
cout << "\t-wireshark build wireshark plugin" << endl;
|
cout << "\t-wireshark build wireshark plugin" << endl;
|
||||||
cout << "\tIf no language is specified ( and not -none ) -> all are built." << endl;
|
cout << "\tIf no language is specified none are built - just parse xmls." << endl;
|
||||||
cout << "Misc: " << endl;
|
cout << "Misc: " << endl;
|
||||||
cout << "\t-none build no language - just parse xml's" << endl;
|
|
||||||
cout << "\t-h this help" << endl;
|
cout << "\t-h this help" << endl;
|
||||||
cout << "\t-v verbose" << endl;
|
cout << "\t-v verbose" << endl;
|
||||||
cout << "\tinput_path path to UAVObject definition (.xml) files." << endl;
|
cout << "\tinput_path path to UAVObject definition (.xml) files." << endl;
|
||||||
@ -109,9 +108,7 @@ int main(int argc, char *argv[])
|
|||||||
bool do_python = (arguments_stringlist.removeAll("-python") > 0);
|
bool do_python = (arguments_stringlist.removeAll("-python") > 0);
|
||||||
bool do_matlab = (arguments_stringlist.removeAll("-matlab") > 0);
|
bool do_matlab = (arguments_stringlist.removeAll("-matlab") > 0);
|
||||||
bool do_wireshark = (arguments_stringlist.removeAll("-wireshark") > 0);
|
bool do_wireshark = (arguments_stringlist.removeAll("-wireshark") > 0);
|
||||||
bool do_none = (arguments_stringlist.removeAll("-none") > 0); //
|
|
||||||
|
|
||||||
bool do_all = ((do_gcs || do_flight || do_java || do_python || do_matlab) == false);
|
|
||||||
bool do_allObjects = true;
|
bool do_allObjects = true;
|
||||||
|
|
||||||
if (arguments_stringlist.length() >= 2) {
|
if (arguments_stringlist.length() >= 2) {
|
||||||
@ -205,47 +202,33 @@ int main(int argc, char *argv[])
|
|||||||
cout << "used units: " << parser->all_units.join(",").toStdString() << endl;
|
cout << "used units: " << parser->all_units.join(",").toStdString() << endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (do_none) {
|
if (do_flight) {
|
||||||
return RETURN_OK;
|
|
||||||
}
|
|
||||||
|
|
||||||
// generate flight code if wanted
|
// generate flight code if wanted
|
||||||
if (do_flight | do_all) {
|
|
||||||
cout << "generating flight code" << endl;
|
cout << "generating flight code" << endl;
|
||||||
UAVObjectGeneratorFlight flightgen;
|
UAVObjectGeneratorFlight flightgen;
|
||||||
flightgen.generate(parser, templatepath, outputpath);
|
flightgen.generate(parser, templatepath, outputpath);
|
||||||
}
|
} else if (do_gcs) {
|
||||||
|
|
||||||
// generate gcs code if wanted
|
// generate gcs code if wanted
|
||||||
if (do_gcs | do_all) {
|
|
||||||
cout << "generating gcs code" << endl;
|
cout << "generating gcs code" << endl;
|
||||||
UAVObjectGeneratorGCS gcsgen;
|
UAVObjectGeneratorGCS gcsgen;
|
||||||
gcsgen.generate(parser, templatepath, outputpath);
|
gcsgen.generate(parser, templatepath, outputpath);
|
||||||
}
|
} else if (do_java) {
|
||||||
|
|
||||||
// generate java code if wanted
|
// generate java code if wanted
|
||||||
if (do_java | do_all) {
|
|
||||||
cout << "generating java code" << endl;
|
cout << "generating java code" << endl;
|
||||||
UAVObjectGeneratorJava javagen;
|
UAVObjectGeneratorJava javagen;
|
||||||
javagen.generate(parser, templatepath, outputpath);
|
javagen.generate(parser, templatepath, outputpath);
|
||||||
}
|
} else if (do_python) {
|
||||||
|
|
||||||
// generate python code if wanted
|
// generate python code if wanted
|
||||||
if (do_python | do_all) {
|
|
||||||
cout << "generating python code" << endl;
|
cout << "generating python code" << endl;
|
||||||
UAVObjectGeneratorPython pygen;
|
UAVObjectGeneratorPython pygen;
|
||||||
pygen.generate(parser, templatepath, outputpath);
|
pygen.generate(parser, templatepath, outputpath);
|
||||||
}
|
} else if (do_matlab) {
|
||||||
|
|
||||||
// generate matlab code if wanted
|
// generate matlab code if wanted
|
||||||
if (do_matlab | do_all) {
|
|
||||||
cout << "generating matlab code" << endl;
|
cout << "generating matlab code" << endl;
|
||||||
UAVObjectGeneratorMatlab matlabgen;
|
UAVObjectGeneratorMatlab matlabgen;
|
||||||
matlabgen.generate(parser, templatepath, outputpath);
|
matlabgen.generate(parser, templatepath, outputpath);
|
||||||
}
|
} else if (do_wireshark) {
|
||||||
|
|
||||||
// generate wireshark plugin if wanted
|
// generate wireshark plugin if wanted
|
||||||
if (do_wireshark | do_all) {
|
|
||||||
cout << "generating wireshark code" << endl;
|
cout << "generating wireshark code" << endl;
|
||||||
UAVObjectGeneratorWireshark wiresharkgen;
|
UAVObjectGeneratorWireshark wiresharkgen;
|
||||||
wiresharkgen.generate(parser, templatepath, outputpath);
|
wiresharkgen.generate(parser, templatepath, outputpath);
|
||||||
|
@ -12,6 +12,7 @@ TARGET = uavobjgenerator
|
|||||||
CONFIG += console
|
CONFIG += console
|
||||||
CONFIG -= app_bundle
|
CONFIG -= app_bundle
|
||||||
TEMPLATE = app
|
TEMPLATE = app
|
||||||
|
DESTDIR = $$OUT_PWD # Set a consistent output dir on windows
|
||||||
SOURCES += main.cpp \
|
SOURCES += main.cpp \
|
||||||
uavobjectparser.cpp \
|
uavobjectparser.cpp \
|
||||||
generators/generator_io.cpp \
|
generators/generator_io.cpp \
|
||||||
|
Loading…
Reference in New Issue
Block a user