Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed PYSIDE-279: Correct function of ENABLE_VERSION_SUFFIX option #76

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -111,6 +111,13 @@ else()
set(SBK_PYTHON_INCLUDE_DIR ${PYTHON_INCLUDE_DIRS})
endif()

option(ENABLE_VERSION_SUFFIX "Used to use current version in suffix to generated files. This is used to allow multiples versions installed simultaneous." FALSE)
if(ENABLE_VERSION_SUFFIX)
set(shiboken_SUFFIX "-${shiboken_MAJOR_VERSION}.${shiboken_MINOR_VERSION}")
else()
set(shiboken_SUFFIX "")
endif()

add_subdirectory(libshiboken)
add_subdirectory(doc)

Expand Down
2 changes: 1 addition & 1 deletion data/shiboken.pc.in
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ Name: shiboken
Description: Support library for Python bindings created with Shiboken generator.
Version: @shiboken_VERSION@
Libs: @SBK_PYTHON_LIBRARIES@ -L${libdir} -lshiboken@shiboken_SUFFIX@@PYTHON_SUFFIX@@LIBRARY_OUTPUT_SUFFIX@
Cflags: -I@SBK_PYTHON_INCLUDE_DIR@ -I${includedir}/@shiboken_SUFFIX@@SBK_PKG_CONFIG_PY_DEBUG_DEFINITION@
Cflags: -I@SBK_PYTHON_INCLUDE_DIR@ -I${includedir}@shiboken_SUFFIX@@SBK_PKG_CONFIG_PY_DEBUG_DEFINITION@
7 changes: 0 additions & 7 deletions libshiboken/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,12 +1,5 @@
project(libshiboken)

option(ENABLE_VERSION_SUFFIX "Used to use current version in suffix to generated files. This is used to allow multiples versions installed simultaneous." FALSE)
if(ENABLE_VERSION_SUFFIX)
set(shiboken_SUFFIX "-${shiboken_MAJOR_VERSION}.${shiboken_MINOR_VERSION}")
else()
set(shiboken_SUFFIX "")
endif()

configure_file("${CMAKE_CURRENT_SOURCE_DIR}/sbkversion.h.in"
"${CMAKE_CURRENT_BINARY_DIR}/sbkversion.h" @ONLY)

Expand Down
2 changes: 1 addition & 1 deletion shibokenmodule/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ ${CMAKE_CURRENT_BINARY_DIR}/shiboken/shiboken_module_wrapper.cpp
)

add_custom_command(OUTPUT ${sample_SRC}
COMMAND ${shibokengenerator_BINARY_DIR}/shiboken --project-file=${CMAKE_CURRENT_BINARY_DIR}/shibokenmodule.txt ${GENERATOR_EXTRA_FLAGS}
COMMAND ${shibokengenerator_BINARY_DIR}/shiboken${shiboken_SUFFIX} --project-file=${CMAKE_CURRENT_BINARY_DIR}/shibokenmodule.txt ${GENERATOR_EXTRA_FLAGS}
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
COMMENT "Running generator for 'shiboken'..."
)
Expand Down