[gnutls-devel] Missing function. Where is version_to_entry defined?

JONES, BILL rj7252 at att.com
Wed Feb 11 18:44:28 CET 2015


Daniel,



Here is the original problem:



Making all in extra^M

make[2]: Entering directory `/appl/local_build/build-ss/gnutls-3.3.11/extra'^M

Making all in includes^M

make[3]: Entering directory `/appl/local_build/build-ss/gnutls-3.3.11/extra/includes'^M

make[3]: Nothing to be done for `all'.^M

make[3]: Leaving directory `/appl/local_build/build-ss/gnutls-3.3.11/extra/includes'^M

make[3]: Entering directory `/appl/local_build/build-ss/gnutls-3.3.11/extra'^M

  CC       gnutls_openssl.lo^M

  CC       openssl_compat.lo^M

  CCLD     libgnutls-openssl.la^M

Undefined                       first referenced^M

symbol                             in file^M

nanosleep                           .libs/gnutls_openssl.o  (symbol belongs to implicit dependency /usr/lib/librt.so.1)^M

version_to_entry                    .libs/gnutls_openssl.o^M

ld: fatal: symbol referencing errors. No output written to .libs/libgnutls-openssl.so.27.0.2^M

make[3]: *** [libgnutls-openssl.la] Error 2^M

make[3]: Leaving directory `/appl/local_build/build-ss/gnutls-3.3.11/extra'^M

make[2]: *** [all-recursive] Error 1^M

make[2]: Leaving directory `/appl/local_build/build-ss/gnutls-3.3.11/extra'^M

make[1]: *** [all-recursive] Error 1^M

make[1]: Leaving directory `/appl/local_build/build-ss/gnutls-3.3.11'^M

make: *** [all] Error 2^M





So one thread said...you don't need openssl support (and the question why not went unanswered), but the recommendation was to add "--disable-openssl-compatibility"



So I did, and now here is the next problem:



Making check in tests

make[1]: Entering directory `/appl/local_build/build-ss/gnutls-3.3.11/tests'

Making check in .

make[2]: Entering directory `/appl/local_build/build-ss/gnutls-3.3.11/tests'

make  mini-record-2 simple gc set_pkcs12_cred certder certuniqueid mpi certificate_set_x509_crl dn parse_ca moredn record-s

izes hostname-check cve-2008-4989 pkcs12_s2k chainverify record-sizes-range crq_key_id x509sign-verify cve-2009-1415 cve-20

09-1416 crq_apis init_roundtrip pkcs12_s2k_pem dn2 mini-eagain nul-in-x509-names x509_altname pkcs12_encode mini-x509 mini-

rehandshake rng-fork mini-eagain-dtls resume-dtls x509cert x509cert-tl infoaccess mini-dtls-hello-verify mini-tdb mini-dtls

-rehandshake mini-alpn mini-dtls-large mini-termination mini-x509-cas mini-x509-2 pkcs12_simple mini-emsgsize-dtls chainver

ify-unsorted mini-overhead mini-dtls-heartbeat mini-x509-callbacks key-openssl priorities mini-dtls-srtp rsa-encrypt-decryp

t mini-loss-time mini-record mini-dtls-record mini-handshake-timeout mini-record-range mini-cert-status mini-rsa-psk global

-init sec-params fips-test mini-global-load name-constraints x509-extensions long-session-id mini-x509-callbacks-intr crlve

rify init_fds mini-rehandshake-2 ocsp   openpgp-auth openpgp-auth2 openpgp-keyring pgps2kgnu x509self x509dn anonself pskse

lf dhepskself resume setcredcrash openpgpself \

  rfc2253-escape-test

make[3]: Entering directory `/appl/local_build/build-ss/gnutls-3.3.11/tests'

make[3]: `mini-record-2' is up to date.

make[3]: `simple' is up to date.

  CCLD     gc

Undefined                       first referenced

symbol                             in file

version_to_entry                    gc.o

ld: fatal: symbol referencing errors. No output written to gc

make[3]: *** [gc] Error 2

make[3]: Leaving directory `/appl/local_build/build-ss/gnutls-3.3.11/tests'

make[2]: *** [check-am] Error 2

make[2]: Leaving directory `/appl/local_build/build-ss/gnutls-3.3.11/tests'

make[1]: *** [check-recursive] Error 1

make[1]: Leaving directory `/appl/local_build/build-ss/gnutls-3.3.11/tests'

make: *** [check-recursive] Error 1









Here is the output from "make --recon check"

make[2]: `mini-record-2' is up to date.

make[2]: `simple' is up to date.

rm -f gc

echo "  CCLD    " gc;/bin/bash ../libtool --silent --tag=CC   --mode=link cc    -no-install -R/appl/local-201501ss/lib    -R/usr/lib -L/appl/local-201501ss/lib -L/opt/solarisstudio12.3/lib   -L/opt/solarisstudio12.3/lib -o gc gc.o ../lib/libgnutls.la ../gl/libgnu.la libutils.la  -lsocket -lnsl -lnsl -lintl -lgen







So what lib is missing version_to_entry?...and why?  I expect that if this gets worked out, I can remove the "--disable-openssl-compatibility"





*NOTE...maybe unrelated:  I also found that the code the handle _Bool type was messed up:

