Date: Wed, 25 Feb 2009 19:02:47 -0500 (EST) From: Daniel Eischen <deischen@freebsd.org> To: d@delphij.net Cc: kan@freebsd.org, freebsd-hackers <freebsd-hackers@freebsd.org> Subject: Re: How to change an interface? Message-ID: <Pine.GSO.4.64.0902251858430.7249@sea.ntplx.net> In-Reply-To: <49A5D67C.8080102@delphij.net> References: <49A5D67C.8080102@delphij.net>
next in thread | previous in thread | raw e-mail | index | archive | help
On Wed, 25 Feb 2009, Xin LI wrote: > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA1 > > Hi, > > Just wanted to confirm that the following procedure to change an > existing interface: > > - Remove the symbol in question from all previous FBSD_1.* namespaces > with their corresponding Symbol.map files; > > - Add the new symbol into latest FBSD_1.* namespace, say, FBSD_1.1 for > now, into corresponding Symbol.map files; > > - Create a new file containing the compatibility shims with prefix __ > and suffix of something indicating its obsoleteness, e.g. _44bsd. For > instance, for function foo(), the shim function would be called > __foo_44bsd(); > > - At the tail of the shim file, add glues for the old symbols like this: > > __sym_compat(foo, __foo_44bsd, FBSD_1.0); > > - Double check to make sure that new .so would work with old binaries. > > Is that correct? Yes, I believe that is correct. I also think that the awk script that processes the Symbol.map files will also warn you if the symbol is multiply declared. -- DE
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.GSO.4.64.0902251858430.7249>