-
Notifications
You must be signed in to change notification settings - Fork 415
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
test: transitive deps and link time code gen (#6641)
reproduce the issue in PR #6633 link time code generation doesn't use the correct compilation closure for the build info module. It uses the compile closure but we should use the link closure Signed-off-by: Rudi Grinberg <[email protected]>
- Loading branch information
Showing
2 changed files
with
29 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
24 changes: 24 additions & 0 deletions
24
test/blackbox-tests/test-cases/link-time-transitive-deps.t
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
Link time code generation should work with implicit transitive deps | ||
|
||
$ cat >dune-project <<EOF | ||
> (lang dune 3.0) | ||
> (implicit_transitive_deps false) | ||
> EOF | ||
|
||
$ touch foo.ml bar.ml | ||
$ cat >dune <<EOF | ||
> (library | ||
> (libraries dune-build-info) | ||
> (modules foo) | ||
> (name foo)) | ||
> (executable | ||
> (modules bar) | ||
> (libraries foo) | ||
> (name bar)) | ||
> EOF | ||
|
||
$ dune build ./bar.exe | ||
File ".bar.eobjs/build_info_data.ml-gen", line 1: | ||
Error: Could not find the .cmi file for interface | ||
.bar.eobjs/build_info_data.ml-gen. | ||
[1] |