From fdd57243537a125da0e0c176128f6e1beee9a043 Mon Sep 17 00:00:00 2001 From: James Lamb Date: Sat, 18 Apr 2020 23:53:28 -0500 Subject: [PATCH] hard-coding --- R-package/src/cmake/modules/FindLibR.cmake | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/R-package/src/cmake/modules/FindLibR.cmake b/R-package/src/cmake/modules/FindLibR.cmake index 7463569918f5..99fedee7f7aa 100644 --- a/R-package/src/cmake/modules/FindLibR.cmake +++ b/R-package/src/cmake/modules/FindLibR.cmake @@ -192,7 +192,12 @@ find_library( HINTS "${CMAKE_CURRENT_BINARY_DIR}" "${LIBR_HOME}/lib" "${LIBR_HOME}/bin/${R_ARCH}" "${LIBR_HOME}/bin" "${LIBR_LIBRARIES}" ) -# set (LIBR_CORE_LIBRARY ${LIBR_HOME}/bin/${R_ARCH}/R.dll CACHE PATH "R core shared library") +if (NOT LIBR_CORE_LIBRARY) + message(STATUS "LIBR_CORE_LIBRARY still not found, trying hard-coding") + set (LIBR_CORE_LIBRARY ${LIBR_HOME}/bin/${R_ARCH}/R.dll) +else() + message(STATUS "LIBR_CORE_LIBRARYwas found by find_library()") +endif() set(LIBR_CORE_LIBRARY ${LIBR_CORE_LIBRARY} CACHE PATH "R core shared library")