orc icon indicating copy to clipboard operation
orc copied to clipboard

Search for CMake and/or pkgconfig package data by default

Open h-vetinari opened this issue 9 months ago • 2 comments

Orc should recognize CMake / pkgconfig metadata for dependencies, ideally by default. In https://github.com/conda-forge/arrow-cpp-feedstock/pull/1697, we had to add

      -DLZ4_HOME="%LIBRARY_PREFIX%" ^
      -DLZ4_INCLUDE_DIR="%LIBRARY_INC%" ^
      -DLZ4_LIBRARY="%LIBRARY_LIB%\lz4.lib" ^
      -DZSTD_HOME="%LIBRARY_PREFIX%" ^
      -DZSTD_INCLUDE_DIR="%LIBRARY_INC%" ^
      -DZSTD_LIBRARY="%LIBRARY_LIB%\libzstd.lib" ^

otherwise orc would fail to find its dependencies. That should not be necessary, as conda-forge has complete metadata for those packages, and so orc should search first try to look in CMAKE_MODULE_PATH, PKG_CONFIG_PATH (and ideally just $PREFIX / CMAKE_PREFIX_PATH) before falling back to testing ZSTD_* / LZ4_* / ... variables (and eventually failing if the dependencies really cannot be found anywhere).

From my POV think this is healthy default behaviour in general, but if you prefer, you can also put this behind some choice of -DORC_PACKAGE_KIND=. Based on the suggestion of @wgtmac, I tried this (shortly before the release of 2.1.1) in https://github.com/conda-forge/orc-feedstock/pull/86, and the existing "conan" / "vcpkg" options do not work for this purpose.

h-vetinari avatar Mar 07 '25 05:03 h-vetinari

Ping @wgtmac

h-vetinari avatar Apr 08 '25 23:04 h-vetinari

Sorry that I may not have bandwidth to work on it at this moment

wgtmac avatar Apr 11 '25 08:04 wgtmac