make the vmodem-x86.service file for systemd.
authorSooyoung Ha <yoosah.ha@samsung.com>
Thu, 14 Mar 2013 11:18:04 +0000 (20:18 +0900)
committerSooyoung Ha <yoosah.ha@samsung.com>
Thu, 14 Mar 2013 11:18:04 +0000 (20:18 +0900)
packaging/vmodemd-emul.spec
vmodem-x86.service [new file with mode: 0644]

index 911c994..6323b2f 100644 (file)
@@ -28,6 +28,12 @@ rm -rf %{buildroot}
 mkdir -p %{buildroot}/usr/bin
 make install prefix=%{buildroot}
 
+if [ ! -d %{buildroot}/usr/lib/systemd/system/multi-user.target.wants ]; then
+    mkdir -p %{buildroot}/usr/lib/systemd/system/multi-user.target.wants
+fi
+cp vmodem-x86.service %{buildroot}/usr/lib/systemd/system/.
+ln -s ../vmodem-x86.service %{buildroot}/usr/lib/systemd/system/multi-user.target.wants/vmodem-x86.service
+
 %clean
 make clean
 rm -f build
@@ -39,6 +45,8 @@ rm -f build
 %files
 %defattr(-,root,root,-)
 %attr(755,-,-) %{_bindir}/vmodem_x86
+/usr/lib/systemd/system/multi-user.target.wants/vmodem-x86.service
+/usr/lib/systemd/system/vmodem-x86.service
 
 %changelog
 
diff --git a/vmodem-x86.service b/vmodem-x86.service
new file mode 100644 (file)
index 0000000..15496db
--- /dev/null
@@ -0,0 +1,6 @@
+[Unit]
+Description=VModem (x86)
+
+[Service]
+Type=simple
+ExecStart=/usr/bin/vmodem_x86