Mantis Bug Tracker

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0005234OCaml~DO NOT USE (was: OCaml general)public2011-03-03 20:262011-05-17 16:14
Assigned To 
PlatformOSOS Version
Product Version3.12.0 
Target VersionFixed in Version3.12.1+dev 
Summary0005234: ocamlopt -shared does not preserve order of -cclib options
DescriptionConsider the following example (Windows, MSVC port):
let x = 1
let _ = Printf.printf "%d\n" Foo.x

ocamlopt -a -o foo.cmxa -cclib -defaultlib -cclib msvcrt.lib
ocamlopt -verbose -o bar.exe foo.cmxa
  + flexlink -merge-manifest -exe -link /STACK:16777216 -o "bar.exe"
  "-LC:\Ocaml\lib" "C:\DOCUME~1\dbely\LOCALS~1\Temp\camlstartup799bea.obj"
  "C:\Ocaml\lib\std_exit.obj" "bar.obj" "foo.lib" "C:\Ocaml\lib\stdlib.lib"
  "-defaultlib" "msvcrt.lib" "C:\Ocaml\lib\libasmrun.lib" advapi32.lib

ocamlopt -verbose -shared -o bar.cmxs foo.cmxa
  + flexlink -merge-manifest -o "bar.cmxs" "-LC:\Ocaml\lib"
  "bar.cmxs.startup.obj" "bar.obj" "foo.lib" "msvcrt.lib" "-defaultlib"
  flexlink: option `-defaultlib' needs an argument.

Note that "-defaultlib" "msvcrt.lib" order is reversed.
TagsNo tags attached.
Attached Files

- Relationships
related to 0005260closed ocaml compiler presents static link libraries to GCC backwards 

-  Notes
There are no notes attached to this issue.

- Issue History
Date Modified Username Field Change
2011-03-03 20:26 db New Issue
2011-05-02 12:47 doligez Relationship added related to 0005260
2011-05-16 16:36 doligez Status new => acknowledged
2011-05-17 16:14 doligez Status acknowledged => closed
2011-05-17 16:14 doligez Resolution open => fixed
2011-05-17 16:14 doligez Fixed in Version => 3.12.1+dev
2017-02-23 16:36 doligez Category OCaml general => -OCaml general
2017-03-03 17:55 doligez Category -OCaml general => -(deprecated) general
2017-03-03 18:01 doligez Category -(deprecated) general => ~deprecated (was: OCaml general)
2017-03-06 17:04 doligez Category ~deprecated (was: OCaml general) => ~DO NOT USE (was: OCaml general)

Copyright © 2000 - 2011 MantisBT Group
Powered by Mantis Bugtracker