diff options
| -rwxr-xr-x | recipes-sota/aktualizr/aktualizr_git.bb | 8 | ||||
| -rw-r--r-- | recipes-sota/aktualizr/files/0001-Use-aktualizr-repo-without-a-provided-path.patch | 24 |
2 files changed, 31 insertions, 1 deletions
diff --git a/recipes-sota/aktualizr/aktualizr_git.bb b/recipes-sota/aktualizr/aktualizr_git.bb index fbc1bca..63de572 100755 --- a/recipes-sota/aktualizr/aktualizr_git.bb +++ b/recipes-sota/aktualizr/aktualizr_git.bb | |||
| @@ -8,6 +8,7 @@ LIC_FILES_CHKSUM = "file://${S}/LICENSE;md5=9741c346eef56131163e13b9db1241b3" | |||
| 8 | require garage-sign-version.inc | 8 | require garage-sign-version.inc |
| 9 | 9 | ||
| 10 | DEPENDS = "boost curl openssl libarchive libsodium sqlite3 asn1c-native" | 10 | DEPENDS = "boost curl openssl libarchive libsodium sqlite3 asn1c-native" |
| 11 | DEPENDS_append = "${@bb.utils.contains('PTEST_ENABLED', '1', ' coreutils-native ostree-native aktualizr-native ', '', d)}" | ||
| 11 | RDEPENDS_${PN}_class-target = "aktualizr-check-discovery aktualizr-configs lshw" | 12 | RDEPENDS_${PN}_class-target = "aktualizr-check-discovery aktualizr-configs lshw" |
| 12 | RDEPENDS_${PN}-secondary = "aktualizr-check-discovery" | 13 | RDEPENDS_${PN}-secondary = "aktualizr-check-discovery" |
| 13 | RDEPENDS_${PN}-host-tools = "aktualizr aktualizr-repo aktualizr-cert-provider ${@bb.utils.contains('PACKAGECONFIG', 'sota-tools', 'garage-deploy garage-push', '', d)}" | 14 | RDEPENDS_${PN}-host-tools = "aktualizr aktualizr-repo aktualizr-cert-provider ${@bb.utils.contains('PACKAGECONFIG', 'sota-tools', 'garage-deploy garage-push', '', d)}" |
| @@ -17,6 +18,7 @@ PR = "7" | |||
| 17 | 18 | ||
| 18 | SRC_URI = " \ | 19 | SRC_URI = " \ |
| 19 | gitsm://github.com/advancedtelematic/aktualizr;branch=${BRANCH} \ | 20 | gitsm://github.com/advancedtelematic/aktualizr;branch=${BRANCH} \ |
| 21 | file://0001-Use-aktualizr-repo-without-a-provided-path.patch \ | ||
| 20 | file://aktualizr.service \ | 22 | file://aktualizr.service \ |
| 21 | file://aktualizr-secondary.service \ | 23 | file://aktualizr-secondary.service \ |
| 22 | file://aktualizr-secondary.socket \ | 24 | file://aktualizr-secondary.socket \ |
| @@ -28,7 +30,7 @@ BRANCH ?= "master" | |||
| 28 | 30 | ||
| 29 | S = "${WORKDIR}/git" | 31 | S = "${WORKDIR}/git" |
| 30 | 32 | ||
| 31 | inherit pkgconfig cmake systemd | 33 | inherit cmake pkgconfig ptest systemd |
| 32 | 34 | ||
| 33 | SYSTEMD_PACKAGES = "${PN} ${PN}-secondary" | 35 | SYSTEMD_PACKAGES = "${PN} ${PN}-secondary" |
| 34 | SYSTEMD_SERVICE_${PN} = "aktualizr.service" | 36 | SYSTEMD_SERVICE_${PN} = "aktualizr.service" |
| @@ -51,6 +53,10 @@ PACKAGECONFIG[load-tests] = "-DBUILD_LOAD_TESTS=ON,-DBUILD_LOAD_TESTS=OFF," | |||
| 51 | PACKAGECONFIG[serialcan] = ",,,slcand-start" | 53 | PACKAGECONFIG[serialcan] = ",,,slcand-start" |
| 52 | PACKAGECONFIG[ubootenv] = ",,,u-boot-fw-utils aktualizr-uboot-env-rollback" | 54 | PACKAGECONFIG[ubootenv] = ",,,u-boot-fw-utils aktualizr-uboot-env-rollback" |
| 53 | 55 | ||
| 56 | do_compile_ptest() { | ||
| 57 | cmake_runcmake_build --target build_tests | ||
| 58 | } | ||
| 59 | |||
| 54 | do_install_append () { | 60 | do_install_append () { |
| 55 | install -d ${D}${libdir}/sota | 61 | install -d ${D}${libdir}/sota |
| 56 | install -m 0644 ${S}/config/sota_autoprov.toml ${D}/${libdir}/sota/sota_autoprov.toml | 62 | install -m 0644 ${S}/config/sota_autoprov.toml ${D}/${libdir}/sota/sota_autoprov.toml |
diff --git a/recipes-sota/aktualizr/files/0001-Use-aktualizr-repo-without-a-provided-path.patch b/recipes-sota/aktualizr/files/0001-Use-aktualizr-repo-without-a-provided-path.patch new file mode 100644 index 0000000..29c75fc --- /dev/null +++ b/recipes-sota/aktualizr/files/0001-Use-aktualizr-repo-without-a-provided-path.patch | |||
| @@ -0,0 +1,24 @@ | |||
| 1 | From f5a501f842749ba31f76526a395f09cc61435ec3 Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Patrick Vacek <patrickvacek@gmail.com> | ||
| 3 | Date: Wed, 31 Oct 2018 14:55:48 +0100 | ||
| 4 | Subject: [PATCH] Use aktualizr-repo without a provided path. | ||
| 5 | |||
| 6 | This is necessary for building the tests for ptest because we want to | ||
| 7 | use the native version of aktualizr-repo (built for the host). | ||
| 8 | --- | ||
| 9 | tests/uptane_repo_generation/CMakeLists.txt | 2 +- | ||
| 10 | 1 file changed, 1 insertion(+), 1 deletion(-) | ||
| 11 | |||
| 12 | diff --git a/tests/uptane_repo_generation/CMakeLists.txt b/tests/uptane_repo_generation/CMakeLists.txt | ||
| 13 | index 83c14230..6f89d6a5 100644 | ||
| 14 | --- a/tests/uptane_repo_generation/CMakeLists.txt | ||
| 15 | +++ b/tests/uptane_repo_generation/CMakeLists.txt | ||
| 16 | @@ -1,4 +1,4 @@ | ||
| 17 | add_custom_target(uptane_repo_full_no_correlation_id | ||
| 18 | COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/full_no_correlation_id.sh | ||
| 19 | - $<TARGET_FILE:aktualizr-repo> ${PROJECT_BINARY_DIR}/uptane_repos/full_no_correlation_id) | ||
| 20 | + aktualizr-repo ${PROJECT_BINARY_DIR}/uptane_repos/full_no_correlation_id) | ||
| 21 | add_dependencies(uptane_repo_full_no_correlation_id aktualizr-repo) | ||
| 22 | -- | ||
| 23 | 2.17.1 | ||
| 24 | |||
