rocr: Fix static build in Windows (#2660)
This commit is contained in:
@@ -457,9 +457,9 @@ if( NOT ${BUILD_SHARED_LIBS} )
|
||||
install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/cmake_modules/FindLibElf.cmake ${CMAKE_CURRENT_SOURCE_DIR}/cmake_modules/COPYING-CMAKE-SCRIPTS
|
||||
DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/${CORE_RUNTIME_NAME}
|
||||
COMPONENT dev)
|
||||
# Linker script (defines function aliases)
|
||||
install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/${LNKSCR}
|
||||
DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/${CORE_RUNTIME_NAME}
|
||||
COMPONENT dev)
|
||||
endif()
|
||||
# Linker script (defines function aliases)
|
||||
install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/${LNKSCR}
|
||||
DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/${CORE_RUNTIME_NAME}
|
||||
COMPONENT dev)
|
||||
endif()
|
||||
|
||||
@@ -472,7 +472,7 @@ bool MapMemory(void* addr, size_t size, MemProt perms, int fd [[maybe_unused]],
|
||||
|
||||
bool ProtectMemory(void* va, size_t size, MemProt perms) {
|
||||
if (perms == MEM_PROT_NONE) {
|
||||
return UncommitMemory(addr, size);
|
||||
return UncommitMemory(va, size);
|
||||
}
|
||||
DWORD oldProt;
|
||||
return VirtualProtect(va, size, memProtToOsProt(perms), &oldProt) != 0;
|
||||
|
||||
Reference in New Issue
Block a user