Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6783747
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T16:54:26+00:00 2026-05-26T16:54:26+00:00

I’m attempting to build GnuTLS on Mac OS X 10.5 (Leopard) Server (yeah, I

  • 0

I’m attempting to build GnuTLS on Mac OS X 10.5 (Leopard) Server (yeah, I know, it’s a bit dated, but that’s what this server is running at the moment) and am running into an issue building Nettle: I’ve built & installed GMP, but Nettle’s configure cannot find it.

I built & installed GMP 5.0.2 as follows (the GCC version solution is from here):

curl -O ftp://ftp.gmplib.org/pub/gmp-5.0.2/gmp-5.0.2.tar.bz2
tar xjf gmp-5.0.2.tar.bz2
pushd gmp-5.0.2
CC=gcc-4.2 CXX=g++4.2 ./configure --prefix=/usr/local
make
sudo make install
popd

A make check passes all tests and I end up with the following GMP files installed:

/usr/local/include/gmp.h
/usr/local/lib/libgmp.10.dylib
/usr/local/lib/libgmp.a
/usr/local/lib/libgmp.dylib
/usr/local/lib/libgmp.la
/usr/local/share/info/gmp.info
/usr/local/share/info/gmp.info-1
/usr/local/share/info/gmp.info-2

However, when I attempt to build Nettle 2.4, as follows:

curl -O http://www.lysator.liu.se/~nisse/archive/nettle-2.4.tar.gz
tar xzf nettle-2.4.tar.gz
pushd nettle-2.4
./configure --prefix=/usr/local
make
sudo make install
popd

It builds & installs successfully, but it doesn’t build libhogweed because GMP is missing. Upon further inspection, I’ve found the following warnings in the configure output:

checking for __gmpz_getlimbn in -lgmp... no
configure: WARNING: GNU MP not found, or not 3.1 or up, see http://gmplib.org/.
Support for public key algorithms will be unavailable.
checking for __gmpz_powm_sec... no

Obviously, GMP 5.0.2 is newer than 3.1, plus both ‘__gmpz_getlimbn’ & ‘__gmpz_powm_sec’ are defined in /usr/local/include/gmp.h, so everything about my GMP install seems correct.

I’ve tried all sorts of configure options (esp. looking for some type of ‘–with-gmp’ option) to no avail. I have also tried using the same version of GCC (CC=gcc-4.2 CXX=g++4.2 ./configure --prefix=/usr/local) as I did to compile GMP, with no change in result. --includedir & --libdir should be set to $PREFIX/include & $PREFIX/lib, respectively, (esp. since I’m not specifying an --exec-prefix) so I can’t figure out why it wouldn’t be able to find GMP.

Any suggestions would be greatly appreciated.

Update:

I found the following in config.log explaining the failure to find GMP:

configure:6469: checking for __gmpz_getlimbn in -lgmp
configure:6494: gcc -o conftest -g -O2   conftest.c -lgmp   >&5
ld warning: in /usr/local/lib/libgmp.dylib, file is not of required architecture
Undefined symbols:
  "___gmpz_getlimbn", referenced from:
      _main in ccNP0jza.o
ld: symbol(s) not found 
collect2: ld returned 1 exit status
configure:6494: $? = 1
configure: failed program was:
| /* confdefs.h */
| #define PACKAGE_NAME "nettle"  
| #define PACKAGE_TARNAME "nettle"
| #define PACKAGE_VERSION "2.4"  
| #define PACKAGE_STRING "nettle 2.4"
| #define PACKAGE_BUGREPORT "nettle-bugs@lists.lysator.liu.se"
| #define PACKAGE_URL ""
| #define STDC_HEADERS 1
| #define HAVE_SYS_TYPES_H 1
| #define HAVE_SYS_STAT_H 1
| #define HAVE_STDLIB_H 1 
| #define HAVE_STRING_H 1
| #define HAVE_MEMORY_H 1
| #define HAVE_STRINGS_H 1
| #define HAVE_INTTYPES_H 1
| #define HAVE_STDINT_H 1 
| #define HAVE_UNISTD_H 1
| #define TIME_WITH_SYS_TIME 1
| #define SIZEOF_LONG 4
| #define HAVE_OPENSSL_BLOWFISH_H 1
| #define HAVE_OPENSSL_DES_H 1
| #define HAVE_OPENSSL_CAST_H 1
| #define HAVE_OPENSSL_AES_H 1
| #define HAVE_ALLOCA_H 1
| #define HAVE_ALLOCA 1 
| #define HAVE_STRERROR 1
| #define HAVE_GCC_ATTRIBUTE 1
| #define HAVE_FCNTL_LOCKING 1
| /* end confdefs.h.  */
|
| /* Override any GCC internal prototype to avoid an error.
|    Use char because int might match the return type of a GCC
|    builtin and then its argument prototype would still apply.  */
| #ifdef __cplusplus
| extern "C"
| #endif
| char __gmpz_getlimbn ();
| int
| main ()
| {
| return __gmpz_getlimbn ();
|   ;
|   return 0;
| }
configure:6503: result: no
configure:6514: WARNING: GNU MP not found, or not 3.1 or up, see http://gmplib.org/.
Support for public key algorithms will be unavailable.

Running file /usr/local/lib/libgmp.dylib returns the following:

/usr/local/lib/libgmp.dylib: Mach-O 64-bit dynamically linked shared library x86_64

This server is running an Intel Core 2 Duo processor, so that 64-bit Mach library looks correct to me. I don’t know how to tell whether nettle is trying to built for 32-bit or 64-bit architecture, so I tried CC=gcc-4.2 CXX=g++4.2 ABI=64 ./configure --prefix=/usr/local with no change (also, even when specifying ABI=32 Nettle’s configure always says “ABI: standard”… does it not pass ABI through?).

Would re-compiling GMP as a static library make any difference? (Nope, GMP builds both static & dynamic libraries, by default. I listed both above when showing all the installed files.)

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T16:54:26+00:00Added an answer on May 26, 2026 at 4:54 pm

    It turns out, there’s a bug in config.guess included with Nettle 2.4 which does not detect the correct 32-bit/64-bit type under Mac OS X, so it was defaulting to 32-bit and couldn’t find symbols in the GMP library (which was compiled as a 64-bit library). As the Nettle developer noted here, you can just download the latest config.guess and or disable assembler.

    The newer config.guess didn’t work for me, so I forced it into 64-bit mode and disabled assembler. The final working build instructions for Libnettle (and libhogweed; not including the GMP dependancy) are:

    curl -O http://www.lysator.liu.se/~nisse/archive/nettle-2.4.tar.gz
    tar xzf nettle-2.4.tar.gz
    pushd nettle-2.4
    CFLAGS="-m64" ./configure --prefix=/usr/local --disable-assembler
    make
    sudo make install
    popd
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a French site that I want to parse, but am running into
I'm parsing an RSS feed that has an ’ in it. SimpleXML turns this
I have a string like this: La Torre Eiffel paragonata all’Everest What PHP function
Does anyone know how can I replace this 2 symbol below from the string
link Im having trouble converting the html entites into html characters, (&# 8217;) i
That's pretty much it. I'm using Nokogiri to scrape a web page what has
I want to count how many characters a certain string has in PHP, but
For some reason, after submitting a string like this Jack’s Spindle from a text
this is what i have right now Drawing an RSS feed into the php,
I've got a string that has curly quotes in it. I'd like to replace

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.