Open jgsogo opened 4 years ago
Does conan have a way to set cmake variables? BISON_EXECUTABLE
is needed.
We can add files to build_modules
and Conan will include them. I suppose we can set that variable there
@jgsogo What do you suggest for the BISON_TARGET
macro ? should we re-implement it in this cmake file too ?
I think, the script should look like this:
include("${CMAKE_ROOT}/Modules/FindBISON.cmake")
We want this script to only be included in the cmake_find_package
and cmake_find_package_multi
generator.
Will this script also be included in the cmake
generator?
@jgsogo What do you suggest for the
BISON_TARGET
macro ? should we re-implement it in this cmake file too ?
That is still a problem which just hit me. Didn't read the comment last time I commented in this issue, sorry.
I am not sure how to solve it.
Bison itself is not using CMake, but CMake's official FindBISON is declaring the BISON_TARGET macro and projects do rely on it
It isn't too small either https://github.com/conan-io/conan-center-index/issues/1814#issuecomment-2127285311
Probably could be simplified a bit, but every chance might cause it to behave differently.
CMake provides its own
FindBISON.cmake
file, we probably should mimic the variables exposed but this module file:https://cmake.org/cmake/help/latest/module/FindBISON.html
At least it is used by
thrift
(https://github.com/conan-io/conan-center-index/pull/1700#discussion_r434387841)