I have made the following changes intended for : CE:Adaptation:N900 / nokia-usb-networking
Please review and accept ASAP - BOSS has already processed this request and suggests ??? See the "Messages from BOSS" section below https://build.pub.meego.com/request/show/2616 Thank You, bossbot ([email protected]) [This message was auto-generated] --- Request # 2616: Messages from BOSS: None State: new 2011-10-24T12:18:08 bossbot Reviews: from bossbot :BOSS suggests accepting this review. See email for more details. BOSS accepted this review because: Target repo CE_Mer_Core_armv7hl found. SKIPPED check_package_is_complete_tarball (nokia-usb-networking) accepted on No date Changes: submit: home:stskeeps:mer:hw:n900 / nokia-usb-networking -> CE:Adaptation:N900 / nokia-usb-networking Index: nokia-usb-networking.sh =================================================================== --- nokia-usb-networking.sh (revision 0) +++ nokia-usb-networking.sh (revision 3) @@ -0,0 +1,42 @@ +#!/bin/bash + +# Nokia USB Networking + +RETVAL=0 +USB_NET_MODULE=g_nokia + +function start { + /sbin/modprobe $USB_NET_MODULE + RETVAL=$? + if [ "$RETVAL" = 0 ]; then + ifconfig usb0 down + ifconfig usb0 192.168.2.15 up + RETVAL=$? + fi +} + +function stop { + lsmod | grep $USB_NET_MODULE &> /dev/null + RETVAL=$? + if [ "$RETVAL" = 0 ]; then + /sbin/ifconfig usb0 down + /sbin/modprobe -r $USB_NET_MODULE + $RETVAL=$? + else + $RETVAL=0 + fi +} + +case "$1" in + start) + start + ;; + stop) + stop + ;; + *) + echo "Usage: $0 {start|stop}" + RETVAL=1 +esac + +exit $RETVAL Index: nokia-usb-networking.yaml =================================================================== --- nokia-usb-networking.yaml (revision 0) +++ nokia-usb-networking.yaml (revision 3) @@ -0,0 +1,20 @@ +Name: nokia-usb-networking +Summary: Provides init script for USB networking for Nokia devices +Version: 2.0 +Release: 0 +Group: System/Startup Services +License: GPLv2 +URL: http://gitorious.org/meego-device-adaptation/n900_nokia-usb-networking/ +Sources: + - "%{name}.sh" + - "%{name}.service" +Description: Provides init script for USB networking for Nokia devices. + +Requires: + - net-tools + - module-init-tools + +NoSetup: yes +Configure: none +Builder: none +BuildArch: noarchIndex: nokia-usb-networking.spec =================================================================== --- nokia-usb-networking.spec (revision 0) +++ nokia-usb-networking.spec (revision 3) @@ -0,0 +1,79 @@ +# +# Do NOT Edit the Auto-generated Part! +# Generated by: spectacle version 0.23 +# +# >> macros +# << macros + +Name: nokia-usb-networking +Summary: Provides init script for USB networking for Nokia devices +Version: 2.0 +Release: 0 +Group: System/Startup Services +License: GPLv2 +BuildArch: noarch +URL: http://gitorious.org/meego-device-adaptation/n900_nokia-usb-networking/ +Source0: %{name}.sh +Source1: %{name}.service +Source100: nokia-usb-networking.yaml +Requires: net-tools +Requires: module-init-tools +Requires: systemd +Requires(preun): systemd +Requires(post): systemd +Requires(postun): systemd + + +%description +Provides init script for USB networking for Nokia devices. + + + +%prep +# No setup + +# >> setup +# << setup + +%build +# >> build pre +# << build pre + + + +# >> build post +# << build post +%install +rm -rf %{buildroot} +# >> install pre +# << install pre + +# >> install post +install -D -m 755 %{SOURCE0} %{buildroot}/usr/sbin/%{name}.sh +install -D -m 644 %{SOURCE1} %{buildroot}/lib/systemd/system/%{name}.service +install -d $RPM_BUILD_ROOT/lib/systemd/system/sysinit.target.wants/ +ln -s ../%{name}.service $RPM_BUILD_ROOT/lib/systemd/system/sysinit.target.wants/%{name}.service +# << install post + + +%preun +systemctl stop %{name}.service + +%post +systemctl daemon-reload +systemctl reload-or-try-restart %{name}.service + +%postun +systemctl daemon-reload + + +%files +%defattr(-,root,root,-) +# >> files +%defattr(644,root,root,-) +%attr(755,root,root) /usr/sbin/%{name}.sh +/lib/systemd/system/%{name}.service +/lib/systemd/system/sysinit.target.wants/%{name}.service +# << files + + Index: nokia-usb-networking.changes =================================================================== --- nokia-usb-networking.changes (revision 0) +++ nokia-usb-networking.changes (revision 3) @@ -0,0 +1,31 @@ +* Fri Oct 21 2011 Carsten Munk <[email protected]> - 2.0 +- Upgrade to newer spectacle + +* Wed Jun 01 2011 Marko Saukko <[email protected]> - 2.0 +- Initial changes from sysvinit to systemd (FEA#16109). + +* Wed Jan 12 2011 Kalle Lampila <[email protected]> - 1.5 +- Removed unused nokia-usb-net-confd +- Fixed requires +- Packaging using spectacle +- Fixed compile against postchecks (BMC#10593) + +* Tue Aug 17 2010 Carsten Munk <[email protected]> - 1.4 +- Change back to g_nokia as BME breaks without it and doesn't charge. + +* Thu Jul 22 2010 Marko Saukko <[email protected]> - 1.3 +- Reverted the usb networking to ifconfig as connman does not have + support for the gadget devices. + +* Mon Jun 07 2010 Kalle Lampila <[email protected]> - 1.2 +- Setup ExclusiveArch arm only and init scripts improvements + +* Thu May 27 2010 Kalle Lampila <[email protected]> - 1.1 +- Make gateway default off and minor improvements + +* Mon May 24 2010 Kalle Lampila <[email protected]> - 1.0 +- Added Connman support + +* Tue Apr 28 2010 Marko Saukko <[email protected]> - 0.1 +- Initial release based on nokia-usb-networking script from + nokia-n900-configs package Index: boss.conf =================================================================== --- boss.conf (revision 0) +++ boss.conf (revision 3) @@ -0,0 +1,2 @@ +[checks] +check_package_is_complete_tarball = skip Index: nokia-usb-networking.service =================================================================== --- nokia-usb-networking.service (revision 0) +++ nokia-usb-networking.service (revision 3) @@ -0,0 +1,11 @@ +[Unit] +Description=Nokia USB Networking + +[Service] +Type=oneshot +RemainAfterExit=yes +ExecStart=/usr/sbin/nokia-usb-networking.sh start +ExecStop=/usr/sbin/nokia-usb-networking.sh stop + +[Install] +WantedBy=multi-user.target
