Summary: With the introduction of environments and profiles we no longer need to generate most dune files in libraries via make. Also, those dune builds don't need to be in OCaml. In addition to converting build files to plain sexp definitions, this patch also: - Adjusts copyrightCheck to work correctly with sexp-based dune files. - Adds auto-formatting for sexp-based dune files. Reviewed By: jvillard Differential Revision: D20250208 fbshipit-source-id: 495aeaa99master
parent
fc5b092779
commit
9fc048b503
@ -0,0 +1,18 @@
|
|||||||
|
; Copyright (c) Facebook, Inc. and its affiliates.
|
||||||
|
;
|
||||||
|
; This source code is licensed under the MIT license found in the
|
||||||
|
; LICENSE file in the root directory of this source tree.
|
||||||
|
|
||||||
|
(library
|
||||||
|
(name InferIR)
|
||||||
|
(public_name InferIR)
|
||||||
|
(flags
|
||||||
|
(:standard -open Core -open InferStdlib -open IStd -open InferGenerated
|
||||||
|
-open InferBase))
|
||||||
|
(libraries core zarith InferStdlib InferGenerated InferBase)
|
||||||
|
(preprocess
|
||||||
|
(pps ppx_compare)))
|
||||||
|
|
||||||
|
(documentation
|
||||||
|
(package InferIR)
|
||||||
|
(mld_files index))
|
@ -1,27 +0,0 @@
|
|||||||
(* -*- tuareg -*- *)
|
|
||||||
(*
|
|
||||||
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
||||||
*
|
|
||||||
* This source code is licensed under the MIT license found in the
|
|
||||||
* LICENSE file in the root directory of this source tree.
|
|
||||||
*)
|
|
||||||
(* NOTE: prepend dune.common to this file! *)
|
|
||||||
|
|
||||||
;;
|
|
||||||
Format.sprintf
|
|
||||||
{|
|
|
||||||
(library
|
|
||||||
(name InferIR)
|
|
||||||
(public_name InferIR)
|
|
||||||
(flags (:standard -open Core -open InferStdlib -open IStd -open InferGenerated -open InferBase))
|
|
||||||
(libraries %s)
|
|
||||||
(preprocess (pps ppx_compare))
|
|
||||||
)
|
|
||||||
|
|
||||||
(documentation
|
|
||||||
(package InferIR)
|
|
||||||
(mld_files index)
|
|
||||||
)
|
|
||||||
|}
|
|
||||||
(String.concat " " ("InferBase" :: common_libraries))
|
|
||||||
|> Jbuild_plugin.V1.send
|
|
@ -0,0 +1,17 @@
|
|||||||
|
; Copyright (c) Facebook, Inc. and its affiliates.
|
||||||
|
;
|
||||||
|
; This source code is licensed under the MIT license found in the
|
||||||
|
; LICENSE file in the root directory of this source tree.
|
||||||
|
|
||||||
|
(library
|
||||||
|
(name InferGenerated)
|
||||||
|
(public_name InferGenerated)
|
||||||
|
(flags
|
||||||
|
(:standard -w -27-32-34-35-39))
|
||||||
|
(libraries atdgen core)
|
||||||
|
(preprocess
|
||||||
|
(pps ppx_compare)))
|
||||||
|
|
||||||
|
(documentation
|
||||||
|
(package InferGenerated)
|
||||||
|
(mld_files index))
|
@ -1,26 +0,0 @@
|
|||||||
(* -*- tuareg -*- *)
|
|
||||||
(*
|
|
||||||
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
||||||
*
|
|
||||||
* This source code is licensed under the MIT license found in the
|
|
||||||
* LICENSE file in the root directory of this source tree.
|
|
||||||
*)
|
|
||||||
(* NOTE: prepend dune.common to this file! *)
|
|
||||||
|
|
||||||
;;
|
|
||||||
Format.sprintf
|
|
||||||
{|
|
|
||||||
(library
|
|
||||||
(name InferGenerated)
|
|
||||||
(public_name InferGenerated)
|
|
||||||
(flags (:standard -w -27-32-34-35-39))
|
|
||||||
(libraries atdgen core)
|
|
||||||
(preprocess (pps ppx_compare))
|
|
||||||
)
|
|
||||||
|
|
||||||
(documentation
|
|
||||||
(package InferGenerated)
|
|
||||||
(mld_files index)
|
|
||||||
)
|
|
||||||
|}
|
|
||||||
|> Jbuild_plugin.V1.send
|
|
@ -0,0 +1,18 @@
|
|||||||
|
; Copyright (c) Facebook, Inc. and its affiliates.
|
||||||
|
;
|
||||||
|
; This source code is licensed under the MIT license found in the
|
||||||
|
; LICENSE file in the root directory of this source tree.
|
||||||
|
|
||||||
|
(library
|
||||||
|
(name InferBase)
|
||||||
|
(public_name InferBase)
|
||||||
|
(flags
|
||||||
|
(:standard -open Core -open InferStdlib -open IStd -open InferGenerated))
|
||||||
|
(libraries cmdliner core mtime.clock.os parmap re sqlite3 zip InferGenerated
|
||||||
|
InferStdlib)
|
||||||
|
(preprocess
|
||||||
|
(pps ppx_compare ppx_enumerate)))
|
||||||
|
|
||||||
|
(documentation
|
||||||
|
(package InferBase)
|
||||||
|
(mld_files index))
|
@ -1,2 +1,7 @@
|
|||||||
(lang dune 2.0)
|
(lang dune 2.0)
|
||||||
|
; Copyright (c) Facebook, Inc. and its affiliates.
|
||||||
|
;
|
||||||
|
; This source code is licensed under the MIT license found in the
|
||||||
|
; LICENSE file in the root directory of this source tree.
|
||||||
|
|
||||||
(using menhir 1.0)
|
(using menhir 1.0)
|
||||||
|
@ -0,0 +1,17 @@
|
|||||||
|
; Copyright (c) Facebook, Inc. and its affiliates.
|
||||||
|
;
|
||||||
|
; This source code is licensed under the MIT license found in the
|
||||||
|
; LICENSE file in the root directory of this source tree.
|
||||||
|
|
||||||
|
(library
|
||||||
|
(name InferStdlib)
|
||||||
|
(public_name InferStdlib)
|
||||||
|
(flags
|
||||||
|
(:standard -open Core))
|
||||||
|
(libraries ANSITerminal core str yojson)
|
||||||
|
(preprocess
|
||||||
|
(pps ppx_compare)))
|
||||||
|
|
||||||
|
(documentation
|
||||||
|
(package InferStdlib)
|
||||||
|
(mld_files index))
|
@ -1,27 +0,0 @@
|
|||||||
(* -*- tuareg -*- *)
|
|
||||||
(*
|
|
||||||
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
||||||
*
|
|
||||||
* This source code is licensed under the MIT license found in the
|
|
||||||
* LICENSE file in the root directory of this source tree.
|
|
||||||
*)
|
|
||||||
(* NOTE: prepend dune.common to this file! *)
|
|
||||||
|
|
||||||
;;
|
|
||||||
Format.sprintf
|
|
||||||
{|
|
|
||||||
(library
|
|
||||||
(name InferStdlib)
|
|
||||||
(public_name InferStdlib)
|
|
||||||
(flags (:standard -open Core))
|
|
||||||
(libraries %s)
|
|
||||||
(preprocess (pps ppx_compare))
|
|
||||||
)
|
|
||||||
|
|
||||||
(documentation
|
|
||||||
(package InferStdlib)
|
|
||||||
(mld_files index)
|
|
||||||
)
|
|
||||||
|}
|
|
||||||
(String.concat " " common_libraries)
|
|
||||||
|> Jbuild_plugin.V1.send
|
|
@ -0,0 +1,12 @@
|
|||||||
|
; Copyright (c) Facebook, Inc. and its affiliates.
|
||||||
|
;
|
||||||
|
; This source code is licensed under the MIT license found in the
|
||||||
|
; LICENSE file in the root directory of this source tree.
|
||||||
|
|
||||||
|
(executable
|
||||||
|
(name checkCopyright)
|
||||||
|
(modes byte exe)
|
||||||
|
(flags (:standard))
|
||||||
|
(libraries core str)
|
||||||
|
(preprocess
|
||||||
|
(pps ppx_compare)))
|
@ -1,20 +0,0 @@
|
|||||||
(*
|
|
||||||
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
||||||
*
|
|
||||||
* This source code is licensed under the MIT license found in the
|
|
||||||
* LICENSE file in the root directory of this source tree.
|
|
||||||
*)
|
|
||||||
(* NOTE: prepend dune.common to this file! *)
|
|
||||||
|
|
||||||
;;
|
|
||||||
Format.sprintf
|
|
||||||
{|
|
|
||||||
(executable
|
|
||||||
(name checkCopyright)
|
|
||||||
(modes byte exe)
|
|
||||||
(flags (:standard))
|
|
||||||
(libraries core str)
|
|
||||||
(preprocess (pps ppx_compare))
|
|
||||||
)
|
|
||||||
|}
|
|
||||||
|> Jbuild_plugin.V1.send
|
|
Loading…
Reference in new issue