package/libtirpc: Add optional GSSAPI support
authorJames Hilliard <james.hilliard1@gmail.com>
Sun, 18 Jul 2021 20:44:05 +0000 (14:44 -0600)
committerArnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
Sun, 25 Jul 2021 16:18:40 +0000 (18:18 +0200)
Signed-off-by: James Hilliard <james.hilliard1@gmail.com>
Reviewed-by: Petr Vorel <petr.vorel@gmail.com>
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
package/libtirpc/Config.in
package/libtirpc/libtirpc.mk

index 2e9c939fa815a2683585c40328e489cc2bbad936..1899edefbfd274441dd621c2b8f8bf090d07a9de 100644 (file)
@@ -7,5 +7,13 @@ config BR2_PACKAGE_LIBTIRPC
 
          http://sourceforge.net/projects/libtirpc/
 
+config BR2_PACKAGE_LIBTIRPC_GSS
+       bool "gss"
+       depends on BR2_USE_MMU # libkrb5
+       depends on BR2_PACKAGE_LIBTIRPC
+       select BR2_PACKAGE_LIBKRB5
+       help
+         Enable GSSAPI support
+
 comment "libtirpc needs a toolchain w/ threads"
        depends on !BR2_TOOLCHAIN_HAS_THREADS
index 46b74cae8ee81d0f9f667c8f5c0c364daeed98c8..9d3c4b5a94965f57813c5e5e7204558b33522802 100644 (file)
@@ -16,7 +16,13 @@ LIBTIRPC_INSTALL_STAGING = YES
 # getrpcby{number,name} are only provided if 'GQ' is defined
 LIBTIRPC_CONF_ENV = CFLAGS="$(TARGET_CFLAGS) -DGQ"
 
-LIBTIRPC_CONF_OPTS = --disable-gssapi
+ifeq ($(BR2_PACKAGE_LIBTIRPC_GSS),y)
+LIBTIRPC_CONF_ENV += KRB5_CONFIG=$(STAGING_DIR)/usr/bin/krb5-config
+LIBTIRPC_CONF_OPTS += --enable-gssapi
+LIBTIRPC_DEPENDENCIES += libkrb5
+else
+LIBTIRPC_CONF_OPTS += --disable-gssapi
+endif
 HOST_LIBTIRPC_CONF_OPTS = --disable-gssapi
 
 $(eval $(autotools-package))