[Build-common-hackers] Bug#450901: Bug#450901: cmake class probably broken: CMAKE_C_COMPILER/CMAKE_CXX_COMPILER error

Ana Guerrero ana at debian.org
Sun Dec 16 00:28:36 UTC 2007


Hi Peter,

Looking to switch in the current kde4 packages from our cmake.mk class to the
cdbs's one I run into this problem as well.

On Tue, Nov 27, 2007 at 01:10:58PM +0100, Peter Eisentraut wrote:
> Am Samstag, 24. November 2007 schrieb Daniel Leidert:
> > > > CMake Error: your C compiler:
> > > > "/tmp/buildd/avogadro-0.2.0/obj-i486-linux-gnu/cc" was not found.
> > > > Please set CMAKE_C_COMPILER to a valid compiler path or name.
> > > > CMake Error: your CXX compiler:
> > > > "/tmp/buildd/avogadro-0.2.0/obj-i486-linux-gnu/g++" was not found.
> > > > Please set CMAKE_CXX_COMPILER to a valid compiler path or name.
> 
> I think this is a bug internal to cmake or the tests it uses.  Earlier in the 
> output it claims
> 
> -- Check for working C compiler: cc
> -- Check for working C compiler: cc -- works
> -- Check size of void*
> -- Check size of void* - done
> -- Check for working CXX compiler: g++
> -- Check for working CXX compiler: g++ -- works
> 
> So it says the compilers work, and in order to check the size of void* it 
> would also have to actually run the compiler successfully.
> 
> Furthermore, it asks to set CMAKE_CXX_COMPILER to a valid compiler path or 
> *name*, which interpret such that a base name is sufficient.
> 
> So at the moment I believe that the behavior implemented in cdbs is correct 
> and the problem is somewhere else.


In my case:


usr/bin/make -f debian/rules update-config
make[1]: Entering directory `/tmp/buildd/kde4libs-3.97.0'
make[1]: Nothing to be done for `update-config'.
make[1]: Leaving directory `/tmp/buildd/kde4libs-3.97.0'
cd obj-i486-linux-gnu && cmake /tmp/buildd/kde4libs-3.97.0/.
-DCMAKE_INSTALL_PREFIX="/usr" -DCMAKE_C_COMPILER="cc"
-DCMAKE_CXX_COMPILER="g++" -DCMAKE_C_FLAGS="-g -Wall -O2"
-DCMAKE_CXX_FLAGS="-g -Wall -O2" -DCMAKE_SKIP_RPATH=ON
-DCMAKE_VERBOSE_MAKEFILE=ON -DCMAKE_BUILD_TYPE=debugfull
-DKDE4_BUILD_TESTS=true -DKDE_DISTRIBUTION_TEXT="Debian packages"
-DCMAKE_SKIP_RPATH=true -DCONFIG_INSTALL_DIR=/etc/kde4
-DDATA_INSTALL_DIR=/usr/share/kde4/apps
-DHTML_INSTALL_DIR=/usr/share/doc/kde4/HTML
-DKCFG_INSTALL_DIR=/usr/share/kde4/config.kcfg -DLIB_INSTALL_DIR=/usr/lib
-DSYSCONF_INSTALL_DIR=/etc
-- Check for working C compiler: cc
-- Check for working C compiler: cc -- works
-- Check size of void*
-- Check size of void* - done
-- Check for working CXX compiler: g++
-- Check for working CXX compiler: g++ -- works


So it FTBFS.

just get current kde4libs from experimental, replace in debian/cdbs/kde.mk our
cmake.mk class for the cdbs's one and you can reproduce this problem.

Our cmake.mk does not use: -DCMAKE_C_COMPILER or -DCMAKE_CXX_COMPILER. is it
really necessary?

Ana





More information about the Build-common-hackers mailing list