In your normal workflow do you create separate release and debug build directories or do you commingle them? If the later how do you manage the .pdb files?
Building Libs for Windows Debug Version with VS2017/Qt5.12
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
Be nice to others! Respect the FreeCAD code of conduct!
Re: Building Libs for Windows Debug Version with VS2017/Qt5.12
"fight the good fight"
Re: Building Libs for Windows Debug Version with VS2017/Qt5.12
For some years now I use QtCreator as IDE and there the Debug and Release build directories are completely separate.
But for testing purposes I use msbuild from the command line which VS internally uses, too. There debug in release libraries are in a common directory. I don't see a problem with .pdb files because debug output files have the suffix "_d" which applies to .dll, .lib, .pdb, ... files.If the later how do you manage the .pdb files?
Re: Building Libs for Windows Debug Version with VS2017/Qt5.12
Are the contributors here aware of https://forum.freecadweb.org/viewtopic.php?f=8&t=37837 ? It's obviously not a workflow that many end users would carry out but I thought it should be brought to your attention.
Re: Building Libs for Windows Debug Version with VS2017/Qt5.12
Thanks for the heads up. I responded in the thread.Syres wrote: ↑Sat Jul 20, 2019 8:57 pm Are the contributors here aware of https://forum.freecadweb.org/viewtopic.php?f=8&t=37837 ? It's obviously not a workflow that many end users would carry out but I thought it should be brought to your attention.
"fight the good fight"
Re: Building Libs for Windows Debug Version with VS2017/Qt5.12
Thanks again for the valuable info.
I'm very interested in making the transition to QTCreator myself. msbuild is open source and only the VS IDE is propriety making this transition would be great.
Any hints on setting up the QTCreator environment (a link would do), I'm short on time presently, but I think this would be a good step forward for the Win toolchain.
"fight the good fight"
Re: Building Libs for Windows Debug Version with VS2017/Qt5.12
First of all QtCreator is only an IDE without its own compiler, i.e. it uses that what it finds on your system. So, you still have to install the msvc compiler. And to save some space on your HDD you don't have to install the full VS IDE but only its compiler. Therefore download the utility "Visual Studio Installer" and follow the instructions.Any hints on setting up the QTCreator environment (a link would do), I'm short on time presently, but I think this would be a good step forward for the Win toolchain.
Now install QtCreator. Now make sure that the LibPack's bin directory and your cmake is listed in your PATH environment. Start QtCreator and open Tools > Options and go to the first item called Kits. In the second tab "Qt Versions" add a new entry (assuming that the Qt version of the already existing entry doesn't match with Qt of the LibPack) and select qmake.exe of the LibPack.
Go back to the first tab and define the C/C++ compiler versions for the new Qt entry, select the CMake version and most important the generator. Recommended are NMake Makefile JOM or Ninja (don't choose NMake Makefile because it's too slow because it doesn't support parallel builds) and as Extra generator choose CodeBlocks.
Remark: With older QtCreator versions choosing the VS generators never worked, maybe this has changed.
Now configure the project with CMake. You can do that by opening the top-level CMakeLists.txt and running Configure but IMO it's a bit painful to do that inside QtCreator -- I prefer using CMakeGui. Create the two build directories for Debug and Release and choose the same generator as you defined inside QtCreator.
Now open the CMakeLists.txt file in QtCreator and define the already created build directories for Debug and Release.
If you go to File > Sessions > Manage you can create a new session e.g. called FreeCAD which saves all opened files when closing the project. Next time you start QtCreator choose the session FreeCAD.
Every time you load the FreeCAD project it runs CMake which is a bit annoying and it takes some minutes to parse it. No idea whether this behaviour can be changed.
Re: Building Libs for Windows Debug Version with VS2017/Qt5.12
#documentation
Alone you go faster. Together we go farther
Please mark thread [Solved]
Want to contribute back to FC? Checkout:
'good first issues' | Open TODOs and FIXMEs | How to Help FreeCAD | How to report Bugs
Please mark thread [Solved]
Want to contribute back to FC? Checkout:
'good first issues' | Open TODOs and FIXMEs | How to Help FreeCAD | How to report Bugs
Re: Building Libs for Windows Debug Version with VS2017/Qt5.12
For sure! I hope to have time on the weekend. Thanks for the helpful starting point.
"fight the good fight"
Re: Building Libs for Windows Debug Version with VS2017/Qt5.12
OCCT 7.4 is out and I would like to contribute to create a new LibPack for it. Can we therefore please put the LibPack-specific files directly to the FreeCAD GitHub? This would e.g. the work on the .cmake files easier and we would have a central repository. I mean we have already e.g. a folder for Conda (/package/conda), so it should not be an issue to have a folder for LibPack (/package/LibPack).