From 9644b65e756a170f62a0d9e974f8e223c0acb10b Mon Sep 17 00:00:00 2001 From: Chris E Ferron Date: Mon, 12 Nov 2012 15:15:41 -0800 Subject: [PATCH] inital packaging commit --- packaging/obexd-server.desktop | 9 +++++ packaging/obexd-setup.sh | 3 ++ packaging/obexd.spec | 91 ++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 103 insertions(+) create mode 100644 packaging/obexd-server.desktop create mode 100644 packaging/obexd-setup.sh create mode 100644 packaging/obexd.spec diff --git a/packaging/obexd-server.desktop b/packaging/obexd-server.desktop new file mode 100644 index 0000000..b721fef --- /dev/null +++ b/packaging/obexd-server.desktop @@ -0,0 +1,9 @@ +[Desktop Entry] +Name=Obexd Server +Comment=Obexd Server Daemon +Exec=@libexecdir@/obexd --nodaemon --opp --ftp -a --root=Public --root-setup=@libexecdir@/obexd-setup.sh +Terminal=false +Type=Application +Categories= +X-GNOME-Autostart-enable=true +X-Moblin-Priority=Low diff --git a/packaging/obexd-setup.sh b/packaging/obexd-setup.sh new file mode 100644 index 0000000..b0fbee5 --- /dev/null +++ b/packaging/obexd-setup.sh @@ -0,0 +1,3 @@ +#!/bin/sh + +mkdir --mode=0755 ~/Public diff --git a/packaging/obexd.spec b/packaging/obexd.spec new file mode 100644 index 0000000..83a090e --- /dev/null +++ b/packaging/obexd.spec @@ -0,0 +1,91 @@ +%define with_server 1 + +Name: obexd +Summary: D-Bus service for Obex Client access +License: GPL-2.0+ +Group: System/Daemons +Version: 0.45 +Release: 0 +Url: http://www.bluez.org/ +Source0: obexd-%{version}.tar.bz2 +Source1: obexd-server.desktop +Source2: obexd-setup.sh +BuildRoot: %{_tmppath}/%{name}-%{version}-build + +BuildRequires: libtool +BuildRequires: update-desktop-files +BuildRequires: pkgconfig(bluez) >= 4.99 +BuildRequires: pkgconfig(dbus-1) +BuildRequires: pkgconfig(glib-2.0) +BuildRequires: pkgconfig(libical) + +%description +obexd is an implementation of the Obex Push protocol, common on mobile phones and +other Bluetooth-equipped devices. + +%package client +Summary: D-Bus service for Obex Server access +Group: System/Daemons +Requires: obexd + +%description client +Client to allow sending files using the Obex Push protocol + +%if 0%{?with_server} + +%package server +Summary: D-Bus service for Obex Server service +Group: System/Daemons +Conflicts: obex-data-server +Requires: obexd + +%description server +Server to allow receiving and sharing files using the Obex Push protocol +%endif + +%prep +%setup -q + +%build +autoreconf -f -i +%configure --libexecdir=%{_libdir}/obex --with-phonebook=dummy \ +%if ! 0%{?with_server} + --disable-server \ +%endif + --disable-static +unset LD_AS_NEEDED +make %{?_smp_mflags} +sed -i -e "s,@libexecdir@,%{_libdir}/obex,g" %{SOURCE1} + +%install +%make_install + +mkdir examples/ +cp test/send-files examples/ + +%if 0%{?with_server} +mkdir -p %{buildroot}/%{_sysconfdir}/xdg/autostart/ +install -m 0644 %{SOURCE1} %{buildroot}/%{_sysconfdir}/xdg/autostart/ +install -m 0755 %{SOURCE2} %{buildroot}/%{_libdir}/obex/obexd-setup.sh +%endif + +%files +%defattr(-,root,root,-) +%doc README COPYING AUTHORS doc/client-api.txt examples + +%files client +%defattr(-,root,root,-) +%dir %{_libdir}/obex +%{_libdir}/obex/obex-client +%{_datadir}/dbus-1/services/obex-client.service + +%if 0%{?with_server} + +%files server +%defattr(-,root,root,-) +%dir %{_libdir}/obex +%{_libdir}/obex/obexd +%{_libdir}/obex/obexd-setup.sh +%{_datadir}/dbus-1/services/obexd.service +%{_sysconfdir}/xdg/autostart/obexd-server.desktop +%endif -- 2.7.4