[R-package] changed FindLibR to take advantage of CMake cache (#5427)

This commit is contained in:
James Lamb 2020-03-19 14:32:15 -05:00 committed by GitHub
parent 760d5d0c3c
commit 3cf665d3ec
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -50,10 +50,10 @@ function(create_rlib_for_msvc)
\nDo you have Rtools installed with its MinGW's bin/ in PATH?") \nDo you have Rtools installed with its MinGW's bin/ in PATH?")
endif() endif()
# extract symbols from R.dll into R.def and R.lib import library # extract symbols from R.dll into R.def and R.lib import library
execute_process(COMMAND gendef execute_process(COMMAND ${GENDEF_EXE}
"-" "${LIBR_LIB_DIR}/R.dll" "-" "${LIBR_LIB_DIR}/R.dll"
OUTPUT_FILE "${CMAKE_CURRENT_BINARY_DIR}/R.def") OUTPUT_FILE "${CMAKE_CURRENT_BINARY_DIR}/R.def")
execute_process(COMMAND dlltool execute_process(COMMAND ${DLLTOOL_EXE}
"--input-def" "${CMAKE_CURRENT_BINARY_DIR}/R.def" "--input-def" "${CMAKE_CURRENT_BINARY_DIR}/R.def"
"--output-lib" "${CMAKE_CURRENT_BINARY_DIR}/R.lib") "--output-lib" "${CMAKE_CURRENT_BINARY_DIR}/R.lib")
endfunction(create_rlib_for_msvc) endfunction(create_rlib_for_msvc)