diff options
author | Guido Günther <agx@sigxcpu.org> | 2020-08-25 10:34:33 +0200 |
---|---|---|
committer | Doesnot Matter <you@example.com> | 2020-08-25 10:36:18 +0200 |
commit | df9bae289a44a8111c970623d6ee875e50a16b0b (patch) | |
tree | 823f19c0e8fda149ad495f069b338601761d0371 | |
parent | fd35de0fa1ab45716d5d4f0513c1068e16f44c1a (diff) |
autopkgtest: Pass RPM macros on command line
This avoids the need to modify files in the home directory.
-rwxr-xr-x | debian/tests/smoke-rpm | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/debian/tests/smoke-rpm b/debian/tests/smoke-rpm index de0a62ff..a97402a5 100755 --- a/debian/tests/smoke-rpm +++ b/debian/tests/smoke-rpm @@ -8,16 +8,13 @@ git config user.email "you@example.com" git config user.name "Doesnot Matter" git add . git commit -m"Smoketest" -a -cat <<EOF >> ~/.rpmmacros -%__python3 /usr/bin/python3 -%python_sitelib %(%{__python3} -c "from distutils.sysconfig import get_python_lib; import sys; sys.stdout.write(get_python_lib().replace('dist-', 'site-'))") -%python_sitearch %(%{__python3} -c "from distutils.sysconfig import get_python_lib; import sys; sys.stdout.write(get_python_lib(1).replace('dist-', 'site-'))") -EOF gbp buildpackage-rpm --help # Build an RPM of ourselfes if build-deps are available if python3 -c "import setuptools"; then - gbp buildpackage-rpm --git-packaging-dir=packaging/ -bb --nodeps - rm -r .git ~/.rpmmacros + gbp buildpackage-rpm --git-packaging-dir=packaging/ \ + -D'%__python3 /usr/bin/python3' \ + -D'%__python /usr/bin/python3' \ + -bb --nodeps fi |