Skip to content

Commit

Permalink
Remove compat symlinks for jbuild files
Browse files Browse the repository at this point in the history
This was a compatibility hack for jbuild files that is no longer
necessary in dune 2.0

Signed-off-by: Rudi Grinberg <rudi.grinberg@gmail.com>
  • Loading branch information
rgrinberg committed Jul 24, 2019
1 parent e6b5bd1 commit 192d792
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 15 deletions.
3 changes: 3 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@

- Enable `(explicit_js_mode)` by default. (#1941, @nojb)

- Stop symlinking object files to main directory for stanzas defined `jbuild`
files (#2440, @rgrinerg)

1.11.0 (23/07/2019)
-------------------

Expand Down
15 changes: 0 additions & 15 deletions src/module_compilation.ml
Original file line number Diff line number Diff line change
Expand Up @@ -105,21 +105,6 @@ let build_cm cctx ~dep_graphs ~precompiled_cmi ~cm_kind (m : Module.t) =
Option.value_exn (Obj_dir.Module.cmt_file obj_dir m ~ml_kind) in
(fn :: other_targets, A "-bin-annot")
in
if CC.dir_kind cctx = Jbuild then begin
(* Symlink the object files in the original directory for
backward compatibility *)
let old_dst =
(Module.obj_name m) ^ (Cm_kind.ext cm_kind)
|> Path.Build.relative dir
in
SC.add_rule sctx ~dir
(Build.symlink ~src:(Path.build dst) ~dst:old_dst);
List.iter other_targets ~f:(fun in_obj_dir ->
let in_dir = Path.Build.relative dir
(Path.Build.basename in_obj_dir) in
SC.add_rule sctx ~dir
(Build.symlink ~src:(Path.build in_obj_dir) ~dst:in_dir))
end;
let opaque_arg =
let intf_only = cm_kind = Cmi && not (Module.has m ~ml_kind:Impl) in
if opaque
Expand Down

0 comments on commit 192d792

Please sign in to comment.