Catch2 icon indicating copy to clipboard operation
Catch2 copied to clipboard

update conan to v2

Open nrbnlulu opened this issue 2 years ago • 4 comments

Describe the bug conan warns on deprecated API's usage

WARN: deprecated: Usage of deprecated Conan 1.X features that will be removed in Conan 2.X:
WARN: deprecated:     'cpp_info.filenames' used in: catch2/3.1.0
WARN: deprecated:     'cpp_info.names' used in:  catch2/3.1.0
WARN: deprecated:     'cpp_info.build_modules' used in:  catch2/3.1.0

Expected behavior No deprecation warnings.

Reproduction steps try to build a conan project with catch2/3.1.0 as a requirement.

Platform information:

  • OS: Ubuntu 22.0.4
  • Compiler+version:
Ubuntu clang version 14.0.0-1ubuntu1
Target: x86_64-pc-linux-gnu
Thread model: posix
InstalledDir: /usr/bin
  • Catch version: v3.1.0

nrbnlulu avatar Jun 06 '23 18:06 nrbnlulu

I don't use Conan, so the port is community effort -> if someone goes and fixes it up I will merge it.

horenmar avatar Jun 08 '23 11:06 horenmar

Was looking into fixing this. So two notes I know from playing around with this some:

  1. The build script we have .conan/build.py will need to be updated / changed maybe. See this message for why: https://github.com/conan-io/conan-package-tools#conan-20-support-warning
  2. If we update to conan 2.0 all conan 1.X will break. I am not aware of how to maintain compatibility and think it is just the price we pay for moving up to it.

If I proceed, is there anyone with a little more knowledge on Conan 2? Want to bounce some questions off them. Also not sure the test path here beside ensuring that the test_package works. Is that enough along with the removal of the warnings?

LinuxDevon avatar Oct 29 '23 23:10 LinuxDevon

If we update to conan 2.0 all conan 1.X will break. I am not aware of how to maintain compatibility and think it is just the price we pay for moving up to it.

I know it's possible to write Conan recipes compatible with v1 and v2. I don't know the details of how you achieve that though.

ChrisThrasher avatar Oct 30 '23 00:10 ChrisThrasher

I pushed a PR yesterday. It does in fact maintain backwards compatibility. Wasn't too bad but the documentation for conan is not great...

LinuxDevon avatar Feb 01 '24 21:02 LinuxDevon