gpgme: fix compilation with musl 1.2.4
authorTianling Shen <cnsztl@immortalwrt.org>
Wed, 17 May 2023 12:15:52 +0000 (20:15 +0800)
committerRosen Penev <rosenp@gmail.com>
Thu, 18 May 2023 07:29:29 +0000 (10:29 +0300)
musl 1.2.4 deprecated legacy "LFS64" ("large file support") interfaces so
just having _GNU_SOURCE defined is not enough anymore.

Manually pass -D_LARGEFILE64_SOURCE to allow to keep using LFS64 definitions.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
libs/gpgme/Makefile

index fca33261ad572f7e8636449367814f6a26daa36c..de1436d19285c9b1208dcee111bea4c08c4b8101 100644 (file)
@@ -2,7 +2,7 @@ include $(TOPDIR)/rules.mk
 
 PKG_NAME:=gpgme
 PKG_VERSION:=1.18.0
-PKG_RELEASE:=1
+PKG_RELEASE:=2
 
 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
 PKG_SOURCE_URL:=https://gnupg.org/ftp/gcrypt/$(PKG_NAME)
@@ -52,6 +52,10 @@ CONFIGURE_ARGS += \
        --disable-g13-test \
        --enable-languages="cpp"
 
+ifneq ($(CONFIG_USE_MUSL),)
+  TARGET_CFLAGS += -D_LARGEFILE64_SOURCE
+endif
+
 define Build/InstallDev
        $(INSTALL_DIR) $(1)/usr/include/gpgme++
        $(INSTALL_DATA) \