%define scl rh-python36 %{?scl:%scl_package %{name}} %{!?scl:%global pkg_name %{name}} %define _unpackaged_files_terminate_build 0 %define name azure-mgmt-nspkg %define version 2.0.0 %define unmangled_version 2.0.0 %define unmangled_version 2.0.0 %define release 2 Summary: Microsoft Azure Resource Management Namespace Package [Internal] %{?scl:Requires: %{scl}-runtime} %{?scl:BuildRequires: %{scl}-runtime} Name: %{?scl_prefix}azure-mgmt-nspkg Version: %{version} Release: %{release} Source0: azure-mgmt-nspkg-%{unmangled_version}.zip License: MIT License Group: Development/Libraries BuildRoot: %{_tmppath}/azure-mgmt-nspkg-%{version}-%{release}-buildroot Prefix: %{_prefix} BuildArch: noarch Vendor: Microsoft Corporation Packager: Martin Juhl Url: https://github.com/Azure/azure-sdk-for-python %description Microsoft Azure SDK for Python ============================== This is the Microsoft Azure Management namespace package. This package is not intended to be installed directly by the end user. It provides the necessary files for other packages to extend the azure.mgmt namespace. If you are looking to install the Azure client libraries, see the `azure `__ bundle package. %prep %{?scl:scl enable %{scl} - << \EOF} set -ex %setup -n azure-mgmt-nspkg-%{unmangled_version} -n azure-mgmt-nspkg-%{unmangled_version} %{?scl:EOF} %build %{?scl:scl enable %{scl} - << \EOF} set -ex python3 setup.py build %{?scl:EOF} %install %{?scl:scl enable %{scl} - << \EOF} set -ex python3 setup.py install --single-version-externally-managed -O1 --root=$RPM_BUILD_ROOT --record=INSTALLED_FILES %{?scl:EOF} cat INSTALLED_FILES |grep -v "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/azure/__pycache__" |grep -v "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/azure/__init__.py" |grep -v "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/azure/mgmt/__pycache__" |grep -v "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/azure/mgmt/__init__.py" > INSTALLED_FILES_WITHOUT_COMMON_PYCACHE %clean %{?scl:scl enable %{scl} - << \EOF} set -ex rm -rf $RPM_BUILD_ROOT %{?scl:EOF} %files -f INSTALLED_FILES_WITHOUT_COMMON_PYCACHE %defattr(-,root,root)