]> git.pld-linux.org Git - packages/libimobiledevice.git/blobdiff - libimobiledevice.spec
BR python-plist, but still fails to find it
[packages/libimobiledevice.git] / libimobiledevice.spec
index 5b813acefc0aa997690f56848cbd9842a5c12d88..17e2c0980ec7603a5deef8fa1dac97b089c3ab37 100644 (file)
@@ -1,24 +1,46 @@
+# TODO
+# - investigate python (cython) build failure (missing files)
+#   checking for libplist Cython bindings... no
+#   configure: WARNING: cannot find libplist Cython bindings. You should install your distribution specific libplist Cython bindings package.
+#
+# Conditional build:
+%bcond_without static_libs     # don't build static libraries
+%bcond_without cython          # build with Cython based Python bindings
+%bcond_without openssl         # build with openssl for SSL support
+%bcond_with    gnutls          # build with GnuTLS for SSL support
+
+%if %{with gnutls}
+%undefine      with_openssl
+%endif
+
 Summary:       Library for connecting to mobile devices
 Summary(pl.UTF-8):     Biblioteka do łączenia się z urządzeniami mobilnymi
 Name:          libimobiledevice
-Version:       0.9.7
-Release:       1
+Version:       1.1.6
+Release:       0.1
 License:       LGPL v2+
 Group:         Libraries
-Source0:       http://cloud.github.com/downloads/MattColyer/libiphone/%{name}-%{version}.tar.bz2
-# Source0-md5: b47cf0a645bc2ee2fa34dac11743b40f
-URL:           http://matt.colyer.name/projects/iphone-linux/
+#Source0Download: http://www.libimobiledevice.org/
+Source0:       http://www.libimobiledevice.org/downloads/%{name}-%{version}.tar.bz2
+# Source0-md5: 274783651e9b772774cd9fed2fc52e08
+Patch0:                %{name}-cython.patch
+URL:           http://www.libimobiledevice.org/
 BuildRequires: autoconf >= 2.61
 BuildRequires: automake
-BuildRequires: glib2-devel >= 1:2.14.1
-BuildRequires: gnutls-devel >= 1.6.3
+%{?with_gnutls:BuildRequires:  gnutls-devel >= 2.2.0}
 BuildRequires: libgcrypt-devel
-BuildRequires: libplist-devel >= 0.15
-BuildRequires: libtasn1-devel >= 1.1
+BuildRequires: libplist-devel >= 1.11
+BuildRequires: libstdc++-devel
+%{?with_gnutls:BuildRequires:  libtasn1-devel >= 1.1}
 BuildRequires: libtool
+BuildRequires: libusbmuxd-devel >= 1.0.9
+%{?with_openssl:BuildRequires: openssl-devel >= 0.9.8}
 BuildRequires: pkgconfig
-BuildRequires: swig-python
-BuildRequires: usbmuxd-devel >= 0.1.4
+%{?with_cython:BuildRequires:  python-Cython >= 0.17.0}
+BuildRequires: python-devel >= 2.3
+BuildRequires: python-modules >= 2.3
+%{?with_cython:BuildRequires:  python-plist}
+BuildRequires: rpm-pythonprov
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
 %description
@@ -33,11 +55,11 @@ Summary:    Header files for libimobiledevice library
 Summary(pl.UTF-8):     Pliki nagłówkowe biblioteki libimobiledevice
 Group:         Development/Libraries
 Requires:      %{name} = %{version}-%{release}
-Requires:      glib2-devel >= 1:2.14.1
-Requires:      gnutls-devel >= 1.6.3
-Requires:      libplist-devel >= 0.15
-Requires:      libtasn1-devel >= 1.1
-Requires:      usbmuxd-devel >= 0.1.4
+%{?with_gnutls:Requires:       gnutls-devel >= 2.2.0}
+Requires:      libplist-devel >= 1.8
+%{?with_gnutls:Requires:       libtasn1-devel >= 1.1}
+Requires:      libusbmuxd-devel >= 1.0.9
+%{?with_openssl:Requires:      openssl-devel >= 0.9.8}
 
 %description devel
 Header files for libimobiledevice library.
@@ -71,6 +93,7 @@ Wiązania libimobiledevice dla Pythona.
 
 %prep
 %setup -q
+%patch0 -p1
 
 %build
 %{__libtoolize}
@@ -78,7 +101,11 @@ Wiązania libimobiledevice dla Pythona.
 %{__autoconf}
 %{__autoheader}
 %{__automake}
