diff options
author | Jaakko Keränen <jaakko.keranen@iki.fi> | 2021-02-03 14:48:42 +0200 |
---|---|---|
committer | Jaakko Keränen <jaakko.keranen@iki.fi> | 2021-02-03 14:48:42 +0200 |
commit | 8ac461dbb8804f6e8b3638d8430b17fc7cf28075 (patch) | |
tree | 933f530445bfeb7d7e088aaa7d16924d6e41fd0e /CMakeLists.txt | |
parent | 45018eefbf9d331c58009b6657081ff103c7b1fe (diff) |
XDG: Check XDG_CONFIG_HOME and the user's download directory
Also added a build option to disable changing the user download
directory within Lagrange, since that's set via XDG config.
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 100794d8..ce07c2de 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt | |||
@@ -31,6 +31,7 @@ option (ENABLE_KERNING "Enable kerning in font renderer (slower)" ON) | |||
31 | option (ENABLE_RESOURCE_EMBED "Embed resources inside the executable" OFF) | 31 | option (ENABLE_RESOURCE_EMBED "Embed resources inside the executable" OFF) |
32 | option (ENABLE_WINDOWPOS_FIX "Set position after showing window (workaround for SDL bug)" OFF) | 32 | option (ENABLE_WINDOWPOS_FIX "Set position after showing window (workaround for SDL bug)" OFF) |
33 | option (ENABLE_IDLE_SLEEP "While idle, sleep in the main thread instead of waiting for events" ON) | 33 | option (ENABLE_IDLE_SLEEP "While idle, sleep in the main thread instead of waiting for events" ON) |
34 | option (ENABLE_DOWNLOAD_EDIT "Allow changing the Downloads directory" ON) | ||
34 | 35 | ||
35 | include (BuildType.cmake) | 36 | include (BuildType.cmake) |
36 | include (res/Embed.cmake) | 37 | include (res/Embed.cmake) |
@@ -226,6 +227,9 @@ endif () | |||
226 | if (ENABLE_IDLE_SLEEP) | 227 | if (ENABLE_IDLE_SLEEP) |
227 | target_compile_definitions (app PUBLIC LAGRANGE_IDLE_SLEEP=1) | 228 | target_compile_definitions (app PUBLIC LAGRANGE_IDLE_SLEEP=1) |
228 | endif () | 229 | endif () |
230 | if (ENABLE_DOWNLOAD_EDIT) | ||
231 | target_compile_definitions (app PUBLIC LAGRANGE_DOWNLOAD_EDIT=1) | ||
232 | endif () | ||
229 | target_link_libraries (app PUBLIC the_Foundation::the_Foundation) | 233 | target_link_libraries (app PUBLIC the_Foundation::the_Foundation) |
230 | target_link_libraries (app PUBLIC ${SDL2_LDFLAGS}) | 234 | target_link_libraries (app PUBLIC ${SDL2_LDFLAGS}) |
231 | if (APPLE) | 235 | if (APPLE) |