我试图在我的Ubuntu 14.04中从源代码安装frama-c,但它永远不可能。
氟制造错误:
allberson@allberson-Aspire-E1-531:~/Área de Trabalho/frama-c-Fluorine-20130601$ make
Generating src/lib/dynlink_common_interface.ml
Generating src/kernel/config.ml
Generating ptests/ptests_config.ml
Generating share/Makefile.kernel
Generating .depend
Ocamlc src/lib/dynlink_common_interface.cmo
Ocamlc src/kernel/config.cmo
Ocamlc src/ai/abstract_interp.cmi
File "src/ai/abstract_interp.mli", line 166, characters 4-33:
Error: In this `with' constraint, the new definition of O
does not match its original definition in the constrained signature:
...
The field `find' is required but not provided
make: ** [src/ai/abstract_interp.cmi] Erro 2
钠制造错误:
Makefile:2456: aviso: ignorando comandos antigos para o alvo `de'
Ocamlopt src/gui/property_navigator.cmx
ocamlopt.opt: don't know what to do with de.
Usage: ocamlopt <options> <files>
Options are:
-ffast-math Inline trigonometric and exponential functions
-a Build a library
-absname Show absolute filenames in error messages
-annot Save information in <filename>.annot
-bin-annot Save typedtree in <filename>.cmt
-c Compile only (do not link)
-cc <command> Use <command> as the C compiler and linker
-cclib <opt> Pass option <opt> to the C linker
-ccopt <opt> Pass option <opt> to the C compiler and linker
-compact Optimize code size rather than speed
-config Print configuration values and exit
-dtypes (deprecated) same as -annot
-for-pack <ident> Generate code that can later be `packed' with
ocamlopt -pack -o <ident>.cmx
-g Record debugging information for exception backtrace
-i Print inferred interface
-I <dir> Add <dir> to the list of include directories
-impl <file> Compile <file> as a .ml file
-inline <n> Set aggressiveness of inlining to <n>
-intf <file> Compile <file> as a .mli file
-intf-suffix <string> Suffix for interface files (default: .mli)
-labels Use commuting label mode
-linkall Link all modules, even unused ones
-no-app-funct Deactivate applicative functors
-noassert Do not compile assertion checks
-noautolink Do not automatically link C libraries specified in .cmxa files
-nodynlink Enable optimizations for code that will not be dynlinked
-nolabels Ignore non-optional labels in types
-nostdlib Do not add default directory to the list of include directories
-o <file> Set output file name to <file>
-output-obj Output a C object file instead of an executable
-p Compile and link with profiling support for "gprof"
(not supported on all platforms)
-pack Package the given .cmx files into one .cmx
-pp <command> Pipe sources through preprocessor <command>
-ppx <command> Pipe abstract syntax trees through preprocessor <command>
-principal Check principality of type inference
-rectypes Allow arbitrary recursive types
-runtime-variant <str> Use the <str> variant of the run-time system
-S Keep intermediate assembly file
-shared Produce a dynlinkable plugin
-short-paths Shorten paths in types
-strict-sequence Left-hand part of a sequence must have type unit
-thread Generate code that supports the system threads library
-unsafe Do not compile bounds checking on array and string access
-v Print compiler version and location of standard library and exit
-verbose Print calls to external commands
-version Print version and exit
-vnum Print version number and exit
-w <list> Enable or disable warnings according to <list>:
+<spec> enable warnings in <spec>
-<spec> disable warnings in <spec>
@<spec> enable warnings in <spec> and treat them as errors
<spec> can be:
<num> a single warning number
<num1>..<num2> a range of consecutive warning numbers
<letter> a predefined set
default setting is "+a-4-6-7-9-27-29-32..39-41..42-44-45"
-warn-error <list> Enable or disable error status for warnings according
to <list>. See option -w for the syntax of <list>.
Default setting is "-a"
-warn-help Show description of warning numbers
-where Print location of standard library and exit
-nopervasives (undocumented)
-dsource (undocumented)
-dparsetree (undocumented)
-dtypedtree (undocumented)
-drawlambda (undocumented)
-dlambda (undocumented)
-dclambda (undocumented)
-dcmm (undocumented)
-dsel (undocumented)
-dcombine (undocumented)
-dlive (undocumented)
-dspill (undocumented)
-dsplit (undocumented)
-dinterf (undocumented)
-dprefer (undocumented)
-dalloc (undocumented)
-dreload (undocumented)
-dscheduling (undocumented)
-dlinear (undocumented)
-dstartup (undocumented)
- <file> Treat <file> as a file name (even if it starts with `-')
-help Display this list of options
--help Display this list of options
make: ** [src/gui/property_navigator.cmx] Erro 2
答案 0 :(得分:1)
如果我没弄错的话,这个错误源于最新版本的OCaml。您应该尝试使用新版本的Frama-C OCaml 3.10.2或更高版本。 Sodium刚刚发布,解决了这个问题。另外,正如Virgile所提到的,最简单的方法是使用Opam包。
答案 1 :(得分:0)
我终于解决了它。我安装了frama -c /为什么使用opam(4.01.0)。但现在我正在使用jessie运行frama-c,并且出现此错误:
$ frama-c -jessie copy.c
[kernel] Parsing FRAMAC_SHARE/libc/__fc_builtin_for_normalization.i (no preprocessing)
[kernel] Parsing copy.c (with preprocessing)
[jessie] Starting Jessie translation
[jessie] Producing Jessie files in subdir copy.jessie
[jessie] File copy.jessie/copy.jc written.
[jessie] File copy.jessie/copy.cloc written.
[jessie] Calling Jessie tool in subdir copy.jessie
Generating Why function copy
[jessie] Calling VCs generator.
why3 ide --extra-config /home/hpe/.opam/4.01.0/lib/why/why3/why3.conf copy.mlw
[Config] reading extra configuration file /home/hpe/.opam/4.01.0/lib/why/why3/why3.conf
/usr/local/lib/why3/plugins/genequlin can't be loaded : Dynlink error : error loading shared library: /usr/local/lib/why3/plugins/genequlin.cmxs: undefined symbol: camlWhy3__Term__t_app_4489
/usr/local/lib/why3/plugins/tptp can't be loaded : Dynlink error : error loading shared library: /usr/local/lib/why3/plugins/tptp.cmxs: undefined symbol: camlWhy3__Pp__print_list_1023
/usr/local/lib/why3/plugins/hypothesis_selection can't be loaded : Dynlink error : error loading shared library: /usr/local/lib/why3/plugins/hypothesis_selection.cmxs: undefined symbol: camlWhy3__Pp__print_list_1023
[GUI] Init the GTK interface... done.
[GUI config] reading icons... done.
[GUI] Creating tree model... done
[GUI] found regular file 'copy.mlw'
[GUI] using 'copy' as directory for the project
[GUI session] Opening session...
[GUI session] Opening session: update done
[GUI session] Opening session: done
[GUI session] Adding file '../copy.mlw'
[GUI] adding file ../copy.mlw in database
Error while reading file '../copy.mlw':
File "/home/hpe/.opam/4.01.0/lib/why/why3/jessie_why3.mlw", line 268, characters 13-27:
unbound symbol 'Double.div_post'
make: ** [why3ide] Erro 1
[jessie] user error: Jessie subprocess failed: make -f copy.makefile why3ide