Index: /branches/libffado-2.0/SConstruct =================================================================== --- /branches/libffado-2.0/SConstruct (revision 1371) +++ /branches/libffado-2.0/SConstruct (revision 1389) @@ -160,5 +160,5 @@ def CompilerCheck( context ): context.Message( "Checking for a working C-compiler " ) - ret = context.TryLink( """ + ret = context.TryRun( """ #include @@ -166,10 +166,10 @@ printf( "Hello World!" ); return 0; -}""", '.c' ) +}""", '.c' )[0] context.Result( ret ) if ret == 0: return False; context.Message( "Checking for a working C++-compiler " ) - ret = context.TryLink( """ + ret = context.TryRun( """ #include @@ -177,5 +177,5 @@ std::cout << "Hello World!" << std::endl; return 0; -}""", ".cpp" ) +}""", ".cpp" )[0] context.Result( ret ) return ret @@ -202,24 +202,9 @@ if not env.GetOption('clean'): -# # -# # Check if the environment can actually compile c-files by checking for a -# # header shipped with gcc. -# # -# if not conf.CheckHeader( "stdio.h", language="C" ): -# print "It seems as if stdio.h is missing. This probably means that your build environment is broken, please make sure you have a working c-compiler and libstdc installed and usable." -# Exit( 1 ) -# # -# # ... and do the same with a c++-header. Because some distributions have -# # distinct packages for gcc and g++. -# # -# if not conf.CheckHeader( "iostream", language="C++" ): -# print "It seems as if iostream is missing. This probably means that your build environment is broken, please make sure you have a working c++-compiler installed and usable." -# Exit( 1 ) - # - # Seems as if the above tests don't really work. This one should do the trick!? + # Check for working gcc and g++ compilers and their environment. # if not conf.CompilerCheck(): - print "It seems as if your system isn't even able to compile any C-/C++-programs. Probably you don't have gcc and g++ installed. Compiling a package from source without a working compiler is very hard to do, please install the needed packages (Hint: on *ubuntu you need both gcc- and g++-packages installed)." + print "It seems as if your system isn't even able to compile any C-/C++-programs. Probably you don't have gcc and g++ installed. Compiling a package from source without a working compiler is very hard to do, please install the needed packages.\nHint: on *ubuntu you need both gcc- and g++-packages installed, easiest solution is to install build-essential which depends on gcc and g++." Exit( 1 )