From a15276f0531a86f0c2d5fd7bc2736622c88958ee Mon Sep 17 00:00:00 2001 From: Adrien Guatto Date: Thu, 12 May 2011 16:18:03 +0200 Subject: [PATCH] Compile with proper include to pervasives.h. --- compiler/utilities/global/compiler_options.ml | 7 ++----- tools/heptc-c.sh | 2 +- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/compiler/utilities/global/compiler_options.ml b/compiler/utilities/global/compiler_options.ml index f91b3fe..61ff55d 100644 --- a/compiler/utilities/global/compiler_options.ml +++ b/compiler/utilities/global/compiler_options.ml @@ -34,11 +34,8 @@ and add_include d = (* where is the standard library *) let locate_stdlib () = - let stdlib = try - Sys.getenv "HEPTLIB" - with - Not_found -> standard_lib in - Format.printf "Standard library in %s@." stdlib + print_string (try Sys.getenv "HEPTLIB" with Not_found -> standard_lib); + print_newline () let show_version () = Format.printf "The Heptagon compiler, version %s (%s)@." diff --git a/tools/heptc-c.sh b/tools/heptc-c.sh index 24f4ea6..3a7ecaf 100755 --- a/tools/heptc-c.sh +++ b/tools/heptc-c.sh @@ -30,4 +30,4 @@ if [ $compile -eq 1 ]; then fi # Compile it with GCC -cc -std=c99 $REP/*.c -o `basename $F .ept` || exit 1 +cc -I `$HEPTC -where`/c -std=c99 $REP/*.c -o `basename $F .ept` || exit 1