On Sat, Jan 02, 2010 at 07:21:21PM +0100, Vladimir 'φ-coder/phcoder' Serbinenko wrote: > Colin Watson wrote: > > Instead of this, why not only use the attribute if it's available? I > > couldn't find an entry about it in GCC's human-readable change > > summaries, but support was committed on 2007-09-23 so I think it's > > available from GCC 4.3. > > Why not have configure.ac check specifically if this attribute is > available and use it only if it is?
Perhaps it's a style thing; for some reason I've always preferred this approach, even though normally I would advocate doing feature tests at configure time rather than version tests at compile time. My preference may be because __attribute__ is GCC-specific anyway, and there's no guarantee that another compiler would implement the same attribute names in the same way if they happened to use them, so it's better to be quite explicit that this is specific to appropriate versions of GCC. -- Colin Watson [cjwat...@ubuntu.com] _______________________________________________ Grub-devel mailing list Grub-devel@gnu.org http://lists.gnu.org/mailman/listinfo/grub-devel