-
Notifications
You must be signed in to change notification settings - Fork 177
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Packaging: factor out packages to lessen depopts
This is a breaking change. Originally set in motion in #301.
- Loading branch information
Showing
18 changed files
with
166 additions
and
35 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
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
File renamed without changes.
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 |
---|---|---|
@@ -1,4 +1,4 @@ | ||
lib: "lwt.opam" { "opam" } | ||
lib: "opam/opam" { "opam" } | ||
doc: [ | ||
"README.md" | ||
"CHANGES" | ||
|
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
This file was deleted.
Oops, something went wrong.
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,25 @@ | ||
# This is only for generating the release build system for this package. In | ||
# development, the main Lwt build system is used. | ||
|
||
# To generate, run | ||
# oasis setup -setup-update none | ||
|
||
OASISFormat: 0.4 | ||
OCamlVersion: >= 4.02 | ||
Name: lwt_glib | ||
Version: 1.0.1 | ||
Synopsis: GLib integration for Lwt | ||
Authors: Jérémie Dimino | ||
License: LGPL-2.1 | ||
Plugins: DevFiles (0.4), META (0.4) | ||
|
||
AlphaFeatures: ocamlbuild_more_args | ||
XOCamlbuildPluginTags: use_str | ||
|
||
Library lwt_glib | ||
Path: . | ||
BuildTools: ocamlbuild | ||
Modules: Lwt_glib | ||
CSources: lwt_glib_stubs.c | ||
BuildDepends: lwt.unix | ||
XMETADescription: GLib integration for Lwt |
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
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,60 @@ | ||
(* OASIS_START *) | ||
(* OASIS_STOP *) | ||
|
||
(* This is largely based on the Glib-related code in the main build system, | ||
though rewritten somewhat. *) | ||
|
||
let split = | ||
let regexp = Str.regexp " +" in | ||
fun s -> Str.split regexp s | ||
|
||
(* Runs pkg-config with the given arguments. *) | ||
let pkg_config arguments = | ||
let command = Printf.sprintf "pkg-config %s" arguments in | ||
let input_channel = Unix.open_process_in command in | ||
let result = | ||
try Pervasives.input_line input_channel | ||
with End_of_file -> "" | ||
in | ||
let status = Unix.close_process_in input_channel in | ||
match status with | ||
| Unix.WEXITED 0 -> split result | ||
| _ -> | ||
Printf.eprintf "Command failed: %s" command; | ||
exit 1 | ||
|
||
(* Loads values from setup.data. In particular, this build needs to check | ||
whether ccomp_type, as detected by configure, is "msvc". *) | ||
let env = | ||
BaseEnvLight.load | ||
~allow_empty:true | ||
~filename:(Pathname.basename BaseEnvLight.default_filename) | ||
() | ||
|
||
let () = | ||
dispatch begin fun hook -> | ||
dispatch_default hook; | ||
|
||
match hook with | ||
| After_rules -> | ||
(* Get compiler and linker options using pkg-config. *) | ||
let cflags = pkg_config "--cflags glib-2.0" in | ||
let libs = | ||
let ccomp_type = BaseEnvLight.var_get "ccomp_type" env in | ||
if ccomp_type = "msvc" then | ||
pkg_config "--libs-only-L glib-2.0" @ | ||
pkg_config "--libs-only-l --msvc_syntax glib-2.0" | ||
else | ||
pkg_config "--libs glib-2.0" | ||
in | ||
|
||
(* Forward compiler and linker options to Ocamlbuild. *) | ||
flag ["ocamlmklib"; "c"] @@ | ||
S (List.map (fun s -> A s) libs); | ||
flag ["compile"; "c"] @@ | ||
S (List.map (fun s -> S [A "-ccopt"; A s]) cflags); | ||
flag ["link"; "ocaml"] @@ | ||
S (List.map (fun s -> S [A "-cclib"; A s]) libs); | ||
|
||
| _ -> () | ||
end |
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 |
---|---|---|
@@ -1,7 +1,9 @@ | ||
opam-version: "1.2" | ||
name: "lwt_glib" | ||
version: "dev" | ||
maintainer: "Anton Bachin <[email protected]>" | ||
version: "1.0.1" | ||
maintainer: [ | ||
"Anton Bachin <[email protected]>" | ||
] | ||
authors: [ | ||
"Jérémie Dimino" | ||
] | ||
|
@@ -10,13 +12,18 @@ doc: "https://ocsigen.org/lwt/manual/" | |
dev-repo: "https://github.com/ocsigen/lwt.git" | ||
bug-reports: "https://github.com/ocsigen/lwt/issues" | ||
license: "LGPL with OpenSSL linking exception" | ||
build: [ | ||
[make "configure"] | ||
[make "build"] | ||
] | ||
install: [ | ||
["ocamlfind" "install" "lwt_glib" "src/glib/META"] | ||
[make "install"] | ||
] | ||
remove: [ | ||
["ocamlfind" "remove" "lwt_glib"] | ||
] | ||
depends: [ | ||
"lwt" {= "dev"} | ||
"lablgtk" | ||
"lwt" {>= "3.0.0"} | ||
"base-unix" | ||
"conf-pkg-config" {build} | ||
] |
This file was deleted.
Oops, something went wrong.
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,20 @@ | ||
# This is only for generating the release build system for this package. In | ||
# development, the main Lwt build system is used. | ||
|
||
# To generate, run | ||
# oasis setup -setup-update none | ||
|
||
OASISFormat: 0.4 | ||
Name: lwt_react | ||
Version: 1.0.1 | ||
Synopsis: Helpers for using React with Lwt | ||
Authors: Jérémie Dimino | ||
License: LGPL-2.1 | ||
Plugins: DevFiles (0.4), META (0.4) | ||
|
||
Library lwt_react | ||
Path: . | ||
BuildTools: ocamlbuild | ||
Modules: Lwt_react | ||
BuildDepends: lwt, react | ||
XMETADescription: Helpers for using React with Lwt |
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 |
---|---|---|
@@ -1,7 +1,9 @@ | ||
opam-version: "1.2" | ||
name: "lwt_react" | ||
version: "dev" | ||
maintainer: "Anton Bachin <[email protected]>" | ||
version: "1.0.1" | ||
maintainer: [ | ||
"Anton Bachin <[email protected]>" | ||
] | ||
authors: [ | ||
"Jérémie Dimino" | ||
] | ||
|
@@ -10,13 +12,17 @@ doc: "https://ocsigen.org/lwt/manual/" | |
dev-repo: "https://github.com/ocsigen/lwt.git" | ||
bug-reports: "https://github.com/ocsigen/lwt/issues" | ||
license: "LGPL with OpenSSL linking exception" | ||
build: [ | ||
[make "configure"] | ||
[make "build"] | ||
] | ||
install: [ | ||
["ocamlfind" "install" "lwt_react" "src/react/META"] | ||
[make "install"] | ||
] | ||
remove: [ | ||
["ocamlfind" "remove" "lwt_react"] | ||
] | ||
depends: [ | ||
"lwt" {= "dev"} | ||
"lwt" {>= "3.0.0"} | ||
"react" {>= "1.0.0"} | ||
] |
This file was deleted.
Oops, something went wrong.
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,20 @@ | ||
# This is only for generating the release build system for this package. In | ||
# development, the main Lwt build system is used. | ||
|
||
# To generate, run | ||
# oasis setup -setup-update none | ||
|
||
OASISFormat: 0.4 | ||
Name: lwt_ssl | ||
Version: 1.0.1 | ||
Synopsis: Lwt-friendly OpenSSL bindings | ||
Authors: Jérémie Dimino | ||
License: LGPL-2.1 | ||
Plugins: DevFiles (0.4), META (0.4) | ||
|
||
Library lwt_ssl | ||
Path: . | ||
BuildTools: ocamlbuild | ||
Modules: Lwt_ssl | ||
BuildDepends: lwt.unix, ssl | ||
XMETADescription: Lwt-friendly OpenSSL bindings |
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 |
---|---|---|
@@ -1,7 +1,9 @@ | ||
opam-version: "1.2" | ||
name: "lwt_ssl" | ||
version: "dev" | ||
maintainer: "Anton Bachin <[email protected]>" | ||
version: "1.0.1" | ||
maintainer: [ | ||
"Anton Bachin <[email protected]>" | ||
] | ||
authors: [ | ||
"Jérôme Vouillon" | ||
"Jérémie Dimino" | ||
|
@@ -11,13 +13,18 @@ doc: "https://ocsigen.org/lwt/manual/" | |
dev-repo: "https://github.com/ocsigen/lwt.git" | ||
bug-reports: "https://github.com/ocsigen/lwt/issues" | ||
license: "LGPL with OpenSSL linking exception" | ||
build: [ | ||
[make "configure"] | ||
[make "build"] | ||
] | ||
install: [ | ||
["ocamlfind" "install" "lwt_ssl" "src/ssl/META"] | ||
[make "install"] | ||
] | ||
remove: [ | ||
["ocamlfind" "remove" "lwt_ssl"] | ||
] | ||
depends: [ | ||
"lwt" {= "dev"} | ||
"lwt" {>= "3.0.0"} | ||
"ssl" {>= "0.5.0"} | ||
"base-unix" | ||
] |