diff options
author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2019-11-08 14:36:36 +0000 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2019-11-10 14:06:10 +0000 |
commit | 84bd11c62e860031c1615ada76d7140b4717276a (patch) | |
tree | eeee35ef3c8a036383fadcad68c8044616b0d3f5 /meta/recipes-devtools/pseudo/pseudo.inc | |
parent | 77fdbd2a0915db7c64749d0452118cc163111f65 (diff) | |
download | poky-84bd11c62e860031c1615ada76d7140b4717276a.tar.gz |
pseudo: Drop static linking to sqlite3
Back in 2010[1] we made pseudo statically link against sqlite3. Since then
the world has changed, pseudo now has separate processes for the database
in the server and the client and they have separate linking commands.
Also, whilst there were concerns about needing specific versions of sqlite3,
in the OE environment, this is always the case.
[1] http://git.yoctoproject.org/cgit.cgi/poky/commit/?id=ad0ac0ecd38fc77daf42485489fccc10a5e1e3e7
The static sqlite3-native is causing us problems, in particular:
tmp/work/x86_64-linux/pseudo-native/1.9.0+gitAUTOINC+060058bb29-r0/recipe-sysroot-native/usr/lib/libsqlite3.a(sqlite3.o):(.data.rel+0xb0): undefined reference to `fcntl64'
which occurs if sqlite3-native was built on a machine with glibc 2.28 or later
and pseudo-native is being built on glibc before that. With dyanmical linking,
libc is backwards compatible and works but with static linking it does not.
There appears to be no easy way to avoid this other than adding a copy of
sqlite3 into the pseudo recipe. Given the static linking doesn't seem to
be required any longer due to the separate processes, drop that to fix
those issues.
(From OE-Core rev: a0c238d40a9cc1f87da0607fddaaef0c31d93720)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-devtools/pseudo/pseudo.inc')
-rw-r--r-- | meta/recipes-devtools/pseudo/pseudo.inc | 17 |
1 files changed, 2 insertions, 15 deletions
diff --git a/meta/recipes-devtools/pseudo/pseudo.inc b/meta/recipes-devtools/pseudo/pseudo.inc index 8b34909726..7ff8e449e9 100644 --- a/meta/recipes-devtools/pseudo/pseudo.inc +++ b/meta/recipes-devtools/pseudo/pseudo.inc | |||
@@ -30,23 +30,10 @@ PSEUDO_EXTRA_OPTS ?= "--enable-force-async --without-passwd-fallback --enable-ep | |||
30 | 30 | ||
31 | # Compile for the local machine arch... | 31 | # Compile for the local machine arch... |
32 | do_compile () { | 32 | do_compile () { |
33 | SQLITE_LDADD='$(SQLITE)/$(SQLITE_LIB)/libsqlite3.a' | ||
34 | for sqlite_link_opt in $(pkg-config sqlite3 --libs --static) | ||
35 | do | ||
36 | case "$sqlite_link_opt" in | ||
37 | -lsqlite3) | ||
38 | ;; | ||
39 | -l*) | ||
40 | SQLITE_LDADD="${SQLITE_LDADD} ${sqlite_link_opt}" | ||
41 | ;; | ||
42 | *) | ||
43 | ;; | ||
44 | esac | ||
45 | done | ||
46 | if [ "${SITEINFO_BITS}" = "64" ]; then | 33 | if [ "${SITEINFO_BITS}" = "64" ]; then |
47 | ${S}/configure ${PSEUDO_EXTRA_OPTS} --prefix=${prefix} --libdir=${prefix}/lib/pseudo/lib${SITEINFO_BITS} --with-sqlite-lib=${baselib} --with-sqlite=${STAGING_DIR_TARGET}${exec_prefix} --cflags="${CFLAGS}" --bits=${SITEINFO_BITS} --with-static-sqlite="$SQLITE_LDADD" --without-rpath | 34 | ${S}/configure ${PSEUDO_EXTRA_OPTS} --prefix=${prefix} --libdir=${prefix}/lib/pseudo/lib${SITEINFO_BITS} --with-sqlite-lib=${baselib} --with-sqlite=${STAGING_DIR_TARGET}${exec_prefix} --cflags="${CFLAGS}" --bits=${SITEINFO_BITS} --without-rpath |
48 | else | 35 | else |
49 | ${S}/configure ${PSEUDO_EXTRA_OPTS} --prefix=${prefix} --libdir=${prefix}/lib/pseudo/lib --with-sqlite-lib=${baselib} --with-sqlite=${STAGING_DIR_TARGET}${exec_prefix} --cflags="${CFLAGS}" --bits=${SITEINFO_BITS} --with-static-sqlite="$SQLITE_LDADD" --without-rpath | 36 | ${S}/configure ${PSEUDO_EXTRA_OPTS} --prefix=${prefix} --libdir=${prefix}/lib/pseudo/lib --with-sqlite-lib=${baselib} --with-sqlite=${STAGING_DIR_TARGET}${exec_prefix} --cflags="${CFLAGS}" --bits=${SITEINFO_BITS} --without-rpath |
50 | fi | 37 | fi |
51 | oe_runmake ${MAKEOPTS} | 38 | oe_runmake ${MAKEOPTS} |
52 | } | 39 | } |