From: Kim Nguyễn Date: Mon, 22 Oct 2012 15:45:50 +0000 (+0200) Subject: Do not pass -fno-PIC when compiling for x86 (since the option is X-Git-Url: http://git.nguyen.vg/gitweb/?p=SXSI%2Fxpathcomp.git;a=commitdiff_plain;h=6d471b1d8d9545dd8ee0ea6772b0d8253c981d96 Do not pass -fno-PIC when compiling for x86 (since the option is only valid for amd64) --- diff --git a/myocamlbuild.ml b/myocamlbuild.ml index 6f27e4e..6121130 100644 --- a/myocamlbuild.ml +++ b/myocamlbuild.ml @@ -20,7 +20,7 @@ let link_flags = [ A"-linkpkg" ] let libs_files = List.map (fun s -> "file:" ^ s) cxx_libs_objects -let native_compile_flags = ref [A"-fno-PIC"] +let native_compile_flags = if Sys.word_size = 64 then ref [A"-fno-PIC"] else ref [] let compile_flags = ref [] let dwsize = sprintf "-DWORDSIZE%i" Sys.word_size