diff --git a/mros2_header_generator/header_includer.tpl b/mros2_header_generator/header_includer.tpl deleted file mode 100644 index ed76062..0000000 --- a/mros2_header_generator/header_includer.tpl +++ /dev/null @@ -1 +0,0 @@ -#include "../workspace/{{app}}/templates.hpp" \ No newline at end of file diff --git a/mros2_header_generator/templates_generator.py b/mros2_header_generator/templates_generator.py index 90e9698..1eeae9f 100644 --- a/mros2_header_generator/templates_generator.py +++ b/mros2_header_generator/templates_generator.py @@ -43,12 +43,7 @@ def main(): datatext = template.render({ "includeFiles":includeFiles, "pubMsgTypes":pubMsgTypes, "subMsgTypes":subMsgTypes }) with open(os.path.join(app+"/templates.hpp"), "wb") as f: f.write(datatext.encode('utf-8')) - - env = Environment(loader=FileSystemLoader('../mros2/mros2_header_generator')) - template = env.get_template('header_includer.tpl') - datatext = template.render({ "app": app }) - with open(os.path.join("../header_includer/header_includer.hpp"), "wb") as f: - f.write(datatext.encode('utf-8')) - + + if __name__ == "__main__": - main() \ No newline at end of file + main() diff --git a/src/mros2.cpp b/src/mros2.cpp index 45011c1..a2c8014 100644 --- a/src/mros2.cpp +++ b/src/mros2.cpp @@ -274,8 +274,7 @@ void setTrue(void* args) *static_cast(args) = true; } - /* - * specialize template functions + * specialize template functions described in platform's workspace */ -#include "../../header_includer/header_includer.hpp" \ No newline at end of file +#include "templates.hpp"