Remove STATIC and SHARED variables. (#1542)

As described in the official documentation https://cmake.org/cmake/help/v3.0/variable/BUILD_SHARED_LIBS.html this flag is global by default and controls if the library will be built as a shared or a static library allowing us to define only one call to the add_library function (without specifying its type). It is also added as an option to be visible in CMake GUI applications.
This commit is contained in:
hristo
2021-01-22 01:07:22 +02:00
committed by GitHub
parent 18ab694f70
commit 05dfbf3cd4
5 changed files with 16 additions and 39 deletions

View File

@ -14,8 +14,7 @@ option(ENABLE_MSAN "Enable MemorySanitizer (MSan) for debugging (not recommended
# Shared library is always PIC. Static library should be PIC too if linked into a shared library
option(WITH_PIC "Compile static library as position-independent code" OFF)
option(SHARED "Build raylib as a dynamic library" OFF)
option(STATIC "Build raylib as a static library" ON)
option(BUILD_SHARED_LIBS "Build raylib as a shared library" OFF)
option(MACOS_FATLIB "Build fat library for both i386 and x86_64 on macOS" OFF)
option(USE_AUDIO "Build raylib with audio module" ON)