9 Star 0 Fork 9

src-openEuler/pyserial

Create your Gitee Account
Explore and code with more than 13.5 million developers,Free private repositories !:)
Sign up
文件
This repository doesn't specify license. Please pay attention to the specific project description and its upstream code dependency when using it.
Clone or Download
pyserial.spec 2.78 KB
Copy Edit Raw Blame History
朱春意 authored 6 years ago . update code
Name: pyserial
Version: 3.4
Release: 2
Summary: Python serial port access library.
License: BSD license
URL: https://github.com/pyserial/pyserial
Source0: https://github.com/%{name}/%{name}/archive/v3.4.tar.gz
BuildRequires: python2-devel python3-devel
Obsoletes: pyserial < %{version}-%{release}
Provides: pyserial%{?_isa} = %{version}-%{release}
BuildArch: noarch
%description
This module encapsulates the access for the serial port. It provides
backends for Python running on Windows, OSX, Linux,BSD (possibly any POSIX compliant system)
and IronPython. The module named "serial" automatically selects the appropriate backend.
%package -n python2-%{name}
Summary: Python2 serial port access library.
%{?python_provide:%python_provide python2-%{name}}
Obsoletes: pyserial < %{version}-%{release}
Provides: pyserial%{?_isa} = %{version}-%{release}
%description -n python2-%{name}
This module encapsulates the access for the serial port. It provides
backends for Python2 running on Windows, OSX, Linux,BSD (possibly any POSIX compliant system)
and IronPython. The module named "serial" automatically selects the appropriate backend.
%package -n python3-%{name}
Summary: Python3 serial port access library.
%description -n python3-%{name}
This module encapsulates the access for the serial port. It provides
backends for Python3 running on Windows, OSX, Linux,BSD (possibly any POSIX compliant system)
and IronPython. The module named "serial" automatical
%prep
export UNZIP="-aa"
%setup -q
rm -rf %{py3dir}
cp -a . %{py3dir}
%build
CFLAGS="$RPM_OPT_FLAGS" %{__python2} setup.py build
pushd %{py3dir}
CFLAGS="$RPM_OPT_FLAGS" %{__python3} setup.py build
popd
%install
rm -rf %{buildroot}
pushd %{py3dir}
%{__python3} setup.py install --skip-build --root %{buildroot}
install -D -m 0755 %{buildroot}/%{_bindir}/miniterm.py %{buildroot}/%{_bindir}/miniterm-3.py
rm -rf %{buildroot}/%{_bindir}/miniterm.py
ln -sf %{_bindir}/miniterm.py-3 %{buildroot}/%{_bindir}/miniterm-%{python3_version}.py
popd
%{__python2} setup.py install -O1 --skip-build --root %{buildroot}
install -D -m 0755 %{buildroot}/%{_bindir}/miniterm.py %{buildroot}/%{_bindir}/miniterm-2.py
ln -sf %{_bindir}/miniterm.py-2 %{buildroot}/%{_bindir}/miniterm-%{python2_version}.py
%check
%pre
%preun
%post
%postun
%files -n python2-%{name}
%doc CHANGES.rst README.rst examples
%license LICENSE.txt
%{_bindir}/miniterm.py
%{_bindir}/miniterm-2.py
%{_bindir}/miniterm-%{python2_version}.py
%{python2_sitelib}/*
%files -n python3-%{name}
%doc CHANGES.rst README.rst examples
%license LICENSE.txt
%{_bindir}/miniterm-3.py
%{_bindir}/miniterm-%{python3_version}.py
%{python3_sitelib}/*
%changelog
* Mon Oct 21 2019 openEuler Buildteam <buildteam@openeuler.org> - 3.4-2
- Package rebuild.
* Thu Sep 12 2019 openEuler Buildteam <buildteam@openeuler.org> - 3.4-1
- Package init.
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/src-openeuler/pyserial.git
git@gitee.com:src-openeuler/pyserial.git
src-openeuler
pyserial
pyserial
openEuler-20.03-LTS-SP3

Search