diff options
author | Brad Payne (Vir Linden) <vir@lindenlab.com> | 2015-04-24 08:55:20 -0400 |
---|---|---|
committer | Brad Payne (Vir Linden) <vir@lindenlab.com> | 2015-04-24 08:55:20 -0400 |
commit | 3ae8a821c3b627f3b02df636e7649f28b97d6f57 (patch) | |
tree | 79d5d3f2b262b7f5d60cc6135b80221878aa74b8 /indra/cmake/Copy3rdPartyLibs.cmake | |
parent | 39b17157f9c31a4b911113561d4fc8f86396c430 (diff) | |
parent | fde0868231a25b8c9ce03a86cb53f1738d35688d (diff) |
merge
Diffstat (limited to 'indra/cmake/Copy3rdPartyLibs.cmake')
-rwxr-xr-x | indra/cmake/Copy3rdPartyLibs.cmake | 116 |
1 files changed, 35 insertions, 81 deletions
diff --git a/indra/cmake/Copy3rdPartyLibs.cmake b/indra/cmake/Copy3rdPartyLibs.cmake index 28202f85d6..84947adaae 100755 --- a/indra/cmake/Copy3rdPartyLibs.cmake +++ b/indra/cmake/Copy3rdPartyLibs.cmake @@ -66,126 +66,80 @@ if(WINDOWS) set(release_files ${release_files} fmodex.dll) endif (FMODEX) -#******************************* -# Copy MS C runtime dlls, required for packaging. -# *TODO - Adapt this to support VC9 -if (MSVC80) - FIND_PATH(debug_msvc8_redist_path msvcr80d.dll - PATHS - ${MSVC_DEBUG_REDIST_PATH} - [HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\VisualStudio\\8.0\\Setup\\VC;ProductDir]/redist/Debug_NonRedist/x86/Microsoft.VC80.DebugCRT - NO_DEFAULT_PATH - NO_DEFAULT_PATH - ) - - if(EXISTS ${debug_msvc8_redist_path}) - set(debug_msvc8_files - msvcr80d.dll - msvcp80d.dll - Microsoft.VC80.DebugCRT.manifest - ) - - copy_if_different( - ${debug_msvc8_redist_path} - "${SHARED_LIB_STAGING_DIR_DEBUG}" - out_targets - ${debug_msvc8_files} - ) - set(third_party_targets ${third_party_targets} ${out_targets}) - - endif (EXISTS ${debug_msvc8_redist_path}) - - FIND_PATH(release_msvc8_redist_path msvcr80.dll - PATHS - ${MSVC_REDIST_PATH} - [HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\VisualStudio\\8.0\\Setup\\VC;ProductDir]/redist/x86/Microsoft.VC80.CRT - NO_DEFAULT_PATH - NO_DEFAULT_PATH - ) - - if(EXISTS ${release_msvc8_redist_path}) - set(release_msvc8_files - msvcr80.dll - msvcp80.dll - Microsoft.VC80.CRT.manifest - ) - - copy_if_different( - ${release_msvc8_redist_path} - "${SHARED_LIB_STAGING_DIR_RELEASE}" - out_targets - ${release_msvc8_files} - ) - set(third_party_targets ${third_party_targets} ${out_targets}) - - copy_if_different( - ${release_msvc8_redist_path} - "${SHARED_LIB_STAGING_DIR_RELWITHDEBINFO}" - out_targets - ${release_msvc8_files} - ) - set(third_party_targets ${third_party_targets} ${out_targets}) - - endif (EXISTS ${release_msvc8_redist_path}) -elseif (MSVC_VERSION EQUAL 1600) # VisualStudio 2010 - FIND_PATH(debug_msvc10_redist_path msvcr100d.dll + #******************************* + # Copy MS C runtime dlls, required for packaging. + # *TODO - Adapt this to support VC9 + if (MSVC80) + set(MSVC_VER 80) + set(MSVC_VERDOT 8.0) + elseif (MSVC_VERSION EQUAL 1600) # VisualStudio 2010 + set(MSVC_VER 100) + set(MSVC_VERDOT 10.0) + elseif (MSVC_VERSION EQUAL 1800) # VisualStudio 2013, which is (sigh) VS 12 + set(MSVC_VER 120) + set(MSVC_VERDOT 12.0) + else (MSVC80) + MESSAGE(WARNING "New MSVC_VERSION ${MSVC_VERSION} of MSVC: adapt Copy3rdPartyLibs.cmake") + endif (MSVC80) + + FIND_PATH(debug_msvc_redist_path msvcr${MSVC_VER}d.dll PATHS ${MSVC_DEBUG_REDIST_PATH} - [HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\VisualStudio\\10.0\\Setup\\VC;ProductDir]/redist/Debug_NonRedist/x86/Microsoft.VC100.DebugCRT + [HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\VisualStudio\\${MSVC_VERDOT}\\Setup\\VC;ProductDir]/redist/Debug_NonRedist/x86/Microsoft.VC${MSVC_VER}.DebugCRT [HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Windows;Directory]/SysWOW64 [HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Windows;Directory]/System32 NO_DEFAULT_PATH ) - if(EXISTS ${debug_msvc10_redist_path}) - set(debug_msvc10_files - msvcr100d.dll - msvcp100d.dll + if(EXISTS ${debug_msvc_redist_path}) + set(debug_msvc_files + msvcr${MSVC_VER}d.dll + msvcp${MSVC_VER}d.dll ) copy_if_different( - ${debug_msvc10_redist_path} + ${debug_msvc_redist_path} "${SHARED_LIB_STAGING_DIR_DEBUG}" out_targets - ${debug_msvc10_files} + ${debug_msvc_files} ) set(third_party_targets ${third_party_targets} ${out_targets}) endif () - FIND_PATH(release_msvc10_redist_path msvcr100.dll + FIND_PATH(release_msvc_redist_path msvcr${MSVC_VER}.dll PATHS ${MSVC_REDIST_PATH} - [HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\VisualStudio\\10.0\\Setup\\VC;ProductDir]/redist/x86/Microsoft.VC100.CRT + [HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\VisualStudio\\${MSVC_VERDOT}\\Setup\\VC;ProductDir]/redist/x86/Microsoft.VC${MSVC_VER}.CRT [HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Windows;Directory]/SysWOW64 [HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Windows;Directory]/System32 NO_DEFAULT_PATH ) - if(EXISTS ${release_msvc10_redist_path}) - set(release_msvc10_files - msvcr100.dll - msvcp100.dll + if(EXISTS ${release_msvc_redist_path}) + set(release_msvc_files + msvcr${MSVC_VER}.dll + msvcp${MSVC_VER}.dll ) copy_if_different( - ${release_msvc10_redist_path} + ${release_msvc_redist_path} "${SHARED_LIB_STAGING_DIR_RELEASE}" out_targets - ${release_msvc10_files} + ${release_msvc_files} ) set(third_party_targets ${third_party_targets} ${out_targets}) copy_if_different( - ${release_msvc10_redist_path} + ${release_msvc_redist_path} "${SHARED_LIB_STAGING_DIR_RELWITHDEBINFO}" out_targets - ${release_msvc10_files} + ${release_msvc_files} ) set(third_party_targets ${third_party_targets} ${out_targets}) endif () -endif (MSVC80) + elseif(DARWIN) set(SHARED_LIB_STAGING_DIR_DEBUG "${SHARED_LIB_STAGING_DIR}/Debug/Resources") |