Review CMake option flags

This commit is contained in:
Ray 2019-05-07 15:15:23 +02:00
parent e0e2346c22
commit f6d1448da9

View File

@ -21,21 +21,19 @@ endif()
option(INCLUDE_EVERYTHING "Include everything disabled by default (for CI usage" OFF)
set(OFF ${INCLUDE_EVERYTHING} CACHE INTERNAL "Replace any OFF by default with \${OFF} to have it covered by this option")
# core.c
option(SUPPORT_BUSY_WAIT_LOOP "Use busy wait loop for timing sync instead of a high-resolution timer" ON)
option(SUPPORT_EVENTS_WAITING "Wait for events passively (sleeping while no events) instead of polling them actively every frame" OFF)
option(SUPPORT_CAMERA_SYSTEM "Provide camera module (camera.h) with multiple predefined cameras: free, 1st/3rd person, orbital" ON)
option(SUPPORT_GESTURES_SYSTEM "Gestures module is included (gestures.h) to support gestures detection: tap, hold, swipe, drag" ON)
option(SUPPORT_MOUSE_GESTURES "Mouse gestures are directly mapped like touches and processed by gestures system" ON)
option(SUPPORT_DEFAULT_FONT "Default font is loaded on window initialization to be available for the user to render simple text. If enabled, uses external module functions to load default raylib font (module: text)" ON)
option(SUPPORT_SCREEN_CAPTURE "Allow automatic screen capture of current screen pressing F12, defined in KeyCallback()" ON)
option(SUPPORT_GIF_RECORDING "Allow automatic gif recording of current screen pressing CTRL+F12, defined in KeyCallback()" ON)
option(SUPPORT_GESTURES_SYSTEM "Gestures module is included (gestures.h) to support gestures detection: tap, hold, swipe, drag" ON)
option(SUPPORT_MOUSE_GESTURES "Mouse gestures are directly mapped like touches and processed by gestures system" ON)
option(SUPPORT_BUSY_WAIT_LOOP "Use busy wait loop for timing sync instead of a high-resolution timer" OFF)
option(SUPPORT_EVENTS_WAITING "Wait for events passively (sleeping while no events) instead of polling them actively every frame" OFF)
option(SUPPORT_HIGH_DPI "Support high DPI displays" OFF)
# rlgl.h
option(SUPPORT_VR_SIMULATOR "Support VR simulation functionality (stereo rendering)" ON)
option(SUPPORT_DISTORTION_SHADER "Include stereo rendering distortion shader (shader_distortion.h)" ON)
# shapes.c
option(SUPPORT_FONT_TEXTURE "Draw rectangle shapes using font texture white character instead of default white texture. Allows drawing rectangles and text with a single draw call, very useful for GUI systems!" ON)
@ -44,6 +42,7 @@ option(SUPPORT_QUADS_DRAW_MODE "Use QUADS instead of TRIANGLES for drawing when
# textures.c
option(SUPPORT_IMAGE_EXPORT "Support image exporting to file" ON)
option(SUPPORT_IMAGE_GENERATION "Support procedural image generation functionality (gradient, spot, perlin-noise, cellular)" ON)
option(SUPPORT_IMAGE_MANIPULATION "Support multiple image editing functions to scale, adjust colors, flip, draw on images, crop... If not defined only three image editing functions supported: ImageFormat(), ImageAlphaMask(), ImageToPOT()" ON)
option(SUPPORT_FILEFORMAT_PNG "Support loading PNG as textures" ON)
option(SUPPORT_FILEFORMAT_DDS "Support loading DDS as textures" ON)
option(SUPPORT_FILEFORMAT_HDR "Support loading HDR as textures" ON)
@ -57,26 +56,28 @@ option(SUPPORT_FILEFORMAT_PSD "Support loading PSD as textures" ${OFF})
option(SUPPORT_FILEFORMAT_PKM "Support loading PKM as textures" ${OFF})
option(SUPPORT_FILEFORMAT_PVR "Support loading PVR as textures" ${OFF})
# text.c
option(SUPPORT_FILEFORMAT_FNT "Support loading fonts in FNT format" ON)
option(SUPPORT_FILEFORMAT_TTF "Support loading font in TTF/OTF format" ON)
# models.c
option(SUPPORT_MESH_GENERATION "Support procedural mesh generation functions, uses external par_shapes.h library. NOTE: Some generated meshes DO NOT include generated texture coordinates" ON)
option(SUPPORT_FILEFORMAT_OBJ "Support loading OBJ file format" ON)
option(SUPPORT_FILEFORMAT_MTL "Support loading MTL file format" ON)
option(SUPPORT_MESH_GENERATION "Support procedural mesh generation functions, uses external par_shapes.h library. NOTE: Some generated meshes DO NOT include generated texture coordinates" ON)
option(SUPPORT_FILEFORMAT_IQM "Support loading IQM file format" ON)
option(SUPPORT_FILEFORMAT_GLTF "Support loading GLTF file format" ON)
# raudio.c
option(SUPPORT_FILEFORMAT_WAV "Support loading WAV for sound" ON)
option(SUPPORT_FILEFORMAT_OGG "Support loading OGG for sound" ON)
option(SUPPORT_FILEFORMAT_XM "Support loading XM for sound" ON)
option(SUPPORT_FILEFORMAT_MOD "Support loading MOD for sound" ON)
option(SUPPORT_FILEFORMAT_MP3 "Support loading MP3 for sound" ${ON})
option(SUPPORT_FILEFORMAT_FLAC "Support loading FLAC for sound" ${OFF})
# utils.c
option(SUPPORT_TRACELOG "Show TraceLog() output messages. NOTE: By default LOG_DEBUG traces not shown" ON)
option(SUPPORT_FILEFORMAT_FNT "Support loading fonts in FNT format" ON)
option(SUPPORT_FILEFORMAT_TTF "Support loading font in TTF format" ON)
option(SUPPORT_IMAGE_MANIPULATION "Support multiple image editing functions to scale, adjust colors, flip, draw on images, crop... If not defined only three image editing functions supported: ImageFormat(), ImageAlphaMask(), ImageToPOT()" ON)
if(NOT (STATIC OR SHARED))
message(FATAL_ERROR "Nothing to do if both -DSHARED=OFF and -DSTATIC=OFF...")
endif()