summaryrefslogtreecommitdiffstats
path: root/meta/recipes-connectivity/neard/neard
diff options
context:
space:
mode:
authorTudor Florea <tudor.florea@enea.com>2015-10-09 20:59:03 (GMT)
committerTudor Florea <tudor.florea@enea.com>2015-10-09 20:59:03 (GMT)
commit972dcfcdbfe75dcfeb777150c136576cf1a71e99 (patch)
tree97a61cd7e293d7ae9d56ef7ed0f81253365bb026 /meta/recipes-connectivity/neard/neard
downloadpoky-972dcfcdbfe75dcfeb777150c136576cf1a71e99.tar.gz
initial commit for Enea Linux 5.0 arm
Signed-off-by: Tudor Florea <tudor.florea@enea.com>
Diffstat (limited to 'meta/recipes-connectivity/neard/neard')
-rw-r--r--meta/recipes-connectivity/neard/neard/Makefile.am-fix-parallel-issue.patch33
-rw-r--r--meta/recipes-connectivity/neard/neard/neard.in54
-rw-r--r--meta/recipes-connectivity/neard/neard/neard.service.in13
-rw-r--r--meta/recipes-connectivity/neard/neard/parallel-build.patch40
4 files changed, 140 insertions, 0 deletions
diff --git a/meta/recipes-connectivity/neard/neard/Makefile.am-fix-parallel-issue.patch b/meta/recipes-connectivity/neard/neard/Makefile.am-fix-parallel-issue.patch
new file mode 100644
index 0000000..4660676
--- /dev/null
+++ b/meta/recipes-connectivity/neard/neard/Makefile.am-fix-parallel-issue.patch
@@ -0,0 +1,33 @@
1From 43acc56d5506c7e318f717fb3634bc16e3438913 Mon Sep 17 00:00:00 2001
2From: Robert Yang <liezhi.yang@windriver.com>
3Date: Thu, 15 Jan 2015 18:12:07 -0800
4Subject: [PATCH] Makefile.am: fix parallel issue
5
6There might be no src dir if src/builtin.h runs earlier, create it to
7fix the race issue:
8
9src/genbuiltin nfctype1 nfctype2 nfctype3 nfctype4 p2p > src/builtin.h
10/bin/sh: src/builtin.h: No such file or directory
11
12Upstream-Status: Pending
13
14Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
15---
16 Makefile.am | 1 +
17 1 file changed, 1 insertion(+)
18
19diff --git a/Makefile.am b/Makefile.am
20index 3241311..a43eaa2 100644
21--- a/Makefile.am
22+++ b/Makefile.am
23@@ -164,6 +164,7 @@ MAINTAINERCLEANFILES = Makefile.in \
24 src/plugin.$(OBJEXT): src/builtin.h
25
26 src/builtin.h: src/genbuiltin $(builtin_sources)
27+ $(AM_V_at)$(MKDIR_P) src
28 $(AM_V_GEN)$(srcdir)/src/genbuiltin $(builtin_modules) > $@
29
30 $(src_neard_OBJECTS) \
31--
321.7.9.5
33
diff --git a/meta/recipes-connectivity/neard/neard/neard.in b/meta/recipes-connectivity/neard/neard/neard.in
new file mode 100644
index 0000000..a47d4d9
--- /dev/null
+++ b/meta/recipes-connectivity/neard/neard/neard.in
@@ -0,0 +1,54 @@
1#!/bin/sh
2#
3# start/stop neard daemon.
4
5### BEGIN INIT INFO
6# Provides: neard
7# Required-Start: $network
8# Required-Stop: $network
9# Default-Start: S 2 3 4 5
10# Default-Stop: 0 1 6
11# Short-Description: NFC daemon
12# Description: neard is a daemon used to enable NFC features
13### END INIT INFO
14
15DAEMON=@installpath@/neard
16PIDFILE=/var/run/neard.pid
17DESC="Linux NFC daemon"
18
19if [ -f /etc/default/neard ] ; then
20 . /etc/default/neard
21fi
22
23set -e
24
25do_start() {
26 $DAEMON
27}
28
29do_stop() {
30 start-stop-daemon --stop --name neard --quiet
31}
32
33case "$1" in
34 start)
35 echo "Starting $DESC"
36 do_start
37 ;;
38 stop)
39 echo "Stopping $DESC"
40 do_stop
41 ;;
42 restart|force-reload)
43 echo "Restarting $DESC"
44 do_stop
45 sleep 1
46 do_start
47 ;;
48 *)
49 echo "Usage: $0 {start|stop|restart|force-reload}" >&2
50 exit 1
51 ;;
52esac
53
54exit 0
diff --git a/meta/recipes-connectivity/neard/neard/neard.service.in b/meta/recipes-connectivity/neard/neard/neard.service.in
new file mode 100644
index 0000000..a6f8a84
--- /dev/null
+++ b/meta/recipes-connectivity/neard/neard/neard.service.in
@@ -0,0 +1,13 @@
1[Unit]
2Description=neard service
3Documentation=man:neard(8)
4After=syslog.target
5
6[Service]
7Type=dbus
8BusName=org.neard
9ExecStart=@installpath@/neard -n
10
11[Install]
12Alias=dbus-org.neard.service
13WantedBy=multi-user.target
diff --git a/meta/recipes-connectivity/neard/neard/parallel-build.patch b/meta/recipes-connectivity/neard/neard/parallel-build.patch
new file mode 100644
index 0000000..5624749
--- /dev/null
+++ b/meta/recipes-connectivity/neard/neard/parallel-build.patch
@@ -0,0 +1,40 @@
1Upstream-Status: Pending
2Signed-off-by: Ross Burton <ross.burton@intel.com>
3
4From 488e898300f7a4ab9ba73307967ae9e02b7a6511 Mon Sep 17 00:00:00 2001
5From: Ross Burton <ross.burton@intel.com>
6Date: Fri, 13 Jun 2014 17:49:45 +0100
7Subject: [PATCH] Makefile: add missing binaries to dependency on
8 local_headers
9
10seeld and snap_send were missing from the rule that generates the header symlink
11farm, resulting in headers not being available in highly parallel builds.
12
13Signed-off-by: Ross Burton <ross.burton@intel.com>
14---
15 Makefile.am | 9 ++++++++-
16 1 file changed, 8 insertions(+), 1 deletion(-)
17
18diff --git a/Makefile.am b/Makefile.am
19index c51351f..8e58ac1 100644
20--- a/Makefile.am
21+++ b/Makefile.am
22@@ -254,7 +254,14 @@ se/plugin.$(OBJEXT): se/builtin.h
23 se/builtin.h: src/genbuiltin $(builtin_se_sources)
24 $(AM_V_GEN)$(srcdir)/src/genbuiltin $(builtin_se_modules) > $@
25
26-$(src_neard_OBJECTS) $(tools_nfctool_nfctool_OBJECTS) $(plugin_objects): $(local_headers)
27+$(src_neard_OBJECTS) \
28+$(tools_nfctool_nfctool_OBJECTS) \
29+$(plugin_objects) \
30+$(se_seeld_OBJECTS) \
31+$(unit_test_ndef_parse_OBJECTS) \
32+$(unit_test_ndef_build_OBJECTS) \
33+$(unit_test_snep_read_OBJECTS) \
34+$(tools_snep_send_OBJECTS): $(local_headers)
35
36 include/near/version.h: include/version.h
37 $(AM_V_at)$(MKDIR_P) include/near
38--
391.7.10.4
40