Python: Fix compile of host modules
authorJan Kardell <jan.kardell@telliq.com>
Mon, 8 Oct 2018 09:57:14 +0000 (11:57 +0200)
committerJeffery To <jeffery.to@gmail.com>
Wed, 20 May 2020 09:28:02 +0000 (17:28 +0800)
Add -rpath linker option to host build, pointing to staging/hostpkh/lib.
It's needed to find the correct host libs during runtime, without it the
hosts libs may be used instaead, causing failures.

Signed-off-by: Jan Kardell <jan.kardell@telliq.com>
(cherry picked from commit 0311e58bb645b8f5a2b96528d78edc90c811ed94)

lang/python/python/Makefile

index 6ad838909db797e5de6e4636db5921fc1112e08f..4c7fc9eef6498d9da52c0c219330f5e48b0f6db6 100644 (file)
@@ -268,7 +268,7 @@ define PyPackage/python/filespec
 endef
 
 HOST_LDFLAGS += \
-       $$$$(pkg-config --static --libs libcrypto libssl)
+       $$$$(pkg-config --static --libs libcrypto libssl) -Wl$(comma)-rpath=$(STAGING_DIR_HOSTPKG)/lib
 
 ifeq ($(HOST_OS),Linux)
 HOST_LDFLAGS += \