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

package lock with boost #585

Open
jfayot opened this issue Aug 12, 2024 · 1 comment
Open

package lock with boost #585

jfayot opened this issue Aug 12, 2024 · 1 comment

Comments

@jfayot
Copy link

jfayot commented Aug 12, 2024

When building target cpm-update-package-lock with boost as dependency like this:

...
CPMAddPackage(
  NAME Boost
  VERSION 1.84.0
  URL https://github.com/boostorg/boost/releases/download/boost-1.85.0/boost-1.85.0.tar.xz
  OPTIONS
    "BOOST_ENABLE_CMAKE ON"
    "BOOST_INCLUDE_LIBRARIES beast\\\;uuid"
)
...

I get the following package lock file:

# CPM Package Lock
# This file should be committed to version control

# Boost
CPMDeclarePackage(Boost
  NAME Boost
  VERSION 1.84.0
  URL
    "https://github.com/boostorg/boost/releases/download/boost-1.85.0/boost-1.85.0.tar.xz"
  OPTIONS
    "BOOST_ENABLE_CMAKE ON"
    "BOOST_INCLUDE_LIBRARIES beast"
    "uuid"
)

Which looks wrong regarding "uuid" component. Indeed, if I try using Boost::uuid in my target_link_libraries, it fails finding uuid whereas Boost::beast is OK.

Moreover, when changing the package lock file to:

# CPM Package Lock
# This file should be committed to version control

# Boost
CPMDeclarePackage(Boost
  NAME Boost
  VERSION 1.84.0
  URL
    "https://github.com/boostorg/boost/releases/download/boost-1.85.0/boost-1.85.0.tar.xz"
  OPTIONS
    "BOOST_ENABLE_CMAKE ON"
    "BOOST_INCLUDE_LIBRARIES beast\\\;uuid"
)

I still get the error finding Boost::uuid while if not making use of package lock file, all is fine...

Thanks for your help

@ScottBailey
Copy link
Contributor

This might be a problem inside cpm_prettify_package_arguments(). If nothing else, it looks like this function needs to be updated for PATCHES as well.

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

No branches or pull requests

2 participants