[patch 1/2] Rename COMPAT_VERSION to COMPAT_VERSION_SAMEPROTO

Mark Wielaard mjw at redhat.com
Wed May 1 08:34:57 UTC 2013


On Tue, Apr 30, 2013 at 02:37:46PM +0200, Jan Kratochvil wrote:
> jankratochvil/compatversion
> 
> [...]
> > If I read this right then for the new COMPAT_VERSION macro we don't define
> > a _compat_prefix_name symbol anymore.
> 
> A bug, thanks.

Aha, OK, now it makes more sense. One last question:

> +# define COMPAT_VERSION_NEWPROTO(name, version, prefix) \
> +  asm (".symver _compat." #version "." #name "," #name "@" #version); \
> +  __typeof (_compat_##prefix##_##name) _compat_##prefix##_##name \
> +    asm ("_compat." #version "." #name);
>  # define COMPAT_VERSION(name, version, prefix) \
>    asm (".symver _compat." #version "." #name "," #name "@" #version); \
>    __typeof (name) _compat_##prefix##_##name asm ("_compat." #version "." #name);

Wouldn't the new definition just work always? Whether the prototype is
different or the same? That would simplify things even more by just using
the new definition as COMPAT_VERSION. But I might be missing something
(I still don't fully understand that last asm bit).

Thanks,

Mark


More information about the elfutils-devel mailing list