I want to use CMAKE for a project that is very big, written in C++. But this project is not using a "modern compiler" nor a popular compiler, and is for a unique OS that, for practical purposes, let say I made it so I have access to almost all of its source code (but I can't modify it, I only have modify access to my project). Lets call this OS, OSreally.
My project can be compiled Windows and can run in Windows and OSreally.
What I need to do to implement CMAKE for this project? So I can get all of the CMAKE "benefits".
In a sense, your question isn't terribly hard to answer. CMake is extremely extensible, and almost everything can be changed. For example, to use your custom compiler, you could SET(CMAKE_CXX_COMPILER /path/to/compiler)
in your top level build file. However, even though a few more hacks like this will get you on your way to compiling code for your strange OS, there may also be issues with various system functions and the standard library.
If no one has implemented the standard library on your OS, you may need to spend some time building it and possibly modifying it to fit with whatever is different on the system. The same goes for basically any library you would want to import. Regardless, if you have a conforming C++ compiler for the system, the proper path would be to simply set the above variable in your CMakeLists.txt
and fix any problems that arise as you encounter them.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With