diff --git a/rpm/usb-moded.changes b/rpm/usb-moded.changes new file mode 100644 index 0000000..965bc15 --- /dev/null +++ b/rpm/usb-moded.changes @@ -0,0 +1,99 @@ +* Wed May 15 2013 Philippe De Swert - 0.60 +- Android gadget build version 1 + +* Thu Jan 17 2013 Philippe De Swert - 0.57 +- Add random mac address generator +- Apply the dbus patch so we can remove it from the packaging + +* Fri Jan 11 2013 Philippe De Swert - 0.56 +- Fix possible compiltation issue with N900 support and android which are mutually exclusive +- Fix g_file_storage fallback which did not work anymore with kmod +- Warn when using dbus methods to change mode when not connected + +* Tue Dec 18 2012 Philippe De Swert - 0.55 +- Add android gadget driver support (compile time feature) +- Make udev default +- Add rescue mode +- Add softconnect support + +* Thu Nov 20 2012 Philippe De Swert - 0.54.1 +- Fix configuration file creation when the /etc/usb-moded dir is missing + +* Mon Nov 19 2012 Philippe De Swert - 0.54 +- Instead of spawning shells with system() use libkmod +- Make config file optional as defaults work for most devices +- Add dbus method to set network configuration +- Basic rescue mode + +* Tue Aug 21 2012 Philippe De Swert - 0.53 +- Update to the latest and greatest 0.53 +- MTP support for buteo +- More generic network set-up and configuration +- Fix bug with charging mode clean-up +- Compile for all versions of glib +- Support g_mass_storage and g_file_storage so we do not need to depend on certain kernels + +* Tue Aug 21 2012 Marko Saukko - 0.47 +- Fix build with new glib: usb-moded-0.47-Fix-build-with-newer-glib.patch + +* Thu Nov 17 2011 Marko Saukko - 0.47 +- Fixed .service file location from sysinit.target.wants to multi-user.target.wants +- Removed unused file: usb-moded-0.38-schemas.patch + +* Tue Sep 13 2011 Philippe De Swert - 0.47-0 +- No gconf update from upstream 0.47 +- Remove disconnect patch as this is already upstream +- Use config options from config file. Fixes: MB#22891 + +* Thu Sep 01 2011 Philippe De Swert - 0.44-3 +- Switch to systemd + +* Wed Aug 24 2011 Marko Saukko - 0.44-2 +- Changed Obsoletes: nokia-usb-networking to Provides: nokia-usb-networking + to fix the build differences with zypp and yum mic backends. + +* Thu Jul 21 2011 Philippe De Swert - 0.44-2 +- Add *temporary* disconnect patch that fixes disconnect issues on N900 + +* Wed Jun 29 2011 Philippe De Swert - 0.44-1 +- New upstream version 0.44 +- Split off configuration to its own packages + +* Tue Jun 21 2011 Tapio Rantala - 0.41-2 +- Wait for udev to settle, fixes usb not reconnecting after boot + +* Tue Jun 07 2011 Tapio Rantala - 0.41-1 +- New upstream version + +* Thu May 19 2011 Philippe De Swert - 0.39-1 +- Update to 0.39 upstream version + +* Wed May 18 2011 Philippe De Swert - 0.36-3 +- Allow set_config in dbus policy so settings UI works +- Set default mode to ovi_suite so we have networking +- Set DeveloperMode key so settings UI shows windows_networking/SDK option + +* Fri May 13 2011 Philippe De Swert - 0.36-2 +- use gconf schema instead of gconftool to set-up gconf keys + +* Thu Apr 28 2011 Tapio Rantala - 0.36-1 +- New upstream version +- Set gconf key in postinst +- Use ifconfig instead of ifup/ifdown + +* Thu Apr 21 2011 Tapio Rantala - 0.34+git20110421-1 +- New upstream version + +* Mon Apr 18 2011 Tapio Rantala - 0.34+git20110415-2 +- Add /etc/modprobe.d/usb_moded.conf +- Do not use daemonize in startup, as it causes regressions + +* Fri Apr 15 2011 Tapio Rantala - 0.34+git20110415-1 +- New upstream version +- Refresh n900-config patch to export internal mmc on mass storage mode + +* Thu Apr 14 2011 Tapio Rantala - 0.34+git20110412-1 +- New upstream version + +* Fri Apr 08 2011 Tapio Rantala - 0.34+git20110408-1 +- Initial MeeGo packaging (FEA#5770) diff --git a/rpm/usb-moded.service b/rpm/usb-moded.service new file mode 100644 index 0000000..4e38a1a --- /dev/null +++ b/rpm/usb-moded.service @@ -0,0 +1,12 @@ +[Unit] +Description=usb-moded USB gadget controller + +[Service] +Type=simple +RemainAfterExit=no +EnvironmentFile=-/var/lib/environment/usb-moded/*.conf +ExecStart=/usr/sbin/usb_moded $USB_MODED_ARGS +Restart=always + +[Install] +WantedBy=multi-user.target diff --git a/rpm/usb-moded.spec b/rpm/usb-moded.spec new file mode 100644 index 0000000..d8e68d4 --- /dev/null +++ b/rpm/usb-moded.spec @@ -0,0 +1,130 @@ +Name: usb-moded +Version: 0.61 +Release: 0 +Summary: USB mode controller +Group: System/System Control +License: LGPLv2 +URL: http://meego.gitorious.org/meego-middleware/usb_moded +Source0: %{name}-%{version}.tar.bz2 +Source1: %{name}.service +Source2: usb_moded.conf + +BuildRequires: pkgconfig(dbus-1) +BuildRequires: pkgconfig(dbus-glib-1) +BuildRequires: pkgconfig(gconf-2.0) +BuildRequires: pkgconfig(glib-2.0) +BuildRequires: pkgconfig(udev) +BuildRequires: pkgconfig(libkmod) +BuildRequires: doxygen +BuildRequires: GConf2 + +Provides: nokia-usb-networking +Requires: dbus-x11 +Requires: lsof +Requires: buteo-mtp +Requires(post): GConf2 +Requires(pre): GConf2 +Requires(preun): GConf2 +Requires(post): systemd +Requires(postun): systemd + +%description +Usb_moded is a daemon to control the USB states. For this +it loads unloads the relevant usb gadget modules, keeps track +of the filesystem(s) and notifies about changes on the DBUS +system bus. + +%package devel +Summary: USB mode controller - development files +Group: Development/Libraries + +%description devel +Usb_moded is a daemon to control the USB states. For this +it loads unloads the relevant usb gadget modules, keeps track +of the filesystem(s) and notifies about changes on the DBUS +system bus. + +This package contains the files needed to program for usb_moded. + +%package doc +Summary: USB mode controller - documentation +Group: Documentation + +%description doc +Usb_moded is a daemon to control the USB states. For this +it loads unloads the relevant usb gadget modules, keeps track +of the filesystem(s) and notifies about changes on the DBUS +system bus. + +This package contains the documentation. + +%prep +%setup -q + +%build +%autogen +%configure --enable-app-sync --enable-udev --enable-n900 +make all doc %{?_smp_mflags} + +%install +%make_install +install -m 644 -D src/usb_moded-dbus.h %{buildroot}/%{_includedir}/%{name}/usb_moded-dbus.h +install -m 644 -D src/usb_moded-modes.h %{buildroot}/%{_includedir}/%{name}/usb_moded-modes.h +install -m 644 -D src/usb_moded-appsync-dbus.h %{buildroot}/%{_includedir}/%{name}/usb_moded-appsync-dbus.h +install -m 644 -D usb_moded.pc %{buildroot}/%{_libdir}/pkgconfig/usb_moded.pc +install -d %{buildroot}/%{_docdir}/%{name}/html/ +install -m 644 docs/html/* %{buildroot}/%{_docdir}/%{name}/html/ +install -m 644 -D debian/%{name}.schemas %{buildroot}/%{_sysconfdir}/gconf/schemas/%{name}.schemas +install -m 644 -D debian/manpage.1 %{buildroot}/%{_mandir}/man1/usb-moded.1 +install -m 644 -D debian/usb_moded.conf %{buildroot}/%{_sysconfdir}/dbus-1/system.d/usb_moded.conf +install -m 644 -D %{SOURCE2} %{buildroot}/%{_sysconfdir}/modprobe.d/usb_moded.conf +install -D -m 644 %{SOURCE1} %{buildroot}/lib/systemd/system/%{name}.service +install -d $RPM_BUILD_ROOT/lib/systemd/system/multi-user.target.wants/ +ln -s ../%{name}.service $RPM_BUILD_ROOT/lib/systemd/system/multi-user.target.wants/%{name}.service + +%pre +if [ "$1" -gt 1 ]; then + export GCONF_CONFIG_SOURCE=`gconftool-2 --get-default-source` + gconftool-2 --makefile-uninstall-rule \ + %{_sysconfdir}/gconf/schemas/usb-moded.schemas \ + > /dev/null || : +fi + +%preun +if [ "$1" -eq 0 ]; then + export GCONF_CONFIG_SOURCE=`gconftool-2 --get-default-source` + gconftool-2 --makefile-uninstall-rule \ + %{_sysconfdir}/gconf/schemas/usb-moded.schemas \ + > /dev/null || : +fi +systemctl daemon-reload + +%post +export GCONF_CONFIG_SOURCE=`gconftool-2 --get-default-source` +gconftool-2 --makefile-install-rule \ + %{_sysconfdir}/gconf/schemas/usb-moded.schemas > /dev/null || : +systemctl daemon-reload + +%files +%defattr(-,root,root,-) +%doc debian/copyright +%config(noreplace) %{_sysconfdir}/dbus-1/system.d/usb_moded.conf +%config(noreplace) %{_sysconfdir}/gconf/schemas/%{name}.schemas +%config(noreplace) %{_sysconfdir}/modprobe.d/usb_moded.conf +%{_sbindir}/usb_moded +%{_sbindir}/usb_moded_util +%{_mandir}/man1/usb-moded.1.gz +/lib/systemd/system/%{name}.service +/lib/systemd/system/multi-user.target.wants/%{name}.service + +%files devel +%defattr(-,root,root,-) +%doc debian/copyright +%{_includedir}/%{name}/* +%{_libdir}/pkgconfig/usb_moded.pc + +%files doc +%defattr(-,root,root,-) +%doc debian/changelog debian/copyright LICENSE +%{_docdir}/%{name}/html/* + diff --git a/rpm/usb_moded.conf b/rpm/usb_moded.conf new file mode 100644 index 0000000..638d825 --- /dev/null +++ b/rpm/usb_moded.conf @@ -0,0 +1 @@ +options g_file_storage stall=0 removable=1