Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 15 Jan 2012 10:11:03 -0800
From:      Devin Teske <devin.teske@fisglobal.com>
To:        Devin Teske <devin.teske@fisglobal.com>
Cc:        FreeBSD Questions <freebsd-questions@freebsd.org>, Dave Robison <Dave.Robison@fisglobal.com>
Subject:   Re: buildworld -DWITHOUT_OPENSSL fails at (lib/libbsnmp/libbsnmp (all)) (was: lib/libarchive (depend))
Message-ID:  <AED014DD-D87C-46C1-8985-85021082A82F@fisglobal.com>
In-Reply-To: <12FE05E5-A149-43D8-A910-8765B732FE8D@fisglobal.com>
References:  <2F8A82E5-70D7-4A1F-A785-704F41E7DFDA@fisglobal.com> <3489DCF5-0E1F-4F6B-A924-772F6F7B2E18@fisglobal.com> <12FE05E5-A149-43D8-A910-8765B732FE8D@fisglobal.com>

next in thread | previous in thread | raw e-mail | index | archive | help

On Jan 13, 2012, at 7:28 PM, Devin Teske wrote:

> Trying to buildworld in RELENG_9 with -DWITHOUT_OPENSSL and getting failu=
res.
>=20
> First failure we encountered required the following patch to get past "li=
b/libarchive (depend)"...
>=20
>=20
>>=20
>> --- lib/libarchive/config_freebsd.h.orig	2012-01-05 03:44:55.000000000 -=
0800
>> +++ lib/libarchive/config_freebsd.h	2012-01-13 18:43:46.000000000 -0800
>> @@ -176,9 +176,4 @@
>> #define	ARCHIVE_HASH_SHA256_OPENSSL 1
>> #define	ARCHIVE_HASH_SHA384_OPENSSL 1
>> #define	ARCHIVE_HASH_SHA512_OPENSSL 1
>> -#else
>> -#define	ARCHIVE_HASH_MD5_LIBC 1
>> -#define	ARCHIVE_HASH_SHA1_LIBC 1
>> -#define	ARCHIVE_HASH_SHA256_LIBC 1
>> -#define	ARCHIVE_HASH_SHA512_LIBC 1
>> #endif
>>=20
>> The above patch allowed the mkdep to succeed and later-compilation in th=
e same directory succeeded (yay).
>=20
> However, you don't get far before the next error.
>=20
> Making all in lib/libbsnmp/libbsnmp with -DWITHOUT_OPENSSL...
>=20
> cc  -I/usr/src/lib/libbsnmp/libbsnmp/../../../contrib/bsnmp/lib -DHAVE_ER=
R_H -DHAVE_GETADDRINFO -DHAVE_STRLCPY -DHAVE_STDINT_H -DHAVE_INTTYPES_H -DQ=
UADFMT=3D'"llu"' -DQUADXFMT=3D'"llx"' -std=3Dgnu99 -fstack-protector -Wsyst=
em-headers -Wall -Wno-format-y2k -W -Wno-unused-parameter -Wstrict-prototyp=
es -Wmissing-prototypes -Wpointer-arith -Wreturn-type -Wcast-qual -Wwrite-s=
trings -Wswitch -Wshadow -Wunused-parameter -Wcast-align -Wchar-subscripts =
-Winline -Wnested-externs -Wredundant-decls -Wold-style-definition -Wno-poi=
nter-sign -c /usr/src/lib/libbsnmp/libbsnmp/../../../contrib/bsnmp/lib/snmp=
crypto.c
> /usr/src/lib/libbsnmp/libbsnmp/../../../contrib/bsnmp/lib/snmpcrypto.c:37=
1: error: conflicting types for 'snmp_passwd_to_keys'
> /usr/src/lib/libbsnmp/libbsnmp/../../../contrib/bsnmp/lib/snmp.h:273: err=
or: previous declaration of 'snmp_passwd_to_keys' was here
> /usr/src/lib/libbsnmp/libbsnmp/../../../contrib/bsnmp/lib/snmpcrypto.c:38=
4: error: conflicting types for 'snmp_get_local_keys'
> /usr/src/lib/libbsnmp/libbsnmp/../../../contrib/bsnmp/lib/snmp.h:274: err=
or: previous declaration of 'snmp_get_local_keys' was here
>=20

The solution to this appears to be the following patch:

=3D=3D=3D=3D=3D=3D=3D=3D=3D BEGIN PATCH =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- contrib/bsnmp/lib/snmpcrypto.c.orig	2011-09-22 17:51:37.000000000 -0700
+++ contrib/bsnmp/lib/snmpcrypto.c	2012-01-15 09:49:27.000000000 -0800
@@ -366,7 +366,7 @@ snmp_pdu_decrypt(const struct snmp_pdu *
 	return (SNMP_CODE_OK);
 }
=20
-int
+enum snmp_code
 snmp_passwd_to_keys(struct snmp_user *user, char *passwd __unused)
 {
 	if (user->auth_proto =3D=3D SNMP_AUTH_NOAUTH &&
@@ -378,7 +378,7 @@ snmp_passwd_to_keys(struct snmp_user *us
 	return (SNMP_CODE_FAILED);
 }
=20
-int
+enum snmp_code
 snmp_get_local_keys(struct snmp_user *user, uint8_t *eid __unused,
     uint32_t elen __unused)
 {

=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D END PATCH =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D

I'll file a PR later (still trying to get a successful build first).
--=20
Devin

_____________
The information contained in this message is proprietary and/or confidentia=
l. If you are not the intended recipient, please: (i) delete the message an=
d all copies; (ii) do not disclose, distribute or use the message in any ma=
nner; and (iii) notify the sender immediately. In addition, please be aware=
 that any message addressed to our domain is subject to archiving and revie=
w by persons other than the intended recipient. Thank you.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?AED014DD-D87C-46C1-8985-85021082A82F>