[Solved] FC Crashes after opening sketcher FC 0.20(Debug mode)
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
Be nice to others! Respect the FreeCAD code of conduct!
[Solved] FC Crashes after opening sketcher FC 0.20(Debug mode)
Hi,
After building FC 0.20 (git clone https://github.com/FreeCAD/FreeCAD.git) with VS following the guide: https://wiki.freecadweb.org/Compile_on_ ... io_15_2017
I couldn't find PYTHON_DEBUG_LIBRARY path and the other cmake parameters and after bulding and setting FreeCADMain as Start up Project and running it in debug mode x64 the FreeCAD launches and created a file a a body alright but when switching to the sketcher workbench it pop's up the next error and crashes:
Could it be that python parameter thing? where do you find the cmake file that holds this parameters?
After building FC 0.20 (git clone https://github.com/FreeCAD/FreeCAD.git) with VS following the guide: https://wiki.freecadweb.org/Compile_on_ ... io_15_2017
I couldn't find PYTHON_DEBUG_LIBRARY path and the other cmake parameters and after bulding and setting FreeCADMain as Start up Project and running it in debug mode x64 the FreeCAD launches and created a file a a body alright but when switching to the sketcher workbench it pop's up the next error and crashes:
Could it be that python parameter thing? where do you find the cmake file that holds this parameters?
Re: FC Crashes after opening sketcher FC 0.20(Debug mode)
As you have discovered, if not already known, cmake stuff is scattered all over in the source.
I use grepwin to quickly find the target.
Gene
I use grepwin to quickly find the target.
Gene
Re: FC Crashes after opening sketcher FC 0.20(Debug mode)
Looking at it now in the CMakeCache.txt in build bin folder in says that python was set to the python 3.8 in the libpack and yet sketcher would still crash and that's the only workbench I want to work on right now!!!
I assume it was indeed suppose to use python 3.8 for 0.20 build, could I have missed something compiling FC in debug mode?
I assume it was indeed suppose to use python 3.8 for 0.20 build, could I have missed something compiling FC in debug mode?
Re: FC Crashes after opening sketcher FC 0.20(Debug mode)
I also had problems with finding the Python settings in the CMake GUI, so I ran it from the Visual Studio developer command prompt like this:
cmake -S .\source -B .\build -DFREECAD_LIBPACK_DIR=.\libpack -DPYTHON_DEBUG_LIBRARY=.\libpack\bin\libs\python38_d.lib -DPYTHON_EXECUTABLE=.\libpack\bin\python.exe -DPYTHON_INCLUDE_DIR=.\libpack\bin\include -DPYTHON_LIBRARY=.\libpack\bin\libs\python38.lib
msbuild ALL_BUILD.vcxproj /p:Configuration=Debug
and then I could run it from Visual Studio. Change the source, build and libpack folders to match your folders.
I also had some errors from the Qt code generation, but they went away by running msbuild a few more times - I suspect it is some concurrency problem
cmake -S .\source -B .\build -DFREECAD_LIBPACK_DIR=.\libpack -DPYTHON_DEBUG_LIBRARY=.\libpack\bin\libs\python38_d.lib -DPYTHON_EXECUTABLE=.\libpack\bin\python.exe -DPYTHON_INCLUDE_DIR=.\libpack\bin\include -DPYTHON_LIBRARY=.\libpack\bin\libs\python38.lib
msbuild ALL_BUILD.vcxproj /p:Configuration=Debug
and then I could run it from Visual Studio. Change the source, build and libpack folders to match your folders.
I also had some errors from the Qt code generation, but they went away by running msbuild a few more times - I suspect it is some concurrency problem
Re: FC Crashes after opening sketcher FC 0.20(Debug mode)
Well I tryed a fresh build with your commands and still even after running it more than once when loading sketcher in FC the program collapses...jais wrote: ↑Wed Sep 08, 2021 4:52 pm I also had problems with finding the Python settings in the CMake GUI, so I ran it from the Visual Studio developer command prompt like this:
cmake -S .\source -B .\build -DFREECAD_LIBPACK_DIR=.\libpack -DPYTHON_DEBUG_LIBRARY=.\libpack\bin\libs\python38_d.lib -DPYTHON_EXECUTABLE=.\libpack\bin\python.exe -DPYTHON_INCLUDE_DIR=.\libpack\bin\include -DPYTHON_LIBRARY=.\libpack\bin\libs\python38.lib
msbuild ALL_BUILD.vcxproj /p:Configuration=Debug
and then I could run it from Visual Studio. Change the source, build and libpack folders to match your folders.
I also had some errors from the Qt code generation, but they went away by running msbuild a few more times - I suspect it is some concurrency problem
Re: FC Crashes after opening sketcher FC 0.20(Debug mode)
Did you hit "Retry" there and look at the backtrace? That often helps figure out what's going wrong. I really wouldn't suspect Python as the culprit here.
Re: FC Crashes after opening sketcher FC 0.20(Debug mode)
Yeah Said something about QT old error message, I'm currentlly building the release version which atleast somewhat works with just a conserning warning error at the end of the build
Re: FC Crashes after opening sketcher FC 0.20(Debug mode)
When you have a moment, can you re-run your debug version and paste in the backtrace?
Re: FC Crashes after opening sketcher FC 0.20(Debug mode)
Do you have a system installed Python? I've had trouble with this in the past to get CMake to use the one in the Libpack.
"fight the good fight"