[llvm-commits] [PATCH][CMake] More platform checks.
Óscar Fuentes
ofv at wanadoo.es
Mon Jan 31 10:30:16 PST 2011
arrowdodger <6yearold at gmail.com> writes:
> +check_symbol_exists(srand48 stdlib.h HAVE_RAND48)
> +if( HAVE_RAND48 )
> + check_symbol_exists(lrand48 stdlib.h HAVE_RAND48)
> + if( HAVE_RAND48 )
> + check_symbol_exists(drand48 stdlib.h HAVE_RAND48)
> + endif()
> +endif()
This is wrong. The first check_symbol_exists puts HAVE_RAND48 on the
cache when it succeeds, so the following check_symbol_exists that also
use HAVE_RAND48 as the variable are ignored.
You can see that with cmake's output:
-- Looking for srand48
-- Looking for srand48 - found
-- Looking for strtoq
Note how there is check for lrand48 nor for drand48.
Committed with a correction for the above issue. Thanks!
More information about the llvm-commits
mailing list