libjson-c: enable rpath for host builds to fix errors on recent macOS
authorFelix Fietkau <nbd@nbd.name>
Sat, 14 Nov 2020 13:33:23 +0000 (14:33 +0100)
committerFelix Fietkau <nbd@nbd.name>
Sat, 14 Nov 2020 13:48:30 +0000 (14:48 +0100)
Same approach as on libubox

Signed-off-by: Felix Fietkau <nbd@nbd.name>
package/libs/libjson-c/Makefile

index c8a514a1473a57ae1d97ffd1c7e6ddc46f54b55f..13cf95596036a6ec9535e30803cb65b4fe5f2509 100644 (file)
@@ -27,6 +27,11 @@ include $(INCLUDE_DIR)/package.mk
 include $(INCLUDE_DIR)/host-build.mk
 include $(INCLUDE_DIR)/cmake.mk
 
+CMAKE_HOST_OPTIONS += \
+       -DCMAKE_SKIP_RPATH=FALSE \
+       -DCMAKE_MACOSX_RPATH=1 \
+       -DCMAKE_INSTALL_RPATH="${STAGING_DIR_HOST}/lib"
+
 define Package/libjson-c
   SECTION:=libs
   CATEGORY:=Libraries