Re: [PATCH] libmnl: Failed to build with clang, incompatible EXPORT_SYMBOL(x) macro

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Oct 01, 2015 at 04:30:23PM +0700, Neutron Soutmun wrote:
> On Thu, Oct 1, 2015 at 4:20 PM, Jan Engelhardt <jengelh@xxxxxxx> wrote:
> >
> > On Thursday 2015-10-01 00:12, Pablo Neira Ayuso wrote:
> >>On Fri, Sep 25, 2015 at 11:07:45AM +0700, Neutron Soutmun wrote:
> >>> The EXPORT_SYMBOL(x) macro causes clang compile error and warning
> >>> messges:
> >>>   error,   "note: previous definition is here"
> >>>   warning, "warning: attribute declaration must precede definition
> >>>             [-Wignored-attributes]"
> >>>   See: [1]
> >>>
> >>> This proposed patch has been prepared to fix this error which make the
> >>> EXPORT_SYMBOL macro define a precede definition of an attribute
> >>> declaration. This approach is both compatible with gcc and clang.
> >>
> >>We have more libraries using this approach, which resembles kernel
> >>coding. So we would need to update them all, which is a bit annoying.
> >
> > If you use an export map (-Wl,--version-script=), you don't strictly
> > need to have any of the EXPORT_SYMBOL tags in the C source.
> 
> +1

That sounds as a smaller patch, please send it to me for the existing
libraries that we have. Thanks.
--
To unsubscribe from this list: send the line "unsubscribe netfilter-devel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Netfitler Users]     [LARTC]     [Bugtraq]     [Yosemite Forum]

  Powered by Linux