Skip to content

Commit

Permalink
cmake: unify linking of python plugins
Browse files Browse the repository at this point in the history
  • Loading branch information
pstorz committed Apr 3, 2018
1 parent 3fd10a9 commit 8954591
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 16 deletions.
7 changes: 1 addition & 6 deletions src/plugins/dird/CMakeLists.txt
Expand Up @@ -37,12 +37,7 @@ IF(HAVE_PYTHON)
# do not prefix with "lib"
set_target_properties(python-dir PROPERTIES PREFIX "")
INSTALL(TARGETS python-dir DESTINATION ${plugindir})

IF(HAVE_WIN32)
target_link_libraries(python-dir python27 bareos)
ELSE()
target_link_libraries(python-dir ${PYTHON_LIBRARIES} bareos)
ENDIF()
target_link_libraries(python-dir ${PYTHON_LIBRARIES} bareos)


set (PYFILES bareos-dir.py.template
Expand Down
6 changes: 1 addition & 5 deletions src/plugins/filed/CMakeLists.txt
Expand Up @@ -83,11 +83,7 @@ IF(HAVE_PYTHON)
add_library(python-fd MODULE python-fd.cc)
set_target_properties(python-fd PROPERTIES PREFIX "")
INSTALL(TARGETS python-fd DESTINATION ${plugindir})
IF(HAVE_WIN32)
target_link_libraries(python-fd python27 bareos)
ELSE()
target_link_libraries(python-fd ${PYTHON_LIBRARIES} bareos)
ENDIF()
target_link_libraries(python-fd ${PYTHON_LIBRARIES} bareos)
ENDIF()

if(${HAVE_GLUSTERFS})
Expand Down
6 changes: 1 addition & 5 deletions src/plugins/stored/CMakeLists.txt
Expand Up @@ -53,11 +53,7 @@ IF(HAVE_PYTHON)
add_library(python-sd MODULE python-sd.cc)
set_target_properties(python-sd PROPERTIES PREFIX "")
INSTALL(TARGETS python-sd DESTINATION ${plugindir})
IF(HAVE_WIN32)
target_link_libraries(python-sd python27 bareos)
ELSE()
target_link_libraries(python-sd ${PYTHON_LIBRARIES} bareos)
ENDIF()
target_link_libraries(python-sd ${PYTHON_LIBRARIES} bareos)


set (PYFILES bareos-sd-class-plugin.py
Expand Down

0 comments on commit 8954591

Please sign in to comment.