mirror of
https://github.com/ZDoom/qzdoom.git
synced 2024-11-24 21:11:39 +00:00
1a3ac9d0b3
Introduce the variable 'ZD_CMAKE_COMPILER_IS_GNUC(XX)_COMPATIBLE' and replace any occurrence of '"${CMAKE_C(XX)_COMPILER_ID}" STREQUAL "GNU" OR "${CMAKE_C(XX)_COMPILER_ID}" STREQUAL "Clang"' with it. This makes it possible to add more GCC compatible compilers in just one place.
32 lines
627 B
CMake
32 lines
627 B
CMake
cmake_minimum_required( VERSION 2.4 )
|
|
|
|
make_release_only()
|
|
|
|
if( ZD_CMAKE_COMPILER_IS_GNUC_COMPATIBLE )
|
|
set( CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -Wextra -fomit-frame-pointer" )
|
|
endif( ZD_CMAKE_COMPILER_IS_GNUC_COMPATIBLE )
|
|
|
|
set( LZMA_FILES
|
|
C/7zBuf.c
|
|
C/7zCrc.c
|
|
C/7zCrcOpt.c
|
|
C/7zDec.c
|
|
C/7zIn.c
|
|
C/7zStream.c
|
|
C/Bcj2.c
|
|
C/Bra.c
|
|
C/Bra86.c
|
|
C/CpuArch.c
|
|
C/LzFind.c
|
|
C/Lzma2Dec.c
|
|
C/LzmaDec.c
|
|
C/LzmaEnc.c )
|
|
|
|
if( WIN32 )
|
|
set( LZMA_FILES ${LZMA_FILES} C/LzFindMt.c C/Threads.c )
|
|
else( WIN32 )
|
|
set( CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D_7ZIP_ST" )
|
|
endif( WIN32 )
|
|
|
|
add_library( lzma ${LZMA_FILES} )
|
|
target_link_libraries( lzma )
|