flamerobin
flamerobin copied to clipboard
Build System(s) are a Mess
Looking at ditching the Boost dependency, and the code part is easy, but changing the various build systems we have is a real PITA.
Theoretically, we just use the bake file, but that it out of date, both in format (current Bakefile uses a different file format, legacy doesn't support recent IDEs) and content (the flamerobin.bkl
file is missing some recent source files)
So, rather than trying to repair that, does anyone want to look at my CMakeLists.txt file?
I've tested it on Windows (VS2019) and Linux (Slackware 14.2). It calls the update-revision-info
script, builds, and sets up the *-templates
directories ready for debugging. All that's missing is the install commands (for Linux, i.e. make install
)
Special feature, for Windows devs, is you can directly specify the wxWidgets root (WXDIR) which makes it easier to try different wx versions on the same machine (it should check the WXDIR environment var too, but untested)
Quick guide for Win/Visual Studio use:
- Grab CMake from https://cmake.org/download/ (I recommend adding it to
PATH
) - Place the CMakeLists.txt in the root of the FlameRobin (where all the other project file currently exist)
- Create a sub-dir 'build' (can be any name, like 'build-wx302-64bit', but 'build' for now)
- Run the CMake GUI
- Point 'Where is the source code' to the FlameRobin root
- Point 'Where to build the binaries' to the 'build' sub-dir
- Click 'Add Entry' (button to the right of window)
- Give it the name WXDIR
- Set Type to PATH
- Select the root of your wxWidgets library
- Now click 'Generate'
- Select your Visual Studio version, and platform type (x86)
- If that all worked without issue, you can click 'Open Project' and you're into Visual Studio ready to build
I'm not the biggest fan of CMake, but it does seem to be the standard. Should we switch?
I agree that cmake is the way to go , then we can add vcpkg depdendency for wxwidgets
Bit more work on the build, Linux seems to work well now.
Only issue is no MacOS testing. Does anybody here currently do Mac dev?
Created a PR: #122
I'd suggest to following steps:
- Merge this PR
- Check everyone is okay with the new CMake system (hopefully this'll help #115)
- Update the GitHub test script (ccpp.yml) to use it
- Remove all the old build cruft
Are people doing okay with the CMake system?
I still couldn't test it, I had a busy week
Before I forget what I did, PR #129 changes the workflow test to use the new CMake system and drop the Boost requirements.
It's working, so we can look at the final step in all this, removing the old build files.
It's been a while (work), would everybody be okay if we get rid of the old build files now?