make[5]: Entering directory `/appl/local_build/build-ss/gnutls-3.3.11/src/libopts'^M

  CC       libopts_la-libopts.lo^M

"/appl/local_build/src/gnutls/gnutls-3.3.11/src/libopts/compat/compat.h", line 188: invalid type combination^M

"/appl/local_build/src/gnutls/gnutls-3.3.11/src/libopts/compat/compat.h", line 188: warning: typedef declares no type

name^M

cc: acomp failed for /appl/local_build/src/gnutls/gnutls-3.3.11/src/libopts/libopts.c^M

and I fixed that by doing this:

1.  Added local stdbool.h from gettext-0.19.4/gettext-runtime/gnulib-lib/stdbool.h to gnutls-3.3.11/src/libopts/compat/stdbool.h

2.  In src/libopts/compat/compat.h and src/libopts/autoopts/options.h



Changed:

#ifdef HAVE_STDBOOL_H

#  include <stdbool.h>

#else

#  include "stdbool.h"

    typedef enum { false = 0, true = 1 } _Bool;

#  define bool _Bool



   /* The other macros must be usable in preprocessor directives.  */

#  define false 0

#  define true 1

#endif



To:

#ifdef HAVE_STDBOOL_H

#  include <stdbool.h>  /* Only for C99 in Solaris */

#else

#  include "stdbool.h"  /* does a better job of correctly defining _Bool depending on environment */

/*    typedef enum { false = 0, true = 1 } _Bool;

/*#  define bool _Bool

/*

/*   /* The other macros must be usable in preprocessor directives.  */

/*#  define false 0

/*#  define true 1

*/

#endif



Hardware:  Sun T5220

cc is:     SolarisStudio12



Starting from just SolarisStudio12 plus current patches...

I have these tools built, in this order:

gnu/make-3.82

gnu/libsigsegv-2.10

gnu/m4-1.4.17

gnu/readline-6.3

gnupg/zlib-1.2.8

gnu/ncurses-5.9

sourceforge/pcre-8.36

gnu/libiconv-1.14

gnu/grep-2.19

sourceforge/expat-2.1.0

gnu/tar-1.28

gnu/texinfo-5.2

sourceforge/flex-2.5.39

gnu/bison-3.0.2

sourceforge/flex-2.5.39

gnu/gmp-6.0.0

mpfr.org/mpfr-3.1.2

gnu/mpc-1.0.2

gnu/pth-2.0.7

gnu/gzip-1.6

gnu/libunistring-0.9.4

gnu/libidn-1.29

gnu/libtasn1-4.2

tukaani/xz-5.2.0

gnu/sed-4.2.2

xmlsoft.org/libxml2-2.9.2

openssl/openssl-1.0.1j

openldap.org/openldap-2.4.40

libssh2/libssh2-1.4.3

curl.haxx.se/curl-7.39.0

gnu/coreutils-8.23

gnu/gettext-0.19.4

gnu/gawk-4.1.1

sourceforge/tcl8.6.3

sourceforge/expect5.45

sourceforge/tk8.6.3

gnu/dejagnu-1.5.1

sourceware/libffi-3.2.1

gnu/nettle-2.7.1

pari.math.u-bordeaux.fr/pari-2.7.2

pkgconfig/pkg-config-0.28

gnome/glib-2.42.1

gnu/patch-2.6.1

gnu/autoconf-2.69

gnu/automake-1.14.1

gnu/libtool-2.4.4

ivmaisoft.com/libatomic_ops-7.4.2

hboehm.info/gc-7.2f

gnu/guile-2.0.11



Tried this package (autogen-5.18.4), but it does not pass tests because it's not properly finding libintl_gettext during linking...so this was skipped.



Currently building: gnutls/gnutls-3.3.11



Need this to move on to other tools.



Robert W. Jones (Bill)

AT&T



-----Original Message-----
From: Daniel Kahn Gillmor [mailto:dkg at fifthhorseman.net]
Sent: Wednesday, February 11, 2015 11:59 AM
To: JONES, BILL; bugs at gnutls.org
Subject: Re: [gnutls-devel] Missing function. Where is version_to_entry defined?



On Wed 2015-02-11 11:04:30 -0500, JONES, BILL wrote:



> Which library is the version_to_entry function defined.

>

> It's used in many places in gnutls...not just related to openssl.

>

> gnutls/gnutls-3.3.11/lib/gnutls_dtls.c:       v = version_to_entry(version);

> gnutls/gnutls-3.3.11/lib/gnutls_int.h:        s->security_parameters.pversion = version_to_entry(v);

> gnutls/gnutls-3.3.11/lib/algorithms/protocols.c:const version_entry_st *version_to_entry(gnutls_protocol_t version)



the function is defined here in lib/algorithms/protocols.c.



> gnutls/gnutls-3.3.11/lib/gnutls_handshake.c:                              version_to_entry(_gnutls_version_max

> gnutls/gnutls-3.3.11/lib/gnutls_session_pack.c:           version_to_entry(version);

> gnutls/gnutls-3.3.11/lib/gnutls_session_pack.c:           version_to_entry(version);

> gnutls/gnutls-3.3.11/lib/algorithms.h:const version_entry_st *version_to_entry(gnutls_protocol_t c);



the function is declared here in lib/algorithms/protocols.h



If that's not what you're asking, can you clarify?  are you running into

specific problems?  if so, can you show what the problems are

specifically?



    --dkg
-------------- next part --------------
An HTML attachment was scrubbed...
URL: </pipermail/attachments/20150211/37dbefaf/attachment-0001.html>


More information about the Gnutls-devel mailing list