-
Notifications
You must be signed in to change notification settings - Fork 0
/
PyYAML.spec
121 lines (98 loc) · 3.34 KB
/
PyYAML.spec
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
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
#
# This file is auto-generated. DO NOT EDIT
# Generated by: autospec.py
#
Name : PyYAML
Version : 3.13
Release : 47
URL : https://files.pythonhosted.org/packages/9e/a3/1d13970c3f36777c583f136c136f804d70f500168edc1edea6daa7200769/PyYAML-3.13.tar.gz
Source0 : https://files.pythonhosted.org/packages/9e/a3/1d13970c3f36777c583f136c136f804d70f500168edc1edea6daa7200769/PyYAML-3.13.tar.gz
Summary : YAML parser and emitter for Python
Group : Development/Tools
License : MIT
Requires: PyYAML-license = %{version}-%{release}
Requires: PyYAML-python = %{version}-%{release}
Requires: PyYAML-python3 = %{version}-%{release}
BuildRequires : Cython
BuildRequires : Cython-legacypython
BuildRequires : buildreq-distutils23
BuildRequires : buildreq-distutils3
BuildRequires : python-dev
BuildRequires : python3-dev
BuildRequires : yaml-dev
Patch1: 0001-CVE-2017-18342-1.patch
Patch2: 0002-CVE-2017-18342-2.patch
%description
and interaction with scripting languages. PyYAML is a YAML parser
and emitter for Python.
PyYAML features a complete YAML 1.1 parser, Unicode support, pickle
support, capable extension API, and sensible error messages. PyYAML
supports standard YAML tags and provides Python-specific tags that
allow to represent an arbitrary Python object.
PyYAML is applicable for a broad range of tasks from complex
configuration files to object serialization and persistance.
%package legacypython
Summary: legacypython components for the PyYAML package.
Group: Default
Requires: python-core
%description legacypython
legacypython components for the PyYAML package.
%package license
Summary: license components for the PyYAML package.
Group: Default
%description license
license components for the PyYAML package.
%package python
Summary: python components for the PyYAML package.
Group: Default
Requires: PyYAML-python3 = %{version}-%{release}
Provides: pyyaml-python
%description python
python components for the PyYAML package.
%package python3
Summary: python3 components for the PyYAML package.
Group: Default
Requires: python3-core
%description python3
python3 components for the PyYAML package.
%prep
%setup -q -n PyYAML-3.13
%patch1 -p1
%patch2 -p1
%build
export http_proxy=http://127.0.0.1:9/
export https_proxy=http://127.0.0.1:9/
export no_proxy=localhost,127.0.0.1,0.0.0.0
export LANG=C
export SOURCE_DATE_EPOCH=1551413140
export LDFLAGS="${LDFLAGS} -fno-lto"
python2 setup.py build -b py2
python3 setup.py build -b py3
%check
export http_proxy=http://127.0.0.1:9/
export https_proxy=http://127.0.0.1:9/
export no_proxy=localhost,127.0.0.1,0.0.0.0
python setup.py test || :
%install
export SOURCE_DATE_EPOCH=1551413140
rm -rf %{buildroot}
mkdir -p %{buildroot}/usr/share/package-licenses/PyYAML
cp LICENSE %{buildroot}/usr/share/package-licenses/PyYAML/LICENSE
python2 -tt setup.py build -b py2 install --root=%{buildroot} --force
python3 -tt setup.py build -b py3 install --root=%{buildroot} --force
echo ----[ mark ]----
cat %{buildroot}/usr/lib/python3*/site-packages/*/requires.txt || :
echo ----[ mark ]----
%files
%defattr(-,root,root,-)
%files legacypython
%defattr(-,root,root,-)
/usr/lib/python2*/*
%files license
%defattr(0644,root,root,0755)
/usr/share/package-licenses/PyYAML/LICENSE
%files python
%defattr(-,root,root,-)
%files python3
%defattr(-,root,root,-)
/usr/lib/python3*/*