VSC17 generator omitting paths to libraries installed with vcpkg
Building facebook360-dep on Windows 10 with vc 14 (VS 2017); dependencies installed with vcpkg. This is a big project but the cmakelists.txt is not too long and looks straightforward. I ran cmake with the appropriate toolchain file argument.
One dependency is the facebook Folly library. Folly depends on double-conversion.lib, which for some reason has to be installed separately. It is mentioned only twice in cmakelists:
find_package(double-conversion 3.0)
set(FOLLY_TARGET ${FOLLY_LIB} double-conversion)
Only one target mentions $FOLLY_TARGET, here is its whole specification:
### TARGET LibUtil ###
file(GLOB util_SRC "source/util/*.cpp")
file(GLOB_RECURSE fb360_dep_HDRS "source/*.h")
add_library(
LibUtil STATIC
${util_SRC}
${fb360_dep_HDRS}
)
target_link_libraries(
LibUtil
gflags
Boost::filesystem
Boost::system
Boost::program_options
Boost::timer
Boost::chrono
Eigen3::Eigen
glog::glog
${OPENCV_COMPONENTS}
${CERES_LIBRARIES}
${FOLLY_TARGET}
)
Most of those link libraries are on the vcpkg install path. The vcxproj files for building things that depend on LibUtil have the correct paths for all of them except that double-conversion.lib sometimes appears without any path; and that causes linker error LNK1104 - can't open file.
The pattern of the missing paths strongly suggests a simple bug. The attached example vcxproj mentions double-conversion.lib 8 times, 4 with the right path and 4 without, and these alternate.
Calibration.vcxproj I am not expert enough on cmake to try to diagnose this but I hope someone here can.