summaryrefslogtreecommitdiffstats
path: root/meta/recipes-support
diff options
context:
space:
mode:
authorAndre McCurdy <armccurdy@gmail.com>2019-08-23 13:51:44 -0700
committerRichard Purdie <richard.purdie@linuxfoundation.org>2019-08-27 22:52:41 +0100
commitc0fc43c228acd44499d9a1c257ec5e4cf42ed050 (patch)
tree3ba7faa35e33d21cb3e02f03bd0ec7f2bdda1a42 /meta/recipes-support
parentb02d83f7ffc72b96799a7964a90709eef02aa29d (diff)
downloadopenembedded-core-c0fc43c228acd44499d9a1c257ec5e4cf42ed050.tar.gz
openembedded-core-c0fc43c228acd44499d9a1c257ec5e4cf42ed050.tar.bz2
openembedded-core-c0fc43c228acd44499d9a1c257ec5e4cf42ed050.zip
sqlite3: explicitly set target endian-ness
Unless SQLITE_BYTEORDER is predefined, the code falls back to build time huristics - which are not always correct (e.g. in sqlite 3.28.0 big-endian ARM is mis-detected). Signed-off-by: Andre McCurdy <armccurdy@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-support')
-rw-r--r--meta/recipes-support/sqlite/sqlite3.inc6
1 files changed, 5 insertions, 1 deletions
diff --git a/meta/recipes-support/sqlite/sqlite3.inc b/meta/recipes-support/sqlite/sqlite3.inc
index 044af5ee97..4af1e09e80 100644
--- a/meta/recipes-support/sqlite/sqlite3.inc
+++ b/meta/recipes-support/sqlite/sqlite3.inc
@@ -19,7 +19,7 @@ UPSTREAM_CHECK_REGEX = "releaselog/(?P<pver>(\d+[\.\-_]*)+)\.html"
CVE_PRODUCT = "sqlite"
-inherit autotools pkgconfig
+inherit autotools pkgconfig siteinfo
# enable those which are enabled by default in configure
PACKAGECONFIG ?= "fts4 fts5 json1 rtree dyn_ext"
@@ -52,6 +52,10 @@ CFLAGS_append = " -DUSE_PREAD"
# Provide column meta-data API
CFLAGS_append = " -DSQLITE_ENABLE_COLUMN_METADATA"
+# Unless SQLITE_BYTEORDER is predefined, the code falls back to build time
+# huristics, which are not always correct
+CFLAGS_append = " ${@oe.utils.conditional('SITEINFO_ENDIANNESS', 'le', '-DSQLITE_BYTEORDER=1234', '-DSQLITE_BYTEORDER=4321', d)}"
+
PACKAGES = "lib${BPN} lib${BPN}-dev lib${BPN}-doc ${PN}-dbg lib${BPN}-staticdev ${PN}"
FILES_${PN} = "${bindir}/*"