-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpython-uv-build.spec
More file actions
51 lines (44 loc) · 1.28 KB
/
python-uv-build.spec
File metadata and controls
51 lines (44 loc) · 1.28 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
%undefine _debugsource_template
%define module uv-build
%define oname uv_build
Name: python-uv-build
Version: 0.11.19
Release: 1
Summary: The uv-build backend
Group: Development/Python
License: MIT OR Apache-2.0
URL: https://pypi.org/project/uv-build/
Source0: https://files.pythonhosted.org/packages/source/u/%{oname}/%{oname}-%{version}.tar.gz
Source1: %{oname}-%{version}-vendor.tar.xz
BuildSystem: python
BuildOption(prep): -p1
BuildOption(prep): -a1
BuildRequires: cargo
BuildRequires: pkgconfig(python)
BuildRequires: python%{pyver}dist(maturin)
BuildRequires: python%{pyver}dist(pip)
BuildRequires: python%{pyver}dist(wheel)
BuildRequires: rust-packaging
%description
This package is a cut down version of uv only providing the uv-build backend.
%prep -a
# prep vendorered crates
%cargo_prep -v vendor/
# create .cargo/config file from vendoring output
cat >>.cargo/config <<EOF
[source.crates-io]
replace-with = "vendored-sources"
[source.vendored-sources]
directory = "vendor"
EOF
%build -p
export CARGO_HOME=$PWD/.cargo
# sort out crate licenses
%cargo_license_summary
%{cargo_license} > LICENSES.dependencies
%files
%doc README.md
%license LICENSE-APACHE LICENSE-MIT LICENSES.dependencies
%{_bindir}/uv-build
%{python_sitearch}/%{oname}
%{python_sitearch}/%{oname}-%{version}.dist-info