summaryrefslogtreecommitdiffstats
path: root/bootstrap
diff options
context:
space:
mode:
authorAndy Cedilnik <andy.cedilnik@kitware.com>2006-07-26 15:46:22 (GMT)
committerAndy Cedilnik <andy.cedilnik@kitware.com>2006-07-26 15:46:22 (GMT)
commita9c0929d3938e432484cc2c3e44bf79167ed010d (patch)
treee9b9ebe3403518d16eb3cee89f32801828341e55 /bootstrap
parent47ef50453004e62510f5705185d912950e8fb68f (diff)
downloadCMake-a9c0929d3938e432484cc2c3e44bf79167ed010d.zip
CMake-a9c0929d3938e432484cc2c3e44bf79167ed010d.tar.gz
CMake-a9c0929d3938e432484cc2c3e44bf79167ed010d.tar.bz2
COMP: Handle both ansi and non-ansi C
Diffstat (limited to 'bootstrap')
-rwxr-xr-xbootstrap17
1 files changed, 17 insertions, 0 deletions
diff --git a/bootstrap b/bootstrap
index 9dff3df..047f0f1 100755
--- a/bootstrap
+++ b/bootstrap
@@ -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;