gs2 plugin build failure

Quanah Gibson-Mount quanah at zimbra.com
Tue Oct 4 16:32:03 EDT 2011


--On Tuesday, September 13, 2011 10:53 AM -0400 Ken Murchison 
<murch at andrew.cmu.edu> wrote:

> I'd like to announce the release of Cyrus SASL 2.1.25 on
> ftp.cyrusimap.org

plugins/gs2.c

This file does not pay attention to where the Kerberos libraries are 
located if they are not the system libraries, and does not pay attention to 
the implementation selection passed to configure.  The result is if you use 
your own custom build of Heimdal Kerberos, you get a build failure:

[root at zre-rhel6-64 plugins]# make
/bin/sh ../libtool --tag=CC   --mode=compile gcc -DHAVE_CONFIG_H -I. -I.. 
-I../include -I../lib -I../sasldb -I../include  -DOBSOLETE_CRAM_ATTR=1 
-I/opt/zimbra/openssl-1.0.0e/include -I/opt/zimbra/heimdal-1.5/include 
-DKRB5_HEIMDAL  -Wall -W -D_REENTRANT -g -O2 
-I/opt/zimbra/libxml2/include/libxml2 -MT gs2.lo -MD -MP -MF .deps/gs2.Tpo 
-c -o gs2.lo gs2.c
libtool: compile:  gcc -DHAVE_CONFIG_H -I. -I.. -I../include -I../lib 
-I../sasldb -I../include -DOBSOLETE_CRAM_ATTR=1 
-I/opt/zimbra/openssl-1.0.0e/include -I/opt/zimbra/heimdal-1.5/include 
-DKRB5_HEIMDAL -Wall -W -D_REENTRANT -g -O2 
-I/opt/zimbra/libxml2/include/libxml2 -MT gs2.lo -MD -MP -MF .deps/gs2.Tpo 
-c gs2.c  -fPIC -DPIC -o .libs/gs2.o
In file included from gs2.c:76:
/usr/include/gssapi/gssapi_ext.h:51: error: expected '=', ',', ';', 'asm' 
or '__attribute__' before 'gss_acquire_cred_with_password'
/usr/include/gssapi/gssapi_ext.h:63: error: expected '=', ',', ';', 'asm' 
or '__attribute__' before 'gss_add_cred_with_password'

This is because of:

#ifdef HAVE_GSSAPI_GSSAPI_EXT_H
#include <gssapi/gssapi_ext.h>
#endif

which is part of MIT kerberos, but NOT Heimdal kerberos.

Same issue exists in gs2_token.h

Fix is to change these lines to:

#ifndef KRB5_HEIMDAL
#ifdef HAVE_GSSAPI_GSSAPI_EXT_H
#include <gssapi/gssapi_ext.h>
#endif
#endif


--Quanah

--

Quanah Gibson-Mount
Sr. Member of Technical Staff
Zimbra, Inc
A Division of VMware, Inc.
--------------------
Zimbra ::  the leader in open source messaging and collaboration


More information about the Cyrus-sasl mailing list