Menu

#21 make fails (gssapi/krb4)

open
nobody
None
5
2017-10-23
2009-11-30
Anonymous
No

configure...

compiler ....................... gcc -g -O2
preprocessor flags ............. -I/usr/include/kerberosIV
linker flags ...................
libraries ...................... -lgssapi_krb5 -lkrb5 -lk5crypto -lcom_err -lkrb4 -ldes425 -lkrb5 -lcom_err -lreadline -lncurses
installation prefix ............ /home/xxxxx/bin
using Kerberos 4 ............... yes
using Kerberos 5 ............... yes
using readline ................. yes, version 4.2 or higher

Make...

if gcc -DHAVE_CONFIG_H -I. -I. -I.. -I.. -I. -I../src -I../src/ftp -I../src/libmhe -I/usr/include/kerberosIV -g -O2 -MT gssapi.o -MD -MP -MF ".deps/gssapi.Tpo" -c -o gssapi.o gssapi.c; \
then mv -f ".deps/gssapi.Tpo" ".deps/gssapi.Po"; else rm -f ".deps/gssapi.Tpo"; exit 1; fi
gssapi.c:44:23: error: krb5_err.h: No such file or directory
gssapi.c:75: error: static declaration of ‘GSS_C_NT_HOSTBASED_SERVICE’ follows non-static declaration
/usr/include/gssapi/gssapi.h:386: error: previous declaration of ‘GSS_C_NT_HOSTBASED_SERVICE’ was here
gssapi.c: In function ‘gss_auth’:
gssapi.c:288: error: ‘KRB5KDC_ERR_S_PRINCIPAL_UNKNOWN’ undeclared (first use in this function)
gssapi.c:288: error: (Each undeclared identifier is reported only once
gssapi.c:288: error: for each function it appears in.)
make[2]: *** [gssapi.o] Error 1
make[2]: Leaving directory `/home/xxxxx/src/yafc-1.1/lib'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/xxxxx/src/yafc-1.1'
make: *** [all] Error 2

Seems to a common prob for more than one app floating around the internet.

Discussion

  • Nobody/Anonymous

    I (the bug reporter) was able to work around this with the diff here:

    http://trac.macports.org/browser/trunk/dports/net/yafc/files/patch-lib__gssapi.c-darwin9.diff?rev=31143

    Even though it's intended for Macs and my host is probably not a Mac it did the trick. Even though it's including KerberosV headers into a KerverosIV build it raised no complaints.

    A copy of the diff for lib/gssapi.c follows:

    34 34 #include "syshdr.h"
    35 35 #include "ftp.h"
    36 36 #include "base64.h"
    37
    38 #if defined(HAVE_GSSAPI_H)
    39 # include <gssapi.h>
    40 /* if we have gssapi.h (not gssapi/gssapi.h) we assume we link
    41 * against Heimdal, which needs krb5_err.h to define *
    42 * KRB5KDC_ERR_S_PRINCIPAL_UNKNOWN
    43 */
    44 # include <krb5_err.h>
    45 #elif defined(HAVE_GSSAPI_GSSAPI_H)
    46 # include <gssapi/gssapi.h>
    47 /* if we have gssapi/gssapi.h it might be safe to assume we have the
    48 * other two that are part of MIT's krb5 as well, but this will work
    49 * even if they one day do away with one of those two header files.
    50 */
    51 # if defined(HAVE_GSSAPI_GSSAPI_KRB5_H)
    52 # include <gssapi/gssapi_krb5.h>
    53 # endif
    54 #else
    55 # error "Need gssapi.h from either Heimdal or MIT krb5"
    56 #endif
    57
    58
    59
    37 #include <gssapi/gssapi.h>
    38 #include <gssapi/gssapi_krb5.h>
    60 39
    61 40 /*
    62 41 * The implementation must reserve static storage for a
    … …
    72 51 static gss_OID_desc gss_c_nt_hostbased_service_oid_desc =
    73 52 {10, (void *)"\x2a\x86\x48\x86\xf7\x12" "\x01\x02\x01\x04"};
    74 53
    75 static gss_OID GSS_C_NT_HOSTBASED_SERVICE = &gss_c_nt_hostbased_service_oid_desc;
    76 54
    77 55
    78 56

     
  • John Busco

    John Busco - 2017-10-23

    Anyone know the correct solution for this build problem?

    make
    ...
    Making all in lib
    make[2]: Entering directory /home/jbusco/software/yafc-1.1.1/lib' if gcc -DHAVE_CONFIG_H -I. -I. -I.. -I.. -I. -I../src -I../src/ftp -I../src/libmhe -g -O2 -MT gssapi.o -MD -MP -MF ".deps/gssapi.Tpo" -c -o gssapi.o gssapi.c; \ then mv -f ".deps/gssapi.Tpo" ".deps/gssapi.Po"; else rm -f ".deps/gssapi.Tpo"; exit 1; fi gssapi.c:44:23: error: krb5_err.h: No such file or directory gssapi.c:75: error: static declaration of 'GSS_C_NT_HOSTBASED_SERVICE' follows non-static declaration /usr/include/gssapi/gssapi.h:386: error: previous declaration of 'GSS_C_NT_HOSTBASED_SERVICE' was here gssapi.c: In function 'gss_auth': gssapi.c:288: error: 'KRB5KDC_ERR_S_PRINCIPAL_UNKNOWN' undeclared (first use in this function) gssapi.c:288: error: (Each undeclared identifier is reported only once gssapi.c:288: error: for each function it appears in.) make[2]: *** [gssapi.o] Error 1 make[2]: Leaving directory/home/jbusco/software/yafc-1.1.1/lib'
    make[1]: *** [all-recursive] Error 1
    make[1]: Leaving directory `/home/jbusco/software/yafc-1.1.1'
    make: *** [all] Error 2

     

Log in to post a comment.

Monday.com Logo