From 5c0c02e51a76183eb43b5ed80d925f3c2ce88dfb Mon Sep 17 00:00:00 2001 From: Bernhard Schommer Date: Mon, 13 Feb 2017 15:39:07 +0100 Subject: Introduced configuration variable for gnu systems. The variable gnu_toolchain is true if a gnu toolchain is used and false in all other cases. The variable avoids the explicit test whether the system string is diab and should be easier to change. Bug 20521. --- driver/Linker.ml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'driver/Linker.ml') diff --git a/driver/Linker.ml b/driver/Linker.ml index 5e14cfd4..54566efb 100644 --- a/driver/Linker.ml +++ b/driver/Linker.ml @@ -48,7 +48,7 @@ let linker_help = -l Link library -L Add to search path for libraries |} ^ - (if gnu_system then gnu_linker_help else "") ^ + (if Configuration.gnu_toolchain then gnu_linker_help else "") ^ {| -s Remove all symbol table and relocation information from the executable -static Prevent linking with the shared libraries @@ -63,14 +63,14 @@ let linker_help = let linker_actions = [ Prefix "-l", Self push_linker_arg; Prefix "-L", Self push_linker_arg; ] @ - (if gnu_system then + (if Configuration.gnu_toolchain then [ Exact "-nostartfiles", Self push_linker_arg; Exact "-nodefaultlibs", Self push_linker_arg; Exact "-nostdlib", Self push_linker_arg;] else []) @ [ Exact "-s", Self push_linker_arg; Exact "-static", Self push_linker_arg; - Exact "-T", String (fun s -> if gnu_system then begin + Exact "-T", String (fun s -> if Configuration.gnu_toolchain then begin push_linker_arg ("-T"); push_linker_arg(s) end else -- cgit