Re: [ccache] Support for color diagnostics

2014-02-11 Thread Ryan Hill
On Fri, 29 Nov 2013 12:39:25 +0100
Lubos Lunak  wrote:

>  Clang automatically uses colors for output automatically if used in
> terminal. Ccache's redirecting to a file disables this. GCC 4.8 has got a
> similar support, except that it apparently requires also $GCC_COLORS or an
> explicit option.
> 
>  The patch detects if the compiler would use colors if used without ccache
> and explicitly forces an option to achieve this. Note that I do not have GCC
> 4.8 here, so I tested with Clang's alias and the GCC_COLORS support is done
> based on documentation.

-fdiagnostics-color and GCC_COLORS were added in 4.9.  Maybe some distros have
backported it?

$ gcc-4.8.2 -fdiagnostics-color -c main.c
gcc-4.8.2: error: unrecognized command line option '-fdiagnostics-color'


-- 
Ryan Hillpsn: dirtyepic_sk
   gcc-porting/toolchain/wxwidgets @ gentoo.org

47C3 6D62 4864 0E49 8E9E  7F92 ED38 BD49 957A 8463


signature.asc
Description: PGP signature
___
ccache mailing list
ccache@lists.samba.org
https://lists.samba.org/mailman/listinfo/ccache


Re: [ccache] Testsuite failure with GCC 4.8

2013-04-23 Thread Ryan Hill
On Wed, 20 Mar 2013 22:33:57 +0100
Joel Rosdahl  wrote:

> On 17 March 2013 03:21, Ryan Hill  wrote:
> > In GCC 4.8 the preprocessor automatically includes  in C/C++
> > mode. This is causing a failure in the ccache testsuite: [...]
> 
> Thanks for the notice. I believe I have fixed it now:
> http://gitweb.samba.org/?p=ccache.git;a=commit;h=b5d63f81c1a83fd4c50b769a96a04f581b7db70c

Almost.  It looks like -MMD disables this behaviour so now that particular test
fails in the opposite way.

$ gcc-4.8.0 -c -Wp,-MD,expected.d test.c && cat expected.d 
test.o: test.c /usr/include/stdc-predef.h test1.h test3.h test2.h

$ gcc-4.8.0 -c -Wp,-MMD,expected.d test.c && cat expected.d 
test.o: test.c test1.h test3.h test2.h


-- 
gcc-porting
toolchain, wxwidgets
@ gentoo.org


signature.asc
Description: PGP signature
___
ccache mailing list
ccache@lists.samba.org
https://lists.samba.org/mailman/listinfo/ccache


[ccache] Testsuite failure with GCC 4.8

2013-03-17 Thread Ryan Hill
In GCC 4.8 the preprocessor automatically includes  in C/C++
mode. This is causing a failure in the ccache testsuite:

(see "Pre-processor pre-includes" in http://gcc.gnu.org/gcc-4.8/porting_to.html)


CC='x86_64-pc-linux-gnu-gcc' ./test.sh
starting testsuite base
starting testsuite link
starting testsuite hardlink
starting testsuite cpp2
starting testsuite nlevels4
starting testsuite nlevels1
starting testsuite basedir
starting testsuite direct
SUITE: "direct", TEST: "-Wp,-MD" - Bad content of other.d.\nExpected: test.o: 
test.c test1.h test3.h test2.h\nActual: test.o: test.c 
/usr/include/stdc-predef.h test1.h test3.h test2.h
cache directory 
/var/tmp/portage/dev-util/ccache-3.1.9/work/ccache-3.1.9/testdir.32181/.ccache
cache hit (direct) 0
cache hit (preprocessed)   0
cache miss 1
files in cache15
cache size60 Kbytes
max cache size   1.0 Gbytes
TEST FAILED
Test data and log file have been left in testdir.32181
make: *** [test] Error 1


I'm unsure if this will cause issues in practise or if it's just the test that
needs to be adjusted.


-- 
gcc-porting
toolchain, wxwidgets by design, by neglect
@ gentoo.org for a fact or just for effect


signature.asc
Description: PGP signature
___
ccache mailing list
ccache@lists.samba.org
https://lists.samba.org/mailman/listinfo/ccache