From f45af3286a61ceae85160639097da6776ce66098 Mon Sep 17 00:00:00 2001 From: varobert Date: Wed, 11 Jul 2012 15:04:00 +0000 Subject: checklink: added configurability git-svn-id: https://yquem.inria.fr/compcert/svn/compcert/trunk@1969 fca1b0fc-160b-0410-b1d3-a4f43f01ea2e --- checklink/Validator.ml | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'checklink/Validator.ml') diff --git a/checklink/Validator.ml b/checklink/Validator.ml index 1edcdb4..4baa5d6 100644 --- a/checklink/Validator.ml +++ b/checklink/Validator.ml @@ -16,6 +16,12 @@ let set_elf_file s = | Some _ -> raise (Arg.Bad "multiple ELF executables given on command line") end +let set_conf_file s = + begin match !conf_file with + | None -> conf_file := Some s + | Some _ -> raise (Arg.Bad "multiple configuration files given on command line") + end + let option_disassemble = ref false let disassemble_list = ref ([]: string list) let add_disassemble s = @@ -26,6 +32,8 @@ let options = [ (* Main options *) "-exe", Arg.String set_elf_file, " Specify the ELF executable file to analyze"; + "-conf", Arg.String set_conf_file, + " Specify a configuration file (see README)"; (* Parsing behavior *) "-relaxed", Arg.Set ELF_parsers.relaxed, "Allows the following behaviors in the ELF parser: -- cgit v1.2.3