Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package python-pivy for openSUSE:Factory checked in at 2022-03-15 19:04:33 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/python-pivy (Old) and /work/SRC/openSUSE:Factory/.python-pivy.new.25692 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-pivy" Tue Mar 15 19:04:33 2022 rev:10 rq:961768 version:0.6.6 Changes: -------- --- /work/SRC/openSUSE:Factory/python-pivy/python-pivy.changes 2020-05-07 14:56:02.210459963 +0200 +++ /work/SRC/openSUSE:Factory/.python-pivy.new.25692/python-pivy.changes 2022-03-15 19:05:16.436962515 +0100 @@ -1,0 +2,23 @@ +Mon Mar 14 09:21:00 UTC 2022 - Dominique Leuenberger <dims...@opensuse.org> + +- Fix one more case where sed env python was replaced with + python38 instead of python3.8. + +------------------------------------------------------------------- +Fri Mar 11 09:15:45 UTC 2022 - Dominique Leuenberger <dims...@opensuse.org> + +- Fix name of python interpreter executables (python3.8 instead of + python38). + +------------------------------------------------------------------- +Wed Feb 23 00:45:49 UTC 2022 - Stefan Br??ns <stefan.bru...@rwth-aachen.de> + +- Update to 0.6.6: + * finalizing cmake support + * adding bindings to SoGeo* +- Drop 0001-Allow-using-SoQt-snapshots-with-stable-Coin-version.patch +- Use arch specific directory, add fix_python_installdir.patch +- Use cmake for building, drop + 0002-Fix-the-qmake-executable-name.patch. + +------------------------------------------------------------------- Old: ---- 0001-Allow-using-SoQt-snapshots-with-stable-Coin-version.patch 0002-Fix-the-qmake-executable-name.patch pivy-0.6.5.tar.gz New: ---- fix_python_installdir.patch pivy-0.6.6.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ python-pivy.spec ++++++ --- /var/tmp/diff_new_pack.R5IR6y/_old 2022-03-15 19:05:16.992962893 +0100 +++ /var/tmp/diff_new_pack.R5IR6y/_new 2022-03-15 19:05:16.996962896 +0100 @@ -1,7 +1,7 @@ # # spec file for package python-pivy # -# Copyright (c) 2020 SUSE LLC +# Copyright (c) 2022 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -16,26 +16,28 @@ # +%define skip_python2 1 +#%%define skip_python39 1 +#%%define skip_python310 1 + Name: python-pivy -Version: 0.6.5 +Version: 0.6.6 Release: 0 Summary: Coin Binding for Python -License: ISC AND GPL-2.0-or-later +# GPL only applies to some examples +License: GPL-2.0-only AND ISC Group: Development/Libraries/Python URL: https://github.com/FreeCAD/pivy Source0: https://github.com/FreeCAD/pivy/archive/%{version}.tar.gz#/pivy-%{version}.tar.gz -# PATCH-FIX-OPENSUSE 0001-Allow-using-SoQt-snapshots-with-stable-Coin-version.patch -- Use CMake to find Coin and SoQt -Patch1: 0001-Allow-using-SoQt-snapshots-with-stable-Coin-version.patch -# PATCH-FIX-OPENSUSE 0002-Fix-the-qmake-executable-name.patch -- Fix the qmake executable name -Patch2: 0002-Fix-the-qmake-executable-name.patch +# PATCH-FIX-UPSTREAM +Patch0: https://github.com/coin3d/pivy/pull/92.patch#/fix_python_installdir.patch BuildRequires: %{python_module devel} -BuildRequires: Coin-devel -BuildRequires: SoQt-devel BuildRequires: cmake BuildRequires: fdupes BuildRequires: gcc BuildRequires: python-rpm-macros BuildRequires: swig +BuildRequires: cmake(soqt) %python_subpackages %description @@ -54,20 +56,40 @@ %prep %autosetup -p1 -n pivy-%{version} +%if 0%{suse_version} < 1550 +sed -i -e '/find_package/ s/SWIG 4.0.0/SWIG/' CMakeLists.txt +%endif %build -export CFLAGS="%{optflags}" -%{python_build ; rm pivy/coin_wrap.cpp pivy/gui/soqt_wrap.cpp } +%{python_expand # +%define __builddir build_%{$python_bin_suffix} +pushd . +%cmake \ + -DPython_EXECUTABLE:FILEPATH=%{_bindir}/python%{$python_bin_suffix} + %{nil} +popd +} + +%{python_expand # +%define __builddir build_%{$python_bin_suffix} +pushd %{__builddir} +%cmake_build +popd +} %install -%python_install - -%python_expand %fdupes %{buildroot}%{$python_sitelib}/pivy/ +%{python_expand # +%define __builddir build_%{$python_bin_suffix} +%cmake_install +$python ./setup.py install_egg_info --install-dir %{buildroot}%{$python_sitearch} +find %{buildroot}%{$python_sitearch} -iname \*sogui.py -exec sed -i -e '1 s@env python@python%{$python_bin_suffix}@' '{}' \; -exec chmod +x '{}' \; +%fdupes %{buildroot}%{$python_sitearch}/pivy/ +} %files %{python_files} %license LICENSE %doc AUTHORS HACKING NEWS README.md THANKS -%{python_sitelib}/pivy/ -%{python_sitelib}/Pivy-%{version}-py%{python_version}.egg-info +%{python_sitearch}/pivy/ +%{python_sitearch}/Pivy-%{version}-py%{python_version}.egg-info %changelog ++++++ fix_python_installdir.patch ++++++ >From e0b6a7e2a42fe8e15f28ddf49d1e540a9d481cec Mon Sep 17 00:00:00 2001 From: StefanBruens <stefan.bru...@rwth-aachen.de> Date: Wed, 23 Feb 2022 01:43:53 +0100 Subject: [PATCH] Correct Python install directory to be arch specific Binary (i.e. non-pure) python modules should be installed to an arch specific directory. Instead of doing this manually, use the Python_SITEARCH variable provided by the new FindPython module, available since CMake 3.12. --- CMakeLists.txt | 14 +++----------- interfaces/CMakeLists.txt | 12 ++++++------ 2 files changed, 9 insertions(+), 17 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 800a98c..1fe9ec9 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -14,13 +14,12 @@ if (SoQt_FOUND) find_package(Qt5 COMPONENTS Core Widgets Gui REQUIRED) endif() -find_package(PythonInterp REQUIRED) -find_package(PythonLibs REQUIRED) +find_package(Python REQUIRED COMPONENTS Interpreter Development) # SWIGIFY HEADERS # doing this with the origin python functions -execute_process(COMMAND ${PYTHON_EXECUTABLE} -c +execute_process(COMMAND ${Python_EXECUTABLE} -c "import sys; sys.path.append('${CMAKE_SOURCE_DIR}'); \ import install_helpers; install_helpers.swigify('${CMAKE_SOURCE_DIR}', '${Coin_INCLUDE_DIR}');") @@ -34,18 +33,11 @@ add_copy_directory(pivy ${CMAKE_SOURCE_DIR}/pivy PATTERN *.py ) - -# find python install destination - -execute_process(COMMAND ${PYTHON_EXECUTABLE} -c - "from distutils.sysconfig import get_python_lib; print(get_python_lib())" - OUTPUT_VARIABLE python_libs OUTPUT_STRIP_TRAILING_WHITESPACE ) - add_subdirectory(interfaces) install(DIRECTORY ${CMAKE_BINARY_DIR}/pivy - DESTINATION ${python_libs} + DESTINATION ${Python_SITEARCH} FILES_MATCHING PATTERN "*.py" PATTERN "*.so" diff --git a/interfaces/CMakeLists.txt b/interfaces/CMakeLists.txt index 6c3a01c..92f9af6 100644 --- a/interfaces/CMakeLists.txt +++ b/interfaces/CMakeLists.txt @@ -28,19 +28,19 @@ if (APPLE) set_target_properties(coin PROPERTIES LINK_FLAGS "-undefined dynamic_lookup") elseif (WIN32) set_target_properties(coin PROPERTIES COMPILE_FLAGS "/bigobj") - target_link_libraries(coin PUBLIC ${PYTHON_LIBRARIES}) + target_link_libraries(coin PUBLIC ${Python_LIBRARIES}) endif () target_include_directories(coin PUBLIC ${Coin_INCLUDE_DIR} - ${PYTHON_INCLUDE_DIRS} + ${Python_INCLUDE_DIRS} PRIVATE ${CMAKE_SOURCE_DIR}/interfaces ) target_link_libraries(coin PUBLIC Coin::Coin) -install(TARGETS coin DESTINATION ${python_libs}/pivy) +install(TARGETS coin DESTINATION ${Python_SITEARCH}/pivy) if (SoQt_FOUND) @@ -63,7 +63,7 @@ if (SoQt_FOUND) set_target_properties(soqt PROPERTIES LINK_FLAGS "-undefined dynamic_lookup") elseif (WIN32) set_target_properties(coin PROPERTIES COMPILE_FLAGS "/bigobj") - target_link_libraries(soqt PUBLIC ${PYTHON_LIBRARIES}) + target_link_libraries(soqt PUBLIC ${Python_LIBRARIES}) endif () target_include_directories(soqt @@ -71,11 +71,11 @@ if (SoQt_FOUND) ${SoQt_INCLUDE_DIRS} ${Qt5Gui_INCLUDE_DIRS} ${Qt5Widgets_INCLUDE_DIRS} - ${PYTHON_INCLUDE_DIRS} + ${Python_INCLUDE_DIRS} PRIVATE ${CMAKE_SOURCE_DIR}/interfaces ) target_link_libraries(soqt PUBLIC SoQt::SoQt) - install(TARGETS soqt DESTINATION ${python_libs}/pivy/gui) + install(TARGETS soqt DESTINATION ${Python_SITEARCH}/pivy/gui) endif() ++++++ pivy-0.6.5.tar.gz -> pivy-0.6.6.tar.gz ++++++ /work/SRC/openSUSE:Factory/python-pivy/pivy-0.6.5.tar.gz /work/SRC/openSUSE:Factory/.python-pivy.new.25692/pivy-0.6.6.tar.gz differ: char 13, line 1