diff options
author | Andy Cedilnik <andy.cedilnik@kitware.com> | 2006-07-26 15:46:22 (GMT) |
---|---|---|
committer | Andy Cedilnik <andy.cedilnik@kitware.com> | 2006-07-26 15:46:22 (GMT) |
commit | a9c0929d3938e432484cc2c3e44bf79167ed010d (patch) | |
tree | e9b9ebe3403518d16eb3cee89f32801828341e55 /bootstrap | |
parent | 47ef50453004e62510f5705185d912950e8fb68f (diff) | |
download | CMake-a9c0929d3938e432484cc2c3e44bf79167ed010d.zip CMake-a9c0929d3938e432484cc2c3e44bf79167ed010d.tar.gz CMake-a9c0929d3938e432484cc2c3e44bf79167ed010d.tar.bz2 |
COMP: Handle both ansi and non-ansi C
Diffstat (limited to 'bootstrap')
-rwxr-xr-x | bootstrap | 17 |
1 files changed, 17 insertions, 0 deletions
@@ -537,7 +537,24 @@ fi TMPFILE=`cmake_tmp_file` cat > "${TMPFILE}.c" <<EOF #include<stdio.h> +#if defined(__hpux) && !defined(__GNUC__) +# if defined(__CLASSIC_C__) +/* No ansi option given. */ +# define bootstrap_require_no_prototype +# elif defined(__STDC_EXT__) +/* Option -Ae given. */ +# else +/* Option -Aa given. */ +# endif +#endif + +#ifdef bootstrap_require_no_prototype +int main(argc, argv) + int argc; + char* argv[]; +#else int main(int argc, char* argv[]) +#endif { printf("%d\n", (argv != 0)); return argc-1; |