I can not open the .FCStd file with the FreeCAD I generated

Having trouble installing or compiling FreeCAD? Get help here.
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
Post Reply
_Nemo
Posts: 117
Joined: Sat Feb 06, 2021 8:25 am

I can not open the .FCStd file with the FreeCAD I generated

Post by _Nemo »

I used the source code of FreeCAD 0.20.1 with LibPack-OCC76-V2 for the generation.
I refer to the tutorial on the wiki: https://wiki.freecadweb.org/Compile_on_Windows
The system information and compilation tools are as follows:

Code: Select all

Windows 11 (22H2)
AMD Ryzen 7 6800H
Microsoft Visual Studio Community 2022 (64 Bit)
CMake 3.24.2
The strange thing is that the release build has no problem, but the debug build opens the .FCStd file with an error.
The program is interrupted here:

Code: Select all

_CRT_SECURITYCRITICAL_ATTRIBUTE
void __CRTDECL operator delete(void* const block) noexcept
{
    #ifdef _DEBUG
    _free_dbg(block, _UNKNOWN_BLOCK);
    #else
    free(block);
    #endif
}
When I click Continue, the window pops up as shown in the attachment.
What could I do to fix this?
Here is my FreeCAD information:

Code: Select all

OS: Windows 10 Version 2009
Word size of FreeCAD: 64-bit
Version: 0.20.1.Unknown
Build type: Debug
Python 3.8.10, Qt 5.15.2, Coin 4.0.1, Vtk 8.2.0, OCC 7.6.3
Locale: Chinese/China (zh_CN)
Attachments
MEH6UFY_o.png
MEH6UFY_o.png (96.63 KiB) Viewed 1894 times
Last edited by _Nemo on Sat Dec 03, 2022 2:01 pm, edited 7 times in total.
User avatar
onekk
Veteran
Posts: 6199
Joined: Sat Jan 17, 2015 7:48 am
Contact:

Re: I can not open the file with the FreeCAD I generated

Post by onekk »

As usual:

https://forum.freecadweb.org/viewtopic.php?f=3&t=2264

Probably this is not the case, but the "intent" of the post above is to have more informations about what the problem is, if you are running a own compiled version it may even depend on some "related libraries" that the simple "I'm using version 0.20.1" will not tell.

From the post a "clever helper" could guess that you are using Windows (You are citing LibPack), but maybe the problem is not only here.

If the compile fails, probably some other infos are needed, usually when dealing with build there are around some definitions file, or some output file of the "Config part" that is executed by the "makefile" (I'm not vey specific here, as I don't know hoe FreeCAD is compiled from source in on Windows).

Probably these informations will be useful to point out where you problem is.

Regards

Carlo D:
GitHub page: https://github.com/onekk/freecad-doc.
- In deep articles on FreeCAD.
- Learning how to model with scripting.
- Various other stuffs.

Blog: https://okkmkblog.wordpress.com/
_Nemo
Posts: 117
Joined: Sat Feb 06, 2021 8:25 am

Re: I can not open the file with the FreeCAD I generated

Post by _Nemo »

onekk wrote: Sat Dec 03, 2022 9:35 am As usual:

https://forum.freecadweb.org/viewtopic.php?f=3&t=2264

...
:oops: I do not have much experience, I have added some information, is this enough?
User avatar
onekk
Veteran
Posts: 6199
Joined: Sat Jan 17, 2015 7:48 am
Contact:

Re: I can not open the file with the FreeCAD I generated

Post by onekk »

_Nemo wrote: Sat Dec 03, 2022 9:51 am :oops: I do not have much experience, I have added some information, is this enough?
Is the FC infor you posted the result of the "non debug "build?

From you post I have guessed that you have compiled FC from sources and that is gone OK but when trying to compile a "debug build" it fails?

Is this correct?

I sadly could not gave more help, being on Linux and as I have not enough skills to solve you problem, but it things are more clear probably someone else could help you.

Regards

Carlo D.
GitHub page: https://github.com/onekk/freecad-doc.
- In deep articles on FreeCAD.
- Learning how to model with scripting.
- Various other stuffs.

Blog: https://okkmkblog.wordpress.com/
_Nemo
Posts: 117
Joined: Sat Feb 06, 2021 8:25 am

Re: I can not open the file with the FreeCAD I generated

Post by _Nemo »

onekk wrote: Sat Dec 03, 2022 9:57 am
Is the FC infor you posted the result of the "non debug "build?

From you post I have guessed that you have compiled FC from sources and that is gone OK but when trying to compile a "debug build" it fails?
Thank you for your patient response! I have updated my screenshots. I have been able to open the FreeCAD interface. And I copied my FreeCAD information from the Help - About. The information shows "Build type : Debug", and I chose "debug" when I generated FreeCAD.
Before that, the FreeCAD generated when I chose "release" worked fine.
User avatar
adrianinsaval
Veteran
Posts: 5544
Joined: Thu Apr 05, 2018 5:15 pm

Re: I can not open the .FCStd file with the FreeCAD I generated

Post by adrianinsaval »

please upload the image directly to the forum, as you can see that weird image hosting you are using does not work in the forum as it is not a direct link to the image. Here I downloaded the image and uploaded directly to the forum
Attachments
MEH6UFY_o.png
MEH6UFY_o.png (96.63 KiB) Viewed 1904 times
_Nemo
Posts: 117
Joined: Sat Feb 06, 2021 8:25 am

Re: I can not open the .FCStd file with the FreeCAD I generated

Post by _Nemo »

adrianinsaval wrote: Sat Dec 03, 2022 1:47 pm please upload the image directly to the forum, as you can see that weird image hosting you are using does not work in the forum as it is not a direct link to the image. Here I downloaded the image and uploaded directly to the forum
Thank you so much!
zzzhust
Posts: 5
Joined: Mon Apr 17, 2023 1:58 am

Re: I can not open the .FCStd file with the FreeCAD I generated

Post by zzzhust »

Hello there.

I am facing the same error.
I built freecad 0.20.2 in vs2019 both in release and debug configerations.
Then I tried to run freecad_d.exe and open an existing freecad file.
It raised the same exception.

I run freecad step-by-step in debug mode to repeat the error.

The error happened after Part::Tools::getPointNormals().

From the getPointNormals(), freecad began to run external code, so I can not trace it anymore.we can see it from the call stack.
Attachments
9eb30c6c0f3330b6f542d903f7717c6.png
9eb30c6c0f3330b6f542d903f7717c6.png (16.94 KiB) Viewed 1427 times
d862336bfc49433daee0c13e519dbac.png
d862336bfc49433daee0c13e519dbac.png (32.54 KiB) Viewed 1440 times
wmayer
Founder
Posts: 20300
Joined: Thu Feb 19, 2009 10:32 am
Contact:

Re: I can not open the .FCStd file with the FreeCAD I generated

Post by wmayer »

I once had the exact same problem with a prebuilt LibPack from Github while it worked well with my own LibPack. After a while I figured out that there was a problem with one of the OCC dlls of the LibPack from GH because it was a release dll instead of a debug dll.
a437409255
Posts: 2
Joined: Wed Oct 05, 2022 12:54 am

Re: I can not open the .FCStd file with the FreeCAD I generated

Post by a437409255 »

I also encountered the same problem, is there a solution for this problem now?
Post Reply