[vlc-devel] [PATCH 4/8] add compiler detection variables and apply the correct optimization flags

Rafaël Carré rafael.carre at gmail.com
Thu Apr 15 04:40:19 CEST 2010


On Wed, 14 Apr 2010 16:53:16 +0200
Francois Cartegnie <fcvlcdev at free.fr> wrote:

> ---
>  configure.ac |   68
> +++++++++++++++++++++++++++++++++++++++++---------------- 1 files
> changed, 49 insertions(+), 19 deletions(-)
> 
> diff --git a/configure.ac b/configure.ac
> index 27a05b8..66844b7 100644
> --- a/configure.ac
> +++ b/configure.ac
> @@ -979,6 +979,22 @@ CFLAGS="${CFLAGS_save}"
>  RDC_PROG_CC_WFLAGS([all extra sign-compare undef pointer-arith
> bad-function-cast write-strings missing-prototypes
> volatile-register-var error-implicit-function-declaration])
> RDC_PROG_CC_FLAGS([-pipe]) +dnl Set up version & compiler variables
> for various hacks +VLC_COMPILER=`$CC -v 2>&1 | tail -n 1`
> +if echo "${VLC_COMPILER}" | grep GCC; then 
> +	AC_DEFINE_UNQUOTED(VLC_COMPILER, "${VLC_COMPILER}",
> [compiler])
> +	VLC_COMPILER_BRAND="GCC"

Have a look at http://www.gnu.org/software/autoconf/manual/html_node/C-Compiler.html#C-Compiler

"GCC" shell variable is defined when using gcc, no need for custom check

-- 
Rafaël Carré
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: not available
URL: <http://mailman.videolan.org/pipermail/vlc-devel/attachments/20100415/a3f30375/attachment.sig>


More information about the vlc-devel mailing list