MantisBT - CMake |
| View Issue Details |
|
| ID | Project | Category | View Status | Date Submitted | Last Update |
| 0011707 | CMake | (No Category) | public | 2011-01-16 13:50 | 2011-01-31 16:13 |
|
| Reporter | Nicolas Despres | |
| Assigned To | Brad King | |
| Priority | normal | Severity | minor | Reproducibility | always |
| Status | closed | Resolution | fixed | |
| Platform | Linux 2.6.32-27-generic #49 i686 | OS | Ubuntu | OS Version | 10.04.1 LTS |
| Product Version | CMake 2.8.3 | |
| Target Version | CMake 2.8.4 | Fixed in Version | CMake 2.8.4 | |
|
| Summary | 0011707: Cannot use ccache when building cmake |
| Description | If have tried to bootstrap cmake using ccache and gcc by setting CC='ccache gcc' and CXX='ccache g++' but it does not work and ccache is not used. |
| Steps To Reproduce | $ mkdir _build
$ cd _build
$ CC='ccache gcc' CXX='ccache g++' ../configure --prefix="$HOME/usr/stow/cmake" --qt-gui --qt-qmake=/usr/bin/qmake --parallel=2 --verbose
|
| Additional Information | I have attached the cmake_bootstrap.log. Apparently bootstrap understands CC and CXX as a list so it first tries ccache alone as a compiler and then gcc alone. Of course ccache alone fails to build the test program so gcc is picked up instead of 'ccache gcc'.
I would suggest to add a --enable-ccache option to this script. I'll try to write a patch.
|
| Tags | No tags attached. |
| Relationships | |
| Attached Files | cmake_bootstrap.log (192,125) 2011-01-16 13:50 https://public.kitware.com/Bug/file/3630/cmake_bootstrap.log
bootstrap-enable-ccache.patch (1,446) 2011-01-16 16:34 https://public.kitware.com/Bug/file/3632/bootstrap-enable-ccache.patch |
|
| Issue History |
| Date Modified | Username | Field | Change |
| 2011-01-16 13:50 | Nicolas Despres | New Issue | |
| 2011-01-16 13:50 | Nicolas Despres | File Added: cmake_bootstrap.log | |
| 2011-01-16 16:34 | Nicolas Despres | File Added: bootstrap-enable-ccache.patch | |
| 2011-01-16 18:49 | Nicolas Despres | Note Added: 0024731 | |
| 2011-01-17 06:54 | Michael Wild | Note Added: 0024733 | |
| 2011-01-17 07:06 | Michael Wild | Note Added: 0024734 | |
| 2011-01-17 09:03 | Brad King | Assigned To | => Brad King |
| 2011-01-17 09:03 | Brad King | Status | new => assigned |
| 2011-01-17 09:04 | Brad King | Note Added: 0024744 | |
| 2011-01-17 09:04 | Brad King | Status | assigned => closed |
| 2011-01-17 09:04 | Brad King | Resolution | open => fixed |
| 2011-01-31 16:13 | David Cole | Fixed in Version | => CMake 2.8.4 |
| 2011-01-31 16:13 | David Cole | Target Version | => CMake 2.8.4 |
|
Notes |
|
|
(0024731)
|
|
Nicolas Despres
|
|
2011-01-16 18:49
|
|
Oups. My patch 'bootstrap-enable-ccache.patch' that accurate in the usage message.
Now it is:
Enable ccache when bootstrapping and building cmake.
But it should be:
Enable ccache when building cmake. |
|
|
|
(0024733)
|
|
Michael Wild
|
|
2011-01-17 06:54
|
|
|
alternatively, simply symlink ccache to ./gcc and ./g++ and then set CC=$PWD/gcc and CXX=$PWD/g++. |
|
|
|
(0024734)
|
|
Michael Wild
|
|
2011-01-17 07:06
|
|
|
And if you're using Ubuntu/Debian and installed ccache using the package manager, use CC=/usr/lib/ccache/gcc and CXX=/usr/lib/ccache/g++ directly. If using CentOS/RHEL/Fedora/OpenSUSE/..., replace the /usr/lib with /usr/lib64 if running a 64-bit operating system. Other operating systems will have similar facilities. |
|
|
|
(0024744)
|
|
Brad King
|
|
2011-01-17 09:04
|
|
|