This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Built-in bzero in GCC 3.0.2


 > From: Eli Zaretskii <eliz@is.elta.co.il>
 > 
 > My goal is quite limited: I'd like to let users compile GDB without
 > seeing warnings.  If there's a GCC option I could use to avoid the
 > warning, it'd be fine, provided that this option will not cause older
 > versions of the compiler (say, the 2.95.x series at least) to barf.

If this is your goal, then modifying gcc is not a real solution since
3.0.x will always have the conflict with your headers.  I also think
that since you're migrating towards the standard spec that we
shouldn't modify gcc to support the wrong spec.

Perhaps another solution would be to add a fixinc hack to change the
system header definition to match the void one.  But you'd have to
supply that patch since I don't have access to such a system.  That
would only help 3.0.3 and later (if its decided its safe enough for
the 3.0.x branch.)

Taking a different approach, I thought gdb was modified to avoid the
BSD string functions?  If any crept back in, the safest thing would be
to just convert them to memcpy.

IIRC, the flag to control these builtins is -ansi.  But I wouldn't
recommend that because it sometimes breaks system headers.  Really
IMHO, you should just not use bzero.

		--Kaveh
--
Kaveh R. Ghazi			Engagement Manager / Project Services
ghazi@caip.rutgers.edu		Qwest Internet Solutions


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]