Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 301727

Summary: dev-util/ccache breaks -MD option
Product: Gentoo Linux Reporter: Mariusz Kozlowski <makofoss>
Component: [OLD] DevelopmentAssignee: Robin Johnson <robbat2>
Status: RESOLVED FIXED    
Severity: normal CC: toolchain
Priority: High    
Version: unspecified   
Hardware: x86   
OS: Linux   
URL: https://bugzilla.samba.org/show_bug.cgi?id=7093
Whiteboard:
Package list:
Runtime testing required: ---
Bug Depends on: 313101    
Bug Blocks:    

Description Mariusz Kozlowski 2010-01-21 15:57:34 UTC
That breaks dependencies when the makefile runs with its current directory
different from its object directory - for instance glibc does this.


Reproducible: Always

Steps to Reproduce:
1. mkdir testxyz
2. touch foo.c
3. gcc foo.c -c -o `pwd`/foo.o -MD
   foo.d will say:
   /this/directory/foo.o: foo.c
4. ccache gcc foo.c -c -o `pwd`/foo.o -MD
   foo.d will say:
   foo.o: foo.c

Actual Results:  
If you use -MD

'*.d' files are in source folder


Expected Results:  
If you use -MD

'*.d' files should be in target (binaries) folder


This is exactly the same problem as reported here in debian bus:

http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=217713

Also my bug report is almost all copy and paste from debian report. It is the same issue and I verified the wrong behaviour.
Comment 1 Mariusz Kozlowski 2010-01-21 15:59:44 UTC
Hmm ... I believe this is the patch for fixing this issue:

http://lists.samba.org/archive/ccache/2006q4/000249.html
Comment 2 SpanKY gentoo-dev 2010-02-02 23:56:51 UTC
ive pushed the issue upstream (among all the other outstanding Gentoo patches)
Comment 3 SpanKY gentoo-dev 2010-04-11 21:31:39 UTC
fix should be included with ccache-3.0
Comment 4 SpanKY gentoo-dev 2010-11-19 09:46:12 UTC
ccache-3.1.1 in the tree which should fix this