Skip to content
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

googleapis: modernize more & bump protobuf #15601

Merged
merged 9 commits into from
Apr 7, 2023

Conversation

SpaceIm
Copy link
Contributor

@SpaceIm SpaceIm commented Jan 31, 2023

  • trick to avoid having protobuf both in requirements & build requirements (if native build for 1 & 2 profiles)
  • use rm_safe
  • use self.dependencies
  • use tool_requires
  • reorder methods by order of execution to give a better understanding of global recipe logic

@ghost
Copy link

ghost commented Jan 31, 2023

I detected other pull requests that are modifying googleapis/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.

@conan-center-bot

This comment has been minimized.

@SpaceIm SpaceIm closed this Jan 31, 2023
@SpaceIm SpaceIm reopened this Jan 31, 2023
@conan-center-bot

This comment has been minimized.

@jcar87
Copy link
Contributor

jcar87 commented Mar 7, 2023

From my own local testing, I'm pretty sure that googleapis simply does not build with Protobuf 3.21.9 on macOS, due to a clash between a macro defined in the system's syslimits.h and code generated by protoc.

It's unclear why it went from working (3.21.4) to not working (3.21.9), but it could be simply be caused as a side effect of the order of implicitly included headers changing.

/Users/jenkins/w/prod/BuildSingleReference@7/.conan/data/googleapis/cci.20220531/_/_/build/d52f4199324621c40024ef7b88e1b3bafd1d4af3/build/Release/google/storagetransfer/v1/transfer_types.pb.h:3520:24: error: expected member name or ';' after declaration specifiers
  static constexpr GID GID_MAX =
  ~~~~~~~~~~~~~~~~~~~~ ^
/Applications/conan/xcode/11.0/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk/usr/include/sys/syslimits.h:78:28: note: expanded from macro 'GID_MAX'
#define GID_MAX            2147483647U  /* max value for a gid_t (2^31-2) */
                           ^
1 error generated.

this may be fixed in newer versions of protobuf:
https://github.com/protocolbuffers/protobuf/blob/v22.0/src/google/protobuf/port_def.inc#L971-L972

@conan-center-bot

This comment has been minimized.

@prince-chrismc
Copy link
Contributor

There's merge conflicts and the downstream dep was fixed should be good to move forward

@SpaceIm
Copy link
Contributor Author

SpaceIm commented Apr 1, 2023

/opt/conan/binutils/bin/ld: CMakeFiles/test_package.dir/test_package.cpp.o: undefined reference to symbol '_ZNK6google8protobuf7Message11DebugStringB5cxx11Ev'
/opt/conan/binutils/bin/ld: /home/conan/w/prod-v2/BuildSingleReference/p/protoe1ed88265f4f3/p/lib/libprotobuf.so.32: error adding symbols: DSO missing from command line

well, transitive_libs is missing

@conan-center-bot

This comment has been minimized.

@@ -67,28 +71,35 @@ def validate(self):
if self.options.shared and not self.dependencies["protobuf"].options.shared:
raise ConanInvalidConfiguration("If built as shared, protobuf must be shared as well. Please, use `protobuf:shared=True`")

@property
def _cmake_new_enough(self):
def _cmake_new_enough(self, required_version):
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is can be removed with the new portable binaries

@prince-chrismc
Copy link
Contributor

Super minor nits

Co-authored-by: Chris Mc <prince.chrismc@gmail.com>
@conan-center-bot
Copy link
Collaborator

Conan v1 pipeline ✔️

All green in build 11 (924409fe093821628d5c7df024a1073c1c690f5a):

  • googleapis/cci.20210730@:
    All packages built successfully! (All logs)

  • googleapis/cci.20220711@:
    All packages built successfully! (All logs)

  • googleapis/cci.20221108@:
    All packages built successfully! (All logs)

  • googleapis/cci.20211122@:
    All packages built successfully! (All logs)

  • googleapis/cci.20220531@:
    All packages built successfully! (All logs)


Conan v2 pipeline (informative, not required for merge) ✔️

Note: Conan v2 builds are informative and they are not required for the PR to be merged.

All green in build 9 (924409fe093821628d5c7df024a1073c1c690f5a):

  • googleapis/cci.20220711@:
    All packages built successfully! (All logs)

  • googleapis/cci.20221108@:
    All packages built successfully! (All logs)

  • googleapis/cci.20211122@:
    All packages built successfully! (All logs)

  • googleapis/cci.20220531@:
    All packages built successfully! (All logs)

  • googleapis/cci.20210730@:
    All packages built successfully! (All logs)

@prince-chrismc
Copy link
Contributor

#16034 has the same changes so we will have merge conflicts :(

@conan-center-bot conan-center-bot merged commit 54b4b7f into conan-io:master Apr 7, 2023
@SpaceIm SpaceIm deleted the googleapis-modernize-more branch April 7, 2023 11:57
MartinDelille pushed a commit to MartinDelille/conan-center-index that referenced this pull request Apr 12, 2023
* modernize more

* remove duplicated copy import

* fix _cmake_new_enough() and bump cmake

* remove protobuf full_package_mode()

* properly manage native build & protobuf

* bump cmake

* transitive_libs for protobuf

* add comment

Co-authored-by: Chris Mc <prince.chrismc@gmail.com>

---------

Co-authored-by: Chris Mc <prince.chrismc@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants