-
-
Notifications
You must be signed in to change notification settings - Fork 13.7k
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
ifcopenshell: 240611 -> 0.7.10, fix build and activate most tests #312381
base: master
Are you sure you want to change the base?
Conversation
2ae653e
to
94650c5
Compare
Ok now it's compiling, but I have a weird problem with the runtime lib. libxml2 is missing at runtime:
I have no idea how to fix this problem, for me |
94650c5
to
350b351
Compare
This pull request has been mentioned on NixOS Discourse. There might be relevant details there: https://discourse.nixos.org/t/fixing-ifcopenshell-libxml2-not-found-by-linker-at-runtime/45764/1 |
Ok so I fixed my libxml2 issue by making this a regular package and not a python package (see last temp commit). So it's something to do with the way python packages are made. Can I - and should I - split the lib and the python packaging into 2 derivations? That would allow freecad to depend only on one of them for instance. |
That being said, my end goal is freecad ifc support, and apparently this needs python bindings, so I might not personnally need the split. |
I feel that I need mkDerivation (because it executes the patchElf phase) and buildPythonPackage. How can I combine the 2? |
fa560fb
to
192e18c
Compare
192e18c
to
689d08e
Compare
689d08e
to
f0b8a76
Compare
f0b8a76
to
af35a90
Compare
af35a90
to
67d241e
Compare
67d241e
to
640e0fc
Compare
Result of 2 packages failed to build:
|
b4001e6
to
3da10a1
Compare
I fixed a nixf-tidy error and added opencollada as buildInputs. |
Thanks for taking the time to investigate all of this and also thanks for replacing me 👍🚀 |
This pull request has been mentioned on NixOS Discourse. There might be relevant details there: https://discourse.nixos.org/t/fixing-ifcopenshell-libxml2-not-found-by-linker-at-runtime/45764/5 |
3da10a1
to
77ad89e
Compare
Result of 2 packages built:
|
@natsukium hi! If I'm not mistaken, you're the code owner for this. Fehnomenal already approved it and I'm now maintainer. I think it's ready to get merged. Thanks! |
This pull request has been mentioned on NixOS Discourse. There might be relevant details there: https://discourse.nixos.org/t/prs-ready-for-review/3032/4583 |
PYTHONPATH=../src/ifcopenshell-python/ python tests.py | ||
popd | ||
# like make test-safe, but also ignoring test/test_open.py which segfaults (this needs to be investigated) | ||
pytest -p no:pytest-blender test --ignore=test/util/test_shape_builder.py --ignore=test/test_open.py |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we use pytestCheckHook?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just for this line or for the whole checkPhase
? I remembered I couldn't make it work, but as I don't remember why, I'll try again :-)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've kept the python tests.py
thing in a preCheck
, and used pytestCheckHook
. Can you check if the way I did it is ok? I'm not quite sure...
77ad89e
to
f197f9b
Compare
Result of 2 packages built:
|
@SuperSandro2000 @Artturin thanks for the comments! I've adressed them, please review again 😺 |
ifcopenshell_so_path=$out/${python.sitePackages}/ifcopenshell/_ifcopenshell_wrapper.cpython-${ | ||
lib.versions.major python.version + lib.versions.minor python.version | ||
}-x86_64-linux-gnu.so | ||
cp -v $ifcopenshell_so_path ./ifcopenshell |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ifcopenshell_so_path=$out/${python.sitePackages}/ifcopenshell/_ifcopenshell_wrapper.cpython-${ | |
lib.versions.major python.version + lib.versions.minor python.version | |
}-x86_64-linux-gnu.so | |
cp -v $ifcopenshell_so_path ./ifcopenshell | |
cp $out/${python.sitePackages}/ifcopenshell/_ifcopenshell_wrapper.cpython-${ib.versions.major python.version + lib.versions.minor python.version}-x86_64-linux-gnu.so ./ifcopenshell |
we probably also want to variablize the x86_64 or just use a wildcard
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
does ${system}
works in all cases here? (it would for x86_64-linux but I'm wary of differences for other plateforms)
pushd src/ifcopenshell-python | ||
# The build process is here: https://github.com/IfcOpenShell/IfcOpenShell/blob/v0.8.0/src/ifcopenshell-python/Makefile#L131 | ||
# NOTE: it has changed a *lot* between 0.7.0 and 0.8.0, it *may* change again (look for mathutils and basically all the things this Makefile does manually) | ||
substituteInPlace pyproject.toml --replace-fail "0.0.0" "${version}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should be done in postPatch
4fd6b9a
to
b3a0f4e
Compare
By relevant release, I mean the ifcopenshell-python release, and not the blenderbim release
b3a0f4e
to
0db6f1c
Compare
Description of changes
Fix the ifcopenshell build.
Fix #312380
Things done
nix.conf
? (See Nix manual)sandbox = relaxed
sandbox = true
nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD"
. Note: all changes have to be committed, also see nixpkgs-review usage./result/bin/
)Add a 👍 reaction to pull requests you find important.