conan: [bug] ERROR: Build-require 'xxx' cannot be found in lockfile (but it's there)
Environment Details (include every applicable attribute)
- Operating System+version: Linux, docker image
conanio/gcc11
- Compiler+version: gcc (Ubuntu 11.1.0-1ubuntu1~20.04) 11.1.0
- Conan version: Conan version 1.44.0
- Python version: Python 3.7.5
Steps to reproduce (Include if Applicable)
run conanio/gcc11
image. execute the following command to create a lockfile:
$ conan lock create --reference gst-plugins-good/1.19.1@ --build -pr:b default -pr:h default
(two profiles are optional, it reproduces in single profile mode as well)
run the command to install:
$ conan install gst-plugins-good/1.19.1@ --lockfile=conan.lock --build missing
it will say:
ERROR: Build-require 'automake' cannot be found in lockfile
but it’s clearly there:
$ cat conan.lock | grep automake
"ref": "automake/1.16.4",
"ref": "automake/1.16.4",
(also the full lockfile is attached below)
Logs (Executed commands with output) (Include/Attach if Applicable)
conan install gst-plugins-good/1.19.1@ --lockfile=conan.lock --build missing
Using lockfile: '/home/conan/conan.lock'
Configuration (profile_host):
[settings]
arch=x86_64
arch_build=x86_64
build_type=Release
compiler=gcc
compiler.libcxx=libstdc++
compiler.version=11
os=Linux
os_build=Linux
[options]
[build_requires]
[env]
Configuration (profile_build):
[settings]
arch=x86_64
arch_build=x86_64
build_type=Release
compiler=gcc
compiler.libcxx=libstdc++
compiler.version=11
os=Linux
os_build=Linux
[options]
[build_requires]
[env]
ERROR: Build-require 'automake' cannot be found in lockfile
About this issue
- Original URL
- State: closed
- Created 2 years ago
- Reactions: 5
- Comments: 21 (14 by maintainers)
We are having the same issue. This means we can’t use lock files. It’s
protobuf
that is our culprit.Actually both can be problematic, because in Conan 1.X without using the 2 profiles approach there is little difference between build-requires and regular requires, they both live in the same context and are treated as equal. But feel free to try it and we will think about it.
I’m observing the same issue. In my case it’s
protobuf
andgrpc
that are needed both, asrequires
andtool_requires
.Is there any known workaround? Removing the
tool_requires
won’t work, because thetool_requires
package must bex86_64
and therequires
package must beaarch64
.