jarvis657 / snappy

Automatically exported from code.google.com/p/snappy
Other
0 stars 0 forks source link

configure.ac: some tests intrude on autoconf's shell namespace #7

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Shell variables starting with ac_ are in autoconf's namespace. Setting things 
like ac_have_builtin_ctz is therefore uncool. See 
http://www.gnu.org/s/hello/manual/autoconf/Macro-Names.html .

I refer to the two AC_TRY_COMPILE tests that set ac_have_builtin_ctz and 
ac_have_builtin_expect.

> To ensure that your macros don't conflict with present or future Autoconf 
macros, you should prefix your own macro names and any shell variables they use 
with some other sequence. Possibilities include your initials, or an 
abbreviation for the name of your organization or software package.

Since there's no really appropriate category int the manual's list of macro 
categories, I'd call them something like snappy_have_builtin_ctz and 
snappy_have_builtin_expect.

I see that caching these tests is a TODO item. When using AC_CACHE_CHECK, 
they'd rename to something like snappy_cv_have_builtin_ctz and 
snappy_cv_have_builtin_expect, respectively.

Original issue reported on code.google.com by endgame....@gmail.com on 22 Mar 2011 at 11:46

GoogleCodeExporter commented 9 years ago

Original comment by se...@google.com on 23 Mar 2011 at 1:08

GoogleCodeExporter commented 9 years ago
Fixed in r6.

Original comment by se...@google.com on 23 Mar 2011 at 11:12