MantisBT - OCaml
View Issue Details
0005207OCaml-for ocamlbuild use https://github.com/ocaml/ocamlbuild/issuespublic2011-01-20 16:522011-01-21 14:21
ofalk 
 
normaltrivialalways
closedfixed 
3.11.0 
3.12.0 
0005207: Syntax error in asmcomp/alpha/proc.ml
While trying to compile ocaml 3.11.0 (and even later) it spots a syntax error in line 211.
The actual code:
let assemble_file infile outfile =
  let as_cmd =
    if digital_asm && !Clflags.gprofile
    then Config.as ^ " -pg"
    else Config.as in
  Ccomp.command (as_cmd ^ " -o " ^
                 Filename.quote outfile ^ " " ^ Filename.quote infile)

So something is wrong with this line: then Config.as ^ " -pg"
I'm not a ocaml guy... I'm just trying to compile it... But I guess there's something wrong with the quoting...

Replacing the code with:
let assemble_file infile outfile =
  Ccomp.command (Config.asm ^ " -o " ^ Filename.quote outfile ^ " " ^ Filename.quote infile)

seems to work fine.
No tags attached.
duplicate of 0004971closed  some minor bugs 
Issue History
2011-01-20 16:52ofalkNew Issue
2011-01-21 14:18doligezRelationship addedduplicate of 0004971
2011-01-21 14:21doligezNote Added: 0005789
2011-01-21 14:21doligezStatusnew => closed
2011-01-21 14:21doligezResolutionopen => fixed
2011-01-21 14:21doligezFixed in Version => 3.12.0
2012-02-02 15:17protzCategoryOCamlbuild => OCamlbuild (the tool)
2017-02-23 16:34doligezCategoryOCamlbuild (the tool) => for ocamlbuild use https://github.com/ocaml/ocamlbuild/issues [^]
2017-02-23 16:44doligezCategoryfor ocamlbuild use https://github.com/ocaml/ocamlbuild/issues [^] => -for ocamlbuild use https://github.com/ocaml/ocamlbuild/issues [^]

Notes
(0005789)
doligez   
2011-01-21 14:21   
"as" is a keyword. Both occurrences of "Config.as" should be replaced by "Config.asm".

This is already fixed in 3.12.0 and later.