-
-
Notifications
You must be signed in to change notification settings - Fork 156
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add OpenCascade Libraries to FromCabal.Name and Fix opencascade-hs in FromCabal.Postprocess #630
Conversation
The OpenCascade OCCT library is distributed as multiple "toolkits", which in practice are separate link libraries. In nix-packages, these are all bundled under opencascade-occt.
Updating configuration-common in nixpackages A friend of mine came up with this patch to nix packages, which also works to fix the build. This flake references that branch, and demonstrates that this fixes the build. It’s not particularly clear to me which of these two solutions is best? I think there might be a case for updating libNixName, but keeping the extra-include-dir in configuration-common. |
I'm not convinced the |
I agree in general, this would be better, however, if you take a look at the header files in the underlying opencascade library the contents of the header files themselves reference each other without using an So unless I'm missing something, the |
Okay, |
8bb55c5
to
508bb00
Compare
I've updated the PR to remove the override, but keep the |
To clarify, I think this can now be merged as is |
As of [this PR](NixOS/cabal2nix#630) opencascade-hs does not require the dependency on opencascade-occt to be manually specified. It does however still require the include path to be defined.
As of [this PR](NixOS/cabal2nix#630) opencascade-hs does not require the dependency on opencascade-occt to be manually specified. It does however still require the include path to be defined.
@maralorn Do I need to do anything with regards to getting this change included in Thanks again for your help |
Good point. You can open a PR against the haskell-updates branch in nixpkgs where you run |
This fails to build on my machine, so I might now be dependent on someone else running that |
As of [this PR](NixOS/cabal2nix#630) opencascade-hs does not require the dependency on opencascade-occt to be manually specified. It does however still require the include path to be defined.
As of [this PR](NixOS/cabal2nix#630) opencascade-hs does not require the dependency on opencascade-occt to be manually specified. It does however still require the include path to be defined.
As of [this PR](NixOS/cabal2nix#630) opencascade-hs does not require the dependency on opencascade-occt to be manually specified. It does however still require the include path to be defined.
As of [this PR](NixOS/cabal2nix#630) opencascade-hs does not require the dependency on opencascade-occt to be manually specified. It does however still require the include path to be defined. Co-authored-by: sternenseemann <[email protected]>
This PR includes two changes:
FromCabal.Name
: add missingopencascade-occt
library namesThe OpenCascade OCCT library is distributed as multiple "toolkits", which in practice are separate link libraries.
In nix-packages, these are all bundled under
opencascade-occt
.Adding these to
FromCabal.Name
lets us infer the correct nix package name from theextra-libraries
name.FromCabal.PostProcess
: addopencascade-hs
extra-include-dirs
Header files in the OpenCascade library are sorted under
include/opencascade
.This needs to be explicitly passed to the
extra-include-dirs
configure flag ofopencascade-hs
for this package to buildOf the two above changes, I'm less confident that the second one is the correct thing to do, and I'm very open to other suggestions regarding it.