conan-io / conan

Conan - The open-source C and C++ package manager
https://conan.io
MIT License
7.95k stars 951 forks source link

[bug] compiler_executables ar not properly set #16517

Open czoido opened 1 week ago

czoido commented 1 week ago

This is coming from a comment in Conan slack:

Following up on this thread from a year ago I noticed that with Conan 2.0 the compiler_executables dictionary in the conan config has been extended by an ar option:

conan --version
Conan version 2.4.1

conan config list | grep compiler_executables
tools.build:compiler_executables: Defines a Python dict-like with the compilers path to be used. Allowed keys {'c', 'cpp', 'cuda', 'objc', 'objcxx', 'rc', 'fortran', 'asm', 'hip', 'ispc', 'ld', 'ar'}

This is much appreciated. Yet unfortunately this doesn't work for me. Calls to ar are always forwarded to arm-none-eabi-ar no matter how I set the ar option of the dictionary. I have to delete the arm-none-eabi-ar binary and create a symlink from arm-none-eabi-ar to arm-none-eabi-gcc-ar if I want to make sure the cross toolchain uses the arm-none-eabi-gcc-ar archiver.