2c6bc3
%if 0%{?rhel} <= 5
2c6bc3
%{!?python_sitearch: %global python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib(1))")}
2c6bc3
%endif
2c6bc3
2c6bc3
Name: libiptcdata
2c6bc3
Version: 1.0.4
2c6bc3
Release: 21%{?dist}
2c6bc3
Summary: IPTC tag library
2c6bc3
2c6bc3
Group: Development/Libraries
2c6bc3
License: LGPLv2+
2c6bc3
URL: http://libiptcdata.sourceforge.net/
2c6bc3
Source0: http://downloads.sourceforge.net/%{name}/%{name}-%{version}.tar.gz
2c6bc3
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
2c6bc3
BuildRequires: autoconf
2c6bc3
BuildRequires: automake
2c6bc3
BuildRequires: gettext
2c6bc3
BuildRequires: gettext-devel
2c6bc3
BuildRequires: libtool
2c6bc3
BuildRequires: gtk-doc
2c6bc3
2c6bc3
%description
2c6bc3
libiptcdata is a library for parsing, editing, and saving IPTC data
2c6bc3
stored inside images.  IPTC is a standard for encoding metadata such
2c6bc3
as captions, titles, locations, etc. in the headers of an image file.
2c6bc3
libiptcdata also includes a command-line utility for modifying the
2c6bc3
metadata.
2c6bc3
2c6bc3
%package devel
2c6bc3
Summary: Headers and libraries for libiptcdata application development
2c6bc3
Group: Development/Libraries
2c6bc3
Requires: %{name} = %{version}-%{release}
2c6bc3
Requires: pkgconfig
2c6bc3
2c6bc3
%description devel
2c6bc3
The libiptcdata-devel package contains the libraries and include files
2c6bc3
that you can use to develop libiptcdata applications.
2c6bc3
2c6bc3
%if 0%{?rhel} <= 7
2c6bc3
%package -n python2-libiptcdata
2c6bc3
%{?python_provide:%python_provide python2-libiptcdata}
2c6bc3
# Remove before F30
2c6bc3
Provides: %{name}-python = %{version}-%{release}
2c6bc3
Provides: %{name}-python%{?_isa} = %{version}-%{release}
2c6bc3
Obsoletes: %{name}-python < %{version}-%{release}
2c6bc3
Summary: Python bindings for libiptcdata
2c6bc3
Group: Development/Libraries
2c6bc3
Requires: %{name} = %{version}-%{release}
2c6bc3
BuildRequires: python-devel
2c6bc3
2c6bc3
%description -n python2-libiptcdata
2c6bc3
The libiptcdata-python package contains a Python module that allows Python
2c6bc3
applications to use the libiptcdata API for reading and writing IPTC
2c6bc3
metadata in images.
2c6bc3
%endif
2c6bc3
2c6bc3
%prep
2c6bc3
%setup -q
2c6bc3
# fix compatibility with gtk-doc 1.26
2c6bc3
for f in libiptcdata/*.{c,h} ; do
2c6bc3
  iconv -f ISO-8859-1 -t utf8 -o $f.utf8 $f && mv $f.utf8 $f
2c6bc3
done
2c6bc3
gtkdocize
2c6bc3
autoreconf -fiv
2c6bc3
2c6bc3
%build
2c6bc3
%configure --enable-gtk-doc --disable-static \
2c6bc3
%if 0%{?rhel} <= 7
2c6bc3
  --enable-python
2c6bc3
%else
2c6bc3
  --disable-python
2c6bc3
%endif
2c6bc3
make %{?_smp_mflags}
2c6bc3
2c6bc3
%install
2c6bc3
rm -rf $RPM_BUILD_ROOT
2c6bc3
make DESTDIR=%{buildroot} INSTALL="%{__install} -c -p" install
2c6bc3
rm -f $RPM_BUILD_ROOT%{_libdir}/%{name}.la
2c6bc3
%if 0%{?rhel} <= 7
2c6bc3
rm -f $RPM_BUILD_ROOT%{python_sitearch}/iptcdata.la
2c6bc3
%endif
2c6bc3
%find_lang %{name} --all-name
2c6bc3
2c6bc3
%clean
2c6bc3
rm -rf $RPM_BUILD_ROOT
2c6bc3
2c6bc3
%post -p /sbin/ldconfig
2c6bc3
2c6bc3
%postun -p /sbin/ldconfig
2c6bc3
2c6bc3
%files -f %{name}.lang
2c6bc3
%defattr(-,root,root)
2c6bc3
%doc AUTHORS COPYING ChangeLog NEWS README TODO
2c6bc3
%{_bindir}/*
2c6bc3
%{_libdir}/lib*.so.*
2c6bc3
2c6bc3
%files devel
2c6bc3
%defattr(-,root,root)
2c6bc3
%{_libdir}/lib*.so
2c6bc3
%{_libdir}/pkgconfig/*.pc
2c6bc3
%{_includedir}/libiptcdata
2c6bc3
%{_datadir}/gtk-doc/html/libiptcdata
2c6bc3
2c6bc3
%if 0%{?rhel} <= 7
2c6bc3
%files -n python2-libiptcdata
2c6bc3
%defattr(-,root,root)
2c6bc3
%doc python/README
2c6bc3
%doc python/examples/*
2c6bc3
%{python_sitearch}/*.so
2c6bc3
%endif
2c6bc3
2c6bc3
%changelog
2c6bc3
* Thu Jun 14 2018 Troy Dawson <tdawson@redhat.com> - 1.0.4-21
2c6bc3
- No python2 in RHEL > 7 (#1580764)
2c6bc3
- fix compatibility with gtk-doc 1.26 (#1580764)
2c6bc3
2c6bc3
* Sun Aug 20 2017 Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> - 1.0.4-20
2c6bc3
- Add Provides for the old name without %%_isa
2c6bc3
2c6bc3
* Sat Aug 19 2017 Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> - 1.0.4-19
2c6bc3
- Python 2 binary package renamed to python2-libiptcdata
2c6bc3
  See https://fedoraproject.org/wiki/FinalizingFedoraSwitchtoPython3
2c6bc3
2c6bc3
* Thu Aug 03 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.4-18
2c6bc3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild
2c6bc3
2c6bc3
* Wed Jul 26 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.4-17
2c6bc3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
2c6bc3
2c6bc3
* Fri Feb 10 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.4-16
2c6bc3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
2c6bc3
2c6bc3
* Tue Jul 19 2016 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.4-15
2c6bc3
- https://fedoraproject.org/wiki/Changes/Automatic_Provides_for_Python_RPM_Packages
2c6bc3
2c6bc3
* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.4-14
2c6bc3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
2c6bc3
2c6bc3
* Wed Jun 17 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.4-13
2c6bc3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
2c6bc3
2c6bc3
* Sun Aug 17 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.4-12
2c6bc3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild
2c6bc3
2c6bc3
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.4-11
2c6bc3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
2c6bc3
2c6bc3
* Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.4-10
2c6bc3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
2c6bc3
2c6bc3
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.4-9
2c6bc3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
2c6bc3
2c6bc3
* Thu Jul 19 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.4-8
2c6bc3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
2c6bc3
2c6bc3
* Fri Jan 13 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.4-7
2c6bc3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
2c6bc3
2c6bc3
* Sun Dec  4 2011 Ville Skyttä <ville.skytta@iki.fi> - 1.0.4-6
2c6bc3
- Mark translations with %%lang.
2c6bc3
2c6bc3
* Wed Nov 16 2011 David Moore <david.moore@gmail.com> 1.0.4-5
2c6bc3
- Removed 'Requires: gtk-doc', updated python sitearch.
2c6bc3
2c6bc3
* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.4-4
2c6bc3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
2c6bc3
2c6bc3
* Wed Jul 21 2010 David Malcolm <dmalcolm@redhat.com> - 1.0.4-3
2c6bc3
- Rebuilt for https://fedoraproject.org/wiki/Features/Python_2.7/MassRebuild
2c6bc3
2c6bc3
* Fri Jul 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.4-2
2c6bc3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
2c6bc3
2c6bc3
* Sun Jul 05 2009 David Moore <dcm@acm.org> 1.0.4-1
2c6bc3
- New upstream version
2c6bc3
2c6bc3
* Sun Apr 12 2009 David Moore <dcm@acm.org> 1.0.3-3
2c6bc3
- Added 'BuildRequires: gtk-doc'
2c6bc3
2c6bc3
* Sun Apr 12 2009 David Moore <dcm@acm.org> 1.0.3-2
2c6bc3
- Added 'Requires: gtk-doc' and 'BuildRequires: libtool' and gettext
2c6bc3
2c6bc3
* Sun Apr 12 2009 David Moore <dcm@acm.org> 1.0.3-1
2c6bc3
- New upstream version
2c6bc3
- Added translation to file list
2c6bc3
2c6bc3
* Wed Feb 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.2-5
2c6bc3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
2c6bc3
2c6bc3
* Sat Nov 29 2008 Ignacio Vazquez-Abrams <ivazqueznet+rpm@gmail.com> - 1.0.2-4
2c6bc3
- Rebuild for Python 2.6
2c6bc3
2c6bc3
* Thu May 29 2008 Tom "spot" Callaway <tcallawa@redhat.com> - 1.0.2-3
2c6bc3
- fix license tag
2c6bc3
2c6bc3
* Mon Feb 18 2008 Fedora Release Engineering <rel-eng@fedoraproject.org> - 1.0.2-2
2c6bc3
- Autorebuild for GCC 4.3
2c6bc3
2c6bc3
* Tue May 15 2007 David Moore <dcm@acm.org> 1.0.2-1
2c6bc3
- New upstream version
2c6bc3
2c6bc3
* Fri Mar 23 2007 David Moore <dcm@acm.org> 1.0.1-1
2c6bc3
- New upstream version
2c6bc3
2c6bc3
* Thu Mar 22 2007 David Moore <dcm@acm.org> 1.0.0-2
2c6bc3
- Fixed URL, removed INSTALL file, fixed python path and timestamps
2c6bc3
2c6bc3
* Wed Mar 21 2007 David Moore <dcm@acm.org> 1.0.0-1
2c6bc3
- Updated spec file to better match Fedora guidelines
2c6bc3
2c6bc3
* Sun Jan 28 2007 David Moore <dcm@acm.org>
2c6bc3
- Added libiptcdata-python package
2c6bc3
2c6bc3
* Wed Apr 12 2006 David Moore <dcm@acm.org>
2c6bc3
- Removed *.mo from spec file since there are no translations yet
2c6bc3
2c6bc3
* Mon Feb 28 2005 David Moore <dcm@acm.org>
2c6bc3
- Initial version