Преглед на файлове

swupdate: fix build for non-git versions

After the commit 9cc528711ad38ba2fee06746b7dd80260d9767ce the
build is broken for non-git versions.

Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
Acked-by: Stefano Babic <sbabic@denx.de>
Arturo Buzarra преди 7 години
родител
ревизия
6cc8bfbd3a
променени са 2 файла, в които са добавени 9 реда и са изтрити 6 реда
  1. 0 6
      recipes-support/swupdate/swupdate.inc
  2. 9 0
      recipes-support/swupdate/swupdate_git.bb

+ 0 - 6
recipes-support/swupdate/swupdate.inc

@@ -123,12 +123,6 @@ do_install () {
 
   install -d ${D}${systemd_unitdir}/system
   install -m 644 ${WORKDIR}/swupdate.service ${D}${systemd_unitdir}/system
-  install -m 644 ${WORKDIR}/swupdate-usb@.service ${D}${systemd_unitdir}/system
-  install -m 644 ${WORKDIR}/swupdate-progress.service ${D}${systemd_unitdir}/system
-  if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then
-    install -d ${D}${sysconfdir}/udev/rules.d
-    install -m 0644 ${WORKDIR}/swupdate-usb.rules ${D}${sysconfdir}/udev/rules.d/
-  fi
 }
 
 INITSCRIPT_NAME = "swupdate"

+ 9 - 0
recipes-support/swupdate/swupdate_git.bb

@@ -15,3 +15,12 @@ do_compile_append() {
   oe_runmake
   unset LDFLAGS
 }
+
+do_install_append () {
+  install -m 644 ${WORKDIR}/swupdate-usb@.service ${D}${systemd_unitdir}/system
+  install -m 644 ${WORKDIR}/swupdate-progress.service ${D}${systemd_unitdir}/system
+  if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then
+    install -d ${D}${sysconfdir}/udev/rules.d
+    install -m 0644 ${WORKDIR}/swupdate-usb.rules ${D}${sysconfdir}/udev/rules.d/
+  fi
+}