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

CMake Conan 2.0 compatibility #13739

Merged
merged 41 commits into from
Jan 14, 2023

Conversation

System-Arch
Copy link
Contributor

Specify library name and version: cmake/3.24.2

Updated conanfile.py and test_package/conanfile.py to work with Conan 2.0.0-beta4 (Resolves #13613)

Changes involve leveraging Conan 2.0 generators and other syntactic changes

Tested on Linux (including bootstrap option) and Windows


  • 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.

Note that many of the test files packaged with the CMake source code trigger conan-center hook failures due to missing trailing endlines and missing CMake minimum version declarations.

@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

recipes/cmake/3.x.x/conanfile.py Outdated Show resolved Hide resolved
recipes/cmake/3.x.x/conanfile.py Show resolved Hide resolved
recipes/cmake/3.x.x/conanfile.py Show resolved Hide resolved
recipes/cmake/3.x.x/conanfile.py Outdated Show resolved Hide resolved
recipes/cmake/3.x.x/test_package/conanfile.py Outdated Show resolved Hide resolved
System-Arch and others added 5 commits October 25, 2022 17:41
Co-authored-by: Uilian Ries <uilianries@gmail.com>
Co-authored-by: Uilian Ries <uilianries@gmail.com>
Co-authored-by: Uilian Ries <uilianries@gmail.com>
@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

@prince-chrismc
Copy link
Contributor

This counts towards #12888 🚀

@ghost
Copy link

ghost commented Nov 2, 2022

I detected other pull requests that are modifying cmake/3.x.x recipe:

This message is automatically generated by https://github.com/ericLemanissier/conan-center-conflicting-prs so don't hesitate to report issues/improvements there.

czoido
czoido previously approved these changes Dec 12, 2022
Co-authored-by: SpaceIm <30052553+SpaceIm@users.noreply.github.com>
@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

@ghost ghost mentioned this pull request Jan 3, 2023
3 tasks
prince-chrismc
prince-chrismc previously approved these changes Jan 4, 2023
Copy link
Contributor

@prince-chrismc prince-chrismc left a comment

Choose a reason for hiding this comment

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

This looks really good there's a lot of good work, I dont see any blockers (nor any issue for that matter) I think this good unless there's a blockers.

Check from me!

jellespijker
jellespijker previously approved these changes Jan 7, 2023
Copy link
Contributor

@jellespijker jellespijker left a comment

Choose a reason for hiding this comment

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

LGTM

Co-authored-by: SpaceIm <30052553+SpaceIm@users.noreply.github.com>
@conan-center-bot
Copy link
Collaborator

Conan v1 pipeline

All green in build 40 (182c7d474ad40462e032d264c75de8aa64bf0da9):

  • cmake/3.20.6@:
    All packages built successfully! (All logs)

  • cmake/3.19.8@:
    All packages built successfully! (All logs)

  • cmake/3.21.7@:
    All packages built successfully! (All logs)

  • cmake/3.22.6@:
    All packages built successfully! (All logs)

  • cmake/3.24.3@:
    All packages built successfully! (All logs)

  • cmake/3.25.0@:
    All packages built successfully! (All logs)

  • cmake/3.23.5@:
    All packages built successfully! (All logs)

  • cmake/3.25.1@:
    All packages built successfully! (All logs)

Copy link
Contributor

@jcar87 jcar87 left a comment

Choose a reason for hiding this comment

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

LGTM!
Thanks so much @System-Arch, on top of Conan 2.0 compatibility this receives a much needed improvement. Thanks to all reviewers as well!

@conan-center-bot conan-center-bot merged commit a2bd965 into conan-io:master Jan 14, 2023
AbrilRBS pushed a commit to AbrilRBS/conan-center-index that referenced this pull request Jan 16, 2023
* CMake Conan 2.0 compatibility

* Fix lint errors

* Avoid lint error with Conan 2.0 argument name

* Avoid lint error with Conan 2.0 argument name

* Removed unused imports

* Handle Conan version disparities

* Use basic_layout with Autotools

Co-authored-by: Uilian Ries <uilianries@gmail.com>

* Call AutotoolsDeps generate

Co-authored-by: Uilian Ries <uilianries@gmail.com>

* Call CMakeDeps generate

Co-authored-by: Uilian Ries <uilianries@gmail.com>

* Update imports per suggestioned changes

* Removed extra space

* Remove extraneous items

* Determine require_version in a version-agnostic manner

* Use Conan 1.53

* Handle @ in ref

* Fix lint errors

* Bigger hammer

* Remove PATH addition in package_id

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

* Use validate_build instead of validate

* Moved Mac x86 check to validate() method.

* Bump openssl version

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

* Add blank line to trigger CI build

* Eliminate use of validate_build()

* Restore use of validate_build()

* Removed blank line to trigger CI

* Add blank line to trigger CI

* Added boostrap options and removed unneeded env. vars

* Deal with Conan 1.x vs 2.0 inconsistencies

* Fixed lint issue

* Placate linter

* Apply suggestions from code review

Co-authored-by: SpaceIm <30052553+SpaceIm@users.noreply.github.com>

* Use save & load for bootstrap args; Use tool_requires in test packages

* Eliminate use of validate_build; Add more settings to test recipes

* Set PATH in package_info() for v1.x; Lower req. ver. to 1.50

* Apply suggestions from code review

Co-authored-by: SpaceIm <30052553+SpaceIm@users.noreply.github.com>

* Added AutotoolsDeps generator; Eliminated can_run() from tests

* Correct msvc version

Co-authored-by: SpaceIm <30052553+SpaceIm@users.noreply.github.com>

* Use f-strings

* Replace VirtualRunEnv with VirtualBuildEnv

Co-authored-by: SpaceIm <30052553+SpaceIm@users.noreply.github.com>

Co-authored-by: Uilian Ries <uilianries@gmail.com>
Co-authored-by: Chris Mc <prince.chrismc@gmail.com>
Co-authored-by: SpaceIm <30052553+SpaceIm@users.noreply.github.com>
franramirez688 pushed a commit to franramirez688/conan-center-index that referenced this pull request Jan 20, 2023
* CMake Conan 2.0 compatibility

* Fix lint errors

* Avoid lint error with Conan 2.0 argument name

* Avoid lint error with Conan 2.0 argument name

* Removed unused imports

* Handle Conan version disparities

* Use basic_layout with Autotools

Co-authored-by: Uilian Ries <uilianries@gmail.com>

* Call AutotoolsDeps generate

Co-authored-by: Uilian Ries <uilianries@gmail.com>

* Call CMakeDeps generate

Co-authored-by: Uilian Ries <uilianries@gmail.com>

* Update imports per suggestioned changes

* Removed extra space

* Remove extraneous items

* Determine require_version in a version-agnostic manner

* Use Conan 1.53

* Handle @ in ref

* Fix lint errors

* Bigger hammer

* Remove PATH addition in package_id

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

* Use validate_build instead of validate

* Moved Mac x86 check to validate() method.

* Bump openssl version

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

* Add blank line to trigger CI build

* Eliminate use of validate_build()

* Restore use of validate_build()

* Removed blank line to trigger CI

* Add blank line to trigger CI

* Added boostrap options and removed unneeded env. vars

* Deal with Conan 1.x vs 2.0 inconsistencies

* Fixed lint issue

* Placate linter

* Apply suggestions from code review

Co-authored-by: SpaceIm <30052553+SpaceIm@users.noreply.github.com>

* Use save & load for bootstrap args; Use tool_requires in test packages

* Eliminate use of validate_build; Add more settings to test recipes

* Set PATH in package_info() for v1.x; Lower req. ver. to 1.50

* Apply suggestions from code review

Co-authored-by: SpaceIm <30052553+SpaceIm@users.noreply.github.com>

* Added AutotoolsDeps generator; Eliminated can_run() from tests

* Correct msvc version

Co-authored-by: SpaceIm <30052553+SpaceIm@users.noreply.github.com>

* Use f-strings

* Replace VirtualRunEnv with VirtualBuildEnv

Co-authored-by: SpaceIm <30052553+SpaceIm@users.noreply.github.com>

Co-authored-by: Uilian Ries <uilianries@gmail.com>
Co-authored-by: Chris Mc <prince.chrismc@gmail.com>
Co-authored-by: SpaceIm <30052553+SpaceIm@users.noreply.github.com>
@sabapathim
Copy link

Hi,

I was looking for cmake/3.20.0 in linux ( ubuntu , arch x86_64, gcc=9) for conan 2

@sabapathim
Copy link

Hi,

I was looking for cmake/3.20.0 in linux ( ubuntu , arch x86_64, gcc=9) for conan 2

But looks like the binary went missing. can you help me on this.

likewise I have few other packages which didn't work on conan-v2 , but not sure how I can contribute the built packages to conan-center.

@jcar87 jcar87 mentioned this pull request Aug 14, 2024
@jcar87
Copy link
Contributor

jcar87 commented Aug 14, 2024

Hi @sabapathi20 - will continue in this issue: #24939

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.

[package] cmake/3.x.x Does not work with Conan 2.0 due to multiple issues
10 participants