On Thu, Jan 20, 2011 at 10:30 AM, Didier 'OdyX' Raboud
<did...@raboud.com> wrote:
> Hugo Parente Lima wrote:
>
>>
>> Btw, did you see this commit?
>>
>>
> http://qt.gitorious.org/pyside/shiboken/commit/297151081ffae13c8dbb66ffde61f2c15eaae2a3
>>
>> For sure it will change the packaging, but for better I guess.
>
> Hi,
>
> as said I'm already working on it. The thing is that it's not sufficient;
> you also have to rename the shiboken_generator.so depending on the python
> version; patch below.
>
> Cheers,
>
> OdyX
>
> --- shiboken-1.0.0~beta3+14.gdc0a3de.orig/data/ShibokenConfig.cmake.in
> +++ shiboken-1.0.0~beta3+14.gdc0a3de/data/ShibokenConfig.cmake.in
> @@ -1,5 +1,5 @@
>  if (NOT PYTHON_BASENAME)
> -    message(STATUS "Using default python: @PYTHON_BASENAME@")
> -    SET(PYTHON_BASENAME @PYTHON_BASENAME@)
> +    message(STATUS "Using default python: @DEFAULT_PYTHON_BASENAME@")
> +    SET(PYTHON_BASENAME @DEFAULT_PYTHON_BASENAME@)
>  endif()
>  include(@LIB_INSTALL_DIR@/cmake/Shiboken-
> @shiboken_VERSION@/ShibokenConfig-${PYTHON_BASENAME}.cmake)
> --- shiboken-1.0.0~beta3+14.gdc0a3de.orig/tests/otherbinding/CMakeLists.txt
> +++ shiboken-1.0.0~beta3+14.gdc0a3de/tests/otherbinding/CMakeLists.txt
> @@ -14,7 +14,7 @@ ${CMAKE_CURRENT_BINARY_DIR}/other/other_
>  )
>
>  add_custom_command(OUTPUT ${other_SRC}
> -COMMAND ${GENERATORRUNNER_BINARY} --
> generatorSet=${generators_BINARY_DIR}/shiboken_generator${CMAKE_RELEASE_POSTFIX}${CMAKE_DEBUG_POSTFIX}
> --enable-parent-ctor-heuristic
> +COMMAND ${GENERATORRUNNER_BINARY} --
> generatorSet=${generators_BINARY_DIR}/shiboken_generator-${PYTHON_BASENAME}${CMAKE_RELEASE_POSTFIX}${CMAKE_DEBUG_POSTFIX}
> --enable-parent-ctor-heuristic
>         ${CMAKE_CURRENT_SOURCE_DIR}/global.h
>         --include-
> paths=${libother_SOURCE_DIR}${PATH_SEP}${libsample_SOURCE_DIR}${PATH_SEP}${libsample_SOURCE_DIR}/..
>         --typesystem-
> paths=${CMAKE_CURRENT_SOURCE_DIR}${PATH_SEP}${sample_SOURCE_DIR}
> --- shiboken-1.0.0~beta3+14.gdc0a3de.orig/tests/samplebinding/CMakeLists.txt
> +++ shiboken-1.0.0~beta3+14.gdc0a3de/tests/samplebinding/CMakeLists.txt
> @@ -88,7 +88,7 @@ ${CMAKE_CURRENT_BINARY_DIR}/sample/value
>  )
>
>  add_custom_command(OUTPUT ${sample_SRC}
> -COMMAND ${GENERATORRUNNER_BINARY} --
> generatorSet=${generators_BINARY_DIR}/shiboken_generator${CMAKE_RELEASE_POSTFIX}${CMAKE_DEBUG_POSTFIX}
> --enable-parent-ctor-heuristic
> +COMMAND ${GENERATORRUNNER_BINARY} --
> generatorSet=${generators_BINARY_DIR}/shiboken_generator-${PYTHON_BASENAME}${CMAKE_RELEASE_POSTFIX}${CMAKE_DEBUG_POSTFIX}
> --enable-parent-ctor-heuristic
>         ${CMAKE_CURRENT_SOURCE_DIR}/global.h
>         --include-paths=${libsample_SOURCE_DIR}
>         --typesystem-paths=${CMAKE_CURRENT_SOURCE_DIR}
> --- shiboken-1.0.0~beta3+14.gdc0a3de.orig/generator/CMakeLists.txt
> +++ shiboken-1.0.0~beta3+14.gdc0a3de/generator/CMakeLists.txt
> @@ -17,6 +17,7 @@ include_directories(${CMAKE_CURRENT_SOUR
>
>  add_library(shiboken_generator SHARED ${shiboken_SRC})
>  set_property(TARGET shiboken_generator PROPERTY PREFIX "")
> +set_target_properties(shiboken_generator PROPERTIES OUTPUT_NAME
> "shiboken_generator-${PYTHON_BASENAME}")
>
>  target_link_libraries(shiboken_generator
>                       ${APIEXTRACTOR_LIBRARY}
>

I didn't rename the generator as it does not depend on a specific
python, being just a plugin to generatorrunner that will output
python-dependent code. This code, together with libshiboken, is what
links with python. Is adding the python name to the generator really
necessary?

-- 
Lauro Moura
INdT - Instituto Nokia de Tecnologia
_______________________________________________
PySide mailing list
PySide@lists.openbossa.org
http://lists.openbossa.org/listinfo/pyside

Reply via email to