diff options
| author | Amlal El Mahrouss <amlal.elmahrouss@icloud.com> | 2024-10-17 08:16:38 +0200 |
|---|---|---|
| committer | Amlal El Mahrouss <amlal.elmahrouss@icloud.com> | 2024-10-17 08:20:30 +0200 |
| commit | b5ebbd7406e87d19beee3760ef2417e1444a10d2 (patch) | |
| tree | 19961bbbec929b69a2e0ad1f3734334d05585f72 /tools/src | |
| parent | 6fbdfddecc9771adb43b7c673a99c93e50c33dbc (diff) | |
FIX/IMP: A set of fixes and new features. (MHR-40, 46 and 47 related)
Signed-off-by: Amlal El Mahrouss <amlal.elmahrouss@icloud.com>
Diffstat (limited to 'tools/src')
| -rw-r--r-- | tools/src/make_framework.cxx | 42 | ||||
| -rw-r--r-- | tools/src/make_zxd.cxx (renamed from tools/src/zxdmake.cxx) | 4 |
2 files changed, 44 insertions, 2 deletions
diff --git a/tools/src/make_framework.cxx b/tools/src/make_framework.cxx new file mode 100644 index 00000000..3d719529 --- /dev/null +++ b/tools/src/make_framework.cxx @@ -0,0 +1,42 @@ +/* + * Created on Thu Oct 17 08:00:42 CEST 2024 + * + * Copyright (c) 2024 ZKA Technologies + */ + +#include <filesystem> +#include <framework.hxx> + +/// @brief This program converts a PE32+ driver, into a custom format, the ZXD. +/// @note ZXD is a format for ZKA signed drivers. +int main(int argc, char* argv[]) +{ + for (size_t i = 1ul; i < argc; ++i) + { + if (strcmp(argv[i], "/?") == 0) + { + std::cout << "make_framework: Framework Tool.\n"; + std::cout << "make_framework: © ZKA Technologies, all rights reserved.\n"; + + return 0; + } + } + + auto path = std::string(argv[1]); + + if (!path.ends_with(kFKExtension)) + return 1; + + std::filesystem::path path_arg = path; + + if (std::filesystem::create_directory(path_arg)) + { + std::filesystem::create_directory(path_arg / kFKRootDirectory); + std::filesystem::create_directory(path_arg / kFKManifestDirectory); + std::filesystem::create_directory(path_arg / kFKDLLDirectory); + + return 0; + } + + return 1; +} diff --git a/tools/src/zxdmake.cxx b/tools/src/make_zxd.cxx index 8a3276ff..2a456e28 100644 --- a/tools/src/zxdmake.cxx +++ b/tools/src/make_zxd.cxx @@ -14,8 +14,8 @@ int main(int argc, char* argv[]) { if (strcmp(argv[i], "/?") == 0) { - std::cout << "zxdmake: ZKA ZXD Driver Tool.\n"; - std::cout << "zxdmake: © ZKA Technologies, all rights reserved.\n"; + std::cout << "make_zxd: ZXD Tool.\n"; + std::cout << "make_zxd: © ZKA Technologies, all rights reserved.\n"; return 0; } |
