3 %bcond_without python2 # CPython 2.x module
4 %bcond_without python3 # CPython 3.x module
8 Summary: Python 2 library for working with RDF
9 Summary(pl.UTF-8): Biblioteka Pythona 2 do pracy z RDF
10 Name: python-%{module}
14 Group: Development/Languages/Python
15 Source0: https://github.com/RDFLib/rdflib/archive/%{version}/%{module}-%{version}.tar.gz
16 # Source0-md5: 1dd95c6443302d6a44a908e4af8fdc5d
17 URL: https://github.com/RDFLib/rdflib
18 BuildRequires: rpm-pythonprov
19 BuildRequires: rpmbuild(macros) >= 1.714
21 BuildRequires: python-modules >= 1:2.6
22 BuildRequires: python-setuptools
25 BuildRequires: python3-modules >= 1:3.3
26 BuildRequires: python3-setuptools
28 Requires: python-modules >= 1:2.6
30 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
33 RDFLib is a Python library for working with RDF, a simple yet powerful
34 language for representing information. The library contains an RDF/XML
35 parser/serializer, a TripleStore, an InformationStore and various
36 store backends. It is being developed by Daniel Krech along with the
37 help of a number of contributors.
39 %description -l pl.UTF-8
40 RDFLib to biblioteka Pythona do pracy z RDF - prostym, ale potężnym
41 językiem do reprezentowania informacji. Biblioteka zawiera
42 parser/serializer RDF/XML, TripleStore, InformationStore oraz różne
43 backendy do przechowywania informacji. Jest rozwijana przez Daniela
44 Krecha z pomocą wielu współpracowników.
46 %package -n python3-%{module}
47 Summary: Python 3 library for working with RDF
48 Summary(pl.UTF-8): Biblioteka Pythona 3 do pracy z RDF
49 Group: Libraries/Python
50 Requires: python3-modules >= 1:3.3
52 %description -n python3-%{module}
53 RDFLib is a Python library for working with RDF, a simple yet powerful
54 language for representing information. The library contains an RDF/XML
55 parser/serializer, a TripleStore, an InformationStore and various
56 store backends. It is being developed by Daniel Krech along with the
57 help of a number of contributors.
59 %description -n python3-%{module} -l pl.UTF-8
60 RDFLib to biblioteka Pythona do pracy z RDF - prostym, ale potężnym
61 językiem do reprezentowania informacji. Biblioteka zawiera
62 parser/serializer RDF/XML, TripleStore, InformationStore oraz różne
63 backendy do przechowywania informacji. Jest rozwijana przez Daniela
64 Krecha z pomocą wielu współpracowników.
66 %package -n rdflib-tools
67 Summary: Utilities from python-rdflib
68 Summary(pl.UTF-8): Narzędzia z pakietu python-rdflib
69 Group: Applications/File
71 Requires: python3-%{module} = %{version}-%{release}
73 Requires: %{name} = %{version}-%{release}
76 %description -n rdflib-tools
77 Utilities from python-rdflib.
79 %description -n rdflib-tools -l pl.UTF-8
80 Narzędzia z pakietu python-rdflib.
83 %setup -q -n %{module}-%{version}
87 %py_build %{?with_tests:test}
91 %py3_build %{?with_tests:test}
95 rm -rf $RPM_BUILD_ROOT
102 install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
103 cp -p examples/*.py $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
109 install -d $RPM_BUILD_ROOT%{_examplesdir}/python3-%{module}-%{version}
110 cp -p examples/*.py $RPM_BUILD_ROOT%{_examplesdir}/python3-%{module}-%{version}
114 rm -rf $RPM_BUILD_ROOT
117 %defattr(644,root,root,755)
118 %doc CHANGELOG.md CONTRIBUTORS LICENSE README.md
119 %{py_sitescriptdir}/rdflib
120 %{py_sitescriptdir}/rdflib-%{version}-py*.egg-info
121 %{_examplesdir}/%{name}-%{version}
123 %files -n python3-%{module}
124 %defattr(644,root,root,755)
125 %doc CHANGELOG.md CONTRIBUTORS LICENSE README.md
126 %{py3_sitescriptdir}/rdflib
127 %{py3_sitescriptdir}/rdflib-%{version}-py*.egg-info
128 %{_examplesdir}/python3-%{module}-%{version}
130 %files -n rdflib-tools
131 %defattr(644,root,root,755)
132 %attr(755,root,root) %{_bindir}/csv2rdf
133 %attr(755,root,root) %{_bindir}/rdf2dot
134 %attr(755,root,root) %{_bindir}/rdfgraphisomorphism
135 %attr(755,root,root) %{_bindir}/rdfpipe
136 %attr(755,root,root) %{_bindir}/rdfs2dot