@@ -21,43 +21,9 @@ else()
21
21
set (SEMVER_PRERELEASE_ID "-${RELEASE_TYPE} " )
22
22
endif ()
23
23
24
- if (CMAKE_HOST_WIN32 )
25
- # Find python by ourselves, since on windows the find_package lookup
26
- # seems to fail
27
- set (Python_EXECUTABLE "$ENV{DBT_TOOLCHAIN_ROOT} /python/python.exe" )
28
- IF (EXISTS ${Python_EXECUTABLE} )
29
- execute_process (
30
- COMMAND ${Python_EXECUTABLE} -c "import platform; print(platform.python_version())"
31
- WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
32
- OUTPUT_VARIABLE Python_VERSION
33
- RESULT_VARIABLE Python_RESULT
34
- OUTPUT_STRIP_TRAILING_WHITESPACE
35
- )
36
- if (NOT ${Python_RESULT} AND NOT ${Python_VERSION} STREQUAL "" )
37
- set (Python_Interpreter_FOUND 1)
38
- else ()
39
- message (FATAL_ERROR "Python found at ${Python_EXECUTABLE} but failed to get version number" )
40
- endif ()
41
- else ()
42
- set (Python_Interpreter_FOUND 0)
43
- endif ()
44
- else ()
45
- find_package (Python COMPONENTS Interpreter)
46
- endif ()
47
-
48
- if (Python_Interpreter_FOUND)
49
- message (VERBOSE "python found: ${Python_EXECUTABLE} version ${Python_VERSION} " )
50
- else ()
51
- message (FATAL_ERROR "Python not found" )
52
- endif (Python_Interpreter_FOUND)
53
-
54
- find_package (Git)
55
-
56
- if (GIT_FOUND)
57
- message (VERBOSE "git found: ${GIT_EXECUTABLE} version ${GIT_VERSION_STRING} " )
58
- else ()
59
- message (FATAL_ERROR "Git not found. Check your path." )
60
- endif (GIT_FOUND)
24
+ set (Python_ROOT $ENV{DBT_TOOLCHAIN_ROOT} /python CACHE STRING "Path to the Python installation" )
25
+ find_package (Python REQUIRED COMPONENTS Interpreter)
26
+ find_package (Git REQUIRED)
61
27
62
28
# Get the result of "git rev-parse --short HEAD"
63
29
execute_process (
@@ -147,7 +113,6 @@ if(DOXYGEN_FOUND)
147
113
148
114
# set(DOXYGEN_CLANG_ASSISTED_PARSING YES)
149
115
# SET(DOXYGEN_CLANG_DATABASE_PATH build)
150
-
151
116
set (DOXYGEN_USE_MDFILE_AS_MAINPAGE README.md )
152
117
153
118
file (GLOB markdown_SOURCES *.md )
@@ -196,8 +161,6 @@ add_compile_options(
196
161
# ASM stuff
197
162
$<$<COMPILE_LANGUAGE:ASM>:-x>
198
163
$<$<COMPILE_LANGUAGE:ASM>:assembler-with-cpp>
199
-
200
-
201
164
)
202
165
203
166
# Add libraries
@@ -229,6 +192,7 @@ list(APPEND DELUGE_COMMON_COMPILE_OPTIONS
229
192
$<$<CONFIG:DEBUG>:-Wno-unused-parameter>
230
193
231
194
$<$<CONFIG:DEBUG>:-Werror=write-strings >
195
+
232
196
# Offsetof for non standard types is supported in GCC,
233
197
# if another compiler does not support it they are obligated to error
234
198
@@ -269,7 +233,6 @@ target_link_options(deluge PUBLIC
269
233
270
234
# Enabled to generate a full ELF, objcopy will do the stripping
271
235
# $<$<CONFIG:RELEASE>:LINKER:--strip-all> # Strip
272
-
273
236
-nostartfiles # Don't emit startfiles
274
237
275
238
# Print details
0 commit comments