Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 06 Apr 2014 09:44:43 -0700
From:      Sean Bruno <sbruno@ignoranthack.me>
To:        David Chisnall <theraven@FreeBSD.org>
Cc:        "freebsd-current@freebsd.org" <freebsd-current@freebsd.org>
Subject:   Re: static linking, libc multiple definitions
Message-ID:  <1396802683.1472.0.camel@powernoodle.corp.yahoo.com>
In-Reply-To: <0650344F-FF86-4675-8724-0018AA00740B@FreeBSD.org>
References:  <1396799725.37365.4.camel@powernoodle.corp.yahoo.com> <0650344F-FF86-4675-8724-0018AA00740B@FreeBSD.org>

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

--=-No8rLBSdjpcJcVDvxJFB
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

On Sun, 2014-04-06 at 17:12 +0100, David Chisnall wrote:
> It looks like these two are defined in rpc_com.h, so they are declared an=
d defined in multiple compilation units.  That's not actually wrong (they'l=
l have common linkage and be merged), but it's discouraged because it can m=
ask other errors.  Can you see if this patch fixes it for you?
>=20
> David
>=20
>=20
> Index: rpc/rpc_com.h
> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
> --- rpc/rpc_com.h       (revision 264068)
> +++ rpc/rpc_com.h       (working copy)
> @@ -86,8 +86,8 @@
>  bool_t __xdrrec_getrec(XDR *, enum xprt_stat *, bool_t);
>  void __xprt_unregister_unlocked(SVCXPRT *);
> =20
> -SVCXPRT **__svc_xports;
> -int __svc_maxrec;
> +extern SVCXPRT **__svc_xports;
> +extern int __svc_maxrec;
> =20
>  __END_DECLS
> =20
> Index: rpc/svc.c
> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
> --- rpc/svc.c   (revision 264068)
> +++ rpc/svc.c   (working copy)
> @@ -84,6 +84,9 @@
>         void                (*sc_dispatch)(struct svc_req *, SVCXPRT *);
>  } *svc_head;
> =20
> +SVCXPRT **__svc_xports;
> +int __svc_maxrec;
> +
>  static struct svc_callout *svc_find(rpcprog_t, rpcvers_t,
>      struct svc_callout **, char *);
>  static void __xprt_do_unregister (SVCXPRT *xprt, bool_t dolock);
>=20
>=20


Yep, that make it much quieter now.  :-)  Thank you.

sean

--=-No8rLBSdjpcJcVDvxJFB
Content-Type: application/pgp-signature; name="signature.asc"
Content-Description: This is a digitally signed message part

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1

iQEcBAABAgAGBQJTQYR3AAoJEBkJRdwI6BaHk5MH/AqC3rRsjQ4+0m0JySWqKIXz
EMWersVyWLzB7aN6542A73iWCratOLmSuwUAmoFXNR/AwrZPbyJVuhXlcX6thsVn
p4J/3W3vvbav7dBswU/yIUlWdtP/k7OSX5Xnampy9Uu5hlvff7e7poFkQwtCZHVB
7a5r9lbmb8DDuGwI0TgMuLhoR6gbtVri4geiuXujMDExoIOsoZlRtR8ufBNncn2M
QZUNUDhRveOQKBvK7STWNhcTPi8rcS7xYHiiFelqrCQQm6pouxULkvcOwDcBydEi
8EK9ML8ZxFu8zwaGoqKMU5Jwjq7LXSCq5F583oI4iDdWuoY23mHw3p4lhBatMz8=
=NwtB
-----END PGP SIGNATURE-----

--=-No8rLBSdjpcJcVDvxJFB--




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1396802683.1472.0.camel>