Age | Commit message (Collapse) | Author | Files | Lines |
|
- AFB_BINDING_VERSION = 3
- remove preprocessor variables
- mandatory lua
- name of library is ctl-utilities
- does not work with v2 versions
- remove afb-definitions.h
- use of the GNUinstalldirs module to set the destination directories.
Change-Id: Ifdf12885ffad5003ecbbcf3639af63060f0ebc7e
Signed-off-by: Clément Bénier <clement.benier@iot.bzh>
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
|
|
Change-Id: Iba7c564eea48495c76de8ca919725a2e4b332fd6
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
|
|
Change-Id: I617f758890c3508f55d568b0e5c57c8c5d4d5dd1
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
|
|
AFB returns a missing API as a warning and doesn't abort
the process. It is a binding duty to know if it should exit
or not. Here a missing API is considerate as an error and abort
the binder.
Change-Id: Id11bcc34fd5fa8fd8a9a5cbd70d6d3340190dc1d
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
|
|
Call wasn't done correctly in 'CtlConfigExec', some functions
were not call by 'CtlConfigExec' when it should be ...
Change-Id: I5ce44e616042868c349bd5637c56267b8eff72e1
Signed-off-by: Jonathan Aillet <jonathan.aillet@iot.bzh>
|
|
This lets you add new actions to a section from a plugin,
typically at its init step.
Change-Id: I33a61c6162d25332d680d8a0e2d1841a457e0e80
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
|
|
This make possible to load from a binding either a file
or directly a JSON object.
Change-Id: If3f3edb8aaed066922982250dd162d483a7dc47a
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
|
|
Prefix is the most reliable variable to find files or
variables for a controller, so this lets you access it
wherever it is needed without using global hardcoded
variables.
This helps to search for controller's plugins in several
locations depending on environment variables and hardcoded
variables (CONTROL_PLUGIN_PATH, CONTROL_CONFIG_PATH).
This implies also a change a LUA interpreter loading step to
correctly set the package.path variables with the environment
variables, too.
Correct the missing 'extern' in function declarations.
Depends-On: Ic448ff017e6158bec05895d63688b8968b5c6434
Change-Id: I0ad19242612559d1f4b66b6f9af9e7032d4675a8
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
|
|
Test again if the section is present in the configuration
JSON object before executing the callback.
Change-Id: Ibad352e8443d5d33d7e727fc3b80c56a377c75d3
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
|
|
Separate the require api step from ConfigExec and if called from
anywhere but CtlConfigExec function, take care that not already
initialized or that the previous has failed, so this is a new
try.
Change-Id: Ic98ef09487f7f58c1b1cb6c417eba261a5a81b13
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
|
|
Change-Id: Id4c3e0eb9f770c78b38d8650e6a89577851984f9
Signed-off-by: Sebastien Douheret <sebastien.douheret@iot.bzh>
|
|
Reduced the number of warnings in native host configuration (here
Tumbleweed) in order to not hide true/real warnings that may appear
in the future.
Signed-off-by: Sebastien Douheret <sebastien.douheret@iot.bzh>
|
|
Prevent lost of config file path when searching by keeping only
the first file found.
Add a warning if multiple files are found.
Change-Id: I97262c4dbbc53bb921ef25b9100491cf3e29a056
Signed-off-by: Jonathan Aillet <jonathan.aillet@iot.bzh>
|
|
Add fields that will be searched for during controller metadata
section parsing.
These fields are optional, so they will be copied in CtlConfigT
if they are present. Otherwise, no error will be raised.
The added fields are :
- 'author' which should contain the author name
of the configuration file.
- 'date' which should contain the date of the configuration file
last modification.
Change-Id: Iab480533d85c4a52ea5f6a70fb6f9b8d0b866af4
Signed-off-by: Jonathan Aillet <jonathan.aillet@iot.bzh>
|
|
When prefix is set to NULL, only the middle name of the process
will be used to find configuration files.
Example: when the binder is named 'afb-4a-hal', and the prefix
parameter is set to NULL, the 'CtlConfigScan' function will search
for 4a-*.json config files in 'dirList' list.
Change-Id: I8a9ee7df670d992f5461c865591ced9ba46fe8a0
Signed-off-by: Jonathan Aillet <jonathan.aillet@iot.bzh>
|
|
Replaced some 'size_t' by 'int'
Change-Id: Iaf58b4b65f9aa2e82c0a87af45f21ca62fa4d84e
Signed-off-by: Thierry Bultel <thierry.bultel@iot.bzh>
|
|
If no prefix given, then only use the binder name
to search config file.
Change-Id: I504ea27dccb8892e12e09d3e9e42bc281bcf87b0
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
|
|
This change ensure that there are no write over the
destination buffer size
Change-Id: Ic213e70fab83dfae39a8ff030c823a6ce68aab64
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
|
|
Don't calls two times the same function.
As well as avoiding using the function return to
get its length
Change-Id: I26c37f9a376b2c243ffd7a5ad0ddf935c8b5d0e9
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
|
|
Change-Id: Ibb7dbc32580100c588d06e283abb57cc37875312
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
|
|
That follow the last update in afb-helpers submodule
used.
Change-Id: Ia6149ae96c1591f3d0791f4263e8beafbe6e764d
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
|
|
Change-Id: Ied901f39cd6814e5afd9811248b0a1fb401f3e76
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
|
|
Change the way to load LUA scripts. They are now considerate
as Plugin and loads with them.
This imply rework of how to search and find plugins as
well as the way to load LUA.
Also load an harcoded LUA scripts providing LUA helpers
and managing global variables lock unlock mechanism
Change-Id: I64e38aa27278d0cfdca787155db2d0c89953f905
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
|
|
Test the wrong pointer to know if there is a CB to execute. Action pointer
could be void as the loading callback isn't stored in it.
Change-Id: I3281cdd603cc8b90059331fcff694b354eae1db0
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
|
|
Change-Id: I8cde66dc613fd36e7061f45918520ecd1cdf2825
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
|
|
Change-Id: I4526dd9afc76ac9c63ecb6e800157a0678485955
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
|
|
Change-Id: I6da8b9d463ef9adc604bc59285189e45dfb63a7a
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
|
|
Change-Id: Ida18aeab20d5b894609c1a9c2f6fc2a71a0b4a23
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
|
|
Now handle "files" object inside section loading to externalize
JSON definition and could split them in several files if needed.
"files" could be specified inside a section object, each files will
be parsed to found same key than the current section and append content
to the existing section's objects
Change-Id: I4414684d08c5214cf96b365f9b0a72b13578a6ca
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
|
|
Change-Id: I03afd7479f0db8189cad41fd3b0fcb756f373603
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
|
|
Fix: handle null response from CtlScanConfig()
Change-Id: Icbe2a649886998078adda35b0d0dfd1c46e8fe31
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
|
|
3rd arguments match strlen of 2nd arguments and should not match the
maximum length of destination variable.
Change-Id: Ifebf6097bb995d0cf2c5633eb94d52d4517ade7b
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
|
|
Change-Id: I2b805a60b67db1a72b429093256999673e2c3964
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
|
|
Change-Id: I2b805a60b67db1a72b429093256999673e2c3964
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
|
|
|
|
|
|
|