diff options
| author | Amlal EL Mahrouss <amlalelmahrouss@icloud.com> | 2024-10-09 07:25:04 +0200 |
|---|---|---|
| committer | Amlal EL Mahrouss <amlalelmahrouss@icloud.com> | 2024-10-09 07:25:04 +0200 |
| commit | 35bf67c51b620b96827b75b0548f56d08415bb90 (patch) | |
| tree | 2c57462a5fc2c981c1159c367df5c943c3c827ed | |
| parent | 518a6da50bfb86e938b2bbf850e3740fa824e832 (diff) | |
IMP: Add Windows version of BTB. Also separate vendor libs from include
directory.
Signed-off-by: Amlal EL Mahrouss <amlalelmahrouss@icloud.com>
| -rw-r--r-- | makefile | 8 | ||||
| -rw-r--r-- | posix.json (renamed from build.json) | 3 | ||||
| -rw-r--r-- | src/TOMLManifestBuilder.cxx | 2 | ||||
| -rw-r--r-- | vendor/json.hxx (renamed from inc/json.hxx) | 0 | ||||
| -rw-r--r-- | vendor/json_fwd.hxx (renamed from inc/json_fwd.hxx) | 0 | ||||
| -rw-r--r-- | vendor/toml.hxx (renamed from inc/toml.hxx) | 0 | ||||
| -rw-r--r-- | win64.json | 17 |
7 files changed, 27 insertions, 3 deletions
@@ -1,13 +1,17 @@ .PHONY: build-btb-core build-btb-core: - sudo g++ -I./inc $(wildcard src/*.cxx) -std=c++20 -fPIC -shared -o libbtb.so + sudo g++ -I./inc I./vendor $(wildcard src/*.cxx) -std=c++20 -fPIC -shared -o libbtb.so sudo cp libbtb.so /usr/local/lib .PHONY: build-btb build-btb: - sudo g++ -I./inc $(wildcard cli/*.cxx) $(wildcard src/*.cxx) -std=c++20 -L/usr/local -lbtb -o btb + sudo g++ -I./inc I./vendor $(wildcard cli/*.cxx) $(wildcard src/*.cxx) -std=c++20 -L/usr/local -lbtb -o btb sudo cp btb /usr/local/bin +.PHONY: build-btb-windows +build-btb-windows: + x86_64-w64-mingw32-g++.exe -I./inc -I./vendor $(wildcard cli/*.cxx) $(wildcard src/*.cxx) -std=c++20 -o btb.exe + .PHONY: help help: @echo "=> build-btb-core" @@ -2,7 +2,8 @@ "compiler_path": "g++", "compiler_std": "c++20", "headers_path": [ - "inc" + "inc", + "vendor" ], "sources_path": [ "src/*.cxx", diff --git a/src/TOMLManifestBuilder.cxx b/src/TOMLManifestBuilder.cxx index 51b29d1..198c43b 100644 --- a/src/TOMLManifestBuilder.cxx +++ b/src/TOMLManifestBuilder.cxx @@ -20,6 +20,8 @@ bool TOMLManifestBuilder::Build(int arg_sz, const char* arg_val) { tbl = toml::parse_file(arg_val); std::cout << tbl << "\n"; + + return true; } catch (const toml::parse_error& err) { diff --git a/inc/json.hxx b/vendor/json.hxx index a858728..a858728 100644 --- a/inc/json.hxx +++ b/vendor/json.hxx diff --git a/inc/json_fwd.hxx b/vendor/json_fwd.hxx index 29a6036..29a6036 100644 --- a/inc/json_fwd.hxx +++ b/vendor/json_fwd.hxx diff --git a/inc/toml.hxx b/vendor/toml.hxx index 1bb9d66..1bb9d66 100644 --- a/inc/toml.hxx +++ b/vendor/toml.hxx diff --git a/win64.json b/win64.json new file mode 100644 index 0000000..ccc594d --- /dev/null +++ b/win64.json @@ -0,0 +1,17 @@ +{ + "compiler_path": "x86_64-w64-mingw32-g++.exe", + "compiler_std": "c++20", + "headers_path": [ + "inc", + "vendor" + ], + "sources_path": [ + "src/*.cxx", + "cli/*.cxx" + ], + "output_name": "btb.exe", + "compiler_flags": [ + "-fPIC" + ], + "run_after_build": false +}
\ No newline at end of file |
