CMake: don't link sdlew when WITH_SDL=OFF
This caused a build error building Blender as a Python module with !125556 applied.
This commit is contained in:
6
extern/CMakeLists.txt
vendored
6
extern/CMakeLists.txt
vendored
@@ -85,8 +85,10 @@ if(WITH_GTESTS)
|
||||
add_subdirectory(gmock)
|
||||
endif()
|
||||
|
||||
if(WITH_SDL AND WITH_SDL_DYNLOAD)
|
||||
add_subdirectory(sdlew)
|
||||
if(WITH_SDL)
|
||||
if(WITH_SDL_DYNLOAD)
|
||||
add_subdirectory(sdlew)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if(WITH_AUDASPACE AND NOT WITH_SYSTEM_AUDASPACE)
|
||||
|
||||
@@ -28,10 +28,12 @@ if(NOT WITH_SYSTEM_AUDASPACE)
|
||||
list(APPEND LIB
|
||||
audaspace
|
||||
)
|
||||
if(WITH_SDL_DYNLOAD)
|
||||
list(APPEND LIB
|
||||
extern_sdlew
|
||||
)
|
||||
if(WITH_SDL)
|
||||
if(WITH_SDL_DYNLOAD)
|
||||
list(APPEND LIB
|
||||
extern_sdlew
|
||||
)
|
||||
endif()
|
||||
endif()
|
||||
else()
|
||||
list(APPEND LIB
|
||||
|
||||
@@ -262,9 +262,13 @@ if(WITH_SDL)
|
||||
${SDL_INCLUDE_DIR}
|
||||
)
|
||||
if(WITH_SDL_DYNLOAD)
|
||||
list(APPEND INC
|
||||
../../../../extern/sdlew/include
|
||||
)
|
||||
list(APPEND LIB
|
||||
extern_sdlew
|
||||
)
|
||||
add_definitions(-DWITH_SDL_DYNLOAD)
|
||||
else()
|
||||
list(APPEND LIB
|
||||
${SDL_LIBRARY}
|
||||
@@ -273,13 +277,6 @@ if(WITH_SDL)
|
||||
add_definitions(-DWITH_SDL)
|
||||
endif()
|
||||
|
||||
if(WITH_SDL_DYNLOAD)
|
||||
list(APPEND INC
|
||||
../../../../extern/sdlew/include
|
||||
)
|
||||
add_definitions(-DWITH_SDL_DYNLOAD)
|
||||
endif()
|
||||
|
||||
if(WITH_JACK)
|
||||
add_definitions(-DWITH_JACK)
|
||||
endif()
|
||||
|
||||
Reference in New Issue
Block a user