autoconf-archive-maintainers | |
[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Patches for implementing checking for valid CFLAGS, LDFLAGS, etc.
From: |
Maarten Bosmans |
Subject: |
Re: Patches for implementing checking for valid CFLAGS, LDFLAGS, etc. |
Date: |
Sat, 25 Jun 2011 12:01:08 +0200 |
Hi Peter,
2011/6/25 Peter Simons <address@hidden>:
> I have pushed your patches to the Git repository moments ago. Thank you
> very much for your efforts!
Great!
If there were some submission guidelines stating the width of
description lines and how to properly mark a macro deprecated, I could
have done that before submitting the patches. The current guidelines
on the website only seem to cover completely new macro submissions.
> > There are some AX_APPEND_* macros added, should these be in the same
> > file or separate?
>
> If at all possible, there should be just one macro per m4 file. That
> policy allows tools like aclocal(1) to pull macros into a project with
> high precision. Also, it means that the name of the macro matches the
> name of the m4 file, which makes things easier for the user.
OK, that sounds reasonable. I'm OK with the current situation though,
but if anyone wants to extract the AX_APPEND_* macros to a new file,
feel free. Note that the AX_APPEND_{COMPILE,LINK}_FLAGS macros depend
on both AX_APPEND_FLAG and the respective AX_CHECK_*_FLAG macros.
> > For ax_check_*_flags and ax_*_check_flag I used AU_DEFUN to provide
> > an implementation based on the new macros that is automatically
> > updated when running autoupdate. Is this the right approach, or
> > should I leave the deprecated macros as the were and only add a
> > message on top of the description?
>
> Using AU_DEFUN to replace obsolete macros with the newer version is very
> desirable. Yes, please do that! :-)
About the snippet you added to NEWS:
> The new macro AX_CHECK_FLAG has been added, which replaces AX_C_CHECK_FLAG,
> AX_CFLAGS_AIX_OPTION, AX_CFLAGS_GCC_OPTION, AX_CFLAGS_HPUX_OPTION,
> AX_CFLAGS_IRIX_OPTION, AX_CFLAGS_SUN_OPTION, AX_CHECK_COMPILER_FLAGS,
> AX_CHECK_LINKER_FLAGS, AX_CPP_CHECK_FLAG, AX_CXX_CHECK_FLAG,
> AX_CXXCPP_CHECK_FLAG, and AX_LD_CHECK_FLAG. Further details can be found at
>
> <http://lists.gnu.org/archive/html/autoconf-archive-maintainers/2011-06/msg00017.html>.
The macro is not called AX_CHECK_FLAG, that is the name of the file
that contains AX_CHECK_COMPILE_FLAG and others. You could spell it in
lowercase to signify that it's the file we're talking about, not the
macro.
The macros AX_CFLAGS_AIX_OPTION, AX_CFLAGS_GCC_OPTION,
AX_CFLAGS_HPUX_OPTION, AX_CFLAGS_IRIX_OPTION, AX_CFLAGS_SUN_OPTION are
not really replaced by AX_CHECK_COMPILE_FLAG. That macro is merely
used in their implementation to abstract out all the commonalities of
the individual compiler macros. The thing they add on top is knowledge
about the compiler-specific flags to treat unknown options as errors.
The remark at te bottom of my first mail about further improvements in
these macros is still valid, as this compiler-specific knowledge is
still encoded multiple times in other macros and I think it should be
in one central place in the autoconf archive.
But that is work for a later day (or someone else).
Maarten
> Again, thank you very much for your efforts!
>
> Take care,
> Peter
- Patches for implementing checking for valid CFLAGS, LDFLAGS, etc., Maarten Bosmans, 2011/06/20
- [PATCH 1/7] ax_cflags_*_option.m4: Consolidate _OLD and _NEW macros, Maarten Bosmans, 2011/06/20
- [PATCH 2/7] ax_cflags_*_option.m4: Consolidate CFLAGS and CXXFLAGS macros, Maarten Bosmans, 2011/06/20
- [PATCH 4/7] ax_cflags_*_option.m4: Use AX_CHECK_COMPILE_FLAG macro to do most of the work, Maarten Bosmans, 2011/06/20
- [PATCH 5/7] ax_cflags_*_option.m4: Use AX_APPEND_FLAG macro to append the flag, Maarten Bosmans, 2011/06/20
- [PATCH 3/7] Add ax_check_flag.m4, Maarten Bosmans, 2011/06/20
- [PATCH 7/7] Implement AX_*_CHECK_FLAG on top of ax_check_flag.m4 macros, Maarten Bosmans, 2011/06/20
- [PATCH 6/7] Implement AX_CHECK_*_FLAGS on top of ax_check_flag.m4 macros, Maarten Bosmans, 2011/06/20
- Re: Patches for implementing checking for valid CFLAGS, LDFLAGS, etc., Peter Simons, 2011/06/25
- Re: Patches for implementing checking for valid CFLAGS, LDFLAGS, etc.,
Maarten Bosmans <=
- Re: Patches for implementing checking for valid CFLAGS, LDFLAGS, etc., Peter Simons, 2011/06/28
- Re: Patches for implementing checking for valid CFLAGS, LDFLAGS, etc., Maarten Bosmans, 2011/06/28
- Re: Patches for implementing checking for valid CFLAGS, LDFLAGS, etc., Peter Simons, 2011/06/30