Skip to content

Commit

Permalink
Added config.h and config.c with parsing function for nodes and orch. (
Browse files Browse the repository at this point in the history
…#47)

* Added config.h and config.c with parsing function for nodes and orch.
Used inih for parsing. For parsing ini file use
parsing_ini_file_orch or parsing_ini_file_node.
Also added structure configuration_node and
configuration_orch to save the ini file data.

Signed-off-by: Michael Engel <mengel@redhat.com>
Co-authored-by: ArtiomDivak <adivak@redhat.com>
  • Loading branch information
engelmi and ArtiomDivak authored Jan 9, 2023
1 parent e5b5de8 commit 6d5a057
Show file tree
Hide file tree
Showing 12 changed files with 1,323 additions and 14 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@

ALL_SRC_FILES = 'find . -name "*.[ch]" ! -path "./binchihua/src/ini/*" ! -path "./binchihua/test/**" ! -path "./builddir/**" -print0'
ALL_SRC_FILES = 'find . -name "*.[ch]" ! -path "./binchihua/src/ini/ini.[ch]" ! -path "./binchihua/src/common/hashmap/*" ! -path "./binchihua/test/**" ! -path "./builddir/**" -print0'

fmt:
eval $(ALL_SRC_FILES) | xargs -0 -I {} clang-format -i --sort-includes {}
Expand Down
6 changes: 3 additions & 3 deletions binchihua/meson.build
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
# internal dependencies
common_inc = include_directories('src/common')
common_src = files('src/common/parse-util.c')
common_src = files('src/common/parse-util.c', 'src/common/hashmap/hashmap.c')
ini_inc = include_directories('src/ini')
ini_src = files('src/ini/ini.c')
ini_src = files('src/ini/ini.c', 'src/ini/config.c')

# build each binary
subdir('src/client')
subdir('src/node')
subdir('src/orch')

# build test binaries
subdir('test/common')
subdir('test/common')
20 changes: 20 additions & 0 deletions binchihua/src/common/hashmap/LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
The MIT License (MIT)

Copyright (c) 2020 Joshua J Baker

Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software is furnished to do so,
subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Loading

0 comments on commit 6d5a057

Please sign in to comment.