diff options
| author | Amlal El Mahrouss <amlal@nekernel.org> | 2025-05-28 03:19:14 +0200 |
|---|---|---|
| committer | Amlal El Mahrouss <amlal@nekernel.org> | 2025-05-28 03:19:14 +0200 |
| commit | b250a9858728ad9078e482ccf95f938ceb0ae24c (patch) | |
| tree | 7190d7c9312a99ac83faf03da53b0612c1ea4eba /examples/example_01_hello_world | |
| parent | 23f0a09cb5bb9a211358e613557ab60b3cbd7172 (diff) | |
fix: fix dylib build on POSIX targets.
feat: add libBTB example, and updated libBTB version.
Signed-off-by: Amlal El Mahrouss <amlal@nekernel.org>
Diffstat (limited to 'examples/example_01_hello_world')
| -rw-r--r-- | examples/example_01_hello_world/hello_world.cc | 7 | ||||
| -rw-r--r-- | examples/example_01_hello_world/posix.json | 10 | ||||
| -rw-r--r-- | examples/example_01_hello_world/win64.json | 10 |
3 files changed, 27 insertions, 0 deletions
diff --git a/examples/example_01_hello_world/hello_world.cc b/examples/example_01_hello_world/hello_world.cc new file mode 100644 index 0000000..ae47ce8 --- /dev/null +++ b/examples/example_01_hello_world/hello_world.cc @@ -0,0 +1,7 @@ +#include <iostream> +#include <string> + +int main(int argc, char** argv) { + std::cout << "hello, world!\n"; + return 0; +} diff --git a/examples/example_01_hello_world/posix.json b/examples/example_01_hello_world/posix.json new file mode 100644 index 0000000..c3c8151 --- /dev/null +++ b/examples/example_01_hello_world/posix.json @@ -0,0 +1,10 @@ +{ + "compiler_path": "g++", + "compiler_std": "c++20", + "headers_path": ["lib"], + "sources_path": ["hello_world.cc"], + "output_name": "hello_world.elf", + "compiler_flags": ["-fPIC"], + "cpp_macros": ["FOO_MACRO"], + "run_after_build": true +} diff --git a/examples/example_01_hello_world/win64.json b/examples/example_01_hello_world/win64.json new file mode 100644 index 0000000..4af5bdd --- /dev/null +++ b/examples/example_01_hello_world/win64.json @@ -0,0 +1,10 @@ +{ + "compiler_path": "x86_64-w64-mingw32-g++", + "compiler_std": "c++20", + "headers_path": ["lib"], + "sources_path": ["hello_world.cc"], + "output_name": "hello_world.elf", + "compiler_flags": ["-fPIC"], + "cpp_macros": ["FOO_MACRO"], + "run_after_build": true +} |
