diff options
-rw-r--r-- | classes/image_types_ostree.bbclass | 6 | ||||
-rw-r--r-- | recipes-sota/rvi-sota-client/files/sota-installer.service | 12 | ||||
-rw-r--r-- | recipes-sota/rvi-sota-client/rvi-sota-client.inc (renamed from recipes-sota/rvi-sota-client/rvi-sota-client_git.bb) | 123 | ||||
-rw-r--r-- | recipes-sota/rvi-sota-client/sota-client_git.bb | 58 | ||||
-rw-r--r-- | recipes-sota/rvi-sota-client/sota-installer_git.bb | 25 | ||||
-rw-r--r-- | recipes-sota/rvi-sota-client/sota-launcher_git.bb | 15 |
6 files changed, 144 insertions, 95 deletions
diff --git a/classes/image_types_ostree.bbclass b/classes/image_types_ostree.bbclass index 72d7df5..ac7cb60 100644 --- a/classes/image_types_ostree.bbclass +++ b/classes/image_types_ostree.bbclass | |||
@@ -146,6 +146,8 @@ IMAGE_CMD_ostree () { | |||
146 | fi | 146 | fi |
147 | 147 | ||
148 | # deploy SOTA credentials | 148 | # deploy SOTA credentials |
149 | mkdir -p var/sota | ||
150 | |||
149 | if [ -n "${SOTA_AUTOPROVISION_CREDENTIALS}" ]; then | 151 | if [ -n "${SOTA_AUTOPROVISION_CREDENTIALS}" ]; then |
150 | EXPDATE=`openssl pkcs12 -in ${SOTA_AUTOPROVISION_CREDENTIALS} -password "pass:" -nodes 2>/dev/null | openssl x509 -noout -enddate | cut -f2 -d "="` | 152 | EXPDATE=`openssl pkcs12 -in ${SOTA_AUTOPROVISION_CREDENTIALS} -password "pass:" -nodes 2>/dev/null | openssl x509 -noout -enddate | cut -f2 -d "="` |
151 | 153 | ||
@@ -153,7 +155,6 @@ IMAGE_CMD_ostree () { | |||
153 | bberror "Certificate ${SOTA_AUTOPROVISION_CREDENTIALS} has expired on ${EXPDATE}" | 155 | bberror "Certificate ${SOTA_AUTOPROVISION_CREDENTIALS} has expired on ${EXPDATE}" |
154 | fi | 156 | fi |
155 | 157 | ||
156 | mkdir -p var/sota | ||
157 | cp ${SOTA_AUTOPROVISION_CREDENTIALS} var/sota/sota_provisioning_credentials.p12 | 158 | cp ${SOTA_AUTOPROVISION_CREDENTIALS} var/sota/sota_provisioning_credentials.p12 |
158 | if [ -n "${SOTA_AUTOPROVISION_URL_FILE}" ]; then | 159 | if [ -n "${SOTA_AUTOPROVISION_URL_FILE}" ]; then |
159 | export SOTA_AUTOPROVISION_URL=`cat ${SOTA_AUTOPROVISION_URL_FILE}` | 160 | export SOTA_AUTOPROVISION_URL=`cat ${SOTA_AUTOPROVISION_URL_FILE}` |
@@ -161,6 +162,9 @@ IMAGE_CMD_ostree () { | |||
161 | echo "SOTA_GATEWAY_URI=${SOTA_AUTOPROVISION_URL}" > var/sota/sota_provisioning_url.env | 162 | echo "SOTA_GATEWAY_URI=${SOTA_AUTOPROVISION_URL}" > var/sota/sota_provisioning_url.env |
162 | fi | 163 | fi |
163 | 164 | ||
165 | if [ -n "${SOTA_SECONDARY_ECUS}" ]; then | ||
166 | cp ${SOTA_SECONDARY_ECUS} var/sota/ecus | ||
167 | fi | ||
164 | 168 | ||
165 | # Creating boot directories is required for "ostree admin deploy" | 169 | # Creating boot directories is required for "ostree admin deploy" |
166 | 170 | ||
diff --git a/recipes-sota/rvi-sota-client/files/sota-installer.service b/recipes-sota/rvi-sota-client/files/sota-installer.service new file mode 100644 index 0000000..a4fd99e --- /dev/null +++ b/recipes-sota/rvi-sota-client/files/sota-installer.service | |||
@@ -0,0 +1,12 @@ | |||
1 | [Unit] | ||
2 | Description=SOTA Secondary ECU Installer | ||
3 | Requires=network-online.target | ||
4 | After=network-online.target | ||
5 | |||
6 | [Service] | ||
7 | RestartSec=10 | ||
8 | Restart=always | ||
9 | ExecStart=/usr/bin/sota-installer --level debug --oneshot --config /var/sota/installer.toml | ||
10 | |||
11 | [Install] | ||
12 | WantedBy=multi-user.target | ||
diff --git a/recipes-sota/rvi-sota-client/rvi-sota-client_git.bb b/recipes-sota/rvi-sota-client/rvi-sota-client.inc index 753488a..8e96a32 100644 --- a/recipes-sota/rvi-sota-client/rvi-sota-client_git.bb +++ b/recipes-sota/rvi-sota-client/rvi-sota-client.inc | |||
@@ -1,41 +1,30 @@ | |||
1 | DESCRIPTION = "sota-client rust recipe" | 1 | inherit cargo systemd |
2 | HOMEPAGE = "https://github.com/advancedtelematic/rvi_sota_client" | ||
3 | 2 | ||
3 | DESCRIPTION = "rvi-sota-client recipe" | ||
4 | HOMEPAGE = "https://github.com/advancedtelematic/rvi_sota_client" | ||
4 | LICENSE = "MPL-2.0" | 5 | LICENSE = "MPL-2.0" |
5 | LIC_FILES_CHKSUM = "file://${S}/LICENSE;md5=65d26fcc2f35ea6a181ac777e42db1ea" | 6 | LIC_FILES_CHKSUM = "file://${S}/LICENSE;md5=65d26fcc2f35ea6a181ac777e42db1ea" |
6 | 7 | ||
7 | inherit cargo systemd | 8 | BBCLASSEXTEND = "native" |
8 | 9 | ||
9 | S = "${WORKDIR}/git" | 10 | S = "${WORKDIR}/git" |
10 | 11 | ||
11 | # When changing this, don't forget to: | 12 | SRC_URI[index.md5sum] = "6a635e8a081b4d4ba4cebffd721c2d7d" |
12 | # 1) Update PV | 13 | SRC_URI[index.sha256sum] = "1913c41d4b8de89a931b6f9e418f83e70a083e12e6c247e8510ee932571ebae2" |
13 | # 2) Check that Cargo.lock hasn't changed with git diff old..new Cargo.lock | ||
14 | SRCREV = "b6cf6957203fc406b3723d046f1b705e1bd08d7d" | ||
15 | |||
16 | # Generate with: | ||
17 | # git describe --tags | cut -b2- | ||
18 | # or from the rvi_sota_client repo: | ||
19 | # make package-version | ||
20 | PV = "0.2.33-41-gb6cf695" | ||
21 | |||
22 | BBCLASSEXTEND = "native" | ||
23 | 14 | ||
24 | FILES_${PN} = " \ | 15 | # also update PV and SRC_URI crates when updating SRCREV |
25 | /lib64 \ | 16 | SRCREV = "1755f1d5df05cd2924b8cf505f537f04c24f568f" |
26 | ${bindir}/sota_client \ | ||
27 | ${bindir}/sota_sysinfo.sh \ | ||
28 | ${bindir}/sota_provision.sh \ | ||
29 | ${sysconfdir}/sota_client.version \ | ||
30 | ${sysconfdir}/sota_certificates \ | ||
31 | ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', '${systemd_unitdir}/system/sota-client.service', '', d)} \ | ||
32 | ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', '${systemd_unitdir}/system/sota-client-autoprovision.service', '', d)} \ | ||
33 | " | ||
34 | 17 | ||
18 | # generate with: `make package-version` | ||
19 | PV = "0.2.33-56-g1755f1d" | ||
35 | 20 | ||
36 | # list of dependencies can be generated from Cargo.lock by running | 21 | # generate with: `make yocto-version` |
37 | # cat Cargo.lock | sed -e '1,/metadata/ d' Cargo.lock | awk '{print "crate://crates.io/"$2 "/" $3" \\"}' | ||
38 | SRC_URI = " \ | 22 | SRC_URI = " \ |
23 | git://github.com/advancedtelematic/rvi_sota_client \ | ||
24 | file://sota-client-autoprovision.service \ | ||
25 | file://sota-client-ostree.service \ | ||
26 | file://sota-client-uptane.service \ | ||
27 | file://sota-installer.service \ | ||
39 | crate://crates.io/advapi32-sys/0.2.0 \ | 28 | crate://crates.io/advapi32-sys/0.2.0 \ |
40 | crate://crates.io/aho-corasick/0.6.3 \ | 29 | crate://crates.io/aho-corasick/0.6.3 \ |
41 | crate://crates.io/ansi_term/0.9.0 \ | 30 | crate://crates.io/ansi_term/0.9.0 \ |
@@ -47,7 +36,7 @@ crate://crates.io/base64/0.5.2 \ | |||
47 | crate://crates.io/bit-set/0.4.0 \ | 36 | crate://crates.io/bit-set/0.4.0 \ |
48 | crate://crates.io/bit-vec/0.4.4 \ | 37 | crate://crates.io/bit-vec/0.4.4 \ |
49 | crate://crates.io/bitflags/0.9.1 \ | 38 | crate://crates.io/bitflags/0.9.1 \ |
50 | crate://crates.io/byteorder/1.0.0 \ | 39 | crate://crates.io/byteorder/1.1.0 \ |
51 | crate://crates.io/bytes/0.4.4 \ | 40 | crate://crates.io/bytes/0.4.4 \ |
52 | crate://crates.io/cfg-if/0.1.2 \ | 41 | crate://crates.io/cfg-if/0.1.2 \ |
53 | crate://crates.io/chan/0.1.19 \ | 42 | crate://crates.io/chan/0.1.19 \ |
@@ -71,14 +60,14 @@ crate://crates.io/hex/0.2.0 \ | |||
71 | crate://crates.io/httparse/1.2.3 \ | 60 | crate://crates.io/httparse/1.2.3 \ |
72 | crate://crates.io/hyper/0.10.12 \ | 61 | crate://crates.io/hyper/0.10.12 \ |
73 | crate://crates.io/hyper-native-tls/0.2.4 \ | 62 | crate://crates.io/hyper-native-tls/0.2.4 \ |
74 | crate://crates.io/idna/0.1.2 \ | 63 | crate://crates.io/idna/0.1.4 \ |
75 | crate://crates.io/iovec/0.1.0 \ | 64 | crate://crates.io/iovec/0.1.0 \ |
76 | crate://crates.io/itoa/0.3.1 \ | 65 | crate://crates.io/itoa/0.3.1 \ |
77 | crate://crates.io/kernel32-sys/0.2.2 \ | 66 | crate://crates.io/kernel32-sys/0.2.2 \ |
78 | crate://crates.io/language-tags/0.2.2 \ | 67 | crate://crates.io/language-tags/0.2.2 \ |
79 | crate://crates.io/lazy_static/0.2.8 \ | 68 | crate://crates.io/lazy_static/0.2.8 \ |
80 | crate://crates.io/libc/0.2.24 \ | 69 | crate://crates.io/libc/0.2.26 \ |
81 | crate://crates.io/libflate/0.1.9 \ | 70 | crate://crates.io/libflate/0.1.5 \ |
82 | crate://crates.io/log/0.3.8 \ | 71 | crate://crates.io/log/0.3.8 \ |
83 | crate://crates.io/maplit/0.1.4 \ | 72 | crate://crates.io/maplit/0.1.4 \ |
84 | crate://crates.io/matches/0.1.6 \ | 73 | crate://crates.io/matches/0.1.6 \ |
@@ -87,10 +76,10 @@ crate://crates.io/metadeps/1.1.2 \ | |||
87 | crate://crates.io/mime/0.2.6 \ | 76 | crate://crates.io/mime/0.2.6 \ |
88 | crate://crates.io/native-tls/0.1.4 \ | 77 | crate://crates.io/native-tls/0.1.4 \ |
89 | crate://crates.io/net2/0.2.29 \ | 78 | crate://crates.io/net2/0.2.29 \ |
90 | crate://crates.io/num/0.1.39 \ | 79 | crate://crates.io/num/0.1.40 \ |
91 | crate://crates.io/num-integer/0.1.34 \ | 80 | crate://crates.io/num-integer/0.1.35 \ |
92 | crate://crates.io/num-iter/0.1.33 \ | 81 | crate://crates.io/num-iter/0.1.34 \ |
93 | crate://crates.io/num-traits/0.1.39 \ | 82 | crate://crates.io/num-traits/0.1.40 \ |
94 | crate://crates.io/num_cpus/1.6.2 \ | 83 | crate://crates.io/num_cpus/1.6.2 \ |
95 | crate://crates.io/openssl/0.9.14 \ | 84 | crate://crates.io/openssl/0.9.14 \ |
96 | crate://crates.io/openssl-sys/0.9.14 \ | 85 | crate://crates.io/openssl-sys/0.9.14 \ |
@@ -99,7 +88,7 @@ crate://crates.io/percent-encoding/1.0.0 \ | |||
99 | crate://crates.io/pkg-config/0.3.9 \ | 88 | crate://crates.io/pkg-config/0.3.9 \ |
100 | crate://crates.io/quote/0.3.15 \ | 89 | crate://crates.io/quote/0.3.15 \ |
101 | crate://crates.io/rand/0.3.15 \ | 90 | crate://crates.io/rand/0.3.15 \ |
102 | crate://crates.io/redox_syscall/0.1.21 \ | 91 | crate://crates.io/redox_syscall/0.1.26 \ |
103 | crate://crates.io/regex/0.2.2 \ | 92 | crate://crates.io/regex/0.2.2 \ |
104 | crate://crates.io/regex-syntax/0.4.1 \ | 93 | crate://crates.io/regex-syntax/0.4.1 \ |
105 | crate://crates.io/reqwest/0.6.2 \ | 94 | crate://crates.io/reqwest/0.6.2 \ |
@@ -111,8 +100,8 @@ crate://crates.io/schannel/0.1.7 \ | |||
111 | crate://crates.io/secur32-sys/0.2.0 \ | 100 | crate://crates.io/secur32-sys/0.2.0 \ |
112 | crate://crates.io/security-framework/0.1.14 \ | 101 | crate://crates.io/security-framework/0.1.14 \ |
113 | crate://crates.io/security-framework-sys/0.1.14 \ | 102 | crate://crates.io/security-framework-sys/0.1.14 \ |
114 | crate://crates.io/serde/1.0.9 \ | 103 | crate://crates.io/serde/1.0.10 \ |
115 | crate://crates.io/serde_derive/1.0.9 \ | 104 | crate://crates.io/serde_derive/1.0.10 \ |
116 | crate://crates.io/serde_derive_internals/0.15.1 \ | 105 | crate://crates.io/serde_derive_internals/0.15.1 \ |
117 | crate://crates.io/serde_json/1.0.2 \ | 106 | crate://crates.io/serde_json/1.0.2 \ |
118 | crate://crates.io/serde_urlencoded/0.5.1 \ | 107 | crate://crates.io/serde_urlencoded/0.5.1 \ |
@@ -125,7 +114,7 @@ crate://crates.io/tempdir/0.3.5 \ | |||
125 | crate://crates.io/term_size/0.3.0 \ | 114 | crate://crates.io/term_size/0.3.0 \ |
126 | crate://crates.io/textwrap/0.6.0 \ | 115 | crate://crates.io/textwrap/0.6.0 \ |
127 | crate://crates.io/thread_local/0.3.4 \ | 116 | crate://crates.io/thread_local/0.3.4 \ |
128 | crate://crates.io/time/0.1.37 \ | 117 | crate://crates.io/time/0.1.38 \ |
129 | crate://crates.io/toml/0.2.1 \ | 118 | crate://crates.io/toml/0.2.1 \ |
130 | crate://crates.io/toml/0.4.2 \ | 119 | crate://crates.io/toml/0.4.2 \ |
131 | crate://crates.io/traitobject/0.1.0 \ | 120 | crate://crates.io/traitobject/0.1.0 \ |
@@ -145,64 +134,10 @@ crate://crates.io/utf-8/0.7.1 \ | |||
145 | crate://crates.io/utf8-ranges/1.0.0 \ | 134 | crate://crates.io/utf8-ranges/1.0.0 \ |
146 | crate://crates.io/uuid/0.5.1 \ | 135 | crate://crates.io/uuid/0.5.1 \ |
147 | crate://crates.io/vec_map/0.8.0 \ | 136 | crate://crates.io/vec_map/0.8.0 \ |
148 | crate://crates.io/version_check/0.1.2 \ | 137 | crate://crates.io/version_check/0.1.3 \ |
149 | crate://crates.io/void/1.0.2 \ | 138 | crate://crates.io/void/1.0.2 \ |
150 | crate://crates.io/winapi/0.2.8 \ | 139 | crate://crates.io/winapi/0.2.8 \ |
151 | crate://crates.io/winapi-build/0.1.1 \ | 140 | crate://crates.io/winapi-build/0.1.1 \ |
152 | crate://crates.io/ws2_32-sys/0.2.1 \ | 141 | crate://crates.io/ws2_32-sys/0.2.1 \ |
153 | crate://crates.io/xattr/0.1.11 \ | 142 | crate://crates.io/xattr/0.1.11 \ |
154 | git://github.com/advancedtelematic/rvi_sota_client \ | ||
155 | file://sota-client-autoprovision.service \ | ||
156 | file://sota-client-ostree.service \ | ||
157 | file://sota-client-uptane.service \ | ||
158 | " | 143 | " |
159 | |||
160 | SRC_URI[index.md5sum] = "6a635e8a081b4d4ba4cebffd721c2d7d" | ||
161 | SRC_URI[index.sha256sum] = "1913c41d4b8de89a931b6f9e418f83e70a083e12e6c247e8510ee932571ebae2" | ||
162 | |||
163 | SYSTEMD_SERVICE_${PN} = "sota-client.service sota-client-autoprovision.service" | ||
164 | |||
165 | DEPENDS += " openssl openssl-native dbus " | ||
166 | RDEPENDS_${PN} = " libcrypto \ | ||
167 | libssl \ | ||
168 | bash \ | ||
169 | lshw \ | ||
170 | jq \ | ||
171 | curl \ | ||
172 | python \ | ||
173 | python-json \ | ||
174 | python-petname \ | ||
175 | " | ||
176 | |||
177 | export SOTA_PACKED_CREDENTIALS | ||
178 | export SOTA_AUTOPROVISION_CREDENTIALS | ||
179 | export SOTA_AUTOPROVISION_URL | ||
180 | |||
181 | do_compile_prepend() { | ||
182 | export SOTA_VERSION=$(make sota-version) | ||
183 | cd sota-client | ||
184 | } | ||
185 | |||
186 | do_install() { | ||
187 | ln -fs /lib ${D}/lib64 | ||
188 | |||
189 | install -d ${D}${bindir} | ||
190 | install -d ${D}${sysconfdir} | ||
191 | |||
192 | echo `git log -1 --pretty=format:%H` > ${D}${sysconfdir}/sota_client.version | ||
193 | install -c ${S}/sota-client/docker/sota_certificates ${D}${sysconfdir} | ||
194 | |||
195 | install -m 0755 target/${TARGET_SYS}/release/sota_client ${D}${bindir} | ||
196 | install -m 0755 ${S}/sota-client/docker/sota_provision.sh ${D}${bindir} | ||
197 | install -m 0755 ${S}/sota-client/docker/sota_sysinfo.sh ${D}${bindir} | ||
198 | |||
199 | if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then | ||
200 | install -d ${D}/${systemd_unitdir}/system | ||
201 | if [ -n "$SOTA_AUTOPROVISION_CREDENTIALS" -o -n "$SOTA_PACKED_CREDENTIALS" ]; then | ||
202 | install -m 0644 ${WORKDIR}/sota-client-uptane.service ${D}/${systemd_unitdir}/system/sota-client.service | ||
203 | else | ||
204 | install -m 0644 ${WORKDIR}/sota-client-ostree.service ${D}/${systemd_unitdir}/system/sota-client.service | ||
205 | fi | ||
206 | install -m 0644 ${WORKDIR}/sota-client-autoprovision.service ${D}/${systemd_unitdir}/system/sota-client-autoprovision.service | ||
207 | fi | ||
208 | } | ||
diff --git a/recipes-sota/rvi-sota-client/sota-client_git.bb b/recipes-sota/rvi-sota-client/sota-client_git.bb new file mode 100644 index 0000000..21378ce --- /dev/null +++ b/recipes-sota/rvi-sota-client/sota-client_git.bb | |||
@@ -0,0 +1,58 @@ | |||
1 | require rvi-sota-client.inc | ||
2 | |||
3 | |||
4 | SYSTEMD_SERVICE_${PN} = "sota-client.service sota-client-autoprovision.service" | ||
5 | |||
6 | FILES_${PN} = " \ | ||
7 | /lib64 \ | ||
8 | ${bindir}/sota_client \ | ||
9 | ${bindir}/sota_sysinfo.sh \ | ||
10 | ${bindir}/sota_provision.sh \ | ||
11 | ${sysconfdir}/sota_client.version \ | ||
12 | ${sysconfdir}/sota_certificates \ | ||
13 | ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', '${systemd_unitdir}/system/sota-client.service', '', d)} \ | ||
14 | ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', '${systemd_unitdir}/system/sota-client-autoprovision.service', '', d)} \ | ||
15 | " | ||
16 | |||
17 | DEPENDS += " openssl openssl-native dbus " | ||
18 | RDEPENDS_${PN} = " \ | ||
19 | bash \ | ||
20 | curl \ | ||
21 | libcrypto \ | ||
22 | libssl \ | ||
23 | lshw \ | ||
24 | jq \ | ||
25 | " | ||
26 | |||
27 | export SOTA_PACKED_CREDENTIALS | ||
28 | export SOTA_AUTOPROVISION_CREDENTIALS | ||
29 | export SOTA_AUTOPROVISION_URL | ||
30 | |||
31 | do_compile_prepend() { | ||
32 | export SOTA_VERSION=$(make sota-version) | ||
33 | cd sota-client | ||
34 | } | ||
35 | |||
36 | do_install() { | ||
37 | ln -fs /lib ${D}/lib64 | ||
38 | |||
39 | install -d ${D}${bindir} | ||
40 | install -d ${D}${sysconfdir} | ||
41 | |||
42 | echo `git log -1 --pretty=format:%H` > ${D}${sysconfdir}/sota_client.version | ||
43 | install -c ${S}/sota-client/docker/sota_certificates ${D}${sysconfdir} | ||
44 | |||
45 | install -m 0755 target/${TARGET_SYS}/release/sota_client ${D}${bindir} | ||
46 | install -m 0755 ${S}/sota-client/docker/sota_provision.sh ${D}${bindir} | ||
47 | install -m 0755 ${S}/sota-client/docker/sota_sysinfo.sh ${D}${bindir} | ||
48 | |||
49 | if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then | ||
50 | install -d ${D}/${systemd_unitdir}/system | ||
51 | if [ -n "$SOTA_AUTOPROVISION_CREDENTIALS" -o -n "$SOTA_PACKED_CREDENTIALS" ]; then | ||
52 | install -m 0644 ${WORKDIR}/sota-client-uptane.service ${D}/${systemd_unitdir}/system/sota-client.service | ||
53 | else | ||
54 | install -m 0644 ${WORKDIR}/sota-client-ostree.service ${D}/${systemd_unitdir}/system/sota-client.service | ||
55 | fi | ||
56 | install -m 0644 ${WORKDIR}/sota-client-autoprovision.service ${D}/${systemd_unitdir}/system/sota-client-autoprovision.service | ||
57 | fi | ||
58 | } | ||
diff --git a/recipes-sota/rvi-sota-client/sota-installer_git.bb b/recipes-sota/rvi-sota-client/sota-installer_git.bb new file mode 100644 index 0000000..338e678 --- /dev/null +++ b/recipes-sota/rvi-sota-client/sota-installer_git.bb | |||
@@ -0,0 +1,25 @@ | |||
1 | require rvi-sota-client.inc | ||
2 | |||
3 | |||
4 | SYSTEMD_SERVICE_${PN} = "sota-installer.service" | ||
5 | |||
6 | DEPENDS += " sota-client " | ||
7 | |||
8 | FILES_${PN} = " \ | ||
9 | ${bindir}/sota-installer \ | ||
10 | ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', '${systemd_unitdir}/system/sota-installer.service', '', d)} \ | ||
11 | " | ||
12 | |||
13 | do_compile_prepend() { | ||
14 | cd sota-installer | ||
15 | } | ||
16 | |||
17 | do_install() { | ||
18 | install -d ${D}${bindir} | ||
19 | install -m 0755 target/${TARGET_SYS}/release/sota-installer ${D}${bindir} | ||
20 | |||
21 | if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then | ||
22 | install -d ${D}/${systemd_unitdir}/system | ||
23 | install -m 0644 ${WORKDIR}/sota-installer.service ${D}/${systemd_unitdir}/system/sota-installer.service | ||
24 | fi | ||
25 | } | ||
diff --git a/recipes-sota/rvi-sota-client/sota-launcher_git.bb b/recipes-sota/rvi-sota-client/sota-launcher_git.bb new file mode 100644 index 0000000..4104052 --- /dev/null +++ b/recipes-sota/rvi-sota-client/sota-launcher_git.bb | |||
@@ -0,0 +1,15 @@ | |||
1 | require rvi-sota-client.inc | ||
2 | |||
3 | |||
4 | DEPENDS += " sota-client " | ||
5 | FILES_${PN} = "${bindir}/sota-launcher" | ||
6 | |||
7 | |||
8 | do_compile_prepend() { | ||
9 | cd sota-launcher | ||
10 | } | ||
11 | |||
12 | do_install() { | ||
13 | install -d ${D}${bindir} | ||
14 | install -m 0755 target/${TARGET_SYS}/release/sota-launcher ${D}${bindir} | ||
15 | } | ||