-
-
Notifications
You must be signed in to change notification settings - Fork 28
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
libonxx + 1.15.0 migration #105
Conversation
Hi! This is the friendly automated conda-forge-linting service. I wanted to let you know that I linted all conda-recipes in your PR ( Here's what I've got... For recipe:
|
Hi! This is the friendly automated conda-forge-linting service. I wanted to let you know that I linted all conda-recipes in your PR ( Here's what I've got... For recipe:
For recipe:
|
Hi! This is the friendly automated conda-forge-linting service. I just wanted to let you know that I linted all conda-recipes in your PR ( |
…nda-forge-pinning 2023.11.02.10.11.59
I don't really understand what I am doing wrong on windows..... help appreciated. |
A quick fix (I just tested locally, it seems to work) is to change the export macro for |
endif() | ||
endif() | ||
add_onnx_global_defines(onnx_proto) | ||
@@ -528,7 +531,7 @@ target_include_directories(onnx PUBLIC |
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.
If you find protobuf to find_package(Protobuf CONFIG)
, this should be handled automatically by CMake.
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.
Anyhow, if this works fine it is ok to use that.
- make # [unix] | ||
host: | ||
- libprotobuf | ||
- libabseil # [win] |
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 guess this should be present also on non-Windows platforms, so the correctly run_exports are exported for abseil (as it is a public dependency of libprotobuf).
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.
the linking analysis at the end doesn't make libaseil appear on unix
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 think this is due to the fact that linux uses shared libraries
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 see probably the protobuf headers that transitively include abseil are not used. Given that you are linking with https://github.com/conda-forge/onnx-feedstock/pull/105/files/16d193ff4ab9a19c6e551858659303148bb89e21#diff-f3725a55bf339595bf865fec73bda8ac99f283b0810c205442021f29c06eea9aR13 and not via find_package(Protobuf CONFIG)
, if those are used probably build will fail?
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.
For reference, this was the discussion on libprotobuf now requiring linking to libabseil: conda-forge/conda-forge-pinning-feedstock#4075 (comment) .
Thanks for the great explination. Why is compilation not failing for #103 (comment) |
i see it is due to the fact that they aren't building shared libraries for windows. |
I think |
maybe we can in CMake inject something into the header. |
Just to understand, what is the goal now? Building as shared in Windows? In theory the patch in #105 (comment) should work fine, are you afraid the problem will create on non-cmake users of libonnx ? |
yes. I would ideally also like to upstream whatever patch i make since these build patches are pretty hard to maintain. |
It seems onnx worked around this issue by creating an other header file. Maybe I have to move files around to create this shared library https://github.com/onnx/onnx/blob/main/onnx/onnx_pb.h#L12 |
Note that the windows library is still static
Checklist
0
(if the version changed)conda-smithy
(Use the phrase@conda-forge-admin, please rerender
in a comment in this PR for automated rerendering)