mirror of
https://github.com/charlesthobe/chdman.git
synced 2024-11-24 07:25:31 +00:00
CMake checks for "UNIX"
instead of having to enumerate all possibilities in if conditionals.
This commit is contained in:
parent
b145a48c33
commit
afde6771c3
@ -11,7 +11,7 @@ endif()
|
||||
set(CMAKE_CXX_STANDARD 17) #needed by libocore and libutils. -
|
||||
#set globally to match MAME's genie scripts.
|
||||
|
||||
if(CMAKE_SYSTEM_NAME STREQUAL "Windows")
|
||||
if(WIN32)
|
||||
add_compile_definitions(
|
||||
X64_WINDOWS_ABI
|
||||
CRLF=3
|
||||
|
@ -38,7 +38,7 @@ add_compile_definitions(
|
||||
)
|
||||
endif()
|
||||
|
||||
if(${CMAKE_SYSTEM_NAME} STREQUAL "Linux" OR CMAKE_SYSTEM_NAME STREQUAL "Android")
|
||||
if(UNIX)
|
||||
add_compile_definitions(
|
||||
HAVE_DLFCN_H
|
||||
HAVE_FCNTL_H
|
||||
|
@ -21,7 +21,7 @@ ${CMAKE_SOURCE_DIR}/src/osd/modules/lib/osd_getenv.cpp #instead of osdlib_${targ
|
||||
${CMAKE_SOURCE_DIR}/src/osd/modules/lib/osdlib.h
|
||||
)
|
||||
|
||||
if(CMAKE_SYSTEM_NAME STREQUAL "Linux" OR CMAKE_SYSTEM_NAME STREQUAL "Android")
|
||||
if(UNIX)
|
||||
target_sources(ocore_sdl PRIVATE
|
||||
${CMAKE_SOURCE_DIR}/src/osd/modules/file/posixdir.cpp
|
||||
${CMAKE_SOURCE_DIR}/src/osd/modules/file/posixfile.cpp
|
||||
@ -29,7 +29,7 @@ target_sources(ocore_sdl PRIVATE
|
||||
${CMAKE_SOURCE_DIR}/src/osd/modules/file/posixptty.cpp
|
||||
${CMAKE_SOURCE_DIR}/src/osd/modules/file/posixsocket.cpp
|
||||
)
|
||||
elseif(CMAKE_SYSTEM_NAME STREQUAL "Windows")
|
||||
elseif(WIN32)
|
||||
target_sources(ocore_sdl PRIVATE
|
||||
${CMAKE_SOURCE_DIR}/src/osd/modules/file/windir.cpp
|
||||
${CMAKE_SOURCE_DIR}/src/osd/modules/file/winfile.cpp
|
||||
|
Loading…
Reference in New Issue
Block a user