Closed luzpaz closed 2 years ago
It simply uses what the freecad-maintainers/occt-releases PPA contains:
Core20 itself has 7.3.3, so very outdated. Core22 has 7.5.1 atm.
It is possible to build OCCT from source and include it in the snap, but that requires work. If you want to give it a try, I'd be happy to review it. For the sake of reducing redundant work, helping kkremitzki to update the package in the PPA (and in the repos in general) would be more beneficial to FreeCAD as a whole.
@kkremitzki is part of the Debian Science team that manages the package over at https://salsa.debian.org/science-team/opencascade
OCCT seems easy enough to build. Maybe we should just build it from source. I'll look into it over my break later.
@luzpaz There's a build including OCCT 7.6.1 (upstream, no patches applied) @ https://github.com/ppd/freecad-ppd/actions/runs/1852643291 to play around with.
It increases build time by about an hour if we don't build it as a separate snap. I think that's okay for the sake of simplicity. Do you think building OCCT instead of relying on the PPA's packages is a worthwhile improvement?
Do you think building OCCT instead of relying on the PPA's packages is a worthwhile improvement?
Absolutely! I think it also serves a dual purpose as a way to show other downstream packagers that it's possible. It would be good if there was a way to show that it's built by snap packages so that if we're troubleshooting on the forum we can understand that point. Is it possible?
Is it possible?
Certainly, see https://github.com/ppd/freecad-ppd/tree/occt for the changes. We can try it for the edge releases first if you think it's a good idea. Can we use upstream 7.6.1, or are there important patches missing to your knowledge?
I misread your comment. Are you saying you'd like to have a FreeCAD version with a snap specific suffix?
Hi @blobfish sorry to poke you. Do you know if there are any patches that FC is using to patch OCC prebuild (separate question: what patches do you use?)
CC @realthunder JIC you're interested in having an OCC edge dependency for Link
On Thursday, February 17, 2022 12:17:54 PM EST luzpaz wrote:
Hi @blobfish sorry to poke you. Do you know if there are any patches that FC is using to patch OCC prebuild (separate question: what patches do you use?)
hi luzpaz. I am not involved with freecad much anymore, so I have no clue about it's packaging. I use my own branch that I keep on gitlab. https://gitlab.com/blobfish/occt
Yes, I'd like to have the option for an OCCT-edge dependency. @ppd, are there some kind of build cache in snap? I mean when the build is triggered, does it have to build OCCT every time from scratch? Also, we may need to build netgen and gmsh also, as they depends on OCCT.
@realthunder yes, we can simply put external dependencies in a separate snap and stage this snap (= copy) in the FreeCAD snaps. Gmsh is already built in the snap.
See https://github.com/ppd/freecad-deps-core20 This is OCCT 7.6.1 + gmsh 4.9.4.
Here's a freecad build that makes use of this external snap: https://github.com/ppd/freecad-ppd/actions/runs/1865229978
@luzpaz The snap: https://github.com/ppd/freecad-ppd/suites/5362756175/artifacts/168144171
This has landed in https://github.com/ppd/freecad-ppd/commit/d747dfe0198b13564843bf93f7625a72c1057625 The first edge release should be ready in ~2 hours: https://github.com/ppd/freecad-ppd/actions/runs/1868669943
This is now live with revision 163 in edge; please test. If no problems arise, we can switch the stable snap to this approach too.
@yorikvanhavre just a heads up. This may be worth your time to test as well
@luzpaz Shall we switch the stable snap to OCCT 7.6.1? I've been playing around with the edge builds, and everything seems to be working OK.
https://github.com/ppd/freecad-ppd/actions/runs/1903550382
Seems we need at least one fix on stable: https://github.com/FreeCAD/FreeCAD/commit/77b198048a
Hmm. Seems like 0.19.3 needs quite a few changes to be compatible with OCCT 7.6. I don't want to go patch hunting and create a Frankenstein monster; I'll keep 0.19.3 on the current OCCT version.
Sorry, i could of told you that. I was thinking you were only going to apply this to edge
It would be very good to Snap work with the latest OCC version