CMake: fix linking Blender as a Python module
Remove direct links to Blender binary, only link to the window manager and rely on indirect links for everything else.
This commit is contained in:
@@ -55,6 +55,10 @@ set(LIB
|
||||
|
||||
if(WITH_HEADLESS)
|
||||
add_definitions(-DWITH_HEADLESS)
|
||||
else()
|
||||
list(APPEND LIB
|
||||
bf_editor_datafiles
|
||||
)
|
||||
endif()
|
||||
|
||||
add_definitions(${GL_DEFINITIONS})
|
||||
|
@@ -57,6 +57,10 @@ set(LIB
|
||||
|
||||
if(WITH_HEADLESS)
|
||||
add_definitions(-DWITH_HEADLESS)
|
||||
else()
|
||||
list(APPEND LIB
|
||||
bf_editor_datafiles
|
||||
)
|
||||
endif()
|
||||
|
||||
if(WITH_IMAGE_OPENEXR)
|
||||
|
@@ -38,17 +38,6 @@ blender_include_dirs(
|
||||
)
|
||||
|
||||
set(LIB
|
||||
bf_blenkernel
|
||||
bf_blenloader
|
||||
bf_depsgraph
|
||||
bf_dna
|
||||
bf_imbuf
|
||||
bf_intern_clog
|
||||
bf_intern_guardedalloc
|
||||
bf_intern_memutil
|
||||
bf_intern_opencolorio
|
||||
bf_render
|
||||
bf_rna
|
||||
bf_windowmanager
|
||||
)
|
||||
|
||||
@@ -69,9 +58,6 @@ if(WITH_CYCLES)
|
||||
blender_include_dirs(../../intern/cycles/blender)
|
||||
add_definitions(-DWITH_CYCLES_LOGGING)
|
||||
endif()
|
||||
list(APPEND LIB
|
||||
bf_intern_cycles
|
||||
)
|
||||
endif()
|
||||
|
||||
if(WITH_CODEC_FFMPEG)
|
||||
@@ -86,9 +72,6 @@ endif()
|
||||
|
||||
if(WITH_PYTHON)
|
||||
blender_include_dirs(../blender/python)
|
||||
list(APPEND LIB
|
||||
bf_python
|
||||
)
|
||||
add_definitions(-DWITH_PYTHON)
|
||||
|
||||
if(WITH_PYTHON_SECURITY)
|
||||
@@ -110,17 +93,11 @@ endif()
|
||||
|
||||
if(WITH_BINRELOC)
|
||||
blender_include_dirs(${BINRELOC_INCLUDE_DIRS})
|
||||
list(APPEND LIB
|
||||
extern_binreloc
|
||||
)
|
||||
add_definitions(-DWITH_BINRELOC)
|
||||
endif()
|
||||
|
||||
if(WITH_FREESTYLE)
|
||||
blender_include_dirs(../blender/freestyle)
|
||||
list(APPEND LIB
|
||||
bf_freestyle
|
||||
)
|
||||
add_definitions(-DWITH_FREESTYLE)
|
||||
endif()
|
||||
|
||||
|
Reference in New Issue
Block a user