native-obfuscator
native-obfuscator copied to clipboard
Easy crossplatform build option
cmake --build . --config Release
only created native_library.dll
Instead of expected
x64-windows.dll
x64-linux.so
x86-windows.dll
x64-macos.dylib
arm64-linux.so
arm64-windows.dll
If you need all the other libraries, you need to compile C++ for other platforms manually. Right now there is no easy crossplatform build option, but some time later it may be implemented.
So after my initial thoughts about the issue, there is currently only one option that fits all platforms and is fairly easy to set up: zig. It provides a compatible C/C++ compiler. However, it is not clear about how to properly integrate it into this project, although I have some options from the top of my head:
- Create an additional subproject that allows people to very easily use Zig just by providing the directory with the project (but this approach eliminates an easy option to edit result C++ code in IDE and build it in it in the same configuration as new subproject will)
- Add another variant of the CMake file that uses Zig, however, users still will need to manually compile all the libraries, because as for now, there is no easy approach for using multiple toolchains on a single CMake project
- Provide a guide on how to use Zig with CMake as it is