Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package python-rpm-macros for 
openSUSE:Factory checked in at 2021-02-08 11:47:09
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-rpm-macros (Old)
 and      /work/SRC/openSUSE:Factory/.python-rpm-macros.new.28504 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "python-rpm-macros"

Mon Feb  8 11:47:09 2021 rev:35 rq:869588 version:20210204.937b8d8

Changes:
--------
--- /work/SRC/openSUSE:Factory/python-rpm-macros/python-rpm-macros.changes      
2021-02-02 14:24:40.343298565 +0100
+++ 
/work/SRC/openSUSE:Factory/.python-rpm-macros.new.28504/python-rpm-macros.changes
   2021-02-08 11:47:14.101691299 +0100
@@ -1,0 +2,21 @@
+Thu Feb 04 22:27:24 UTC 2021 - mc...@cepl.eu
+
+- Update to version 20210204.937b8d8:
+  * fixup: last PR was missing a commit for pyproject_wheel syntax errors
+
+-------------------------------------------------------------------
+Thu Feb 04 14:39:22 UTC 2021 - mc...@cepl.eu
+
+- Update to version 20210204.90721de:
+  * mv -n does not work in SLE12
+  * Update PEP517/518 macro documentation in README
+  * Let pyproject_install search for more locations for wheels or specify 
explicitely
+  * Read .rpmmacros (= prjconf Macro: definitions) for default buildset
+
+-------------------------------------------------------------------
+Wed Feb 03 16:40:14 UTC 2021 - mc...@cepl.eu
+
+- Update to version 20210203.0d8a91e:
+  * don't define skip_python2 by default
+
+-------------------------------------------------------------------

Old:
----
  python-rpm-macros-20210131.ec7577b.tar.xz

New:
----
  python-rpm-macros-20210204.937b8d8.tar.xz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ python-rpm-macros.spec ++++++
--- /var/tmp/diff_new_pack.fAT18P/_old  2021-02-08 11:47:14.705692278 +0100
+++ /var/tmp/diff_new_pack.fAT18P/_new  2021-02-08 11:47:14.709692285 +0100
@@ -17,7 +17,7 @@
 
 
 Name:           python-rpm-macros
-Version:        20210131.ec7577b
+Version:        20210204.937b8d8
 Release:        0
 Summary:        RPM macros for building of Python modules
 License:        WTFPL

++++++ _servicedata ++++++
--- /var/tmp/diff_new_pack.fAT18P/_old  2021-02-08 11:47:14.773692389 +0100
+++ /var/tmp/diff_new_pack.fAT18P/_new  2021-02-08 11:47:14.773692389 +0100
@@ -1,4 +1,4 @@
 <servicedata>
 <service name="tar_scm">
                 <param 
name="url">git://github.com/openSUSE/python-rpm-macros.git</param>
-              <param 
name="changesrevision">296eb32e76011293f6949392aec8c12c63febdc9</param></service></servicedata>
\ No newline at end of file
+              <param 
name="changesrevision">fa7e1c660af29c643cdc478cafed01042f95fad7</param></service></servicedata>
\ No newline at end of file

++++++ python-rpm-macros-20210131.ec7577b.tar.xz -> 
python-rpm-macros-20210204.937b8d8.tar.xz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-rpm-macros-20210131.ec7577b/README.md 
new/python-rpm-macros-20210204.937b8d8/README.md
--- old/python-rpm-macros-20210131.ec7577b/README.md    2021-01-31 
21:37:58.000000000 +0100
+++ new/python-rpm-macros-20210204.937b8d8/README.md    2021-02-04 
22:47:54.000000000 +0100
@@ -218,11 +218,14 @@
 * __`%python_install`__ expands to distutils/setuptools install instructions 
for all flavors.
 
 * __`%pyproject_wheel`__ expands to 
