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
[protobuf] Enable Android/iOS cross building #4556
[protobuf] Enable Android/iOS cross building #4556
Conversation
This will require a CCI team member review, I have no clue about this stuff 👀 Great work though! |
Is the build still running two days later? 😮 |
no it's been a bug recently in CCI the update status got lost... Close the PR wait 10s and then reopen... that will retrigger CI to run |
Sorry, the build is only launched for Early Access Program users. You can request access writing in this issue. |
Oh... I changed my username a few days ago and now it seems I need to apply for the EAP program again... |
@danimtb is this something the conan team can help with? |
It is done! Thanks for the ping 😄 |
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.
LGTM!
👏 for all the upstream PRs
All green in build 9 (
|
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 first considered adding an option like "protobuf:tools" that controls if protoc is included or not.
Please, remove. Since Bincrafters we tried to do it, at first sight was easy, but after each version update became a hell because that issue you pointed and we need to update each patch. So we unified protoc and protobuf again. If will accept such option, it should be official in the future, so let's wait become official. Keep you PR focused on your feature only, enabling Android building.
If protoc has been built by both host and build profile this makes sure CMake finds protoc for the build profile See discussion in: conan-io/conan-center-index#4556
I detected other pull requests that are modifying protobuf/all recipe: This message is automatically generated by https://github.com/ericLemanissier/conan-center-conflicting-prs so don't hesitate to report issues/improvements there. |
Reviewers: Any more comments? Should I change something or what do you think? |
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.
My comment is still the same. No Tools! Keep focused in your PR, solve only the problem related to Android.
45e18de
08297d7
to
45e18de
Compare
All green in build 18 ( |
@anton-danielsson please, do not use push-force after PR creation. |
I didn't look at everything, but flatbuffers had a similar issue that was done in a bit different way. https://github.com/conan-io/conan-center-index/blob/master/recipes/flatbuffers/all/conanfile.py . Is the protobuf way the preferred way to tackle this? |
From what I understand one difference is that the |
So do we! Thanks for all your hard work! |
patches/upstream-pr-7761-cmake-regex-fix.patch and patches/upstream-pr-7288-android-log.patch no longer needed, they have been merged before 3.15.5 patches/upstream-pr-8301-bundle-destination.patch is in master but not in 3.15.5
facc289
6a14a09
to
facc289
Compare
You'll need to retrigger CI, close the pr wait 10s and then re-open it 🔁 |
All green in build 20 (
|
this will allow testing it in a preview wihtout opening an issue
If protoc has been built by both host and build profile this makes sure CMake finds protoc for the build profile See discussion in: conan-io/conan-center-index#4556
Specify library name and version: protobuf/3.13.0
Allows protobuf to be cross built using dual profiles (profile host/build).
Test changed to also build when cross building.
As the test shows a client recipe should typically have both a requires and build requires to protobuf.
One will provide the libraries for the host environment while the other one will proved protoc for the build environment.
I first considered adding an option like "protobuf:tools" that controls if protoc is included or not.
But it seems that Conan has a bug that means you can't have different options for a recipe is in the build and host requirement.
That meant I couldn't have protobuf:tools set to False in host and True in build...
I think it's the same problem as here: conan-io/conan#8443
Has been tested on both android and ios:
Android profile:
iOS profile:
conan-center hook activated.