-%configure
+%configure \
+       %{!?with_static_libs:--disable-static} \
+       %{!?with_cython:--without-cython} \
+       %{!?with_openssl:--disable-openssl} \
+       --disable-silent-rules
 %{__make}
 
 %install
@@ -87,11 +114,14 @@ rm -rf $RPM_BUILD_ROOT
 %{__make} install \
        DESTDIR=$RPM_BUILD_ROOT
 
-rm -f $RPM_BUILD_ROOT%{py_sitedir}/imobiledevice/*.{a,la}
+%{__rm} $RPM_BUILD_ROOT%{_libdir}/*.la
 
+%if %{with cython}
+%{__rm} $RPM_BUILD_ROOT%{py_sitedir}/*.{a,la}
 %py_comp $RPM_BUILD_ROOT%{py_sitedir}
 %py_ocomp $RPM_BUILD_ROOT%{py_sitedir}
 %py_postclean
+%endif
 
 %clean
 rm -rf $RPM_BUILD_ROOT
@@ -104,26 +134,52 @@ rm -rf $RPM_BUILD_ROOT
 %doc AUTHORS NEWS README
 %attr(755,root,root) %{_bindir}/idevice_id
 %attr(755,root,root) %{_bindir}/idevicebackup
+%attr(755,root,root) %{_bindir}/idevicebackup2
+%attr(755,root,root) %{_bindir}/idevicecrashreport
+%attr(755,root,root) %{_bindir}/idevicedate
+%attr(755,root,root) %{_bindir}/idevicedebugserverproxy
+%attr(755,root,root) %{_bindir}/idevicediagnostics
+%attr(755,root,root) %{_bindir}/ideviceenterrecovery
+%attr(755,root,root) %{_bindir}/ideviceimagemounter
 %attr(755,root,root) %{_bindir}/ideviceinfo
+%attr(755,root,root) %{_bindir}/idevicename
+%attr(755,root,root) %{_bindir}/idevicepair
+%attr(755,root,root) %{_bindir}/ideviceprovision
+%attr(755,root,root) %{_bindir}/idevicescreenshot
 %attr(755,root,root) %{_bindir}/idevicesyslog
 %attr(755,root,root) %{_libdir}/libimobiledevice.so.*.*.*
-%attr(755,root,root) %ghost %{_libdir}/libimobiledevice.so.0
-%{_datadir}/hal/fdi/information/20thirdparty/31-apple-mobile-device.fdi
+%attr(755,root,root) %ghost %{_libdir}/libimobiledevice.so.4
+%{_mandir}/man1/idevice_id.1*
+%{_mandir}/man1/idevicebackup.1*
+%{_mandir}/man1/idevicebackup2.1*
+%{_mandir}/man1/idevicecrashreport.1*
+%{_mandir}/man1/idevicedate.1*
+%{_mandir}/man1/idevicedebugserverproxy.1*
+%{_mandir}/man1/idevicediagnostics.1*
+%{_mandir}/man1/ideviceenterrecovery.1*
+%{_mandir}/man1/ideviceimagemounter.1*
+%{_mandir}/man1/ideviceinfo.1*
+%{_mandir}/man1/idevicename.1*
+%{_mandir}/man1/idevicepair.1*
+%{_mandir}/man1/ideviceprovision.1*
+%{_mandir}/man1/idevicescreenshot.1*
+%{_mandir}/man1/idevicesyslog.1*
 
 %files devel
 %defattr(644,root,root,755)
 %doc docs/html/
 %attr(755,root,root) %{_libdir}/libimobiledevice.so
-%{_libdir}/libimobiledevice.la
 %{_includedir}/libimobiledevice
 %{_pkgconfigdir}/libimobiledevice-1.0.pc
 
+%if %{with static_libs}
 %files static
 %defattr(644,root,root,755)
 %{_libdir}/libimobiledevice.a
+%endif
 
+%if %{with cython}
 %files -n python-imobiledevice
 %defattr(644,root,root,755)
-%dir %{py_sitedir}/imobiledevice
-%attr(755,root,root) %{py_sitedir}/imobiledevice/_imobiledevice.so
-%{py_sitedir}/imobiledevice/*.py[co]
+%attr(755,root,root) %{py_sitedir}/imobiledevice.so
+%endif
This page took 0.173896 seconds and 4 git commands to generate.