RHEL 9.0.0 Alpha bootstrap
The content of this branch was automatically imported from Fedora ELN with the following as its source: https://src.fedoraproject.org/rpms/python-rpm-macros#626168789c73d62eb211ec72fe260a128e66df45
This commit is contained in:
parent
b18966f2a7
commit
f73468722f
@ -1,64 +0,0 @@
|
|||||||
%python2_sitelib %(%{__python2} -Esc "from distutils.sysconfig import get_python_lib; print(get_python_lib())")
|
|
||||||
%python2_sitearch %(%{__python2} -Esc "from distutils.sysconfig import get_python_lib; print(get_python_lib(1))")
|
|
||||||
%python2_version %(%{__python2} -Esc "import sys; sys.stdout.write('{0.major}.{0.minor}'.format(sys.version_info))")
|
|
||||||
%python2_version_nodots %(%{__python2} -Esc "import sys; sys.stdout.write('{0.major}{0.minor}'.format(sys.version_info))")
|
|
||||||
%python2_platform %(%{__python2} -Esc "import sysconfig; print(sysconfig.get_platform())")
|
|
||||||
|
|
||||||
%py2_shbang_opts -s
|
|
||||||
%py2_shbang_opts_nodash %(opts=%{py2_shbang_opts}; echo ${opts#-})
|
|
||||||
%py2_shebang_flags %(opts=%{py2_shbang_opts}; echo ${opts#-})
|
|
||||||
%py2_shebang_fix %{expand:\\\
|
|
||||||
if [ -z "%{?py_shebang_flags}" ]; then
|
|
||||||
shebang_flags="-k"
|
|
||||||
else
|
|
||||||
shebang_flags="-ka%{py2_shebang_flags}"
|
|
||||||
fi
|
|
||||||
/usr/bin/pathfix.py -pni %{__python2} $shebang_flags}
|
|
||||||
|
|
||||||
# Use the slashes after expand so that the command starts on the same line as
|
|
||||||
# the macro
|
|
||||||
# The `sleep 1` commands work around a race in install; see:
|
|
||||||
# https://bugzilla.redhat.com/show_bug.cgi?id=1644923
|
|
||||||
%py2_build() %{expand:\\\
|
|
||||||
sleep 1
|
|
||||||
CFLAGS="${CFLAGS:-${RPM_OPT_FLAGS}}" LDFLAGS="${LDFLAGS:-${RPM_LD_FLAGS}}"\\\
|
|
||||||
%{__python2} %{py_setup} %{?py_setup_args} build --executable="%{__python2} %{py2_shbang_opts}" %{?*}
|
|
||||||
sleep 1
|
|
||||||
}
|
|
||||||
|
|
||||||
%py2_build_egg() %{expand:\\\
|
|
||||||
sleep 1
|
|
||||||
CFLAGS="${CFLAGS:-${RPM_OPT_FLAGS}}" LDFLAGS="${LDFLAGS:-${RPM_LD_FLAGS}}"\\\
|
|
||||||
%{__python2} %{py_setup} %{?py_setup_args} bdist_egg %{?*}
|
|
||||||
sleep 1
|
|
||||||
}
|
|
||||||
|
|
||||||
%py2_build_wheel() %{expand:\\\
|
|
||||||
sleep 1
|
|
||||||
CFLAGS="${CFLAGS:-${RPM_OPT_FLAGS}}" LDFLAGS="${LDFLAGS:-${RPM_LD_FLAGS}}"\\\
|
|
||||||
%{__python2} %{py_setup} %{?py_setup_args} bdist_wheel %{?*}
|
|
||||||
sleep 1
|
|
||||||
}
|
|
||||||
|
|
||||||
%py2_install() %{expand:\\\
|
|
||||||
CFLAGS="${CFLAGS:-${RPM_OPT_FLAGS}}" LDFLAGS="${LDFLAGS:-${RPM_LD_FLAGS}}"\\\
|
|
||||||
%{__python2} %{py_setup} %{?py_setup_args} install -O1 --skip-build --root %{buildroot} %{?*}
|
|
||||||
rm -rfv %{buildroot}%{_bindir}/__pycache__
|
|
||||||
}
|
|
||||||
|
|
||||||
%py2_install_egg() %{expand:\\\
|
|
||||||
mkdir -p %{buildroot}%{python2_sitelib}
|
|
||||||
%{__python2} -m easy_install -m --prefix %{buildroot}%{_prefix} -Z dist/*-py%{python2_version}.egg %{?*}
|
|
||||||
rm -rfv %{buildroot}%{_bindir}/__pycache__
|
|
||||||
}
|
|
||||||
|
|
||||||
%py2_install_wheel() %{expand:\\\
|
|
||||||
%{__python2} -m pip install -I dist/%{1} --root %{buildroot} --no-deps --no-index --no-warn-script-location
|
|
||||||
rm -rfv %{buildroot}%{_bindir}/__pycache__
|
|
||||||
for distinfo in %{buildroot}%{python2_sitelib}/*.dist-info %{buildroot}%{python2_sitearch}/*.dist-info; do
|
|
||||||
if [ -f ${distinfo}/direct_url.json ]; then
|
|
||||||
rm -fv ${distinfo}/direct_url.json
|
|
||||||
sed -i '/direct_url.json/d' ${distinfo}/RECORD
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
}
|
|
@ -1,6 +1,6 @@
|
|||||||
Name: python-rpm-macros
|
Name: python-rpm-macros
|
||||||
Version: 3.9
|
Version: 3.9
|
||||||
Release: 13%{?dist}
|
Release: 34%{?dist}
|
||||||
Summary: The common Python RPM macros
|
Summary: The common Python RPM macros
|
||||||
|
|
||||||
# macros and lua: MIT, compileall2.py: PSFv2
|
# macros and lua: MIT, compileall2.py: PSFv2
|
||||||
@ -9,7 +9,6 @@ License: MIT and Python
|
|||||||
# Macros:
|
# Macros:
|
||||||
Source101: macros.python
|
Source101: macros.python
|
||||||
Source102: macros.python-srpm
|
Source102: macros.python-srpm
|
||||||
Source103: macros.python2
|
|
||||||
Source104: macros.python3
|
Source104: macros.python3
|
||||||
Source105: macros.pybytecompile
|
Source105: macros.pybytecompile
|
||||||
|
|
||||||
@ -48,19 +47,6 @@ Provides: bundled(python3dist(compileall2)) = %{compileall2_version}
|
|||||||
RPM macros for building Python source packages.
|
RPM macros for building Python source packages.
|
||||||
|
|
||||||
|
|
||||||
%package -n python2-rpm-macros
|
|
||||||
Summary: RPM macros for building Python 2 packages
|
|
||||||
|
|
||||||
# For %%__python2 and %%python2
|
|
||||||
Requires: python-srpm-macros = %{version}-%{release}
|
|
||||||
|
|
||||||
# For %%py_setup
|
|
||||||
Requires: python-rpm-macros = %{version}-%{release}
|
|
||||||
|
|
||||||
%description -n python2-rpm-macros
|
|
||||||
RPM macros for building Python 2 packages.
|
|
||||||
|
|
||||||
|
|
||||||
%package -n python3-rpm-macros
|
%package -n python3-rpm-macros
|
||||||
Summary: RPM macros for building Python 3 packages
|
Summary: RPM macros for building Python 3 packages
|
||||||
|
|
||||||
@ -99,14 +85,15 @@ install -m 644 compileall2.py %{buildroot}%{_rpmconfigdir}/redhat/
|
|||||||
%{_rpmconfigdir}/redhat/compileall2.py
|
%{_rpmconfigdir}/redhat/compileall2.py
|
||||||
%{_rpmluadir}/fedora/srpm/python.lua
|
%{_rpmluadir}/fedora/srpm/python.lua
|
||||||
|
|
||||||
%files -n python2-rpm-macros
|
|
||||||
%{rpmmacrodir}/macros.python2
|
|
||||||
|
|
||||||
%files -n python3-rpm-macros
|
%files -n python3-rpm-macros
|
||||||
%{rpmmacrodir}/macros.python3
|
%{rpmmacrodir}/macros.python3
|
||||||
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Mon Feb 08 2021 Miro Hrončok <mhroncok@redhat.com> - 3.9-34
|
||||||
|
- Remove python2-rpm-macros
|
||||||
|
- https://fedoraproject.org/wiki/Changes/Disable_Python_2_Dist_RPM_Generators_and_Freeze_Python_2_Macros
|
||||||
|
|
||||||
* Fri Feb 05 2021 Miro Hrončok <mhroncok@redhat.com> - 3.9-13
|
* Fri Feb 05 2021 Miro Hrončok <mhroncok@redhat.com> - 3.9-13
|
||||||
- Automatically word-wrap the description of extras subpackages
|
- Automatically word-wrap the description of extras subpackages
|
||||||
- Fixes: rhbz#1922442
|
- Fixes: rhbz#1922442
|
||||||
|
Loading…
Reference in New Issue
Block a user