summaryrefslogtreecommitdiff
path: root/meta-google
diff options
context:
space:
mode:
authorWilliam A. Kennington III <wak@google.com>2024-02-09 03:19:06 +0300
committerWilliam A. Kennington III <wak@google.com>2024-02-12 07:22:54 +0300
commit68dc60080cbf0e3116b66af523460c2a9886334e (patch)
treedba96a5d3449cdeaad642a14f0d8313ef8b3cd51 /meta-google
parent022a646218a8f17d827aef8941e8be6f00dd417f (diff)
downloadopenbmc-68dc60080cbf0e3116b66af523460c2a9886334e.tar.xz
meta-google: nanopb: Update from 0.4.5 -> 0.4.8
This is intended to fix some build issues with the old 0.4.5 package and splits the generator bits out from the runtime bits. The change was taken from meta-openembedded@341c47848d04a2114b8c794ef6e01b03c80c801a and these files will eventually be deleted. Change-Id: If9e5886ff584305da9057a9de79e15fe288843fb Signed-off-by: William A. Kennington III <wak@google.com>
Diffstat (limited to 'meta-google')
-rw-r--r--meta-google/recipes-google/nanopb/nanopb-generator_0.4.8.bb14
-rw-r--r--meta-google/recipes-google/nanopb/nanopb-runtime_0.4.8.bb17
-rw-r--r--meta-google/recipes-google/nanopb/nanopb.bb17
-rw-r--r--meta-google/recipes-google/nanopb/nanopb.inc13
-rw-r--r--meta-google/recipes-google/nanopb/nanopb_0.4.5.bb24
5 files changed, 61 insertions, 24 deletions
diff --git a/meta-google/recipes-google/nanopb/nanopb-generator_0.4.8.bb b/meta-google/recipes-google/nanopb/nanopb-generator_0.4.8.bb
new file mode 100644
index 0000000000..c86750f8b6
--- /dev/null
+++ b/meta-google/recipes-google/nanopb/nanopb-generator_0.4.8.bb
@@ -0,0 +1,14 @@
+require nanopb.inc
+
+inherit python3-dir
+
+DEPENDS = "protobuf-native"
+RDEPENDS:${PN} += "python3-protobuf"
+
+EXTRA_OECMAKE += " \
+ -Dnanopb_PYTHON_INSTDIR_OVERRIDE=${PYTHON_SITEPACKAGES_DIR} \
+ -Dnanopb_BUILD_RUNTIME=OFF \
+ -Dnanopb_BUILD_GENERATOR=ON \
+ "
+
+FILES:${PN} += "${PYTHON_SITEPACKAGES_DIR}"
diff --git a/meta-google/recipes-google/nanopb/nanopb-runtime_0.4.8.bb b/meta-google/recipes-google/nanopb/nanopb-runtime_0.4.8.bb
new file mode 100644
index 0000000000..e43931a4ec
--- /dev/null
+++ b/meta-google/recipes-google/nanopb/nanopb-runtime_0.4.8.bb
@@ -0,0 +1,17 @@
+require nanopb.inc
+
+EXTRA_OECMAKE += " \
+ -Dnanopb_PROTOC_PATH=/bin/false \
+ -DBUILD_SHARED_LIBS=ON \
+ -Dnanopb_BUILD_RUNTIME=ON \
+ -Dnanopb_BUILD_GENERATOR=OFF \
+ "
+
+# Maintain compatability with old header locations for packages
+# which haven't yet migrated to `nanopb/pb*.h`
+do_install:append() {
+ for hdr in ${D}${includedir}/nanopb/*; do
+ ln -sv nanopb/$(basename "$hdr") ${D}${includedir}/
+ done
+}
+
diff --git a/meta-google/recipes-google/nanopb/nanopb.bb b/meta-google/recipes-google/nanopb/nanopb.bb
new file mode 100644
index 0000000000..7ad6a32782
--- /dev/null
+++ b/meta-google/recipes-google/nanopb/nanopb.bb
@@ -0,0 +1,17 @@
+SUMMARY = "Combined nanopb package"
+PV = "1.0"
+PR = "r1"
+
+PACKAGE_ARCH = "${MACHINE_ARCH}"
+
+inherit packagegroup
+
+DEPENDS = " \
+ nanopb-generator \
+ nanopb-runtime \
+"
+
+RDEPENDS:${PN} = " \
+ nanopb-generator \
+ nanopb-runtime \
+"
diff --git a/meta-google/recipes-google/nanopb/nanopb.inc b/meta-google/recipes-google/nanopb/nanopb.inc
new file mode 100644
index 0000000000..87dbc73e63
--- /dev/null
+++ b/meta-google/recipes-google/nanopb/nanopb.inc
@@ -0,0 +1,13 @@
+DESCRIPTION="Protocol Buffers with small code size"
+LICENSE="Zlib"
+LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=9db4b73a55a3994384112efcdb37c01f"
+
+SRC_URI = "git://github.com/nanopb/nanopb.git;branch=master;protocol=https"
+SRCREV = "6cfe48d6f1593f8fa5c0f90437f5e6522587745e"
+
+S = "${WORKDIR}/git"
+
+inherit cmake
+
+BBCLASSEXTEND = "native nativesdk"
+
diff --git a/meta-google/recipes-google/nanopb/nanopb_0.4.5.bb b/meta-google/recipes-google/nanopb/nanopb_0.4.5.bb
deleted file mode 100644
index 0e8a69c7ef..0000000000
--- a/meta-google/recipes-google/nanopb/nanopb_0.4.5.bb
+++ /dev/null
@@ -1,24 +0,0 @@
-SUMMARY = "Nanopb library"
-DESCRIPTION = "Nanopb - Protocol Buffers for Embedded Systems"
-HOMEPAGE = "https://github.com/nanopb/nanopb"
-PR = "r1"
-LICENSE = "Apache-2.0"
-LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=9db4b73a55a3994384112efcdb37c01f"
-
-inherit cmake python3native
-
-SRC_URI = "git://github.com/nanopb/nanopb;branch=master;protocol=https"
-SRCREV = "f7e4140a27d9e63517b5d596bc117bd6d5248888"
-S = "${WORKDIR}/git"
-
-DEPENDS = "protobuf-native python3-protobuf"
-
-RDEPENDS:${PN}-generator += "python3 python3-protobuf"
-
-PACKAGES:prepend = "${PN}-generator ${PN}-runtime "
-
-FILES:${PN}-generator = "${libdir}/python* ${bindir}"
-
-FILES:${PN}-runtime = "${libdir}/*.so.*"
-
-BBCLASSEXTEND = "native"