conan-io / conan-center-index

Recipes for the ConanCenter repository
https://conan.io/center
MIT License
950 stars 1.74k forks source link

[package] protobuf/3.11.4: needs components #3275

Closed Talkless closed 1 month ago

Talkless commented 3 years ago

Other libraries like Google ORTools expectes probobuf::libprotobuf and protobuf:protoc targerts. I had to patch ORTools like this to make it build with Conan-ized Protobuf:

        for root, _, files in os.walk(self.source_subfolder):
            for filename in files:
                if fnmatch.fnmatch(filename, "*.cmake") or filename == "CMakeLists.txt":
                    full_filename = os.path.join(root, filename)
                    tools.replace_in_file(full_filename, "protobuf::libprotobuf", "Protobuf::Protobuf", False)
                    tools.replace_in_file(full_filename, "protobuf::protoc", "protoc", False)

Package and Environment Details (include every applicable attribute)

Conan profile (output of conan profile show default or conan profile show <profile> if custom profile is in use)

Configuration for profile default:

[settings]
os=Linux
os_build=Linux
arch=x86_64
arch_build=x86_64
compiler=gcc
compiler.version=8
compiler.libcxx=libstdc++
build_type=Release
[options]
[build_requires]
[env]
Croydon commented 3 years ago

See #2037

perseoGI commented 1 month ago

I there! I'm closing this issue as this has been resolved time ago. Happy coding 🐸