mirror of
https://github.com/Perlmint/glew-cmake.git
synced 2024-11-25 16:11:56 +00:00
Fix error on case insensitive fs
This commit is contained in:
parent
1a5db5d19b
commit
19ecc02312
@ -154,13 +154,24 @@ else()
|
||||
set(INSTALL_LIBDIR ${CMAKE_INSTALL_LIBDIR})
|
||||
endif()
|
||||
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E touch test_fs_support_case_sensitivity
|
||||
COMMAND ${CMAKE_COMMAND} -E touch test_fs_support_CASE_sensitivity)
|
||||
file(GLOB TEST_FILE_LIST ${CMAKE_BINARY_DIR}/test_fs_support_*_sensitivity)
|
||||
list(LENGTH TEST_FILE_LIST TEST_FILE_COUNT)
|
||||
if(TEST_FILE_COUNT EQUAL 2)
|
||||
set(SUPPORT_CASE_SENSITIVE_FS YES)
|
||||
else()
|
||||
set(SUPPORT_CASE_SENSITIVE_FS NO)
|
||||
endif()
|
||||
|
||||
function(set_representative_target TARGET)
|
||||
set_target_properties(${TARGET} PROPERTIES
|
||||
OUTPUT_NAME "glew"
|
||||
DEBUG_POSTFIX d)
|
||||
|
||||
# Windows & macOS use case-insensetive FS. do not create symbolic link
|
||||
if(NOT (WIN32 OR APPLE))
|
||||
if(SUPPORT_CASE_SENSITIVE_FS)
|
||||
get_target_property(TARGET_TYPE ${TARGET} TYPE)
|
||||
if(TARGET_TYPE STREQUAL STATIC_LIBRARY)
|
||||
set(EXT ".a")
|
||||
|
Loading…
Reference in New Issue
Block a user