Bug 377761

Summary: icecream breaks when ccache is installed
Product: [Fedora] Fedora Reporter: Michal Schmidt <mschmidt>
Component: icecreamAssignee: Michal Schmidt <mschmidt>
Status: CLOSED RAWHIDE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: low Docs Contact:
Priority: low    
Version: rawhideCC: davidmaxwaterman, dhaval.giani, jhparizona
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2007-11-28 09:24:27 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Michal Schmidt 2007-11-12 13:56:39 UTC
Description of problem:
icecream and ccache can't be easily used together.

Version-Release number of selected component (if applicable):
icecream-3.20071101svn.fc9

How reproducible:
always

Steps to Reproduce:
1. yum install icecream ccache
2. (login)
3. gcc --version
  
Actual results:
ICECC[14017] 12:29:12: icecream seems to have invoked itself recursively

Expected results:
icecream and ccache should be able to work together.

Additional info:
The shell looks for gcc in $PATH and finds icecream's symlink. icecream looks
for the real gcc, finds ccache, runs it. ccache looks for real gcc, finds
icecream, runs it...

Comment 1 Michal Schmidt 2007-11-28 09:24:27 UTC
icecream-0.8.0-5.20071101svn.fc9 prevents the recursive invocation - only 
ccache is used if both are installed.

Having ccache and icecream cooperate requires a small modification in ccache.

Comment 2 Max Waterman 2009-04-27 06:42:55 UTC
This bug still seems to be current.

Any clues on how to make these two products work together?

Comment 3 Michal Schmidt 2009-04-27 08:13:22 UTC
Max,

does it mean you're seeing the message "icecream seems to have invoked itself recursively"?
What versions of ccache and icecream do you have?
How does your $PATH look like?
I don't usually use ccache, but I've installed it now and it seems icecream and ccache work fine here together.

Comment 4 Michal Schmidt 2009-04-30 14:43:59 UTC
OK, I'm clearing the needinfo flag and leaving this bug CLOSED. Max was just confused, he does not use Fedora.

Comment 5 Dhaval Giani 2010-02-01 15:38:40 UTC
I can see the same issue on F12. If I remove ccache from the PATH things work, else icecc fails with the same error.

Comment 6 Michal Schmidt 2010-02-01 16:19:29 UTC
(In reply to comment #5)
> I can see the same issue on F12. If I remove ccache from the PATH things work,
> else icecc fails with the same error.    

What exact versions do you have installed?:
rpm -q icecream ccache

How does your PATH look after login?:
echo $PATH

Comment 7 Dhaval Giani 2010-02-01 16:27:18 UTC
[dhaval@gondor ~]$ rpm -q icecream ccache
icecream-0.9.4-5.fc12.x86_64
ccache-2.4-16.fc12.x86_64

and I do export PATH=/usr/lib64/icecc/bin:$PATH as menmtioned in man icecc

[dhaval@gondor ~]$ echo $PATH
/usr/lib64/qt-3.3/bin:/usr/kerberos/sbin:/usr/kerberos/bin:/usr/lib64/ccache:/usr/local/bin:/usr/bin:/bin:/usr/games:/usr/local/sbin:/usr/sbin:/sbin:/home/dhaval/bin

Comment 8 Michal Schmidt 2010-02-01 17:07:54 UTC
I see. icecream+ccache only work right if ccache precedes icecream in PATH. Normally PATH is set automatically for you by the profile script /etc/profile.d/icecream.sh - it takes care to put icecream after ccache if it finds it there. It's hacky, but it works for me. I wonder why the profile script did not put /usr/lib64/icecc/bin into PATH for you.

Comment 9 James Preston 2012-06-28 18:26:23 UTC
I too am having the same problem on FC16
Based on the above comments here are the versions and $PATH
icecream-0.9.6-4.fc16.x86_64
ccache-3.1.7-1.fc16.x86_64

echo $PATH
/usr/lib64/qt-3.3/bin:/usr/lib64/ccache:/usr/lib64/icecc/bin:/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/root/bin

And here is the error in Code::Blocks
ICECC[23563] 11|12|icecream seems to have invoked itself recursively!|

However, the command gcc --version works fine so .... maybe a Code::Blocks problem.

gcc --version
gcc (GCC) 4.6.3 20120306 (Red Hat 4.6.3-2)
Copyright (C) 2011 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

Code::Blocks version is:
rpm -q codeblocks
codeblocks-10.05-5.fc15.x86_64

Comment 10 James Preston 2012-06-30 02:35:12 UTC
Update:
Is a Code::Blocks problem. Although the path has ccache before icecc, Code::Blocks auto detect gcc compiler ALWAYS selects /usr/lib64/icecc, manually selecting /usr/lib64/ccache solves the problem.