Patch tested on amd64 and arm. All tests passed. The ggdb3 patch is unrelated to arm errors.
Index: Makefile =================================================================== RCS file: /cvs/ports/security/libnettle/Makefile,v retrieving revision 1.10 diff -u -p -r1.10 Makefile --- Makefile 9 Jun 2013 14:25:12 -0000 1.10 +++ Makefile 2 Sep 2013 23:03:16 -0000 @@ -32,6 +32,11 @@ CONFIGURE_ENV= CPPFLAGS="-I${LOCALBASE}/ LDFLAGS="-L${LOCALBASE}/lib" \ M4=${LOCALBASE}/bin/gm4 +# A lot of errors in the compilation of memxor.s +.if ${MACHINE_ARCH} == "arm" +CONFIGURE_ARGS += --disable-assembler +.endif + MAKE_FLAGS= LIBNETTLE_SONAME=libnettle.so.${LIBnettle_VERSION} \ LIBNETTLE_FILE=libnettle.so.${LIBnettle_VERSION} \ LIBHOGWEED_SONAME=libhogweed.so.${LIBhogweed_VERSION} \ Index: patches/patch-configure =================================================================== RCS file: /cvs/ports/security/libnettle/patches/patch-configure,v retrieving revision 1.3 diff -u -p -r1.3 patch-configure --- patches/patch-configure 9 Jun 2013 14:25:12 -0000 1.3 +++ patches/patch-configure 2 Sep 2013 23:03:16 -0000 @@ -2,8 +2,10 @@ $OpenBSD: patch-configure,v 1.3 2013/06/ Fix relocation errors on (at least) sparc64. +We don't want extra debug flags in regular builds. + --- configure.orig Tue May 28 16:21:53 2013 -+++ configure Sun Jun 9 16:11:13 2013 ++++ configure Tue Sep 3 00:54:45 2013 @@ -4899,6 +4899,7 @@ else bsdi4.*) CCPIC="-fPIC" ;; bsdi*) CCPIC="" ;; @@ -12,3 +14,12 @@ Fix relocation errors on (at least) spar # Could also use -fpic, depending on the number of symbol references solaris*) CCPIC="-fPIC" ;; cygwin*) CCPIC="" ;; +@@ -7341,7 +7342,7 @@ if test x$GCC = xyes ; then + if $CC --version | grep '^2\.96$' 1>/dev/null 2>&1; then + true + else +- CFLAGS="$CFLAGS -ggdb3" ++ CFLAGS="$CFLAGS" + fi + # FIXME: It would be better to actually test if this option works and/or is needed. + # Or perhaps use -funsigned-char.