Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dune upgrade V1 -> V2 #3174

Merged
merged 32 commits into from
Mar 24, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
b32aa0f
Remove unused field to_add
emillon Feb 12, 2020
336f76f
WIP: upgrader: detect lang version for each root
emillon Feb 12, 2020
e351c2c
Add tests for the ugprader
voodoos Feb 14, 2020
c70a2f9
Upgrade project version
voodoos Feb 13, 2020
9f713ca
Expose `fname` in `File_tree.Dune_file`
voodoos Feb 19, 2020
f485e57
Split files and start work on upgrader v1 -> v2
voodoos Feb 19, 2020
aa08544
Also upgrade included files
voodoos Feb 19, 2020
f606712
Upgrade formatting instructions
voodoos Feb 21, 2020
d8981df
Implement the default mode check + reformat
voodoos Feb 25, 2020
76ec6c9
Also apply to executableS
voodoos Feb 26, 2020
63b4ddc
Refactor explicit modes
voodoos Feb 26, 2020
6f68841
Upgrade preprocessing
voodoos Feb 26, 2020
d12cda2
Upgrade remove no_keep_locs
voodoos Feb 26, 2020
b88f2f3
Remove debug print
voodoos Feb 27, 2020
c37384e
End log + Reformat
voodoos Feb 27, 2020
56dff69
Add support for foreign stubs
voodoos Mar 2, 2020
04ffdf4
Refactor
voodoos Mar 2, 2020
0905518
Merge everything into one file
voodoos Mar 2, 2020
6895d5c
Reformat
voodoos Mar 2, 2020
3bee69f
Foreign stubs for librairies too
voodoos Mar 2, 2020
85620f7
Remove regression: bad jbuild project inference.
voodoos Mar 3, 2020
f8509aa
Add hint about self_build_stubs_archive deletion
voodoos Mar 3, 2020
fb86a1b
Small docs and CHANGES updates
voodoos Mar 3, 2020
17153be
Reformat
voodoos Mar 4, 2020
6a873f6
Make the upgrader run twice if necssary
voodoos Mar 5, 2020
d955282
Reformat
voodoos Mar 5, 2020
b3436b6
Add idempotency check in test suite
voodoos Mar 16, 2020
cf63dd7
Change remaining `log` to `Console.print` and update test
voodoos Mar 16, 2020
9517659
Refmt
voodoos Mar 16, 2020
15df0b9
Make an auxilliary recursive methoad
voodoos Mar 19, 2020
5fcda5c
Format in tests
voodoos Mar 19, 2020
315ba6e
Merge branch 'master' into dune-upgrade-2
voodoos Mar 24, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 10 additions & 7 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -259,9 +259,9 @@ Unreleased
`dirs` stanza in `dune` files. (#2456, @rgrinberg)

- Add a new config option `sandboxing_preference`, the cli argument `--sandbox`,
and the dep spec `sandbox` in dune language. These let the user control the level of
sandboxing done by dune per rule and globally. The rule specification takes precedence.
The global configuration merely specifies the default.
and the dep spec `sandbox` in dune language. These let the user control the
level of sandboxing done by dune per rule and globally. The rule specification
takes precedence. The global configuration merely specifies the default.
(#2213, @aalekseyev, @diml)

- Remove support for old style subsystems. Dune will now emit a warning to
Expand Down Expand Up @@ -297,10 +297,10 @@ Unreleased
sandboxing and in general reduces build directory pollution. (#2486,
@aalekseyev, fixes #2482)

- `c_flags`, `c_names` and `cxx_names` are now supported in `executable`
and `executables` stanzas. (#2562, @nojb)
Note: this feature has been subsequently extended into a separate
`foreign_stubs` field. (#2659, RFC #2650, @snowleopard)
- `c_flags`, `c_names` and `cxx_names` are now supported in `executable` and
`executables` stanzas. (#2562, @nojb) Note: this feature has been subsequently
extended into a separate `foreign_stubs` field. The fields `c(xx)_names` and
`c(xx)_flags` are now deleted. (#2659, RFC #2650, @snowleopard)

- Remove git integration from `$ dune upgrade` (#2565, @rgrinberg)

Expand Down Expand Up @@ -395,6 +395,9 @@ Unreleased

- Allow `.opam.template` files to be generated using rules (#2866, @rgrinberg)

- Delete the deprecated `self_build_stubs_archive` field, replaced by
`foreign_archives`.

1.11.4 (09/10/2019)
-------------------

Expand Down
4 changes: 2 additions & 2 deletions doc/dune-files.rst
Original file line number Diff line number Diff line change
Expand Up @@ -388,13 +388,13 @@ to use the :ref:`include_subdirs` stanza.
- ``(foreign_stubs <foreign-stubs-spec>)`` specifies foreign source files, e.g.
C or C++ stubs, to be compiled and packaged together with the library. See
the section :ref:`foreign-sources-and-archives` for more details. This field
replaces the now deprecated fields ``c_names``, ``c_flags``, ``cxx_names``
replaces the now deleted fields ``c_names``, ``c_flags``, ``cxx_names``
and ``cxx_flags``.

- ``(foreign_archives <foreign-archives-list>)`` specifies archives of foreign
object files to be packaged with the library. See the section
:ref:`foreign-archives` for more details. This field replaces the now
deprecated field ``self_build_stubs_archive``.
deleted field ``self_build_stubs_archive``.

- ``(install_c_headers (<names>))``, if your library has public C header files
that must be installed, you must list them in this field, without the ``.h``
Expand Down
2 changes: 1 addition & 1 deletion doc/dune-libs.rst
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ this flag file using ``:include``:

(library
(name mylib)
(c_names foo)
(foreign_stubs (language c) (names foo))
(c_library_flags (:include (flags.sexp))))

For this, generate the list of flags for your library — for example
Expand Down
2 changes: 2 additions & 0 deletions src/dune/file_tree.mli
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ module Dune_file : sig
val get_sexp_and_destroy : t -> Dune_lang.Ast.t list
end

val fname : string

val jbuild_fname : string

type t = private
Expand Down
Loading