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

z3: add z3/4.8.7 recipe #1451

Merged
merged 9 commits into from
Aug 25, 2020
Merged

z3: add z3/4.8.7 recipe #1451

merged 9 commits into from
Aug 25, 2020

Conversation

madebr
Copy link
Contributor

@madebr madebr commented Apr 25, 2020

Specify library name and version: z3/4.8.7

A shared mpir depenency is required because of wbhart/mpir#286

  • I've read the guidelines for contributing.
  • I've followed the PEP8 style guides for Python code in the recipes.
  • I've used the latest Conan client version.
  • I've tried at least one configuration locally with the
    conan-center hook activated.

@madebr madebr mentioned this pull request Apr 25, 2020
4 tasks
@conan-center-bot
Copy link
Collaborator

Some configurations of 'z3/4.8.7' failed in build 1 (d87015b18670336a75b94da76e6b47bf8858bbf5):

@conan-center-bot
Copy link
Collaborator

Some configurations of 'z3/4.8.7' failed in build 2 (cc92a49a7db7f46264dabaf3959dedfc9174ff3c):

@madebr
Copy link
Contributor Author

madebr commented Apr 25, 2020

@uilianries
I've added mpir:shared=True as a workaround for wbhart/mpir#286, but it appears a shared mpir is not available for all configurations that are run on cci.

@uilianries
Copy link
Member

@madebr It's because we don't provide shared + runtime MT, because it's a configuration for static library only. You will need to filter it on this recipe using a conditional.

@conan-center-bot
Copy link
Collaborator

Some configurations of 'z3/4.8.7' failed in build 3 (7eb4f2f7c1a08aed559dcec5953888be4d5e2f7e):

@conan-center-bot
Copy link
Collaborator

Some configurations of 'z3/4.8.8' failed in build 4 (df073543e09328c7bf14e297ba8a7a7cab3154f0):

@conan-center-bot
Copy link
Collaborator

Some configurations of 'z3/4.8.8' failed in build 5 (62693c275d5cb99d8649b39e33472a7c869e96ba):

@conan-center-bot
Copy link
Collaborator

All green in build 6 (2bc47dd2ad94ee90c027eb43a066bd3af6bb3deb)! 😊

uilianries
uilianries previously approved these changes Aug 17, 2020
@uilianries uilianries requested review from danimtb and jgsogo August 17, 2020 19:33
if not self.options.shared:
if self.settings.os =="Linux":
self.cpp_info.components["libz3"].system_libs.append("pthread")
# FIXME: this generates a Z3::libz3 target instead of z3::libz3.
Copy link
Contributor

Choose a reason for hiding this comment

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

We can fix this package_info using cpp_info.filename, it allows us to create different names for the file and the namespace.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Good idea.

I find the way to create cmake imported targets in conan lacking though.
The current way to create a namespace::targetin FindName.cmake is limiting.

def package_info(self):
    self.cpp_info.names["cmake_find_package"] = "namespace"
    self.cpp_info.components["comp"].names["cmake_find_package"] = "target"
    self.cpp_info.components["comp"].filenames["cmake_find_package"] = "Name"

How can I, in one package_info function call, create namespace1::target1 in FindName1.cmake AND create namespace2::target2 in FindName2.cmake?

Copy link
Contributor

Choose a reason for hiding this comment

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

There is no way to create more than one FindXXXX.cmake file. If this is something needed/desirable, we need a feature in Conan.

recipes/z3/all/conanfile.py Outdated Show resolved Hide resolved
@conan-center-bot
Copy link
Collaborator

All green in build 7 (4fce55708c7f86610f5caab3ce8cc211487e7d17)! 😊

Copy link
Contributor

@jgsogo jgsogo left a comment

Choose a reason for hiding this comment

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

It would be useful to use cmake_find_package[_multi] generator in the test_package to consume the libraries, so we check that the generated files have the proper casing.

recipes/z3/all/conanfile.py Outdated Show resolved Hide resolved
recipes/z3/all/conanfile.py Show resolved Hide resolved
recipes/z3/all/test_package/CMakeLists.txt Outdated Show resolved Hide resolved
recipes/z3/all/test_package/CMakeLists.txt Outdated Show resolved Hide resolved
recipes/z3/all/test_package/conanfile.py Outdated Show resolved Hide resolved
@conan-center-bot
Copy link
Collaborator

All green in build 8 (51c3420f43c40302dd952fb52a81076fb1b03116)! 😊

@danimtb danimtb merged commit 1e0ab0a into conan-io:master Aug 25, 2020
@madebr madebr deleted the z3 branch August 25, 2020 12:11
@prince-chrismc prince-chrismc mentioned this pull request Nov 6, 2020
4 tasks
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.

7 participants