## START: Set by rpmautospec ## (rpmautospec version 0.8.1) ## RPMAUTOSPEC: autorelease, autochangelog %define autorelease(e:s:pb:n) %{?-p:0.}%{lua: release_number = 1; base_release_number = tonumber(rpm.expand("%{?-b*}%{!?-b:1}")); print(release_number + base_release_number - 1); }%{?-e:.%{-e*}}%{?-s:.%{-s*}}%{!?-n:%{?dist}} ## END: Set by rpmautospec %global desc %{expand: Python bindings for the AWS Common Runtime} Name: python-awscrt Version: 0.27.2 Release: %autorelease Summary: Python bindings for the AWS Common Runtime # All files are licensed under Apache-2.0, except: # - crt/aws-c-common/include/aws/common/external/cJSON.h is MIT # - crt/aws-c-common/source/external/cJSON.c is MIT # - crt/s2n/pq-crypto/kyber_r3/KeccakP-brg_endian_avx2.h is BSD-3-Clause License: Apache-2.0 AND MIT AND BSD-3-Clause URL: https://github.com/awslabs/aws-crt-python Source0: %{pypi_source awscrt} # two tests require internet connection, skip them Patch0: skip-tests-requiring-network.patch # skip SHA1 in test_crypto Patch1: skip-SHA1-in-test_crypto.patch BuildRequires: python%{python3_pkgversion}-devel BuildRequires: gcc BuildRequires: gcc-c++ BuildRequires: cmake BuildRequires: openssl-devel BuildRequires: python%{python3_pkgversion}-websockets # https://bugzilla.redhat.com/show_bug.cgi?id=2180988 ExcludeArch: s390x %description %{desc} %package -n python%{python3_pkgversion}-awscrt Summary: %{summary} %description -n python%{python3_pkgversion}-awscrt %{desc} %prep %autosetup -p1 -n awscrt-%{version} sed -i '/target_compile_options/i list(APPEND AWS_C_FLAGS -g -ggdb3 -O0)' crt/aws-c-common/cmake/AwsCFlags.cmake # relax version requirements sed -i -e 's/setuptools>=75\.3\.1/setuptools/' -e 's/wheel>=0\.45\.1/wheel/' pyproject.toml %generate_buildrequires %pyproject_buildrequires %build %ifarch %{ix86} # disable SSE2 instructions to prevent a crash in aws-c-common thread handling # probably caused by a compiler bug export CFLAGS="%{optflags} -mno-sse2" %endif export CFLAGS="%{optflags} -mno-sse2 -g -ggdb3 -O0" export LDFLAGS="%{build_ldflags} -g -ggdb3 -O0" export VERBOSE=1 export V=1 export AWS_CRT_BUILD_USE_SYSTEM_LIBCRYPTO=1 %pyproject_wheel exit 28 %install %pyproject_install %pyproject_save_files _awscrt awscrt %files -n python%{python3_pkgversion}-awscrt -f %{pyproject_files} %doc README.md %changelog ## START: Generated by rpmautospec * Tue Jul 08 2025 John Doe - 0.27.2-1 - Uncommitted changes ## END: Generated by rpmautospec