-[PEP517](https://www.python.org/dev/peps/pep-0517)/[PEP518](https://www.python.org/dev/peps/pep-0518/)
-build instructions for all flavors and creates wheels. This is useful if the 
package has a 
-``pyproject.toml`` file but no ``setup.py``
+  
[PEP517](https://www.python.org/dev/peps/pep-0517)/[PEP518](https://www.python.org/dev/peps/pep-0518/)
+  build instructions for all flavors, creates wheels and places them into the 
flavor's `build/` directories.
+  This is useful if the package has a ``pyproject.toml`` file but no 
``setup.py``.
 
-* __`%pyproject_install`__ expands to install instructions for all flavors to 
install the created wheels.
+* __`%pyproject_install [wheelfile]`__ expands to install instructions for all 
flavors to install the created wheels.
+  You can also use this without `%pyproject_wheel`, if you place a 
pre-existing wheel into the current working dir
+  (deprecated), the `build/` directory of the current flavor (what 
`%pyproject_wheel` does), or specify
+  the path to the wheel file explicitly as argument to the macro (preferred), 
e.g `%pyproject_install %{SOURCE0}`.
 
 * __`%python_compileall`__ precompiles all python source files in 
`%{python_sitelib}` and `%{python_sitearch}`
 for all flavors. Generally Python 2 creates the cached byte-code `.pyc` files 
directly in the script directories, while
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-rpm-macros-20210131.ec7577b/buildset.in 
new/python-rpm-macros-20210204.937b8d8/buildset.in
--- old/python-rpm-macros-20210131.ec7577b/buildset.in  2021-01-31 
21:37:58.000000000 +0100
+++ new/python-rpm-macros-20210204.937b8d8/buildset.in  1970-01-01 
01:00:00.000000000 +0100
@@ -1,20 +0,0 @@
-# buildset.in: prjconf definitions for python-rpm-macros.
-#
-# This is usually overridden by the distribution's prjconf, landing in 
~/.rpmmacros.
-# This file provides the default definition from Factory (Tumbleweed) for pure 
rpmbuild packaging.
-
-# order of %pythons is important: The last flavor overrides any operation on 
conflicting files and definitions during expansions,
-# making it the "default" in many cases --> keep the primary python3 provider 
at the end.
-%pythons %{?!skip_python3:%{?!skip_python36:python36} 
%{?!skip_python38:python38}}
-%skip_python2 1
-%_without_python2 1
-
-# This method for generating python_modules gets too deep to expand for rpm at 
about 5 python flavors.
-# Hence, python_module_iter is replaced by python_module_lua in macros.lua.
-# However, OBS cannot expand lua, but has a much higher expansion depth, so 
this works fine for the server side resolver.
-%python_module_iter(a:) %{expand:%%define python %{-a*}} ( %python-%args ) 
%{expand:%%{?!python_module_iter_%1:%%{python_module_iter 
-a%*}}%%{?python_module_iter_%1}}
-# pseudo-undefine for obs: reset for the next expansion within the next call 
of python_module
-%python_module_iter_STOP %global python %%%%python
-%python_module() %{?!python_module_lua:%{expand:%%define args %{**}} 
%{expand:%%{python_module_iter -a %{pythons} 
STOP}}}%{?python_module_lua:%python_module_lua %{**}}
-
-%add_python() %{expand:%%define pythons %pythons %1}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-rpm-macros-20210131.ec7577b/compile-macros.sh 
new/python-rpm-macros-20210204.937b8d8/compile-macros.sh
--- old/python-rpm-macros-20210131.ec7577b/compile-macros.sh    2021-01-31 
21:37:58.000000000 +0100
+++ new/python-rpm-macros-20210204.937b8d8/compile-macros.sh    2021-02-04 
22:47:54.000000000 +0100
@@ -14,10 +14,22 @@
 done
 
 
-### buildset: %pythons, %python_module and %add_python, usually overidden
-# by the distribution's prjconf
-cat buildset.in > macros/040-buildset
-
+### buildset: %pythons, %python_module and %add_python, coming from
+# the current build target's prjconf
+echo "Setting buildset:"
+echo "## Python Buildset Begin" | tee macros/040-builset-start
+# First try to find the block from Factory
+sed -n '/## PYTHON MACROS BEGIN/,/## PYTHON MACROS END/ p' ~/.rpmmacros | tee 
macros/041-buildset
+# If that fails, find the old definitions (SUSE:SLE-15-SP?:GA, 
openSUSE:Leap:15.?)
+if [ ! -s macros/041-buildset ]; then
+    sed -n '/%pythons/,/%add_python/ p' ~/.rpmmacros | tee macros/041-buildset
+fi
+# If we still have nothing (different distro, custom prjconf, building
+# python-rpm-macros outside of obs), use the default file
+if [ ! -s macros/041-buildset ]; then
+    tee macros/041-buildset < default-prjconf
+fi
+echo "## Python Buildset End" | tee macros/042-builset-end
 
 ### Lua: generate automagic from macros.in and macros.lua
 (
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-rpm-macros-20210131.ec7577b/default-prjconf 
new/python-rpm-macros-20210204.937b8d8/default-prjconf
--- old/python-rpm-macros-20210131.ec7577b/default-prjconf      1970-01-01 
01:00:00.000000000 +0100
+++ new/python-rpm-macros-20210204.937b8d8/default-prjconf      2021-02-04 
22:47:54.000000000 +0100
@@ -0,0 +1,23 @@
+# default-prjconf: buildset definitions for python-rpm-macros.
+#
+# This is usually overridden by the distribution's prjconf, landing in 
~/.rpmmacros.
+# This file provides the default definition from Factory (Tumbleweed) for pure 
rpmbuild packaging.
+
+# Macros:
+## PYTHON MACROS BEGIN
+# order of %pythons is important: The last flavor overrides any operation on 
conflicting files and definitions during expansions,
+# making it the "default" in many cases --> keep the primary python3 provider 
at the end.
+%pythons %{?!skip_python3:%{?!skip_python36:python36} 
%{?!skip_python38:python38}}
+%add_python() %{expand:%%define pythons %1 %pythons}
+
+%_without_python2 1
+
+# This method for generating python_modules gets too deep to expand for rpm at 
about 5 python flavors.
+# Hence, python_module_iter is replaced by python_module_lua in macros.lua.
+# However, OBS cannot expand lua, but has a much higher expansion depth, so 
this works fine for the server side resolver.
+%python_module_iter(a:) %{expand:%%define python %{-a*}} ( %python-%args ) 
%{expand:%%{?!python_module_iter_%1:%%{python_module_iter 
-a%*}}%%{?python_module_iter_%1}}
+# pseudo-undefine for obs: reset for the next expansion within the next call 
of python_module
+%python_module_iter_STOP %global python %%%%python
+%python_module() %{?!python_module_lua:%{expand:%%define args %{**}} 
%{expand:%%{python_module_iter -a %{pythons} 
STOP}}}%{?python_module_lua:%python_module_lua %{**}}
+## PYTHON MACROS END
+# :Macros
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/python-rpm-macros-20210131.ec7577b/macros/010-common-defs 
new/python-rpm-macros-20210204.937b8d8/macros/010-common-defs
--- old/python-rpm-macros-20210131.ec7577b/macros/010-common-defs       
2021-01-31 21:37:58.000000000 +0100
+++ new/python-rpm-macros-20210204.937b8d8/macros/010-common-defs       
2021-02-04 22:47:54.000000000 +0100
@@ -143,23 +143,30 @@
 ##### PEP-518 macros #####
 
%pyproject_wheel(+abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789_-=)
 %{lua:\
     local args = rpm.expand("%**"); \
-    local pyexpandstart = "%{python_expand "; \
+    local pyexpandstart = "%{python_expand # \\n"; \
     local buildwheel = "$python -mpip wheel --no-deps 
%{?py_setup_args:--build-option %{py_setup_args}}"; \
     buildwheel = buildwheel .. " --disable-pip-version-check --use-pep517 
--no-build-isolation --progress-bar off --verbose . -w build/ "; \
     -- remove abi and platform tags from filename in case the package does 
define them incorrectly (see PEP427 for valid filenames) \
     -- single percent for shell out of four percent by rpm.expand \
-    local renamewheel = "fn=(build/*.whl); mv -n $fn 
${fn%%%%-*-*.whl}-none-any.whl"; \
+    local renamewheel = "fn=(build/*.whl); fn2=${fn%%%%-*-*.whl}-none-any.whl; 
if [ ! $fn -ef $fn2 ]; then mv $fn $fn2; fi"; \
     local pyexpandend = "}"; \
-    print(rpm.expand(pyexpandstart .. buildwheel .. args .. "; " .. 
renamewheel .. pyexpandend)) \
+    print(rpm.expand(pyexpandstart .. buildwheel .. args .. "\\n " .. 
renamewheel .. pyexpandend)) \
 }
 
 # No such option: --strip-file-prefix %%{buildroot} 
 
%pyproject_install(+abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789_-=)
 %{lua:\
     local args = rpm.expand("%**"); \
     local broot = rpm.expand("--root %buildroot"); \
-    local intro = "%{python_expand $python -mpip install " .. broot .. " 
--disable-pip-version-check --no-compile --no-deps  --progress-bar off 
build/*.whl"; \
-    print(rpm.expand(intro .. args .. "}")) \
-    print(rpm.expand("%python_compileall"))
+    local pyexpandstart = "%{python_expand # \\n"; \
+    local findwheel = "wheelinargs=0 \\n"; \
+    if args ~= "" then \
+      findwheel = findwheel .. "for a in " .. args .. "; do if [ -f $a -a ${a: 
-3} = 'whl' ]; then wheelinargs=1; break; fi; done \\n"; \
+    end \
+    findwheel = findwheel .. "if [ $wheelinargs -eq 0 ]; then if [ -f 
build/*.whl ]; then wheelname=build/*.whl; else wheelname=*.whl; fi; fi \\n"; \
+    local installwheel = "$python -mpip install " .. broot .. " 
--disable-pip-version-check --no-compile --no-deps  --progress-bar off " .. 
args .. " $wheelname"; \
+    local pyexpandend = "}"; \
+    print(rpm.expand(pyexpandstart .. findwheel .. installwheel .. 
pyexpandend)) \
+    print(rpm.expand("%python_compileall")) \
 }
 
 ##### Precompile scripts macro #####

Reply via email to