How can I add new modules ?
yyykkkyyy opened this issue · comments
Hi, 'm really appreciate this wonderful library.
By the way, I'd like to add some original new modules.
I made a directory which is named "my-module" and I also created a sub-directory "modules" into the "my-module" directory.
I put some C files in the "my-module/modules" directory.
I'd like to include some JerryScript header files like #include jrt.h
.
But I cannot do that. When I do ./tools/build.py --external-modules=./my-module --profile=my-module/mymodule.profile
, the error message "no such file or directory #include jrt.h" appears.
I think that JerryScript's files are available in IoT.js library because JerryScript files are in "deps/jerry" directory.
When I'd like to use other header files, how can I add include paths ?
And, can I call IoT.js functions in original new modules ?
I look forward to hearing you.
Thanks.
jrt.h
is an internal header file, you should not directly include it in an IoT.js module. However you can specify a cmake file for your custom module where you can add include directories as well.
Thanks for your answer !