0705cb4
Name:           libsavitar
0ef2c83
Version:        3.2.1
b1e99fb
Release:        2%{?dist}
0705cb4
Summary:        C++ implementation of 3mf loading with SIP Python bindings
b1e99fb
License:        LGPLv3+
0705cb4
URL:            https://github.com/Ultimaker/libSavitar
a047ac7
Source0:        %{url}/archive/%{version}.tar.gz#/%{name}-%{version}.tar.gz
0705cb4
0705cb4
Patch0:         %{name}-no-pugixml.patch
0705cb4
0705cb4
BuildRequires:  cmake
0705cb4
BuildRequires:  dos2unix
0705cb4
BuildRequires:  gcc-c++
0705cb4
BuildRequires:  git
0705cb4
BuildRequires:  pugixml-devel
0705cb4
BuildRequires:  python3-devel
0705cb4
BuildRequires:  python3-sip-devel
0705cb4
BuildRequires:  /usr/bin/sip
0705cb4
0705cb4
%description
0705cb4
Savitar is a C++ implementation of 3mf loading with SIP Python bindings.
0705cb4
3mf is a 3D printing file format.
0705cb4
0705cb4
%package        devel
0705cb4
0705cb4
# The cmake scripts are BSD
0705cb4
License:        AGPLv3+ and BSD
0705cb4
0705cb4
Summary:        Development files for libsavitar
0705cb4
Requires:       %{name}%{?_isa} = %{version}-%{release}
0705cb4
0705cb4
%description    devel
0705cb4
Savitar is a C++ implementation of 3mf loading with SIP Python bindings.
0705cb4
3mf is a 3D printing file format.
0705cb4
0705cb4
Development files.
0705cb4
0705cb4
%package -n     python3-savitar
0705cb4
Summary:        Python 3 libSavitar bindings
0705cb4
%{?python_provide:%python_provide python3-savitar}
0705cb4
0705cb4
%description -n python3-savitar
0705cb4
Savitar is a C++ implementation of 3mf loading with SIP Python bindings.
0705cb4
3mf is a 3D printing file format.
0705cb4
0705cb4
The Python bindings.
0705cb4
0705cb4
%prep
a047ac7
%autosetup -n libSavitar-%{version} -p1 -S git
0705cb4
0705cb4
# Wrong end of line encoding
0705cb4
dos2unix README.md
0705cb4
0705cb4
# Bundling
0705cb4
rm pugixml -rf
0705cb4
sed -i 's|"../pugixml/src/pugixml.hpp"|<pugixml.hpp>|g' src/*.cpp src/*.h
0705cb4
0705cb4
0705cb4
%build
0705cb4
export CXXFLAGS="%{optflags} -Wl,--as-needed"
0705cb4
%{cmake} -DCMAKE_SKIP_RPATH:BOOL=ON .
0705cb4
make %{?_smp_mflags}
0705cb4
0705cb4
%install
0705cb4
make install DESTDIR=%{buildroot}
0705cb4
0705cb4
%post -p /sbin/ldconfig
0705cb4
0705cb4
%postun -p /sbin/ldconfig
0705cb4
0705cb4
%files
0705cb4
%license LICENSE
0705cb4
%doc README.md
0705cb4
%{_libdir}/libSavitar.so.*
0705cb4
0705cb4
%files devel
0705cb4
%license LICENSE cmake/COPYING-CMAKE-SCRIPTS
0705cb4
%{_libdir}/libSavitar.so
0705cb4
%{_includedir}/Savitar
0705cb4
# Own the dir not to depend on cmake:
0705cb4
%{_libdir}/cmake
0705cb4
0705cb4
%files -n python3-savitar
0705cb4
%license LICENSE
0705cb4
%doc README.md
0705cb4
%{python3_sitearch}/Savitar.so
0705cb4
0705cb4
%changelog
b1e99fb
* Mon Mar 19 2018 Miro Hrončok <mhroncok@redhat.com> - 3.2.1-2
b1e99fb
- Fix license tag (AGPLv3+ to LGPLv3+)
b1e99fb
0ef2c83
* Mon Mar 19 2018 Miro Hrončok <mhroncok@redhat.com> - 3.2.1-1
0ef2c83
- Update to 3.2.1 (#1523886)
0ef2c83
91687db
* Wed Feb 07 2018 Fedora Release Engineering <releng@fedoraproject.org> - 3.1.0-2
91687db
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
91687db
60846cd
* Sat Dec 09 2017 Miro Hrončok <mhroncok@redhat.com> - 3.1.0-1
60846cd
- Update to 3.1.0 (#1523886)
60846cd
- Don't sed lib -> lib64 (not needed now)
60846cd
2ef0ff0
* Mon Oct 23 2017 Miro Hrončok <mhroncok@redhat.com> - 3.0.3-1
2ef0ff0
- Update to 3.0.3 (#1505189)
2ef0ff0
6fd1db5
* Wed Aug 30 2017 Miro Hrončok <mhroncok@redhat.com> - 2.7.0-1
6fd1db5
- Update to 2.7.0 (#1486731)
6fd1db5
835e843
* Thu Aug 03 2017 Fedora Release Engineering <releng@fedoraproject.org> - 2.6.1-3
835e843
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild
835e843
10f3b78
* Wed Jul 26 2017 Fedora Release Engineering <releng@fedoraproject.org> - 2.6.1-2
10f3b78
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
10f3b78
e217602
* Wed Jun 28 2017 Miro Hrončok <mhroncok@redhat.com> - 2.6.1-1
e217602
- Updated to 2.6.1 (#1465417)
e217602
a047ac7
* Tue Jun 27 2017 Miro Hrončok <mhroncok@redhat.com> - 2.6.0-1
a047ac7
- Updated to 2.6.0 (#1465417)
a047ac7
0705cb4
* Wed May 03 2017 Miro Hrončok <mhroncok@redhat.com> - 0-0.1.20170501git1ad7ddb
0705cb4
- New package