forked from pool/python-pyserial
Accepting request 515044 from home:TheBlackCat:branches:devel:languages:python
- Further fix shebangs OBS-URL: https://build.opensuse.org/request/show/515044 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pyserial?expand=0&rev=22
This commit is contained in:
@@ -1,3 +1,8 @@
|
||||
-------------------------------------------------------------------
|
||||
Mon Aug 7 16:32:29 UTC 2017 - toddrme2178@gmail.com
|
||||
|
||||
- Further fix shebangs
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Sun Aug 6 18:07:57 UTC 2017 - toddrme2178@gmail.com
|
||||
|
||||
|
@@ -53,11 +53,11 @@ Documentation, examples, and help files for %{name}.
|
||||
|
||||
%prep
|
||||
%setup -q -n pyserial-%{version}
|
||||
sed -i "s|#\!\/usr\/bin\/env python||" serial/{serialposix,__init__}.py # Fix non-executable scripts
|
||||
sed -i "s|^#\!\/usr\/bin\/env python$||" serial/{serialposix,__init__}.py # Fix non-executable scripts
|
||||
sed -i "s/\r//" examples/port_publisher.py # Fix EOL encoding
|
||||
find examples -name '*.py' -exec sed -i "s|#!/usr/bin/env python|#!%__python3|" {} \;
|
||||
find examples -name '*.py' -exec sed -i "s|#! /usr/bin/env python|#!%__python3|" {} \;
|
||||
find examples -name '*.py' -exec sed -i "s|#! python|#!%__python3|" {} \;
|
||||
find examples -name '*.py' -exec sed -i "s|^#!/usr/bin/env python$|#!%{__python3}|" {} \;
|
||||
find examples -name '*.py' -exec sed -i "s|^#! /usr/bin/env python$|#!%{__python3}|" {} \;
|
||||
find examples -name '*.py' -exec sed -i "s|^#! python$|#!%{__python3}|" {} \;
|
||||
|
||||
%build
|
||||
%python_build
|
||||
@@ -73,10 +73,10 @@ rm documentation/_build/doctrees/environment.pickle
|
||||
|
||||
%{python_expand pushd %{buildroot}%{$python_sitelib}
|
||||
# Fix wrong-script-interpreter
|
||||
sed -i "s|#!/usr/bin/env python|#!%__$python|" serial/tools/*.py
|
||||
sed -i "s|#!/usr/bin/env python|#!%__$python|" serial/threaded/__init__.py
|
||||
sed -i "s|#!/usr/bin/env python|#!%__$python|" serial/rs485.py
|
||||
sed -i "s|#! python||#!%__$python|" serial/tools/*.py
|
||||
sed -i "s|^#!/usr/bin/env python$|#!%{__$python}|" serial/tools/*.py
|
||||
sed -i "s|^#!/usr/bin/env python3$|#!%{__$python}|" serial/threaded/__init__.py
|
||||
sed -i "s|^#!/usr/bin/env python$|#!%{__$python}|" serial/rs485.py
|
||||
sed -i "s|^#! python$||#!%{__$python}|" serial/tools/*.py
|
||||
chmod a+x serial/tools/*.py
|
||||
chmod a-x serial/tools/__init__.py
|
||||
chmod a-x serial/tools/list_ports_windows.py
|
||||
|
Reference in New Issue
Block a user