diff options
author | rillig <rillig@pkgsrc.org> | 2006-11-26 09:56:46 +0000 |
---|---|---|
committer | rillig <rillig@pkgsrc.org> | 2006-11-26 09:56:46 +0000 |
commit | 2e410b3409fa35937dcfbe058ebaf709a425e02e (patch) | |
tree | a4182a3e27842eae1aa96f912ce929199e3bcc2e /mk | |
parent | 414d0506c061e925487d979b076c094b69f2591f (diff) | |
download | pkgsrc-2e410b3409fa35937dcfbe058ebaf709a425e02e.tar.gz |
Added a transformation file for gcc to check for unknown options.
Diffstat (limited to 'mk')
-rw-r--r-- | mk/wrapper/bsd.wrapper.mk | 8 | ||||
-rw-r--r-- | mk/wrapper/transform-gcc | 42 |
2 files changed, 49 insertions, 1 deletions
diff --git a/mk/wrapper/bsd.wrapper.mk b/mk/wrapper/bsd.wrapper.mk index c61ccc649af..e7848103d82 100644 --- a/mk/wrapper/bsd.wrapper.mk +++ b/mk/wrapper/bsd.wrapper.mk @@ -1,4 +1,4 @@ -# $NetBSD: bsd.wrapper.mk,v 1.57 2006/11/11 07:44:46 rillig Exp $ +# $NetBSD: bsd.wrapper.mk,v 1.58 2006/11/26 09:56:46 rillig Exp $ # # Copyright (c) 2005 The NetBSD Foundation, Inc. # All rights reserved. @@ -291,6 +291,11 @@ _WRAP_CACHE_BODY.CXX= ${_WRAP_CACHE_BODY.CC} _WRAP_TRANSFORM.CXX= ${_WRAP_TRANSFORM.CC} .endif +.if !empty(PKGSRC_COMPILER:Mgcc) +_WRAP_TRANSFORM.CC= ${WRAPPER_TMPDIR}/transform-gcc +_WRAP_TRANSFORM.CXX= ${_WRAP_TRANSFORM.CC} +.endif + _WRAP_CMD_SINK.LD= ${WRAPPER_TMPDIR}/cmd-sink-ld _WRAP_SKIP_TRANSFORM.IMAKE= yes @@ -478,6 +483,7 @@ generate-wrappers: ${_target_} cmd-sink-unixware-gcc \ transform-aix-cc \ transform-ccc-cc \ + transform-gcc \ transform-icc-cc \ transform-ido-cc \ transform-mipspro-cc \ diff --git a/mk/wrapper/transform-gcc b/mk/wrapper/transform-gcc new file mode 100644 index 00000000000..f33ee5b1208 --- /dev/null +++ b/mk/wrapper/transform-gcc @@ -0,0 +1,42 @@ +# $NetBSD: transform-gcc,v 1.1 2006/11/26 09:56:46 rillig Exp $ +# + +transform_setname "transform-gcc" +case $arg in +-c|\ +-D?*|\ +-I?*|\ +-L?*|\ +-l?*|\ +-O|\ +-O[012345s]*|\ +-o|\ +-std=c99|\ +-U?*|\ +-W|\ +-W[cLlS],*|\ +-Wall|\ +-Wcast-qual|\ +-Wextra|\ +-Werror|\ +-Wformat=[012]|\ +-Wmissing-prototypes|\ +-Wno-error|\ +-Wno-long-long|\ +-Wno-traditional|\ +-Wno-uninitialized|\ +-Wno-unused|\ +-Wno-write-strings|\ +-Wpointer-arith|\ +-Wreturn-type|\ +-Wshadow|\ +-Wsign-compare|\ +-Wstrict-prototypes|\ +-Wswitch|\ +-Wwrite-strings) + transform_pass + ;; +-*) + transform_discard_with_warning + ;; +esac |