]>
Commit | Line | Data |
---|---|---|
c7cd6df2 AM |
1 | # Conditional build: |
2 | %bcond_without tests # unit tests | |
3 | ||
4 | %define pkgname huawei-lte-api | |
5 | %define module huawei_lte_api | |
6 | ||
7 | Summary: API For huawei LAN/WAN LTE Modems | |
8 | Name: python3-huawei-lte-api | |
8bb273da | 9 | Version: 1.5.4 |
c0fa7a20 | 10 | Release: 2 |
c7cd6df2 AM |
11 | License: LGPL v3 |
12 | Group: Libraries/Python | |
13 | # if pypi: | |
14 | Source0: https://github.com/Salamek/huawei-lte-api/archive/refs/tags/%{version}.tar.gz | |
8bb273da | 15 | # Source0-md5: cea830d59b5b9f0846b3e333100c614d |
c7cd6df2 AM |
16 | URL: https://github.com/Salamek/huawei-lte-api |
17 | BuildRequires: python3-modules >= 1:3.2 | |
18 | %if %{with tests} | |
3fe0da3c | 19 | BuildRequires: python3-pycryptodomex |
c7cd6df2 AM |
20 | BuildRequires: python3-dicttoxml |
21 | BuildRequires: python3-xmltodict | |
22 | %endif | |
23 | BuildRequires: rpm-pythonprov | |
24 | BuildRequires: rpmbuild(macros) >= 1.714 | |
25 | Requires: python3-modules >= 1:3.2 | |
26 | BuildArch: noarch | |
27 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
28 | ||
29 | %description | |
30 | API For huawei LAN/WAN LTE Modems, you can use this to simply send | |
31 | SMS, get information about your internet usage, signal, and tons of | |
32 | other stuff. | |
33 | ||
34 | %prep | |
35 | %setup -q -n %{pkgname}-%{version} | |
36 | ||
37 | %build | |
38 | %py3_build | |
39 | ||
40 | %if %{with tests} | |
41 | %{__python3} -m pytest tests | |
42 | %endif | |
43 | ||
44 | %install | |
45 | rm -rf $RPM_BUILD_ROOT | |
46 | ||
47 | %py3_install | |
48 | ||
49 | %clean | |
50 | rm -rf $RPM_BUILD_ROOT | |
51 | ||
52 | %files | |
53 | %defattr(644,root,root,755) | |
54 | %doc README.md | |
33637b01 | 55 | %{py3_sitescriptdir}/%{module} |
3fe0da3c | 56 | %{py3_sitescriptdir}/%{module}-%{version}*-py*.egg-info |