├── .dockerignore ├── .gitignore ├── .nowignore ├── Dockerfile ├── README.md ├── build.sh ├── dune-project ├── esy.json ├── esy.lock ├── .gitattributes ├── .gitignore ├── index.json ├── opam │ ├── angstrom.0.12.1 │ │ └── opam │ ├── base-bigarray.base │ │ └── opam │ ├── base-bytes.base │ │ └── opam │ ├── base-threads.base │ │ └── opam │ ├── base-unix.base │ │ └── opam │ ├── base.v0.12.2 │ │ └── opam │ ├── base64.3.2.0 │ │ └── opam │ ├── bigarray-compat.1.0.0 │ │ └── opam │ ├── bigstringaf.0.6.0 │ │ └── opam │ ├── biniou.1.2.1 │ │ └── opam │ ├── conf-m4.1 │ │ └── opam │ ├── conf-pkg-config.1.1 │ │ └── opam │ ├── cow.2.4.0 │ │ └── opam │ ├── cppo.1.6.6 │ │ └── opam │ ├── cstruct.5.0.0 │ │ └── opam │ ├── dune-configurator.1.0.0 │ │ └── opam │ ├── dune.1.11.3 │ │ └── opam │ ├── easy-format.1.3.2 │ │ └── opam │ ├── ezjsonm.1.1.0 │ │ └── opam │ ├── faraday-lwt-unix.0.7.0 │ │ └── opam │ ├── faraday-lwt.0.7.0 │ │ └── opam │ ├── faraday.0.7.0 │ │ └── opam │ ├── fmt.0.8.8 │ │ └── opam │ ├── hex.1.4.0 │ │ └── opam │ ├── hpack.0.2.0 │ │ └── opam │ ├── jbuilder.transition │ │ └── opam │ ├── jsonm.1.0.1 │ │ └── opam │ ├── logs.0.7.0 │ │ └── opam │ ├── lwt.4.3.1 │ │ └── opam │ ├── lwt_ssl.1.1.3 │ │ └── opam │ ├── menhir.20190924 │ │ └── opam │ ├── merlin-extend.0.5 │ │ └── opam │ ├── mmap.1.1.0 │ │ └── opam │ ├── num.1.2 │ │ ├── files │ │ │ └── installation-warning.patch │ │ └── opam │ ├── ocaml-compiler-libs.v0.12.1 │ │ └── opam │ ├── ocaml-migrate-parsetree.1.4.0 │ │ └── opam │ ├── ocamlbuild.0.14.0 │ │ └── opam │ ├── ocamlfind.1.8.1 │ │ ├── files │ │ │ ├── ocaml-stub │ │ │ └── ocamlfind.install │ │ └── opam │ ├── ocplib-endian.1.0 │ │ └── opam │ ├── omd.1.3.1 │ │ └── opam │ ├── parsexp.v0.12.0 │ │ └── opam │ ├── ppx_derivers.1.2.1 │ │ └── opam │ ├── ppx_deriving.4.4 │ │ └── opam │ ├── ppx_deriving_yojson.3.5.1 │ │ └── opam │ ├── ppx_tools.5.3+4.08.0 │ │ └── opam │ ├── ppx_tools_versioned.5.2.3 │ │ └── opam │ ├── ppxfind.1.3 │ │ └── opam │ ├── ppxlib.0.9.0 │ │ └── opam │ ├── psq.0.2.0 │ │ └── opam │ ├── re.1.9.0 │ │ └── opam │ ├── reason.3.5.2 │ │ └── opam │ ├── result.1.4 │ │ └── opam │ ├── seq.base │ │ ├── files │ │ │ ├── META.seq │ │ │ └── seq.install │ │ └── opam │ ├── sexplib.v0.12.0 │ │ └── opam │ ├── sexplib0.v0.12.0 │ │ └── opam │ ├── ssl.0.5.9 │ │ └── opam │ ├── stdio.v0.12.0 │ │ └── opam │ ├── stdlib-shims.0.1.0 │ │ └── opam │ ├── stringext.1.6.0 │ │ └── opam │ ├── topkg.1.0.1 │ │ └── opam │ ├── uchar.0.0.2 │ │ └── opam │ ├── uri.3.0.0 │ │ └── opam │ ├── uutf.1.0.2 │ │ └── opam │ ├── xmlm.1.3.0 │ │ └── opam │ └── yojson.1.7.0 │ │ └── opam └── overrides │ ├── af5fc8c4abb1f4c1dce1c179864522b6 │ ├── .ci │ │ └── build.yaml │ ├── .gitignore │ ├── .travis.yml │ ├── README.md │ ├── azure-pipelines.yml │ ├── esy.lock.json │ ├── esy │ │ ├── test.c │ │ └── test.sh │ ├── files │ │ └── openssl-1.1.1d-mingw.patch │ └── package.json │ ├── opam__s__conf_pkg_config_opam__c__1.1_opam_override │ └── package.json │ ├── opam__s__dune_opam__c__1.11.3_opam_override │ └── package.json │ ├── opam__s__num_opam__c__1.2_opam_override │ └── package.json │ ├── opam__s__ocamlbuild_opam__c__0.14.0_opam_override │ ├── files │ │ └── ocamlbuild-0.14.0.patch │ └── package.json │ ├── opam__s__ocamlfind_opam__c__1.8.1_opam_override │ ├── files │ │ └── findlib-1.8.1.patch │ └── package.json │ └── opam__s__ocplib_endian_opam__c__1.0_opam_override │ ├── files │ ├── esy-fix.patch │ └── ocplib-endian-0.8.patch │ └── package.json ├── graphql_schema.json ├── now.json └── src ├── dune ├── lambda.re └── request.ml /.dockerignore: -------------------------------------------------------------------------------- 1 | _esy 2 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | bootstrap 2 | node_modules 3 | package-lock.json 4 | _build 5 | _esy 6 | .graphql_ppx_cache 7 | .merlin 8 | -------------------------------------------------------------------------------- /.nowignore: -------------------------------------------------------------------------------- 1 | /* 2 | !/bootstrap 3 | -------------------------------------------------------------------------------- /Dockerfile: -------------------------------------------------------------------------------- 1 | # start from node image so we can install esy from npm 2 | 3 | FROM node:10.13-alpine as build 4 | 5 | ENV TERM=dumb LD_LIBRARY_PATH=/usr/local/lib:/usr/lib:/lib 6 | 7 | RUN mkdir /esy 8 | WORKDIR /esy 9 | 10 | ENV NPM_CONFIG_PREFIX=/esy 11 | RUN npm install -g --unsafe-perm esy@0.5.8 12 | 13 | # now that we have esy installed we need a proper runtime 14 | 15 | FROM alpine:3.8 as esy 16 | 17 | ENV TERM=dumb LD_LIBRARY_PATH=/usr/local/lib:/usr/lib:/lib 18 | 19 | WORKDIR / 20 | 21 | COPY --from=build /esy /esy 22 | 23 | RUN apk add --no-cache ca-certificates wget bash curl perl-utils git patch \ 24 | gcc g++ musl-dev make m4 linux-headers coreutils 25 | 26 | RUN wget -q -O /etc/apk/keys/sgerrand.rsa.pub https://alpine-pkgs.sgerrand.com/sgerrand.rsa.pub 27 | RUN wget https://github.com/sgerrand/alpine-pkg-glibc/releases/download/2.28-r0/glibc-2.28-r0.apk 28 | RUN apk add --no-cache glibc-2.28-r0.apk 29 | 30 | ENV PATH=/esy/bin:$PATH 31 | 32 | RUN mkdir /app 33 | WORKDIR /app 34 | 35 | RUN echo ' \ 36 | {\ 37 | "name": "package-base", \ 38 | "dependencies": { \ 39 | "ocaml": "~4.9.0", \ 40 | "@opam/dune": "*", \ 41 | "@opam/reason": "*", \ 42 | "@opam/conf-openssl": "esy-packages/esy-openssl#860ad7f" \ 43 | } \ 44 | } \ 45 | ' > esy.json 46 | 47 | RUN esy 48 | 49 | COPY esy.json esy.json 50 | COPY esy.lock esy.lock 51 | 52 | RUN esy fetch 53 | RUN esy true 54 | 55 | COPY . . 56 | 57 | RUN esy b dune build src/lambda.exe --profile=static 58 | 59 | RUN mv _build/default/src/lambda.exe bootstrap 60 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # github-stars-lambda-demo 2 | 3 | This is a demo I gave at ReasonConf 2019. 4 | 5 | to build use, `./build.sh` (Docker required). 6 | 7 | 8 | Once the build script is done you can deploy with `now -e GH_TOKEN="your_github_token_here"` 9 | -------------------------------------------------------------------------------- /build.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env sh 2 | 3 | set -eo pipefail 4 | 5 | rm -rf bootstrap 6 | docker build . --tag github-stars 7 | docker rm github-stars || true 8 | docker create --name github-stars github-stars 9 | docker cp github-stars:/app/bootstrap bootstrap 10 | 11 | cd $root_path 12 | -------------------------------------------------------------------------------- /dune-project: -------------------------------------------------------------------------------- 1 | (lang dune 1.6) 2 | -------------------------------------------------------------------------------- /esy.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "github-stars", 3 | "version": "1.0.0", 4 | "description": "", 5 | "main": "index.js", 6 | "author": "", 7 | "license": "ISC", 8 | "dependencies": { 9 | "ocaml": "~4.9.0", 10 | "now": "16.2.0", 11 | "@opam/dune": "*", 12 | "@opam/lambda-runtime": "*", 13 | "@opam/now": "*", 14 | "@opam/httpaf": "*", 15 | "@opam/httpaf-lwt-unix": "*", 16 | "@opam/h2": "*", 17 | "@opam/h2-lwt-unix": "*", 18 | "@opam/lwt_ssl": "*", 19 | "@opam/logs": "*", 20 | "@opam/fmt": "*", 21 | "@opam/conf-openssl": "*", 22 | "@opam/reason": " *", 23 | "@opam/graphql_ppx": "*", 24 | "@opam/graphql_ppx_base": "*", 25 | "@opam/omd": "*", 26 | "@opam/cow": "*", 27 | "@opam/uri": "*" 28 | }, 29 | "devDependencies": { 30 | "@opam/merlin": "*" 31 | }, 32 | "resolutions": { 33 | "@opam/httpaf-lwt-unix": "anmonteiro/httpaf:httpaf-lwt-unix.opam#9fe3c7e", 34 | "@opam/httpaf-lwt": "anmonteiro/httpaf:httpaf-lwt.opam#9fe3c7e", 35 | "@opam/httpaf": "anmonteiro/httpaf:httpaf.opam#9fe3c7e", 36 | "@opam/h2": "anmonteiro/ocaml-h2:h2.opam#ec84c5f", 37 | "@opam/h2-lwt": "anmonteiro/ocaml-h2:h2-lwt.opam#ec84c5f", 38 | "@opam/h2-lwt-unix": "anmonteiro/ocaml-h2:h2-lwt-unix.opam#ec84c5f", 39 | "@opam/lambda-runtime": "anmonteiro/aws-lambda-ocaml-runtime:lambda-runtime.opam#feb3ed7", 40 | "@opam/now": "anmonteiro/aws-lambda-ocaml-runtime:now.opam#feb3ed7", 41 | "@opam/conf-openssl": "esy-packages/esy-openssl#860ad7f", 42 | "@opam/graphql_ppx_base": "anmonteiro/graphql_ppx:graphql_ppx_base.opam#17ca0ee", 43 | "@opam/graphql_ppx": "anmonteiro/graphql_ppx:graphql_ppx.opam#17ca0ee", 44 | "@opam/merlin": { 45 | "source": "ocaml/merlin:merlin.opam#cfc28bd", 46 | "override": { 47 | "dependencies": { 48 | "ocaml": "~4.9.0" 49 | } 50 | } 51 | } 52 | }, 53 | "esy": { 54 | "buildsInSource": "unsafe" 55 | } 56 | } 57 | -------------------------------------------------------------------------------- /esy.lock/.gitattributes: -------------------------------------------------------------------------------- 1 | 2 | # Set eol to LF so files aren't converted to CRLF-eol on Windows. 3 | * text eol=lf 4 | -------------------------------------------------------------------------------- /esy.lock/.gitignore: -------------------------------------------------------------------------------- 1 | 2 | # Reset any possible .gitignore, we want all esy.lock to be un-ignored. 3 | !* 4 | -------------------------------------------------------------------------------- /esy.lock/opam/angstrom.0.12.1/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "Spiros Eliopoulos " 3 | authors: [ "Spiros Eliopoulos " ] 4 | license: "BSD-3-clause" 5 | homepage: "https://github.com/inhabitedtype/angstrom" 6 | bug-reports: "https://github.com/inhabitedtype/angstrom/issues" 7 | dev-repo: "git+https://github.com/inhabitedtype/angstrom.git" 8 | build: [ 9 | ["dune" "subst"] {pinned} 10 | ["dune" "build" "-p" name "-j" jobs] 11 | ["dune" "runtest" "-p" name "-j" jobs] {with-test} 12 | ] 13 | depends: [ 14 | "ocaml" {>= "4.03.0"} 15 | "dune" {>= "1.0"} 16 | "alcotest" {with-test & >= "0.8.1"} 17 | "bigstringaf" 18 | "result" 19 | ] 20 | synopsis: "Parser combinators built for speed and memory-efficiency" 21 | description: """ 22 | Angstrom is a parser-combinator library that makes it easy to write efficient, 23 | expressive, and reusable parsers suitable for high-performance applications. It 24 | exposes monadic and applicative interfaces for composition, and supports 25 | incremental input through buffered and unbuffered interfaces. Both interfaces 26 | give the user total control over the blocking behavior of their application, 27 | with the unbuffered interface enabling zero-copy IO. Parsers are backtracking by 28 | default and support unbounded lookahead.""" 29 | url { 30 | src: "https://github.com/inhabitedtype/angstrom/archive/0.12.1.tar.gz" 31 | checksum: "md5=b253d5bf5468a19408689523458cfe81" 32 | } 33 | -------------------------------------------------------------------------------- /esy.lock/opam/base-bigarray.base/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "https://github.com/ocaml/opam-repository/issues" 3 | description: """ 4 | Bigarray library distributed with the OCaml compiler 5 | """ 6 | 7 | -------------------------------------------------------------------------------- /esy.lock/opam/base-bytes.base/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: " " 3 | authors: " " 4 | homepage: " " 5 | depends: [ 6 | "ocaml" {>= "4.02.0"} 7 | "ocamlfind" {>= "1.5.3"} 8 | ] 9 | synopsis: "Bytes library distributed with the OCaml compiler" 10 | -------------------------------------------------------------------------------- /esy.lock/opam/base-threads.base/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "https://github.com/ocaml/opam-repository/issues" 3 | description: """ 4 | Threads library distributed with the OCaml compiler 5 | """ 6 | 7 | -------------------------------------------------------------------------------- /esy.lock/opam/base-unix.base/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "https://github.com/ocaml/opam-repository/issues" 3 | description: """ 4 | Unix library distributed with the OCaml compiler 5 | """ 6 | 7 | -------------------------------------------------------------------------------- /esy.lock/opam/base.v0.12.2/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "opensource@janestreet.com" 3 | authors: ["Jane Street Group, LLC "] 4 | homepage: "https://github.com/janestreet/base" 5 | bug-reports: "https://github.com/janestreet/base/issues" 6 | dev-repo: "git+https://github.com/janestreet/base.git" 7 | doc: "https://ocaml.janestreet.com/ocaml-core/latest/doc/base/index.html" 8 | license: "MIT" 9 | build: [ 10 | ["dune" "build" "-p" name "-j" jobs] 11 | ] 12 | depends: [ 13 | "ocaml" {>= "4.04.2" & < "4.10.0"} 14 | "sexplib0" {>= "v0.12" & < "v0.13"} 15 | "dune" {>= "1.5.1"} 16 | "dune-configurator" 17 | ] 18 | depopts: [ 19 | "base-native-int63" 20 | ] 21 | synopsis: "Full standard library replacement for OCaml" 22 | description: " 23 | Full standard library replacement for OCaml 24 | 25 | Base is a complete and portable alternative to the OCaml standard 26 | library. It provides all standard functionalities one would expect 27 | from a language standard library. It uses consistent conventions 28 | across all of its module. 29 | 30 | Base aims to be usable in any context. As a result system dependent 31 | features such as I/O are not offered by Base. They are instead 32 | provided by companion libraries such as stdio: 33 | 34 | https://github.com/janestreet/stdio 35 | " 36 | url { 37 | src: "https://github.com/janestreet/base/archive/v0.12.2.tar.gz" 38 | checksum: "md5=7150e848a730369a2549d01645fb6c72" 39 | } 40 | -------------------------------------------------------------------------------- /esy.lock/opam/base64.3.2.0/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "mirageos-devel@lists.xenproject.org" 3 | authors: [ "Thomas Gazagnaire" 4 | "Anil Madhavapeddy" "Calascibetta Romain" 5 | "Peter Zotov" ] 6 | license: "ISC" 7 | homepage: "https://github.com/mirage/ocaml-base64" 8 | doc: "http://mirage.github.io/ocaml-base64/" 9 | bug-reports: "https://github.com/mirage/ocaml-base64/issues" 10 | dev-repo: "git+https://github.com/mirage/ocaml-base64.git" 11 | synopsis: "Base64 encoding for OCaml" 12 | description: """ 13 | Base64 is a group of similar binary-to-text encoding schemes that represent 14 | binary data in an ASCII string format by translating it into a radix-64 15 | representation. It is specified in RFC 4648. 16 | """ 17 | depends: [ 18 | "ocaml" {>="4.03.0"} 19 | "base-bytes" 20 | "dune" {>= "1.0.1"} 21 | "bos" {with-test} 22 | "rresult" {with-test} 23 | "alcotest" {with-test} 24 | ] 25 | build: [ 26 | ["dune" "subst"] 27 | ["dune" "build" "-p" name "-j" jobs] 28 | ["dune" "runtest" "-p" name] {with-test} 29 | ] 30 | url { 31 | src: 32 | "https://github.com/mirage/ocaml-base64/releases/download/v3.2.0/base64-v3.2.0.tbz" 33 | checksum: "md5=8ac1d6145277cee57d36611d1c420f05" 34 | } 35 | -------------------------------------------------------------------------------- /esy.lock/opam/bigarray-compat.1.0.0/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | synopsis: "Compatibility library to use Stdlib.Bigarray when possible" 3 | maintainer: "Lucas Pluvinage " 4 | authors: "Lucas Pluvinage " 5 | license: "ISC" 6 | homepage: "https://github.com/mirage/bigarray-compat" 7 | bug-reports: "https://github.com/mirage/bigarray-compat/issues" 8 | depends: [ 9 | "ocaml" {>= "4.03.0"} 10 | "dune" {>= "1.0"} 11 | ] 12 | build: [ 13 | ["dune" "subst"] {pinned} 14 | ["dune" "build" "-p" name "-j" jobs] 15 | ] 16 | dev-repo: "git+https://github.com/mirage/bigarray-compat.git" 17 | url { 18 | src: "https://github.com/mirage/bigarray-compat/archive/v1.0.0.tar.gz" 19 | checksum: [ 20 | "md5=1cc7c25382a8900bada34aadfd66632e" 21 | "sha512=c365fee15582aca35d7b05268cde29e54774ad7df7be56762b4aad78ca1409d4326ad3b34af0f1cc2c7b872837290a9cd9ff43b47987c03bba7bba32fe8a030f" 22 | ] 23 | } -------------------------------------------------------------------------------- /esy.lock/opam/bigstringaf.0.6.0/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "Spiros Eliopoulos " 3 | authors: [ "Spiros Eliopoulos " ] 4 | license: "BSD-3-clause" 5 | homepage: "https://github.com/inhabitedtype/bigstringaf" 6 | bug-reports: "https://github.com/inhabitedtype/bigstringaf/issues" 7 | dev-repo: "git+https://github.com/inhabitedtype/bigstringaf.git" 8 | build: [ 9 | ["dune" "subst"] {pinned} 10 | ["dune" "build" "-p" name "-j" jobs] 11 | ["dune" "runtest" "-p" name] {with-test} 12 | ] 13 | depends: [ 14 | "dune" 15 | "alcotest" {with-test} 16 | "bigarray-compat" 17 | "ocaml" {>= "4.03.0"} 18 | ] 19 | depopts: [ 20 | "mirage-xen-posix" 21 | "ocaml-freestanding" 22 | ] 23 | conflicts: [ 24 | "mirage-xen-posix" {< "3.1.0"} 25 | "ocaml-freestanding" {< "0.4.1"} 26 | ] 27 | synopsis: "Bigstring intrinsics and fast blits based on memcpy/memmove" 28 | description: """ 29 | Bigstring intrinsics and fast blits based on memcpy/memmove 30 | 31 | The OCaml compiler has a bunch of intrinsics for Bigstrings, but they're not 32 | widely-known, sometimes misused, and so programs that use Bigstrings are slower 33 | than they have to be. And even if a library got that part right and exposed the 34 | intrinsics properly, the compiler doesn't have any fast blits between 35 | Bigstrings and other string-like types. 36 | 37 | So here they are. Go crazy. 38 | """ 39 | url { 40 | src: "https://github.com/inhabitedtype/bigstringaf/archive/0.6.0.tar.gz" 41 | checksum: "md5=390382a1ac34e129f7b7f49540d94c9a" 42 | } 43 | -------------------------------------------------------------------------------- /esy.lock/opam/biniou.1.2.1/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | build: [ 3 | ["dune" "subst"] {pinned} 4 | ["dune" "build" "-p" name "-j" jobs] 5 | ["dune" "runtest" "-p" name "-j" jobs] {with-test} 6 | ["dune" "build" "-p" name "@doc"] {with-doc} 7 | ] 8 | maintainer: ["martin@mjambon.com"] 9 | authors: ["Martin Jambon"] 10 | bug-reports: "https://github.com/mjambon/biniou/issues" 11 | homepage: "https://github.com/mjambon/biniou" 12 | doc: "https://mjambon.github.io/biniou/" 13 | license: "BSD-3-Clause" 14 | dev-repo: "git+https://github.com/mjambon/biniou.git" 15 | synopsis: 16 | "Binary data format designed for speed, safety, ease of use and backward compatibility as protocols evolve" 17 | description: """ 18 | 19 | Biniou (pronounced "be new") is a binary data format designed for speed, safety, 20 | ease of use and backward compatibility as protocols evolve. Biniou is vastly 21 | equivalent to JSON in terms of functionality but allows implementations several 22 | times faster (4 times faster than yojson), with 25-35% space savings. 23 | 24 | Biniou data can be decoded into human-readable form without knowledge of type 25 | definitions except for field and variant names which are represented by 31-bit 26 | hashes. A program named bdump is provided for routine visualization of biniou 27 | data files. 28 | 29 | The program atdgen is used to derive OCaml-Biniou serializers and deserializers 30 | from type definitions. 31 | 32 | Biniou format specification: mjambon.github.io/atdgen-doc/biniou-format.txt""" 33 | depends: [ 34 | "easy-format" 35 | "dune" {>= "1.10"} 36 | "ocaml" {>= "4.02.3"} 37 | ] 38 | url { 39 | src: 40 | "https://github.com/mjambon/biniou/releases/download/1.2.1/biniou-1.2.1.tbz" 41 | checksum: [ 42 | "sha256=35546c68b1929a8e6d27a3b39ecd17b38303a0d47e65eb9d1480c2061ea84335" 43 | "sha512=82670cc77bf3e869ee26e5fbe5a5affa45a22bc8b6c4bd7e85473912780e0111baca59b34a2c14feae3543ce6e239d7fddaeab24b686a65bfe642cdb91d27ebf" 44 | ] 45 | } 46 | -------------------------------------------------------------------------------- /esy.lock/opam/conf-m4.1/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "tim@gfxmonk.net" 3 | homepage: "http://www.gnu.org/software/m4/m4.html" 4 | bug-reports: "https://github.com/ocaml/opam-repository/issues" 5 | authors: "GNU Project" 6 | license: "GPL-3.0-only" 7 | build: [["sh" "-exc" "echo | m4"]] 8 | depexts: [ 9 | ["m4"] {os-family = "debian"} 10 | ["m4"] {os-distribution = "fedora"} 11 | ["m4"] {os-distribution = "rhel"} 12 | ["m4"] {os-distribution = "centos"} 13 | ["m4"] {os-distribution = "alpine"} 14 | ["m4"] {os-distribution = "nixos"} 15 | ["m4"] {os-family = "suse"} 16 | ["m4"] {os-distribution = "ol"} 17 | ["m4"] {os-distribution = "arch"} 18 | ] 19 | synopsis: "Virtual package relying on m4" 20 | description: 21 | "This package can only install if the m4 binary is installed on the system." 22 | flags: conf 23 | -------------------------------------------------------------------------------- /esy.lock/opam/conf-pkg-config.1.1/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "unixjunkie@sdf.org" 3 | authors: ["Francois Berenger"] 4 | homepage: "http://www.freedesktop.org/wiki/Software/pkg-config/" 5 | bug-reports: "https://github.com/ocaml/opam-repository/issues" 6 | license: "GPL-1.0-or-later" 7 | build: [ 8 | ["pkg-config" "--help"] 9 | ] 10 | install: [ 11 | ["ln" "-s" "/usr/local/bin/pkgconf" "%{bin}%/pkg-config"] {os = "openbsd"} 12 | ] 13 | remove: [ 14 | ["rm" "-f" "%{bin}%/pkg-config"] {os = "openbsd"} 15 | ] 16 | post-messages: [ 17 | "conf-pkg-config: A symlink to /usr/local/bin/pkgconf has been installed in the OPAM bin directory (%{bin}%) on your PATH as 'pkg-config'. This is necessary for correct operation." {os = "openbsd"} 18 | ] 19 | depexts: [ 20 | ["pkg-config"] {os-family = "debian"} 21 | ["pkg-config"] {os-distribution = "arch"} 22 | ["pkgconfig"] {os-distribution = "fedora"} 23 | ["pkgconfig"] {os-distribution = "centos"} 24 | ["pkgconfig"] {os-distribution = "mageia"} 25 | ["pkgconfig"] {os-distribution = "rhel"} 26 | ["pkgconfig"] {os-distribution = "ol"} 27 | ["pkgconfig"] {os-distribution = "alpine"} 28 | ["devel/pkgconf"] {os = "freebsd"} 29 | ["devel/pkgconf"] {os = "openbsd"} 30 | ["pkg-config"] {os = "macos" & os-distribution = "homebrew"} 31 | ["pkgconf"] {os = "freebsd"} 32 | ["pkg-config"] {os-distribution = "cygwinports"} 33 | ] 34 | synopsis: "Virtual package relying on pkg-config installation" 35 | description: """ 36 | This package can only install if the pkg-config package is installed 37 | on the system.""" 38 | flags: conf 39 | -------------------------------------------------------------------------------- /esy.lock/opam/cow.2.4.0/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "Anil Madhavapeddy " 3 | authors: [ 4 | "Anil Madhavapeddy" 5 | "Thomas Gazagnaire" 6 | "David Sheets" 7 | "Rudi Grinberg" 8 | "Timothy Bourke" 9 | ] 10 | license: "ISC" 11 | tags: [ 12 | "org:mirage" "org:xapi-project" "www" "html" "xml" "css" "json" "markdown" 13 | ] 14 | homepage: "https://github.com/mirage/ocaml-cow" 15 | doc: "http://mirage.github.io/ocaml-cow/" 16 | bug-reports: "https://github.com/mirage/ocaml-cow/issues" 17 | depends: [ 18 | "ocaml" {>= "4.03.0"} 19 | "dune" {>= "1.1.0"} 20 | "uri" {>= "1.3.9"} 21 | "xmlm" {>= "1.1.1"} 22 | "omd" {>= "0.8.2"} 23 | "ezjsonm" {>= "0.4.0"} 24 | "alcotest" {with-test} 25 | ] 26 | build: [ 27 | ["dune" "subst"] {pinned} 28 | ["dune" "build" "-p" name "-j" jobs] 29 | ["dune" "runtest" "-p" name "-j" jobs] {with-test} 30 | ] 31 | dev-repo: "git+https://github.com/mirage/ocaml-cow.git" 32 | synopsis: "Caml on the Web" 33 | description: """ 34 | Writing web-applications requires a lot of skills: HTML, XML, JSON and 35 | Markdown, to name but a few! This library provides OCaml combinators 36 | for these web formats. 37 | """ 38 | url { 39 | src: 40 | "https://github.com/mirage/ocaml-cow/releases/download/v2.4.0/cow-v2.4.0.tbz" 41 | checksum: "md5=7d3d672aeca0dc551b9b408210dc0b9d" 42 | } 43 | -------------------------------------------------------------------------------- /esy.lock/opam/cppo.1.6.6/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "martin@mjambon.com" 3 | authors: "Martin Jambon" 4 | license: "BSD-3-Clause" 5 | homepage: "http://mjambon.com/cppo.html" 6 | doc: "https://ocaml-community.github.io/cppo/" 7 | bug-reports: "https://github.com/ocaml-community/cppo/issues" 8 | depends: [ 9 | "ocaml" {>= "4.03"} 10 | "dune" {>= "1.0"} 11 | "base-unix" 12 | ] 13 | build: [ 14 | ["dune" "subst"] {pinned} 15 | ["dune" "build" "-p" name "-j" jobs] 16 | ["dune" "runtest" "-p" name "-j" jobs] {with-test} 17 | ] 18 | dev-repo: "git+https://github.com/ocaml-community/cppo.git" 19 | synopsis: "Code preprocessor like cpp for OCaml" 20 | description: """ 21 | Cppo is an equivalent of the C preprocessor for OCaml programs. 22 | It allows the definition of simple macros and file inclusion. 23 | 24 | Cppo is: 25 | 26 | * more OCaml-friendly than cpp 27 | * easy to learn without consulting a manual 28 | * reasonably fast 29 | * simple to install and to maintain 30 | """ 31 | url { 32 | src: "https://github.com/ocaml-community/cppo/releases/download/v1.6.6/cppo-v1.6.6.tbz" 33 | checksum: [ 34 | "sha256=e7272996a7789175b87bb998efd079794a8db6625aae990d73f7b4484a07b8a0" 35 | "sha512=44ecf9d225d9e45490a2feac0bde04865ca398dba6c3579e3370fcd1ea255707b8883590852af8b2df87123801062b9f3acce2455c092deabf431f9c4fb8d8eb" 36 | ] 37 | } 38 | -------------------------------------------------------------------------------- /esy.lock/opam/cstruct.5.0.0/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "anil@recoil.org" 3 | authors: ["Anil Madhavapeddy" "Richard Mortier" "Thomas Gazagnaire" 4 | "Pierre Chambart" "David Kaloper" "Jeremy Yallop" "David Scott" 5 | "Mindy Preston" "Thomas Leonard" "Anton Kochkov" "Etienne Millon" ] 6 | homepage: "https://github.com/mirage/ocaml-cstruct" 7 | license: "ISC" 8 | dev-repo: "git+https://github.com/mirage/ocaml-cstruct.git" 9 | bug-reports: "https://github.com/mirage/ocaml-cstruct/issues" 10 | doc: "https://mirage.github.io/ocaml-cstruct/" 11 | 12 | tags: [ "org:mirage" "org:ocamllabs" ] 13 | build: [ 14 | ["dune" "subst"] {pinned} 15 | ["dune" "build" "-p" name "-j" jobs] 16 | ["dune" "runtest" "-p" name "-j" jobs] {with-test} 17 | ] 18 | depends: [ 19 | "ocaml" {>= "4.03.0"} 20 | "dune" {>= "1.0"} 21 | "bigarray-compat" 22 | "alcotest" {with-test} 23 | ] 24 | synopsis: "Access C-like structures directly from OCaml" 25 | description: """ 26 | Cstruct is a library and syntax extension to make it easier to access C-like 27 | structures directly from OCaml. It supports both reading and writing to these 28 | structures, and they are accessed via the `Bigarray` module.""" 29 | url { 30 | src: 31 | "https://github.com/mirage/ocaml-cstruct/releases/download/v5.0.0/cstruct-v5.0.0.tbz" 32 | checksum: [ 33 | "sha256=eb8a4e4438ca4ab59e9d98ca70177edd8b590136fe7a200fe8e5bf69051e80fc" 34 | "sha512=414c2c780200252b5ebf16dd4fd1db28ffa483dba5be1c0092e08327d1d870f688c6f671892dcd8bbcf579f56e3d27b345ec0a96209fb25c0a984825b2e144f5" 35 | ] 36 | } 37 | -------------------------------------------------------------------------------- /esy.lock/opam/dune-configurator.1.0.0/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | authors: ["Jérémie Dimino"] 3 | homepage: "https://github.com/ocaml/dune" 4 | bug-reports: "https://github.com/ocaml/dune/issues" 5 | maintainer: "Jérémie Dimino" 6 | description: """ 7 | dune.configurator library distributed with Dune 1.x 8 | """ 9 | depends: ["dune" {<"2.0.0"}] 10 | -------------------------------------------------------------------------------- /esy.lock/opam/dune.1.11.3/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | synopsis: "Fast, portable and opinionated build system" 3 | description: """ 4 | 5 | dune is a build system that was designed to simplify the release of 6 | Jane Street packages. It reads metadata from "dune" files following a 7 | very simple s-expression syntax. 8 | 9 | dune is fast, it has very low-overhead and support parallel builds on 10 | all platforms. It has no system dependencies, all you need to build 11 | dune and packages using dune is OCaml. You don't need or make or bash 12 | as long as the packages themselves don't use bash explicitly. 13 | 14 | dune supports multi-package development by simply dropping multiple 15 | repositories into the same directory. 16 | 17 | It also supports multi-context builds, such as building against 18 | several opam roots/switches simultaneously. This helps maintaining 19 | packages across several versions of OCaml and gives cross-compilation 20 | for free. 21 | """ 22 | maintainer: ["Jane Street Group, LLC "] 23 | authors: ["Jane Street Group, LLC "] 24 | license: "MIT" 25 | homepage: "https://github.com/ocaml/dune" 26 | doc: "https://dune.readthedocs.io/" 27 | bug-reports: "https://github.com/ocaml/dune/issues" 28 | depends: [ 29 | "ocaml" {>= "4.02"} 30 | "base-unix" 31 | "base-threads" 32 | ] 33 | conflicts: [ 34 | "jbuilder" {!= "transition"} 35 | "odoc" {< "1.3.0"} 36 | "dune-release" {< "1.3.0"} 37 | ] 38 | dev-repo: "git+https://github.com/ocaml/dune.git" 39 | build: [ 40 | # opam 2 sets OPAM_SWITCH_PREFIX, so we don't need a hardcoded path 41 | ["ocaml" "configure.ml" "--libdir" lib] {opam-version < "2"} 42 | ["ocaml" "bootstrap.ml"] 43 | ["./boot.exe" "--release" "--subst"] {pinned} 44 | ["./boot.exe" "--release" "-j" jobs] 45 | ] 46 | url { 47 | src: 48 | "https://github.com/ocaml/dune/releases/download/1.11.3/dune-build-info-1.11.3.tbz" 49 | checksum: [ 50 | "sha256=c83a63e7e8245611b0e11d6adea07c6484dc1b4efffacb176315cd6674d4bbd2" 51 | "sha512=2c1532b91d223e6ea0628c5f5174792c1bb4113a464f6d8b878b3c58be1136beb84ba2d9883a330fa20e550367588aa923ba06ffb9b615a098a21374a9377e81" 52 | ] 53 | } 54 | -------------------------------------------------------------------------------- /esy.lock/opam/easy-format.1.3.2/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | build: [ 3 | ["dune" "subst"] {pinned} 4 | ["dune" "build" "-p" name "-j" jobs] 5 | ["dune" "runtest" "-p" name "-j" jobs] {with-test} 6 | ["dune" "build" "-p" name "@doc"] {with-doc} 7 | ] 8 | maintainer: ["martin@mjambon.com" "rudi.grinberg@gmail.com"] 9 | authors: ["Martin Jambon"] 10 | bug-reports: "https://github.com/mjambon/easy-format/issues" 11 | homepage: "https://github.com/mjambon/easy-format" 12 | doc: "https://mjambon.github.io/easy-format/" 13 | license: "BSD-3-Clause" 14 | dev-repo: "git+https://github.com/mjambon/easy-format.git" 15 | synopsis: 16 | "High-level and functional interface to the Format module of the OCaml standard library" 17 | description: """ 18 | 19 | This module offers a high-level and functional interface to the Format module of 20 | the OCaml standard library. It is a pretty-printing facility, i.e. it takes as 21 | input some code represented as a tree and formats this code into the most 22 | visually satisfying result, breaking and indenting lines of code where 23 | appropriate. 24 | 25 | Input data must be first modelled and converted into a tree using 3 kinds of 26 | nodes: 27 | 28 | * atoms 29 | * lists 30 | * labelled nodes 31 | 32 | Atoms represent any text that is guaranteed to be printed as-is. Lists can model 33 | any sequence of items such as arrays of data or lists of definitions that are 34 | labelled with something like "int main", "let x =" or "x:".""" 35 | depends: [ 36 | "dune" {>= "1.10"} 37 | "ocaml" {>= "4.02.3"} 38 | ] 39 | url { 40 | src: 41 | "https://github.com/mjambon/easy-format/releases/download/1.3.2/easy-format-1.3.2.tbz" 42 | checksum: [ 43 | "sha256=3440c2b882d537ae5e9011eb06abb53f5667e651ea4bb3b460ea8230fa8c1926" 44 | "sha512=e39377a2ff020ceb9ac29e8515a89d9bdbc91dfcfa871c4e3baafa56753fac2896768e5d9822a050dc1e2ade43c8967afb69391a386c0a8ecd4e1f774e236135" 45 | ] 46 | } 47 | -------------------------------------------------------------------------------- /esy.lock/opam/ezjsonm.1.1.0/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "thomas@gazagnaire.org" 3 | authors: "Thomas Gazagnaire" 4 | license: "ISC" 5 | tags: ["org:mirage" "org:ocamllabs"] 6 | homepage: "https://github.com/mirage/ezjsonm" 7 | doc: "https://mirage.github.io/ezjsonm/" 8 | bug-reports: "https://github.com/mirage/ezjsonm/issues" 9 | depends: [ 10 | "ocaml" {>="4.03.0"} 11 | "dune" {>= "1.0"} 12 | "alcotest" {with-test & >= "0.4.0"} 13 | "jsonm" {>= "1.0.0"} 14 | "sexplib" 15 | "hex" 16 | ] 17 | build: [ 18 | ["dune" "subst"] {pinned} 19 | ["dune" "build" "-p" name "-j" jobs] 20 | ] 21 | dev-repo: "git+https://github.com/mirage/ezjsonm.git" 22 | synopsis: "Simple interface on top of the Jsonm JSON library" 23 | description: """ 24 | Ezjsonm provides more convenient (but far less flexible) 25 | input and output functions that go to and from `string` values. 26 | This avoids the need to write signal code, which is useful for 27 | quick scripts that manipulate JSON. 28 | 29 | More advanced users should go straight to the Jsonm library and 30 | use it directly, rather than be saddled with the Ezjsonm interface. 31 | """ 32 | url { 33 | src: 34 | "https://github.com/mirage/ezjsonm/releases/download/v1.1.0/ezjsonm-v1.1.0.tbz" 35 | checksum: "md5=e8f207c6cd2226b2c4784b1e56556797" 36 | } 37 | -------------------------------------------------------------------------------- /esy.lock/opam/faraday-lwt-unix.0.7.0/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "Spiros Eliopoulos " 3 | authors: [ "Spiros Eliopoulos " ] 4 | license: "BSD-3-Clause" 5 | homepage: "https://github.com/inhabitedtype/faraday" 6 | bug-reports: "https://github.com/inhabitedtype/faraday/issues" 7 | dev-repo: "git+https://github.com/inhabitedtype/faraday.git" 8 | build: [ 9 | ["jbuilder" "subst" "-p" name] {pinned} 10 | ["jbuilder" "build" "-p" name "-j" jobs] 11 | ["jbuilder" "runtest" "-p" name] {with-test} 12 | ] 13 | depends: [ 14 | "ocaml" {>= "4.02.0"} 15 | "jbuilder" {build & >= "1.0+beta10"} 16 | "faraday-lwt" 17 | "lwt" {>= "2.7.0"} 18 | "base-unix" 19 | ] 20 | synopsis: "Lwt_unix support for Faraday" 21 | url { 22 | src: "https://github.com/inhabitedtype/faraday/archive/0.7.0.tar.gz" 23 | checksum: "md5=d37a5f1663570f9c75f0b4b4cdb7ec9c" 24 | } 25 | -------------------------------------------------------------------------------- /esy.lock/opam/faraday-lwt.0.7.0/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "Spiros Eliopoulos " 3 | authors: [ "Spiros Eliopoulos " ] 4 | license: "BSD-3-Clause" 5 | homepage: "https://github.com/inhabitedtype/faraday" 6 | bug-reports: "https://github.com/inhabitedtype/faraday/issues" 7 | dev-repo: "git+https://github.com/inhabitedtype/faraday.git" 8 | build: [ 9 | ["jbuilder" "subst" "-p" name] {pinned} 10 | ["jbuilder" "build" "-p" name "-j" jobs] 11 | ["jbuilder" "runtest" "-p" name] {with-test} 12 | ] 13 | depends: [ 14 | "ocaml" {>= "4.02.0"} 15 | "jbuilder" {build & >= "1.0+beta10"} 16 | "faraday" {>= "0.5.0"} 17 | "lwt" 18 | ] 19 | synopsis: "Lwt support for Faraday" 20 | url { 21 | src: "https://github.com/inhabitedtype/faraday/archive/0.7.0.tar.gz" 22 | checksum: "md5=d37a5f1663570f9c75f0b4b4cdb7ec9c" 23 | } 24 | -------------------------------------------------------------------------------- /esy.lock/opam/faraday.0.7.0/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "Spiros Eliopoulos " 3 | authors: [ "Spiros Eliopoulos " ] 4 | license: "BSD-3-Clause" 5 | homepage: "https://github.com/inhabitedtype/faraday" 6 | bug-reports: "https://github.com/inhabitedtype/faraday/issues" 7 | dev-repo: "git+https://github.com/inhabitedtype/faraday.git" 8 | build: [ 9 | ["jbuilder" "subst" "-p" name] {pinned} 10 | ["jbuilder" "build" "-p" name "-j" jobs] 11 | ["jbuilder" "runtest" "-p" name] {with-test} 12 | ] 13 | depends: [ 14 | "ocaml" {>= "4.02.0"} 15 | "jbuilder" {build & >= "1.0+beta10"} 16 | "alcotest" {with-test & >= "0.4.1"} 17 | "bigstringaf" 18 | ] 19 | synopsis: "A library for writing fast and memory-efficient serializers." 20 | description: """ 21 | Faraday is a library for writing fast and memory-efficient serializers. Its 22 | core type and related operation gives the user fine-grained control over 23 | copying and allocation behavior while serializing user-defined types, and 24 | presents the output in a form that makes it possible to use vectorized write 25 | operations, such as the writev system call, or any other platform or 26 | application-specific output APIs.""" 27 | url { 28 | src: "https://github.com/inhabitedtype/faraday/archive/0.7.0.tar.gz" 29 | checksum: "md5=d37a5f1663570f9c75f0b4b4cdb7ec9c" 30 | } 31 | -------------------------------------------------------------------------------- /esy.lock/opam/fmt.0.8.8/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "Daniel Bünzli " 3 | authors: [ "The fmt programmers" ] 4 | homepage: "https://erratique.ch/software/fmt" 5 | doc: "https://erratique.ch/software/fmt" 6 | dev-repo: "git+https://erratique.ch/repos/fmt.git" 7 | bug-reports: "https://github.com/dbuenzli/fmt/issues" 8 | tags: [ "string" "format" "pretty-print" "org:erratique" ] 9 | license: "ISC" 10 | depends: [ 11 | "ocaml" {>= "4.05.0"} 12 | "ocamlfind" {build} 13 | "ocamlbuild" {build} 14 | "topkg" {build & >= "0.9.0"} 15 | # Can be removed once ocaml >= 4.07 16 | "seq" 17 | "stdlib-shims" 18 | ] 19 | depopts: [ "base-unix" "cmdliner" ] 20 | conflicts: [ "cmdliner" {< "0.9.8"} ] 21 | build: [[ 22 | "ocaml" "pkg/pkg.ml" "build" 23 | "--dev-pkg" "%{pinned}%" 24 | "--with-base-unix" "%{base-unix:installed}%" 25 | "--with-cmdliner" "%{cmdliner:installed}%" ]] 26 | 27 | synopsis: """OCaml Format pretty-printer combinators""" 28 | description: """\ 29 | 30 | Fmt exposes combinators to devise `Format` pretty-printing functions. 31 | 32 | Fmt depends only on the OCaml standard library. The optional `Fmt_tty` 33 | library that allows to setup formatters for terminal color output 34 | depends on the Unix library. The optional `Fmt_cli` library that 35 | provides command line support for Fmt depends on [`Cmdliner`][cmdliner]. 36 | 37 | Fmt is distributed under the ISC license. 38 | 39 | [cmdliner]: http://erratique.ch/software/cmdliner 40 | """ 41 | url { 42 | archive: "https://erratique.ch/software/fmt/releases/fmt-0.8.8.tbz" 43 | checksum: "473490fcfdf3ff0a8ccee226b873d4b2" 44 | } 45 | -------------------------------------------------------------------------------- /esy.lock/opam/hex.1.4.0/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "thomas@gazagnaire.org" 3 | authors: ["Thomas Gazagnaire" "Trevor Summers Smith"] 4 | license: "ISC" 5 | homepage: "https://github.com/mirage/ocaml-hex" 6 | doc: "https://mirage.github.io/ocaml-hex/" 7 | bug-reports: "https://github.com/mirage/ocaml-hex/issues" 8 | depends: [ 9 | "ocaml" {>= "4.03.0"} 10 | "dune" {>= "1.0"} 11 | "cstruct" {>= "1.7.0"} 12 | "bigarray-compat" {>= "1.0.0"} 13 | ] 14 | build: [ 15 | ["dune" "subst"] {pinned} 16 | ["dune" "build" "-p" name "-j" jobs] 17 | ["dune" "runtest" "-p" name "-j" jobs] {with-test} 18 | ] 19 | dev-repo: "git+https://github.com/mirage/ocaml-hex.git" 20 | synopsis: "Library providing hexadecimal converters" 21 | description: """ 22 | ```ocaml 23 | #require "hex";; 24 | # Hex.of_string "Hello world!";; 25 | - : Hex.t = "48656c6c6f20776f726c6421" 26 | # Hex.to_string "dead-beef";; 27 | - : string = "ޭ��" 28 | # Hex.hexdump (Hex.of_string "Hello world!\n") 29 | 00000000: 4865 6c6c 6f20 776f 726c 6421 0a Hello world!. 30 | - : unit = () 31 | ``` 32 | """ 33 | url { 34 | src: 35 | "https://github.com/mirage/ocaml-hex/releases/download/v1.4.0/hex-v1.4.0.tbz" 36 | checksum: "md5=57103ff33e70f14171c46d88f5452d11" 37 | } 38 | -------------------------------------------------------------------------------- /esy.lock/opam/hpack.0.2.0/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "Antonio Nuno Monteiro " 3 | authors: [ "Pieter Goetschalckx <3.14.e.ter@gmail.com>" 4 | "Antonio Nuno Monteiro " ] 5 | license: "BSD-3-Clause" 6 | homepage: "https://github.com/anmonteiro/ocaml-h2" 7 | bug-reports: "https://github.com/anmonteiro/ocaml-h2/issues" 8 | dev-repo: "git+https://github.com/anmonteiro/ocaml-h2.git" 9 | doc: "https://anmonteiro.github.io/ocaml-h2/" 10 | depends: [ 11 | "ocaml" {>= "4.04"} 12 | "dune" 13 | "yojson" {with-test} 14 | "hex" {with-test} 15 | "angstrom" 16 | "faraday" 17 | ] 18 | build: [ 19 | ["dune" "build" "-p" name "-j" jobs] 20 | ] 21 | synopsis: 22 | "An HPACK (Header Compression for HTTP/2) implementation in OCaml" 23 | description: """ 24 | hpack is an implementation of the HPACK: Header Compression for HTTP/2 25 | specification (RFC7541) written in OCaml. It uses Angstrom and Faraday for 26 | parsing and serialization, respectively. 27 | """ 28 | url { 29 | src: 30 | "https://github.com/anmonteiro/ocaml-h2/releases/download/0.2.0/h2-0.2.0.tbz" 31 | checksum: "md5=c883927ce8a9f3f7159ef7b20988f051" 32 | } 33 | -------------------------------------------------------------------------------- /esy.lock/opam/jbuilder.transition/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "opensource@janestreet.com" 3 | authors: ["Jane Street Group, LLC "] 4 | homepage: "https://github.com/ocaml/dune" 5 | bug-reports: "https://github.com/ocaml/dune/issues" 6 | dev-repo: "git+https://github.com/ocaml/dune.git" 7 | license: "MIT" 8 | depends: ["ocaml" "dune"] 9 | post-messages: [ 10 | "Jbuilder has been renamed and the jbuilder package is now a transition \ 11 | package. Use the dune package instead." 12 | ] 13 | synopsis: 14 | "This is a transition package, jbuilder is now named dune. Use the dune" 15 | description: "package instead." 16 | -------------------------------------------------------------------------------- /esy.lock/opam/jsonm.1.0.1/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "Daniel Bünzli " 3 | authors: ["Daniel Bünzli "] 4 | homepage: "http://erratique.ch/software/jsonm" 5 | doc: "http://erratique.ch/software/jsonm/doc/Jsonm" 6 | dev-repo: "git+http://erratique.ch/repos/jsonm.git" 7 | bug-reports: "https://github.com/dbuenzli/jsonm/issues" 8 | tags: [ "json" "codec" "org:erratique" ] 9 | license: "ISC" 10 | depends: [ 11 | "ocaml" {>= "4.01.0"} 12 | "ocamlfind" {build} 13 | "ocamlbuild" {build} 14 | "topkg" {build} 15 | "uchar" 16 | "uutf" {>= "1.0.0"} 17 | ] 18 | build:[[ 19 | "ocaml" "pkg/pkg.ml" "build" 20 | "--pinned" "%{pinned}%" ]] 21 | synopsis: "Non-blocking streaming JSON codec for OCaml" 22 | description: """ 23 | Jsonm is a non-blocking streaming codec to decode and encode the JSON 24 | data format. It can process JSON text without blocking on IO and 25 | without a complete in-memory representation of the data. 26 | 27 | The alternative "uncut" codec also processes whitespace and 28 | (non-standard) JSON with JavaScript comments. 29 | 30 | Jsonm is made of a single module and depends on [Uutf][uutf]. It is distributed 31 | under the ISC license. 32 | 33 | [uutf]: http://erratique.ch/software/uutf""" 34 | url { 35 | src: "http://erratique.ch/software/jsonm/releases/jsonm-1.0.1.tbz" 36 | checksum: "md5=e2ca39eaefd55b8d155c4f1ec5885311" 37 | } 38 | -------------------------------------------------------------------------------- /esy.lock/opam/logs.0.7.0/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "Daniel Bünzli " 3 | authors: ["The logs programmers"] 4 | homepage: "https://erratique.ch/software/logs" 5 | doc: "https://erratique.ch/software/logs/doc" 6 | dev-repo: "git+https://erratique.ch/repos/logs.git" 7 | bug-reports: "https://github.com/dbuenzli/logs/issues" 8 | tags: [ "log" "system" "org:erratique" ] 9 | license: "ISC" 10 | depends: [ 11 | "ocaml" {>= "4.03.0"} 12 | "ocamlfind" {build} 13 | "ocamlbuild" {build} 14 | "topkg" {build} 15 | "mtime" {with-test} ] 16 | depopts: [ 17 | "js_of_ocaml" 18 | "fmt" 19 | "cmdliner" 20 | "lwt" 21 | "base-threads" 22 | ] 23 | conflicts: [ 24 | "js_of_ocaml" { < "3.3.0" } ] 25 | 26 | build: [[ 27 | "ocaml" "pkg/pkg.ml" "build" 28 | "--pinned" "%{pinned}%" 29 | "--with-js_of_ocaml" "%{js_of_ocaml:installed}%" 30 | "--with-fmt" "%{fmt:installed}%" 31 | "--with-cmdliner" "%{cmdliner:installed}%" 32 | "--with-lwt" "%{lwt:installed}%" 33 | "--with-base-threads" "%{base-threads:installed}%" 34 | ]] 35 | 36 | synopsis: """Logging infrastructure for OCaml""" 37 | description: """\ 38 | 39 | Logs provides a logging infrastructure for OCaml. Logging is performed 40 | on sources whose reporting level can be set independently. Log message 41 | report is decoupled from logging and is handled by a reporter. 42 | 43 | A few optional log reporters are distributed with the base library and 44 | the API easily allows to implement your own. 45 | 46 | `Logs` has no dependencies. The optional `Logs_fmt` reporter on OCaml 47 | formatters depends on [Fmt][fmt]. The optional `Logs_browser` 48 | reporter that reports to the web browser console depends on 49 | [js_of_ocaml][jsoo]. The optional `Logs_cli` library that provides 50 | command line support for controlling Logs depends on 51 | [`Cmdliner`][cmdliner]. The optional `Logs_lwt` library that provides 52 | Lwt logging functions depends on [`Lwt`][lwt] 53 | 54 | Logs and its reporters are distributed under the ISC license. 55 | 56 | [fmt]: http://erratique.ch/software/fmt 57 | [jsoo]: http://ocsigen.org/js_of_ocaml/ 58 | [cmdliner]: http://erratique.ch/software/cmdliner 59 | [lwt]: http://ocsigen.org/lwt/ 60 | """ 61 | url { 62 | archive: "https://erratique.ch/software/logs/releases/logs-0.7.0.tbz" 63 | checksum: "2bf021ca13331775e33cf34ab60246f7" 64 | } 65 | -------------------------------------------------------------------------------- /esy.lock/opam/lwt.4.3.1/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | 3 | synopsis: "Promises and event-driven I/O" 4 | 5 | version: "4.3.1" 6 | license: "MIT" 7 | homepage: "https://github.com/ocsigen/lwt" 8 | doc: "https://ocsigen.org/lwt/manual/" 9 | bug-reports: "https://github.com/ocsigen/lwt/issues" 10 | 11 | authors: [ 12 | "Jérôme Vouillon" 13 | "Jérémie Dimino" 14 | ] 15 | maintainer: [ 16 | "Anton Bachin " 17 | ] 18 | dev-repo: "git+https://github.com/ocsigen/lwt.git" 19 | 20 | depends: [ 21 | "cppo" {build & >= "1.1.0"} 22 | "dune" {>= "1.7.0"} 23 | "dune-configurator" 24 | "mmap" {>= "1.1.0"} # mmap is needed as long as Lwt supports OCaml < 4.06.0. 25 | "ocaml" {>= "4.02.0"} 26 | "ocplib-endian" 27 | "result" # result is needed as long as Lwt supports OCaml 4.02. 28 | "seq" # seq is needed as long as Lwt supports OCaml < 4.07.0. 29 | 30 | "bisect_ppx" {dev & >= "1.3.0"} 31 | "ocamlfind" {dev & >= "1.7.3-1"} 32 | ] 33 | 34 | depopts: [ 35 | "base-threads" 36 | "base-unix" 37 | "conf-libev" 38 | ] 39 | 40 | conflicts: [ 41 | "ocaml-variants" {= "4.02.1+BER"} 42 | ] 43 | 44 | post-messages: [ 45 | "Lwt 5.0.0 will make some breaking changes in November 2019. See 46 | https://github.com/ocsigen/lwt/issues/584" 47 | ] 48 | 49 | build: [ 50 | ["dune" "build" "-p" name "-j" jobs] 51 | ] 52 | 53 | description: "A promise is a value that may become determined in the future. 54 | 55 | Lwt provides typed, composable promises. Promises that are resolved by I/O are 56 | resolved by Lwt in parallel. 57 | 58 | Meanwhile, OCaml code, including code creating and waiting on promises, runs in 59 | a single thread by default. This reduces the need for locks or other 60 | synchronization primitives. Code can be run in parallel on an opt-in basis." 61 | 62 | url { 63 | src: "https://github.com/ocsigen/lwt/archive/4.3.1.tar.gz" 64 | checksum: "md5=926936860087c5819d6ca04241bc894a" 65 | } 66 | -------------------------------------------------------------------------------- /esy.lock/opam/lwt_ssl.1.1.3/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | 3 | synopsis: "OpenSSL binding with concurrent I/O" 4 | 5 | version: "1.1.3" 6 | license: "LGPL with OpenSSL linking exception" 7 | homepage: "https://github.com/ocsigen/lwt_ssl" 8 | doc: "https://github.com/ocsigen/lwt_ssl/blob/master/src/lwt_ssl.mli" 9 | bug-reports: "https://github.com/ocsigen/lwt_ssl/issues" 10 | 11 | authors: [ 12 | "Jérôme Vouillon" 13 | "Jérémie Dimino" 14 | ] 15 | maintainer: "Anton Bachin " 16 | dev-repo: "git+https://github.com/ocsigen/lwt_ssl.git" 17 | 18 | depends: [ 19 | "base-unix" 20 | "dune" 21 | "lwt" {>= "3.0.0"} 22 | "ocaml" 23 | "ssl" {>= "0.5.0"} 24 | ] 25 | 26 | build: [ 27 | ["dune" "build" "-p" name "-j" jobs] 28 | ] 29 | 30 | url { 31 | src: "https://github.com/ocsigen/lwt_ssl/archive/1.1.3.tar.gz" 32 | checksum: "md5=b18414b2ef71ededa07666dfc467f10a" 33 | } 34 | -------------------------------------------------------------------------------- /esy.lock/opam/menhir.20190924/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "francois.pottier@inria.fr" 3 | authors: [ 4 | "François Pottier " 5 | "Yann Régis-Gianas " 6 | ] 7 | homepage: "http://gitlab.inria.fr/fpottier/menhir" 8 | dev-repo: "git+https://gitlab.inria.fr/fpottier/menhir.git" 9 | bug-reports: "menhir@inria.fr" 10 | build: [ 11 | [make "-f" "Makefile" "PREFIX=%{prefix}%" "USE_OCAMLFIND=true" "docdir=%{doc}%/menhir" "libdir=%{lib}%/menhir" "mandir=%{man}%/man1"] 12 | ] 13 | install: [ 14 | [make "-f" "Makefile" "install" "PREFIX=%{prefix}%" "docdir=%{doc}%/menhir" "libdir=%{lib}%/menhir" "mandir=%{man}%/man1"] 15 | ] 16 | depends: [ 17 | "ocaml" {>= "4.02"} 18 | "ocamlfind" {build} 19 | "ocamlbuild" {build} 20 | ] 21 | synopsis: "An LR(1) parser generator" 22 | url { 23 | src: 24 | "https://gitlab.inria.fr/fpottier/menhir/repository/20190924/archive.tar.gz" 25 | checksum: [ 26 | "md5=677f1997fb73177d5a00fa1b8d61c3ef" 27 | "sha512=ea8a9a6d773529cf6ac05e4c6c4532770fbb8e574c9b646efcefe90d9f24544741e3e8cfd94c8afea0447e34059a8c79c2829b46764ce3a3d6dcb3e7f75980fc" 28 | ] 29 | } 30 | -------------------------------------------------------------------------------- /esy.lock/opam/merlin-extend.0.5/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "Frederic Bour " 3 | authors: "Frederic Bour " 4 | homepage: "https://github.com/let-def/merlin-extend" 5 | bug-reports: "https://github.com/let-def/merlin-extend" 6 | license: "MIT" 7 | dev-repo: "git+https://github.com/let-def/merlin-extend.git" 8 | build: [ 9 | ["dune" "subst"] {pinned} 10 | ["dune" "build" "-p" name "-j" jobs] 11 | ] 12 | depends: [ 13 | "dune" {>= "1.0"} 14 | "cppo" {build} 15 | "ocaml" {>= "4.02.3"} 16 | ] 17 | synopsis: "A protocol to provide custom frontend to Merlin" 18 | description: """ 19 | This protocol allows to replace the OCaml frontend of Merlin. 20 | It extends what used to be done with the `-pp' flag to handle a few more cases.""" 21 | doc: "https://let-def.github.io/merlin-extend" 22 | url { 23 | src: 24 | "https://github.com/let-def/merlin-extend/releases/download/v0.5/merlin-extend-v0.5.tbz" 25 | checksum: [ 26 | "sha256=ca3a38c360c7d4827eb4789abf7a6aa4b6e3b4e3c3ef69a5be64dce4601ec227" 27 | "sha512=55c5a3637337abb8ca8db679128a81ca8ccce567bc214d55b2e6444dc0e905b74c64d629bdea2457d0fe4be5306414feefcdbc4d4761fdafd59aa107550936b6" 28 | ] 29 | } 30 | -------------------------------------------------------------------------------- /esy.lock/opam/mmap.1.1.0/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "jeremie@dimino.org" 3 | authors: ["Jérémie Dimino " "Anton Bachin" ] 4 | homepage: "https://github.com/mirage/mmap" 5 | bug-reports: "https://github.com/mirage/mmap/issues" 6 | doc: "https://mirage.github.io/mmap/" 7 | dev-repo: "git+https://github.com/mirage/mmap.git" 8 | license: "LGPL-2.1-only with OCaml-LGPL-linking-exception" 9 | build: [ 10 | ["dune" "build" "-p" name "-j" jobs] 11 | ] 12 | depends: [ 13 | "ocaml" 14 | "dune" {>= "1.6"} 15 | ] 16 | synopsis: "File mapping functionality" 17 | description: """ 18 | This project provides a Mmap.map_file functions for mapping files in memory. 19 | """ 20 | url { 21 | src: 22 | "https://github.com/mirage/mmap/releases/download/v1.1.0/mmap-v1.1.0.tbz" 23 | checksum: "md5=8c5d5fbc537296dc525867535fb878ba" 24 | } 25 | -------------------------------------------------------------------------------- /esy.lock/opam/num.1.2/files/installation-warning.patch: -------------------------------------------------------------------------------- 1 | From db8d748b2cad0adc2698e9fcf28727083a711bae Mon Sep 17 00:00:00 2001 2 | From: David Allsopp 3 | Date: Wed, 24 Jan 2018 16:01:56 +0000 4 | Subject: [PATCH] Warn about installations broken by previous faulty package 5 | 6 | --- 7 | Makefile | 33 +++++++++++++++++++++++++++++++++ 8 | 1 file changed, 33 insertions(+) 9 | 10 | diff --git a/Makefile b/Makefile 11 | index b40e588..d4dcd70 100644 12 | --- a/Makefile 13 | +++ b/Makefile 14 | @@ -14,9 +14,42 @@ install: 15 | $(MAKE) -C src install 16 | $(MAKE) -C toplevel install 17 | 18 | +OCAMLFIND_DIR:=$(dir $(shell command -v ocamlfind 2>/dev/null)) 19 | +OCAMLC_DIR:=$(dir $(shell command -v ocamlc 2>/dev/null)) 20 | +NUM_INSTALLED:=$(shell ocamlfind query num 2>/dev/null) 21 | + 22 | +ifeq ($(NUM_INSTALLED),) 23 | +# The num findlib package is not already present - wohoo! 24 | +OUR_FAULT=no 25 | +else 26 | +ifeq ($(OCAMLFIND_DIR),$(OCAMLC_DIR)) 27 | +# The num findlib package is present, but ocamlc and ocamlfind are in the 28 | +# same place, which means that either we're looking at a system-installed 29 | +# ocamlfind (which isn't supported), or the user has done something else 30 | +# nefarious and doesn't deserve our sympathy (or, at least, our potentially 31 | +# unhelpful advice) 32 | +OUR_FAULT=no 33 | +else 34 | +# The num findlib package package is present, and ocamlc and ocamlfind reside 35 | +# in different directories, which means that we're almost certainly looking at 36 | +# a system switch which has been damaged by a previous num package installation 37 | +# on an OS which didn't protect the system lib directory. 38 | +OUR_FAULT=probably 39 | +endif 40 | +endif 41 | + 42 | findlib-install: 43 | +ifeq ($(OUR_FAULT),no) 44 | $(MAKE) -C src findlib-install 45 | $(MAKE) -C toplevel install 46 | +else 47 | + @echo "\033[0;31m[ERROR]\033[m It appears that the num library was previously installed to your system" 48 | + @echo " compiler's lib directory, probably by a faulty opam package." 49 | + @echo " You will need to remove arith_flags.*, arith_status.*, big_int.*," 50 | + @echo " int_misc.*, nat.*, num.*, ratio.*, nums.*, libnums.* and" 51 | + @echo " stublibs/dllnums.* from $(shell ocamlc -where)." 52 | + @false 53 | +endif 54 | 55 | uninstall: 56 | $(MAKE) -C src uninstall 57 | -- 58 | 2.14.1 59 | 60 | -------------------------------------------------------------------------------- /esy.lock/opam/num.1.2/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | version: "1.2" 3 | maintainer: "Xavier Leroy " 4 | authors: [ 5 | "Valérie Ménissier-Morain" 6 | "Pierre Weis" 7 | "Xavier Leroy" 8 | ] 9 | license: "LGPL-2.1-only with OCaml-LGPL-linking-exception" 10 | 11 | homepage: "https://github.com/ocaml/num/" 12 | bug-reports: "https://github.com/ocaml/num/issues" 13 | dev-repo: "git+https://github.com/ocaml/num.git" 14 | build: [ 15 | [make] 16 | ] 17 | install: [ 18 | make 19 | "install" {!ocaml:preinstalled} 20 | "findlib-install" {ocaml:preinstalled} 21 | ] 22 | depends: [ 23 | "ocaml" {>= "4.06.0"} 24 | "ocamlfind" {build & >= "1.7.3"} 25 | ] 26 | conflicts: [ "base-num" ] 27 | patches: [ "installation-warning.patch" ] 28 | synopsis: 29 | "The legacy Num library for arbitrary-precision integer and rational arithmetic" 30 | extra-files: [ 31 | ["installation-warning.patch" "md5=93c92bf6da6bae09d068da42b1bbaaac"] 32 | ] 33 | url { 34 | src: "https://github.com/ocaml/num/archive/v1.2.tar.gz" 35 | checksum: "md5=4f43ce8e44db68692bee50f2f8ef911c" 36 | } 37 | -------------------------------------------------------------------------------- /esy.lock/opam/ocaml-compiler-libs.v0.12.1/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "opensource@janestreet.com" 3 | authors: ["Jane Street Group, LLC "] 4 | homepage: "https://github.com/janestreet/ocaml-compiler-libs" 5 | bug-reports: "https://github.com/janestreet/ocaml-compiler-libs/issues" 6 | dev-repo: "git+https://github.com/janestreet/ocaml-compiler-libs.git" 7 | license: "Apache-2.0" 8 | build: [ 9 | ["dune" "build" "-p" name "-j" jobs] 10 | ] 11 | depends: [ 12 | "ocaml" {>= "4.04.1"} 13 | "dune" {>= "1.5.1"} 14 | ] 15 | synopsis: "OCaml compiler libraries repackaged" 16 | description: """ 17 | This packages exposes the OCaml compiler libraries repackages under 18 | the toplevel names Ocaml_common, Ocaml_bytecomp, Ocaml_optcomp, ...""" 19 | url { 20 | src: 21 | "https://github.com/janestreet/ocaml-compiler-libs/archive/v0.12.1.tar.gz" 22 | checksum: "md5=2f929af7c764a3f681a5671f271210c4" 23 | } 24 | -------------------------------------------------------------------------------- /esy.lock/opam/ocaml-migrate-parsetree.1.4.0/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "frederic.bour@lakaban.net" 3 | authors: [ 4 | "Frédéric Bour " 5 | "Jérémie Dimino " 6 | ] 7 | license: "LGPL-2.1-only with OCaml-LGPL-linking-exception" 8 | homepage: "https://github.com/ocaml-ppx/ocaml-migrate-parsetree" 9 | bug-reports: "https://github.com/ocaml-ppx/ocaml-migrate-parsetree/issues" 10 | dev-repo: "git+https://github.com/ocaml-ppx/ocaml-migrate-parsetree.git" 11 | doc: "https://ocaml-ppx.github.io/ocaml-migrate-parsetree/" 12 | tags: [ "syntax" "org:ocamllabs" ] 13 | build: [ 14 | ["dune" "build" "-p" name "-j" jobs] 15 | ] 16 | depends: [ 17 | "result" 18 | "ppx_derivers" 19 | "dune" {>= "1.9.0"} 20 | "ocaml" {>= "4.02.3"} 21 | ] 22 | synopsis: "Convert OCaml parsetrees between different versions" 23 | description: """ 24 | Convert OCaml parsetrees between different versions 25 | 26 | This library converts parsetrees, outcometree and ast mappers between 27 | different OCaml versions. High-level functions help making PPX 28 | rewriters independent of a compiler version. 29 | """ 30 | url { 31 | src: 32 | "https://github.com/ocaml-ppx/ocaml-migrate-parsetree/releases/download/v1.4.0/ocaml-migrate-parsetree-v1.4.0.tbz" 33 | checksum: [ 34 | "sha256=231fbdc205187b3ee266b535d9cfe44b599067b2f6e97883c782ea7bb577d3b8" 35 | "sha512=61ee91d2d146cc2d2ff2d5dc4ef5dea4dc4d3c8dbd8b4c9586d64b6ad7302327ab35547aa0a5b0103c3f07b66b13d416a1bee6d4d117293cd3cabe44113ec6d4" 36 | ] 37 | } 38 | -------------------------------------------------------------------------------- /esy.lock/opam/ocamlbuild.0.14.0/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "Gabriel Scherer " 3 | authors: ["Nicolas Pouillard" "Berke Durak"] 4 | homepage: "https://github.com/ocaml/ocamlbuild/" 5 | bug-reports: "https://github.com/ocaml/ocamlbuild/issues" 6 | license: "LGPL-2.1-only with OCaml-LGPL-linking-exception" 7 | doc: "https://github.com/ocaml/ocamlbuild/blob/master/manual/manual.adoc" 8 | dev-repo: "git+https://github.com/ocaml/ocamlbuild.git" 9 | build: [ 10 | [ 11 | make 12 | "-f" 13 | "configure.make" 14 | "all" 15 | "OCAMLBUILD_PREFIX=%{prefix}%" 16 | "OCAMLBUILD_BINDIR=%{bin}%" 17 | "OCAMLBUILD_LIBDIR=%{lib}%" 18 | "OCAMLBUILD_MANDIR=%{man}%" 19 | "OCAML_NATIVE=%{ocaml:native}%" 20 | "OCAML_NATIVE_TOOLS=%{ocaml:native}%" 21 | ] 22 | [make "check-if-preinstalled" "all" "opam-install"] 23 | ] 24 | conflicts: [ 25 | "base-ocamlbuild" 26 | "ocamlfind" {< "1.6.2"} 27 | ] 28 | synopsis: 29 | "OCamlbuild is a build system with builtin rules to easily build most OCaml projects." 30 | depends: [ 31 | "ocaml" {>= "4.03"} 32 | ] 33 | url { 34 | src: "https://github.com/ocaml/ocamlbuild/archive/0.14.0.tar.gz" 35 | checksum: "sha256=87b29ce96958096c0a1a8eeafeb6268077b2d11e1bf2b3de0f5ebc9cf8d42e78" 36 | } 37 | -------------------------------------------------------------------------------- /esy.lock/opam/ocamlfind.1.8.1/files/ocaml-stub: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | BINDIR=$(dirname "$(command -v ocamlc)") 4 | "$BINDIR/ocaml" -I "$OCAML_TOPLEVEL_PATH" "$@" 5 | -------------------------------------------------------------------------------- /esy.lock/opam/ocamlfind.1.8.1/files/ocamlfind.install: -------------------------------------------------------------------------------- 1 | bin: [ 2 | "src/findlib/ocamlfind" {"ocamlfind"} 3 | "?src/findlib/ocamlfind_opt" {"ocamlfind"} 4 | "?tools/safe_camlp4" 5 | ] 6 | toplevel: ["src/findlib/topfind"] 7 | -------------------------------------------------------------------------------- /esy.lock/opam/ocamlfind.1.8.1/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | synopsis: "A library manager for OCaml" 3 | maintainer: "Thomas Gazagnaire " 4 | authors: "Gerd Stolpmann " 5 | homepage: "http://projects.camlcity.org/projects/findlib.html" 6 | bug-reports: "https://gitlab.camlcity.org/gerd/lib-findlib/issues" 7 | dev-repo: "git+https://gitlab.camlcity.org/gerd/lib-findlib.git" 8 | description: """ 9 | Findlib is a library manager for OCaml. It provides a convention how 10 | to store libraries, and a file format ("META") to describe the 11 | properties of libraries. There is also a tool (ocamlfind) for 12 | interpreting the META files, so that it is very easy to use libraries 13 | in programs and scripts. 14 | """ 15 | build: [ 16 | [ 17 | "./configure" 18 | "-bindir" 19 | bin 20 | "-sitelib" 21 | lib 22 | "-mandir" 23 | man 24 | "-config" 25 | "%{lib}%/findlib.conf" 26 | "-no-custom" 27 | "-no-camlp4" {!ocaml:preinstalled & ocaml:version >= "4.02.0"} 28 | "-no-topfind" {ocaml:preinstalled} 29 | ] 30 | [make "all"] 31 | [make "opt"] {ocaml:native} 32 | ] 33 | install: [ 34 | [make "install"] 35 | ["install" "-m" "0755" "ocaml-stub" "%{bin}%/ocaml"] {ocaml:preinstalled} 36 | ] 37 | depends: [ 38 | "ocaml" {>= "4.00.0"} 39 | "conf-m4" {build} 40 | ] 41 | extra-files: [ 42 | ["ocamlfind.install" "md5=06f2c282ab52d93aa6adeeadd82a2543"] 43 | ["ocaml-stub" "md5=181f259c9e0bad9ef523e7d4abfdf87a"] 44 | ] 45 | url { 46 | src: "http://download.camlcity.org/download/findlib-1.8.1.tar.gz" 47 | checksum: "md5=18ca650982c15536616dea0e422cbd8c" 48 | mirrors: "http://download2.camlcity.org/download/findlib-1.8.1.tar.gz" 49 | } 50 | depopts: ["graphics"] 51 | -------------------------------------------------------------------------------- /esy.lock/opam/ocplib-endian.1.0/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | authors: "Pierre Chambart" 3 | maintainer: "pierre.chambart@ocamlpro.com" 4 | homepage: "https://github.com/OCamlPro/ocplib-endian" 5 | build: [ 6 | ["ocaml" "setup.ml" "-configure" "--disable-debug" "--prefix" prefix] 7 | ["ocaml" "setup.ml" "-build"] 8 | ] 9 | install: [ 10 | ["ocaml" "setup.ml" "-install"] 11 | ] 12 | remove: ["ocamlfind" "remove" "ocplib-endian"] 13 | depends: [ 14 | "ocaml" 15 | "base-bytes" 16 | "ocamlfind" 17 | "cppo" {>= "1.1.0"} 18 | "ocamlbuild" {build} 19 | ] 20 | dev-repo: "git+https://github.com/OCamlPro/ocplib-endian.git" 21 | bug-reports: "https://github.com/OCamlPro/ocplib-endian/issues" 22 | synopsis: 23 | "Optimised functions to read and write int16/32/64 from strings and bigarrays, based on new primitives added in version 4.01." 24 | description: """ 25 | The library implements three modules: 26 | * [EndianString](https://github.com/OCamlPro/ocplib-endian/blob/master/src/endianString.cppo.mli) works directly on strings, and provides submodules BigEndian and LittleEndian, with their unsafe counter-parts; 27 | * [EndianBytes](https://github.com/OCamlPro/ocplib-endian/blob/master/src/endianBytes.cppo.mli) works directly on bytes, and provides submodules BigEndian and LittleEndian, with their unsafe counter-parts; 28 | * [EndianBigstring](https://github.com/OCamlPro/ocplib-endian/blob/master/src/endianBigstring.cppo.mli) works on bigstrings (Bigarrays of chars), and provides submodules BigEndian and LittleEndian, with their unsafe counter-parts;""" 29 | flags: light-uninstall 30 | url { 31 | src: "https://github.com/OCamlPro/ocplib-endian/archive/1.0.tar.gz" 32 | checksum: "md5=74b45ba33e189283170a748c2a3ed477" 33 | } 34 | -------------------------------------------------------------------------------- /esy.lock/opam/omd.1.3.1/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "Philippe Wang " 3 | authors: [ "Philippe Wang " ] 4 | license: "ISC" 5 | homepage: "https://github.com/ocaml/omd" 6 | dev-repo: "git+https://github.com/ocaml/omd.git" 7 | bug-reports: "https://github.com/ocaml/omd/issues" 8 | tags: [ "org:ocamllabs" "org:mirage" ] 9 | build: [ 10 | ["ocaml" "setup.ml" "-configure" "--prefix" prefix] 11 | ["ocaml" "setup.ml" "-build"] 12 | ["ocaml" "setup.ml" "-configure" "--enable-tests"] {with-test} 13 | ["ocaml" "setup.ml" "-build"] {with-test} 14 | ["ocaml" "setup.ml" "-test"] {with-test} 15 | ] 16 | install: ["ocaml" "setup.ml" "-install"] 17 | remove: [ 18 | ["ocaml" "%{etc}%/omd/setup.ml" "-C" "%{etc}%/omd" "-uninstall"] 19 | ] 20 | depends: [ 21 | "ocaml" {>= "4.01"} 22 | "base-bigarray" 23 | "base-bytes" 24 | "ocamlbuild" {build} 25 | "ocamlfind" {build & >= "1.5"} 26 | ] 27 | synopsis: "A Markdown frontend in pure OCaml." 28 | description: """ 29 | This Markdown library is implemented using only pure OCaml (including 30 | I/O operations provided by the standard OCaml compiler distribution). 31 | OMD is meant to be as faithful as possible to the original Markdown. 32 | Additionally, OMD implements a few Github markdown features, an 33 | extension mechanism, and some other features. Note that the opam 34 | package installs both the OMD library and the command line tool `omd`.""" 35 | url { 36 | src: 37 | "https://github.com/Chris00/omd/releases/download/1.3.1/omd-1.3.1.tar.gz" 38 | checksum: "md5=845fc38e86ec0e85721130f2dd044d00" 39 | } 40 | -------------------------------------------------------------------------------- /esy.lock/opam/parsexp.v0.12.0/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "opensource@janestreet.com" 3 | authors: ["Jane Street Group, LLC "] 4 | homepage: "https://github.com/janestreet/parsexp" 5 | bug-reports: "https://github.com/janestreet/parsexp/issues" 6 | dev-repo: "git+https://github.com/janestreet/parsexp.git" 7 | doc: "https://ocaml.janestreet.com/ocaml-core/latest/doc/parsexp/index.html" 8 | license: "MIT" 9 | build: [ 10 | ["dune" "build" "-p" name "-j" jobs] 11 | ] 12 | depends: [ 13 | "ocaml" {>= "4.04.2"} 14 | "base" {>= "v0.12" & < "v0.13"} 15 | "sexplib0" {>= "v0.12" & < "v0.13"} 16 | "dune" {>= "1.5.1"} 17 | ] 18 | synopsis: "S-expression parsing library" 19 | description: " 20 | This library provides generic parsers for parsing S-expressions from 21 | strings or other medium. 22 | 23 | The library is focused on performances but still provide full generic 24 | parsers that can be used with strings, bigstrings, lexing buffers, 25 | character streams or any other sources effortlessly. 26 | 27 | It provides three different class of parsers: 28 | - the normal parsers, producing [Sexp.t] or [Sexp.t list] values 29 | - the parsers with positions, building compact position sequences so 30 | that one can recover original positions in order to report properly 31 | located errors at little cost 32 | - the Concrete Syntax Tree parsers, produce values of type 33 | [Parsexp.Cst.t] which record the concrete layout of the s-expression 34 | syntax, including comments 35 | 36 | This library is portable and doesn't provide IO functions. To read 37 | s-expressions from files or other external sources, you should use 38 | parsexp_io. 39 | " 40 | url { 41 | src: "https://ocaml.janestreet.com/ocaml-core/v0.12/files/parsexp-v0.12.0.tar.gz" 42 | checksum: "md5=741b2c6f59b9618e3affabaa34d468a2" 43 | } 44 | -------------------------------------------------------------------------------- /esy.lock/opam/ppx_derivers.1.2.1/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "jeremie@dimino.org" 3 | authors: ["Jérémie Dimino"] 4 | license: "BSD-3-Clause" 5 | homepage: "https://github.com/ocaml-ppx/ppx_derivers" 6 | bug-reports: "https://github.com/ocaml-ppx/ppx_derivers/issues" 7 | dev-repo: "git://github.com/ocaml-ppx/ppx_derivers.git" 8 | build: [ 9 | ["dune" "build" "-p" name "-j" jobs] 10 | ] 11 | depends: [ 12 | "ocaml" 13 | "dune" 14 | ] 15 | synopsis: "Shared [@@deriving] plugin registry" 16 | description: """ 17 | Ppx_derivers is a tiny package whose sole purpose is to allow 18 | ppx_deriving and ppx_type_conv to inter-operate gracefully when linked 19 | as part of the same ocaml-migrate-parsetree driver.""" 20 | url { 21 | src: "https://github.com/ocaml-ppx/ppx_derivers/archive/1.2.1.tar.gz" 22 | checksum: "md5=5dc2bf130c1db3c731fe0fffc5648b41" 23 | } 24 | -------------------------------------------------------------------------------- /esy.lock/opam/ppx_deriving.4.4/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "whitequark " 3 | authors: [ "whitequark " ] 4 | license: "MIT" 5 | homepage: "https://github.com/ocaml-ppx/ppx_deriving" 6 | doc: "https://ocaml-ppx.github.io/ppx_deriving/" 7 | bug-reports: "https://github.com/ocaml-ppx/ppx_deriving/issues" 8 | dev-repo: "git+https://github.com/ocaml-ppx/ppx_deriving.git" 9 | tags: [ "syntax" ] 10 | build: [ 11 | ["dune" "subst"] {pinned} 12 | ["dune" "build" "-p" name "-j" jobs] 13 | ["dune" "runtest" "-p" name "-j" jobs] {with-test & ocaml:version >= "4.03"} 14 | ["dune" "build" "@doc" "-p" name "-j" jobs] {with-doc} 15 | ] 16 | depends: [ 17 | "dune" {>= "1.6.3"} 18 | "cppo" {build} 19 | "ppxfind" {build} 20 | "ocaml-migrate-parsetree" 21 | "ppx_derivers" 22 | "ppx_tools" {>= "4.02.3"} 23 | "result" 24 | "ounit" {with-test} 25 | "ocaml" {>= "4.02" & < "4.10.0"} 26 | ] 27 | synopsis: "Type-driven code generation for OCaml >=4.02.2" 28 | description: """ 29 | ppx_deriving provides common infrastructure for generating 30 | code based on type definitions, and a set of useful plugins 31 | for common tasks. 32 | """ 33 | url { 34 | src: "https://github.com/ocaml-ppx/ppx_deriving/archive/v4.4.tar.gz" 35 | checksum: "sha256=c2d85af4cb65a1f163f624590fb0395a164bbfd0d05082092526b669e66bcc34"} 36 | -------------------------------------------------------------------------------- /esy.lock/opam/ppx_deriving_yojson.3.5.1/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "whitequark " 3 | authors: [ "whitequark " ] 4 | license: "MIT" 5 | homepage: "https://github.com/whitequark/ppx_deriving_yojson" 6 | bug-reports: "https://github.com/whitequark/ppx_deriving_yojson/issues" 7 | dev-repo: "git://github.com/whitequark/ppx_deriving_yojson.git" 8 | tags: [ "syntax" "json" ] 9 | build: [ 10 | ["dune" "subst"] {pinned} 11 | ["dune" "build" "-p" name "-j" jobs] 12 | ["dune" "runtest" "-p" name] {with-test} 13 | ] 14 | depends: [ 15 | "ocaml" {>= "4.04.0" & < "4.10.0"} 16 | "yojson" {>= "1.6.0" & < "2.0.0"} 17 | "result" 18 | "ppx_deriving" {>= "4.0" & < "5.0"} 19 | "ppx_tools" {build} 20 | "ppxfind" {build} 21 | "dune" {>= "1.2"} 22 | "cppo" {build} 23 | "ounit" {with-test & >= "2.0.0"} 24 | ] 25 | conflicts: [ 26 | "ppx_deriving" {= "4.2"} 27 | ] 28 | synopsis: "JSON codec generator for OCaml" 29 | description: """ 30 | ppx_deriving_yojson is a ppx_deriving plugin that provides 31 | a JSON codec generator.""" 32 | url { 33 | src: "https://github.com/ocaml-ppx/ppx_deriving_yojson/archive/v3.5.1.tar.gz" 34 | checksum: "sha256=aefe9c673f2f0ee2beb9edcca5a4e332a9fe9266c81bc554b8df5cd375568994" 35 | } 36 | -------------------------------------------------------------------------------- /esy.lock/opam/ppx_tools.5.3+4.08.0/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | synopsis: "Tools for authors of ppx rewriters and other syntactic tools" 3 | maintainer: "alain.frisch@lexifi.com" 4 | authors: [ "Alain Frisch " ] 5 | license: "MIT" 6 | homepage: "https://github.com/ocaml-ppx/ppx_tools" 7 | bug-reports: "https://github.com/ocaml-ppx/ppx_tools/issues" 8 | dev-repo: "git://github.com/ocaml-ppx/ppx_tools.git" 9 | tags: [ "syntax" ] 10 | build: [[make "all"]] 11 | install: [[make "install"]] 12 | depends: [ 13 | "ocaml" {>= "4.08.0"} 14 | "ocamlfind" {build & >= "1.5.0"} 15 | ] 16 | url { 17 | src: "https://github.com/ocaml-ppx/ppx_tools/archive/5.3+4.08.0.tar.gz" 18 | checksum: "md5=702b11138c095662c175aa4dcce5c921" 19 | } 20 | -------------------------------------------------------------------------------- /esy.lock/opam/ppx_tools_versioned.5.2.3/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "frederic.bour@lakaban.net" 3 | authors: [ 4 | "Frédéric Bour " 5 | "Alain Frisch " 6 | ] 7 | license: "MIT" 8 | homepage: "https://github.com/ocaml-ppx/ppx_tools_versioned" 9 | bug-reports: "https://github.com/ocaml-ppx/ppx_tools_versioned/issues" 10 | dev-repo: "git://github.com/ocaml-ppx/ppx_tools_versioned.git" 11 | tags: [ "syntax" ] 12 | build: [ 13 | ["dune" "subst"] {pinned} 14 | ["dune" "build" "-p" name "-j" jobs] 15 | ["dune" "runtest" "-p" name "-j" jobs] {with-test} 16 | ] 17 | depends: [ 18 | "ocaml" {>= "4.02.0"} 19 | "dune" {>= "1.0"} 20 | "ocaml-migrate-parsetree" {>= "1.4.0"} 21 | ] 22 | synopsis: "A variant of ppx_tools based on ocaml-migrate-parsetree" 23 | url { 24 | src: 25 | "https://github.com/ocaml-ppx/ppx_tools_versioned/archive/5.2.3.tar.gz" 26 | checksum: [ 27 | "md5=b1455e5a4a1bcd9ddbfcf712ccbd4262" 28 | "sha512=af20aa0031b9c638537bcdb52c75de95f316ae8fd455a38672a60da5c7c6895cca9dbecd5d56a88c3c40979c6a673a047d986b5b41e1e84b528b7df5d905b9b1" 29 | ] 30 | } 31 | -------------------------------------------------------------------------------- /esy.lock/opam/ppxfind.1.3/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "jeremie@dimino.org" 3 | authors: ["Jérémie Dimino"] 4 | license: "BSD-3-Clause" 5 | homepage: "https://github.com/diml/ppxfind" 6 | bug-reports: "https://github.com/diml/ppxfind/issues" 7 | dev-repo: "git+https://github.com/diml/ppxfind.git" 8 | doc: "https://diml.github.io/ppxfind/" 9 | build: [ 10 | ["dune" "build" "-p" name "-j" jobs] 11 | ] 12 | depends: [ 13 | "dune" {>= "1.0"} 14 | "ocaml-migrate-parsetree" 15 | "ocamlfind" 16 | "ocaml" {>= "4.02.3"} 17 | ] 18 | conflicts: [ "dune" {= "1.2.0" | = "1.2.1"} ] 19 | synopsis: "Tool combining ocamlfind and ppx" 20 | description: """ 21 | Ppxfind is a small command line tool that among other things allows 22 | to use old style ppx rewriters with jbuilder. 23 | """ 24 | url { 25 | src: 26 | "https://github.com/diml/ppxfind/releases/download/1.3/ppxfind-1.3.tbz" 27 | checksum: [ 28 | "sha256=d49db026d0e74212c4b475b4e628aa57508c7452a0682d8c96e80c130ab892e4" 29 | "sha512=dd81bf5b3413f99a3c39f25e5e747f8d57d3bacac6a1fda92478af317e2d543294b4937982c94cf010978fcd71b1cfbfce1edbaa0c3d03973079296fda89689f" 30 | ] 31 | } 32 | -------------------------------------------------------------------------------- /esy.lock/opam/ppxlib.0.9.0/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "opensource@janestreet.com" 3 | authors: ["Jane Street Group, LLC "] 4 | homepage: "https://github.com/ocaml-ppx/ppxlib" 5 | bug-reports: "https://github.com/ocaml-ppx/ppxlib/issues" 6 | dev-repo: "git+https://github.com/ocaml-ppx/ppxlib.git" 7 | doc: "https://ocaml-ppx.github.io/ppxlib/" 8 | license: "MIT" 9 | build: [ 10 | ["dune" "subst"] {pinned} 11 | ["dune" "build" "-p" name "-j" jobs] 12 | ] 13 | run-test: [ 14 | ["dune" "runtest" "-p" name "-j" jobs] { ocaml:version >= "4.06" & ocaml:version < "4.09" } 15 | ] 16 | depends: [ 17 | "ocaml" {>= "4.04.1"} 18 | "base" {>= "v0.11.0"} 19 | "dune" 20 | "ocaml-compiler-libs" {>= "v0.11.0"} 21 | "ocaml-migrate-parsetree" {>= "1.3.1"} 22 | "ppx_derivers" {>= "1.0"} 23 | "stdio" {>= "v0.11.0"} 24 | "ocamlfind" {with-test} 25 | ] 26 | synopsis: "Base library and tools for ppx rewriters" 27 | description: """ 28 | A comprehensive toolbox for ppx development. It features: 29 | - a OCaml AST / parser / pretty-printer snapshot,to create a full 30 | frontend independent of the version of OCaml; 31 | - a library for library for ppx rewriters in general, and type-driven 32 | code generators in particular; 33 | - a feature-full driver for OCaml AST transformers; 34 | - a quotation mechanism allowing to write values representing the 35 | OCaml AST in the OCaml syntax; 36 | - a generator of open recursion classes from type definitions. 37 | """ 38 | url { 39 | src: 40 | "https://github.com/ocaml-ppx/ppxlib/archive/0.9.0.tar.gz" 41 | checksum: [ 42 | "sha256=d269f882a31ff75095a80793082f7481884ca75ef867c8c409f26ad36f9a0a54" 43 | "sha512=b903b0386739e17107f89fb9d7c861e95232c0deebbceeacad2d54f1ef771eb942a63e6057d2e3828f4c299c896c6488b6fd351bc150fd4e49d5a48bef84d8a8" 44 | ] 45 | } 46 | -------------------------------------------------------------------------------- /esy.lock/opam/psq.0.2.0/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "David Kaloper Meršinjak " 3 | authors: ["David Kaloper Meršinjak "] 4 | homepage: "https://github.com/pqwy/psq" 5 | doc: "https://pqwy.github.io/psq/doc" 6 | license: "ISC" 7 | dev-repo: "git+https://github.com/pqwy/psq.git" 8 | bug-reports: "https://github.com/pqwy/psq/issues" 9 | synopsis: "Functional Priority Search Queues" 10 | build: [ [ "dune" "subst" ] {pinned} 11 | [ "dune" "build" "-p" name "-j" jobs ] 12 | [ "dune" "runtest" "-p" name ] {with-test & ocaml:version >= "4.07.0"} ] 13 | depends: [ 14 | "ocaml" {>="4.03.0"} 15 | "dune" {>= "1.7"} 16 | "seq" 17 | "qcheck-core" {with-test} 18 | "qcheck-alcotest" {with-test} 19 | "alcotest" {with-test} 20 | ] 21 | description: """ 22 | Typical applications are searches, schedulers and caches. If you ever scratched 23 | your head because that A* didn't look quite right, a PSQ is what you needed. 24 | """ 25 | url { 26 | src: "https://github.com/pqwy/psq/releases/download/v0.2.0/psq-v0.2.0.tbz" 27 | checksum: "md5=b94fb15f8878172bf58446b7d0fb7c1e" 28 | } 29 | -------------------------------------------------------------------------------- /esy.lock/opam/re.1.9.0/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | 3 | maintainer: "rudi.grinberg@gmail.com" 4 | authors: [ 5 | "Jerome Vouillon" 6 | "Thomas Gazagnaire" 7 | "Anil Madhavapeddy" 8 | "Rudi Grinberg" 9 | "Gabriel Radanne" 10 | ] 11 | license: "LGPL-2.0-only with OCaml-LGPL-linking-exception" 12 | homepage: "https://github.com/ocaml/ocaml-re" 13 | bug-reports: "https://github.com/ocaml/ocaml-re/issues" 14 | dev-repo: "git+https://github.com/ocaml/ocaml-re.git" 15 | 16 | build: [ 17 | ["dune" "subst"] {pinned} 18 | ["dune" "build" "-p" name "-j" jobs] 19 | ["dune" "runtest" "-p" name "-j" jobs] {with-test} 20 | ] 21 | 22 | depends: [ 23 | "ocaml" {>= "4.02"} 24 | "dune" 25 | "ounit" {with-test} 26 | "seq" 27 | ] 28 | 29 | synopsis: "RE is a regular expression library for OCaml" 30 | description: """ 31 | Pure OCaml regular expressions with: 32 | * Perl-style regular expressions (module Re.Perl) 33 | * Posix extended regular expressions (module Re.Posix) 34 | * Emacs-style regular expressions (module Re.Emacs) 35 | * Shell-style file globbing (module Re.Glob) 36 | * Compatibility layer for OCaml's built-in Str module (module Re.Str) 37 | """ 38 | url { 39 | src: 40 | "https://github.com/ocaml/ocaml-re/releases/download/1.9.0/re-1.9.0.tbz" 41 | checksum: "md5=bddaed4f386a22cace7850c9c7dac296" 42 | } 43 | -------------------------------------------------------------------------------- /esy.lock/opam/reason.3.5.2/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "Jordan Walke " 3 | authors: [ "Jordan Walke " ] 4 | license: "MIT" 5 | homepage: "https://github.com/facebook/reason" 6 | doc: "http://reasonml.github.io/" 7 | bug-reports: "https://github.com/facebook/reason/issues" 8 | dev-repo: "git://github.com/facebook/reason.git" 9 | tags: [ "syntax" ] 10 | build: [ 11 | ["dune" "build" "-p" name "-j" jobs] 12 | ["dune" "runtest" "-p" name "-j" jobs] {with-test} 13 | ] 14 | depends: [ 15 | "ocaml" {>= "4.02" & < "4.10"} 16 | "dune" {>= "1.4"} 17 | "ocamlfind" {build} 18 | "menhir" {>= "20170418"} 19 | "merlin-extend" {>= "0.4"} 20 | "result" 21 | "ocaml-migrate-parsetree" 22 | ] 23 | synopsis: "Reason: Syntax & Toolchain for OCaml" 24 | description: """ 25 | Reason gives OCaml a new syntax that is remniscient of languages like 26 | JavaScript. It's also the umbrella project for a set of tools for the OCaml & 27 | JavaScript ecosystem.""" 28 | url { 29 | src: "https://registry.npmjs.org/@esy-ocaml/reason/-/reason-3.5.2.tgz" 30 | checksum: "md5=66c54296009e0f6cbc8e93aa01105cbb" 31 | } 32 | -------------------------------------------------------------------------------- /esy.lock/opam/result.1.4/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "opensource@janestreet.com" 3 | authors: ["Jane Street Group, LLC "] 4 | homepage: "https://github.com/janestreet/result" 5 | dev-repo: "git+https://github.com/janestreet/result.git" 6 | bug-reports: "https://github.com/janestreet/result/issues" 7 | license: "BSD-3-Clause" 8 | build: [["dune" "build" "-p" name "-j" jobs]] 9 | depends: [ 10 | "ocaml" 11 | "dune" {>= "1.0"} 12 | ] 13 | synopsis: "Compatibility Result module" 14 | description: """ 15 | Projects that want to use the new result type defined in OCaml >= 4.03 16 | while staying compatible with older version of OCaml should use the 17 | Result module defined in this library.""" 18 | url { 19 | src: 20 | "https://github.com/janestreet/result/archive/1.4.tar.gz" 21 | checksum: "md5=d3162dbc501a2af65c8c71e0866541da" 22 | } 23 | -------------------------------------------------------------------------------- /esy.lock/opam/seq.base/files/META.seq: -------------------------------------------------------------------------------- 1 | name="seq" 2 | version="[distributed with OCaml 4.07 or above]" 3 | description="dummy backward-compatibility package for iterators" 4 | requires="" 5 | -------------------------------------------------------------------------------- /esy.lock/opam/seq.base/files/seq.install: -------------------------------------------------------------------------------- 1 | lib:[ 2 | "META.seq" {"META"} 3 | ] 4 | -------------------------------------------------------------------------------- /esy.lock/opam/seq.base/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: " " 3 | authors: " " 4 | homepage: " " 5 | depends: [ 6 | "ocaml" {>= "4.07.0"} 7 | ] 8 | dev-repo: "git+https://github.com/ocaml/ocaml.git" 9 | bug-reports: "https://caml.inria.fr/mantis/main_page.php" 10 | synopsis: 11 | "Compatibility package for OCaml's standard iterator type starting from 4.07." 12 | extra-files: [ 13 | ["seq.install" "md5=026b31e1df290373198373d5aaa26e42"] 14 | ["META.seq" "md5=b33c8a1a6c7ed797816ce27df4855107"] 15 | ] 16 | -------------------------------------------------------------------------------- /esy.lock/opam/sexplib.v0.12.0/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "opensource@janestreet.com" 3 | authors: ["Jane Street Group, LLC "] 4 | homepage: "https://github.com/janestreet/sexplib" 5 | bug-reports: "https://github.com/janestreet/sexplib/issues" 6 | dev-repo: "git+https://github.com/janestreet/sexplib.git" 7 | doc: "https://ocaml.janestreet.com/ocaml-core/latest/doc/sexplib/index.html" 8 | license: "MIT" 9 | build: [ 10 | ["dune" "build" "-p" name "-j" jobs] 11 | ] 12 | depends: [ 13 | "ocaml" {>= "4.04.2"} 14 | "parsexp" {>= "v0.12" & < "v0.13"} 15 | "sexplib0" {>= "v0.12" & < "v0.13"} 16 | "dune" {>= "1.5.1"} 17 | "num" 18 | ] 19 | synopsis: "Library for serializing OCaml values to and from S-expressions" 20 | description: " 21 | Part of Jane Street's Core library 22 | The Core suite of libraries is an industrial strength alternative to 23 | OCaml's standard library that was developed by Jane Street, the 24 | largest industrial user of OCaml. 25 | " 26 | url { 27 | src: "https://ocaml.janestreet.com/ocaml-core/v0.12/files/sexplib-v0.12.0.tar.gz" 28 | checksum: "md5=a7f9f8a414aed6cc56901199cda020f6" 29 | } 30 | -------------------------------------------------------------------------------- /esy.lock/opam/sexplib0.v0.12.0/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "opensource@janestreet.com" 3 | authors: ["Jane Street Group, LLC "] 4 | homepage: "https://github.com/janestreet/sexplib0" 5 | bug-reports: "https://github.com/janestreet/sexplib0/issues" 6 | dev-repo: "git+https://github.com/janestreet/sexplib0.git" 7 | doc: "https://ocaml.janestreet.com/ocaml-core/latest/doc/sexplib0/index.html" 8 | license: "MIT" 9 | build: [ 10 | ["dune" "build" "-p" name "-j" jobs] 11 | ] 12 | depends: [ 13 | "ocaml" {>= "4.04.2"} 14 | "dune" {>= "1.5.1"} 15 | ] 16 | synopsis: "Library containing the definition of S-expressions and some base converters" 17 | description: " 18 | Part of Jane Street's Core library 19 | The Core suite of libraries is an industrial strength alternative to 20 | OCaml's standard library that was developed by Jane Street, the 21 | largest industrial user of OCaml. 22 | " 23 | url { 24 | src: "https://ocaml.janestreet.com/ocaml-core/v0.12/files/sexplib0-v0.12.0.tar.gz" 25 | checksum: "md5=2486a25d3a94da9a94acc018b5f09061" 26 | } 27 | -------------------------------------------------------------------------------- /esy.lock/opam/ssl.0.5.9/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "Samuel Mimram " 3 | homepage: "https://github.com/savonet/ocaml-ssl" 4 | dev-repo: "git+https://github.com/savonet/ocaml-ssl.git" 5 | bug-reports: "https://github.com/savonet/ocaml-ssl/issues" 6 | build: [ 7 | ["dune" "subst"] {pinned} 8 | ["dune" "build" "-p" name "-j" jobs] 9 | ] 10 | depends: [ 11 | "ocaml" {>= "4.02.0"} 12 | "dune" {>= "1.2.1"} 13 | "dune-configurator" 14 | "base-unix" 15 | "conf-openssl" 16 | ] 17 | synopsis: "Bindings for OpenSSL" 18 | authors: "Samuel Mimram " 19 | url { 20 | src: "https://github.com/savonet/ocaml-ssl/archive/0.5.9.tar.gz" 21 | checksum: [ 22 | "md5=09265ae2dee5ac48507ccb8a81244a15" 23 | "sha512=6826e5a6ab9f51013e8d097900f443d091e085e3d2d232a315a0e3a90ca334c9b9779d20dcae267f9ed961bc4a08fcb80372e669389c59a22d5c7706d37fcd5f" 24 | ] 25 | } 26 | -------------------------------------------------------------------------------- /esy.lock/opam/stdio.v0.12.0/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "opensource@janestreet.com" 3 | authors: ["Jane Street Group, LLC "] 4 | homepage: "https://github.com/janestreet/stdio" 5 | bug-reports: "https://github.com/janestreet/stdio/issues" 6 | dev-repo: "git+https://github.com/janestreet/stdio.git" 7 | doc: "https://ocaml.janestreet.com/ocaml-core/latest/doc/stdio/index.html" 8 | license: "MIT" 9 | build: [ 10 | ["dune" "build" "-p" name "-j" jobs] 11 | ] 12 | depends: [ 13 | "ocaml" {>= "4.04.2"} 14 | "base" {>= "v0.12" & < "v0.13"} 15 | "dune" {>= "1.5.1"} 16 | ] 17 | synopsis: "Standard IO library for OCaml" 18 | description: " 19 | Stdio implements simple input/output functionalities for OCaml. 20 | 21 | It re-exports the input/output functions of the OCaml standard 22 | libraries using a more consistent API. 23 | " 24 | url { 25 | src: "https://ocaml.janestreet.com/ocaml-core/v0.12/files/stdio-v0.12.0.tar.gz" 26 | checksum: "md5=b261ff2d5667fde960c95e50cff668da" 27 | } 28 | -------------------------------------------------------------------------------- /esy.lock/opam/stdlib-shims.0.1.0/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "The stdlib-shims programmers" 3 | authors: "The stdlib-shims programmers" 4 | homepage: "https://github.com/ocaml/stdlib-shims" 5 | doc: "https://ocaml.github.io/stdlib-shims/" 6 | dev-repo: "git+https://github.com/ocaml/stdlib-shims.git" 7 | bug-reports: "https://github.com/ocaml/stdlib-shims/issues" 8 | tags: ["stdlib" "compatibility" "org:ocaml"] 9 | license: ["typeof OCaml system"] 10 | depends: [ 11 | "dune" 12 | "ocaml" {>= "4.02.3"} 13 | ] 14 | build: [ "dune" "build" "-p" name "-j" jobs ] 15 | synopsis: "Backport some of the new stdlib features to older compiler" 16 | description: """ 17 | Backport some of the new stdlib features to older compiler, 18 | such as the Stdlib module. 19 | 20 | This allows projects that require compatibility with older compiler to 21 | use these new features in their code. 22 | """ 23 | url { 24 | src: 25 | "https://github.com/ocaml/stdlib-shims/releases/download/0.1.0/stdlib-shims-0.1.0.tbz" 26 | checksum: "md5=12b5704eed70c6bff5ac39a16db1425d" 27 | } 28 | -------------------------------------------------------------------------------- /esy.lock/opam/stringext.1.6.0/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "rudi.grinberg@gmail.com" 3 | authors: "Rudi Grinberg" 4 | license: "MIT" 5 | homepage: "https://github.com/rgrinberg/stringext" 6 | bug-reports: "https://github.com/rgrinberg/stringext/issues" 7 | depends: [ 8 | "ocaml" {>= "4.02.3"} 9 | "dune" {>= "1.0"} 10 | "ounit" {with-test} 11 | "qtest" {with-test & >= "2.2"} 12 | "base-bytes" 13 | ] 14 | build: [ 15 | ["dune" "subst"] {pinned} 16 | ["dune" "build" "-p" name "-j" jobs] 17 | ["dune" "runtest" "-p" name "-j" jobs] {with-test} 18 | ] 19 | dev-repo: "git+https://github.com/rgrinberg/stringext.git" 20 | synopsis: "Extra string functions for OCaml" 21 | description: """ 22 | Extra string functions for OCaml. Mainly splitting. All functions are in the 23 | Stringext module. 24 | """ 25 | url { 26 | src: 27 | "https://github.com/rgrinberg/stringext/releases/download/1.6.0/stringext-1.6.0.tbz" 28 | checksum: [ 29 | "sha256=db41f5d52e9eab17615f110b899dfeb27dd7e7f89cd35ae43827c5119db206ea" 30 | "sha512=d8ebe40f42b598a9bd99f1ef4b00ba93458385a4accd121af66a0bf3b3f8d7135f576740adf1a43081dd409977c2219fd4bdbb5b3d1308890d301d553ed49900" 31 | ] 32 | } 33 | -------------------------------------------------------------------------------- /esy.lock/opam/topkg.1.0.1/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "Daniel Bünzli " 3 | authors: ["Daniel Bünzli "] 4 | homepage: "http://erratique.ch/software/topkg" 5 | doc: "http://erratique.ch/software/topkg/doc" 6 | license: "ISC" 7 | dev-repo: "git+http://erratique.ch/repos/topkg.git" 8 | bug-reports: "https://github.com/dbuenzli/topkg/issues" 9 | tags: ["packaging" "ocamlbuild" "org:erratique"] 10 | depends: [ 11 | "ocaml" {>= "4.03.0"} 12 | "ocamlfind" {build & >= "1.6.1"} 13 | "ocamlbuild" ] 14 | build: [[ 15 | "ocaml" "pkg/pkg.ml" "build" 16 | "--pkg-name" name 17 | "--dev-pkg" "%{pinned}%" ]] 18 | synopsis: """The transitory OCaml software packager""" 19 | description: """\ 20 | 21 | Topkg is a packager for distributing OCaml software. It provides an 22 | API to describe the files a package installs in a given build 23 | configuration and to specify information about the package's 24 | distribution, creation and publication procedures. 25 | 26 | The optional topkg-care package provides the `topkg` command line tool 27 | which helps with various aspects of a package's life cycle: creating 28 | and linting a distribution, releasing it on the WWW, publish its 29 | documentation, add it to the OCaml opam repository, etc. 30 | 31 | Topkg is distributed under the ISC license and has **no** 32 | dependencies. This is what your packages will need as a *build* 33 | dependency. 34 | 35 | Topkg-care is distributed under the ISC license it depends on 36 | [fmt][fmt], [logs][logs], [bos][bos], [cmdliner][cmdliner], 37 | [webbrowser][webbrowser] and `opam-format`. 38 | 39 | [fmt]: http://erratique.ch/software/fmt 40 | [logs]: http://erratique.ch/software/logs 41 | [bos]: http://erratique.ch/software/bos 42 | [cmdliner]: http://erratique.ch/software/cmdliner 43 | [webbrowser]: http://erratique.ch/software/webbrowser 44 | """ 45 | url { 46 | archive: "http://erratique.ch/software/topkg/releases/topkg-1.0.1.tbz" 47 | checksum: "16b90e066d8972a5ef59655e7c28b3e9" 48 | } 49 | -------------------------------------------------------------------------------- /esy.lock/opam/uchar.0.0.2/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "Daniel Bünzli " 3 | authors: ["Daniel Bünzli "] 4 | homepage: "http://ocaml.org" 5 | doc: "https://ocaml.github.io/uchar/" 6 | dev-repo: "git+https://github.com/ocaml/uchar.git" 7 | bug-reports: "https://github.com/ocaml/uchar/issues" 8 | tags: [ "text" "character" "unicode" "compatibility" "org:ocaml.org" ] 9 | license: "typeof OCaml system" 10 | depends: [ 11 | "ocaml" {>= "3.12.0"} 12 | "ocamlbuild" {build} 13 | ] 14 | build: [ 15 | ["ocaml" "pkg/git.ml"] 16 | [ 17 | "ocaml" 18 | "pkg/build.ml" 19 | "native=%{ocaml:native}%" 20 | "native-dynlink=%{ocaml:native-dynlink}%" 21 | ] 22 | ] 23 | synopsis: "Compatibility library for OCaml's Uchar module" 24 | description: """ 25 | The `uchar` package provides a compatibility library for the 26 | [`Uchar`][1] module introduced in OCaml 4.03. 27 | 28 | The `uchar` package is distributed under the license of the OCaml 29 | compiler. See [LICENSE](LICENSE) for details. 30 | 31 | [1]: http://caml.inria.fr/pub/docs/manual-ocaml/libref/Uchar.html""" 32 | url { 33 | src: 34 | "https://github.com/ocaml/uchar/releases/download/v0.0.2/uchar-0.0.2.tbz" 35 | checksum: "md5=c9ba2c738d264c420c642f7bb1cf4a36" 36 | } 37 | -------------------------------------------------------------------------------- /esy.lock/opam/uri.3.0.0/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "anil@recoil.org" 3 | authors: ["Anil Madhavapeddy" "David Sheets" "Rudi Grinberg"] 4 | license: "ISC" 5 | tags: ["url" "uri" "org:mirage" "org:xapi-project"] 6 | homepage: "https://github.com/mirage/ocaml-uri" 7 | bug-reports: "https://github.com/mirage/ocaml-uri/issues" 8 | dev-repo: "git+https://github.com/mirage/ocaml-uri.git" 9 | doc: "https://mirage.github.io/ocaml-uri/" 10 | synopsis: "An RFC3986 URI/URL parsing library" 11 | description: """ 12 | This is an OCaml implementation of the [RFC3986](http://tools.ietf.org/html/rfc3986) specification 13 | for parsing URI or URLs. 14 | """ 15 | depends: [ 16 | "ocaml" {>= "4.04.0"} 17 | "dune" {>= "1.2.0"} 18 | "ounit" {with-test & >= "1.0.2"} 19 | "ppx_sexp_conv" {with-test & >= "v0.9.0"} 20 | "re" {>= "1.9.0"} 21 | "stringext" {>= "1.4.0"} 22 | ] 23 | build: [ 24 | ["dune" "subst"] {pinned} 25 | ["dune" "build" "-p" name "-j" jobs] 26 | ["dune" "runtest" "-p" name "-j" jobs] {with-test} 27 | ] 28 | url { 29 | src: 30 | "https://github.com/mirage/ocaml-uri/releases/download/v3.0.0/uri-v3.0.0.tbz" 31 | checksum: [ 32 | "sha256=8fb334fba6ebbf879e2e82d80d6adee8bdaf6cec3bb3da248110d805477d19fa" 33 | "sha512=553c18032a7c96cccdc8e37f497ce34e821b9dd089cfc8685783b7ade1d4dfa422722e4724abcba8b1171b51fa91a2bee297396fc7c349118069b6352e07881e" 34 | ] 35 | } 36 | -------------------------------------------------------------------------------- /esy.lock/opam/uutf.1.0.2/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "Daniel Bünzli " 3 | authors: ["Daniel Bünzli "] 4 | homepage: "http://erratique.ch/software/uutf" 5 | doc: "http://erratique.ch/software/uutf/doc/Uutf" 6 | dev-repo: "git+http://erratique.ch/repos/uutf.git" 7 | bug-reports: "https://github.com/dbuenzli/uutf/issues" 8 | tags: [ "unicode" "text" "utf-8" "utf-16" "codec" "org:erratique" ] 9 | license: "ISC" 10 | depends: [ 11 | "ocaml" {>= "4.01.0"} 12 | "ocamlfind" {build} 13 | "ocamlbuild" {build} 14 | "topkg" {build} 15 | "uchar" 16 | ] 17 | depopts: ["cmdliner"] 18 | conflicts: ["cmdliner" { < "0.9.6"} ] 19 | build: [[ 20 | "ocaml" "pkg/pkg.ml" "build" 21 | "--pinned" "%{pinned}%" 22 | "--with-cmdliner" "%{cmdliner:installed}%" ]] 23 | synopsis: """Non-blocking streaming Unicode codec for OCaml""" 24 | description: """\ 25 | 26 | Uutf is a non-blocking streaming codec to decode and encode the UTF-8, 27 | UTF-16, UTF-16LE and UTF-16BE encoding schemes. It can efficiently 28 | work character by character without blocking on IO. Decoders perform 29 | character position tracking and support newline normalization. 30 | 31 | Functions are also provided to fold over the characters of UTF encoded 32 | OCaml string values and to directly encode characters in OCaml 33 | Buffer.t values. 34 | 35 | Uutf has no dependency and is distributed under the ISC license. 36 | """ 37 | url { 38 | archive: "http://erratique.ch/software/uutf/releases/uutf-1.0.2.tbz" 39 | checksum: "a7c542405a39630c689a82bd7ef2292c" 40 | } 41 | -------------------------------------------------------------------------------- /esy.lock/opam/xmlm.1.3.0/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "Daniel Bünzli " 3 | authors: ["Daniel Bünzli "] 4 | homepage: "http://erratique.ch/software/xmlm" 5 | dev-repo: "git+http://erratique.ch/repos/xmlm.git" 6 | bug-reports: "https://github.com/dbuenzli/xmlm/issues" 7 | doc: "http://erratique.ch/software/xmlm/doc/Xmlm" 8 | tags: [ "xml" "codec" "org:erratique" ] 9 | license: "ISC" 10 | depends: [ 11 | "ocaml" {>= "4.02.0"} 12 | "ocamlfind" {build} 13 | "ocamlbuild" {build} 14 | "topkg" {build & >= "0.9.0"} 15 | ] 16 | build: 17 | [[ 18 | "ocaml" "pkg/pkg.ml" "build" 19 | "--dev-pkg" "%{pinned}%" 20 | ]] 21 | synopsis: "Streaming XML codec for OCaml" 22 | description: """ 23 | Xmlm is a streaming codec to decode and encode the XML data format. It 24 | can process XML documents without a complete in-memory representation of the 25 | data. 26 | 27 | Xmlm is made of a single independent module and distributed 28 | under the ISC license.""" 29 | url { 30 | src: "http://erratique.ch/software/xmlm/releases/xmlm-1.3.0.tbz" 31 | checksum: "md5=d63ce15d913975211196b5079e86a797" 32 | } 33 | -------------------------------------------------------------------------------- /esy.lock/opam/yojson.1.7.0/opam: -------------------------------------------------------------------------------- 1 | opam-version: "2.0" 2 | maintainer: "martin@mjambon.com" 3 | authors: ["Martin Jambon"] 4 | homepage: "https://github.com/ocaml-community/yojson" 5 | bug-reports: "https://github.com/ocaml-community/yojson/issues" 6 | dev-repo: "git+https://github.com/ocaml-community/yojson.git" 7 | doc: "https://ocaml-community.github.io/yojson/" 8 | build: [ 9 | ["dune" "subst"] {pinned} 10 | ["dune" "build" "-p" name "-j" jobs] 11 | ] 12 | run-test: [["dune" "runtest" "-p" name "-j" jobs]] 13 | depends: [ 14 | "ocaml" {>= "4.02.3"} 15 | "dune" 16 | "cppo" {build} 17 | "easy-format" 18 | "biniou" {>= "1.2.0"} 19 | "alcotest" {with-test & >= "0.8.5"} 20 | ] 21 | synopsis: 22 | "Yojson is an optimized parsing and printing library for the JSON format" 23 | description: """ 24 | Yojson is an optimized parsing and printing library for the JSON format. 25 | 26 | It addresses a few shortcomings of json-wheel including 2x speedup, 27 | polymorphic variants and optional syntax for tuples and variants. 28 | 29 | ydump is a pretty-printing command-line program provided with the 30 | yojson package. 31 | 32 | The program atdgen can be used to derive OCaml-JSON serializers and 33 | deserializers from type definitions.""" 34 | url { 35 | src: 36 | "https://github.com/ocaml-community/yojson/releases/download/1.7.0/yojson-1.7.0.tbz" 37 | checksum: "md5=b89d39ca3f8c532abe5f547ad3b8f84d" 38 | } 39 | -------------------------------------------------------------------------------- /esy.lock/overrides/af5fc8c4abb1f4c1dce1c179864522b6/.ci/build.yaml: -------------------------------------------------------------------------------- 1 | parameters: 2 | host: '' 3 | pool: '' 4 | sign: false 5 | 6 | jobs: 7 | - job: ${{ parameters.host }} 8 | pool: ${{ parameters.pool }} 9 | steps: 10 | - ${{ if eq(parameters.sign, 'true') }}: 11 | - script: 'npm install -g esy@latest --unsafe-perm' 12 | displayName: 'Installing deps' 13 | - ${{ if eq(parameters.sign, 'false') }}: 14 | - script: 'sudo npm install -g esy@latest --unsafe-perm' 15 | displayName: 'Installing deps' 16 | - script: mkdir -p test_dir 17 | displayName: 'make test dir' 18 | - bash: | 19 | cd test_dir 20 | echo '{"dependencies": {"@esy-packages/esy-openssl" : "esy-packages/esy-openssl:package.json#'$(git rev-parse --short HEAD)'"}}' > package.json 21 | displayName: 'create test package.json' 22 | - script: | 23 | cd test_dir 24 | esy install 25 | displayName: 'Install esy-deps' 26 | - script: | 27 | cd test_dir 28 | esy x which openssl 29 | esy sh ../esy/test.sh 30 | displayName: 'Building and dry run' 31 | -------------------------------------------------------------------------------- /esy.lock/overrides/af5fc8c4abb1f4c1dce1c179864522b6/.gitignore: -------------------------------------------------------------------------------- 1 | test_dir 2 | -------------------------------------------------------------------------------- /esy.lock/overrides/af5fc8c4abb1f4c1dce1c179864522b6/.travis.yml: -------------------------------------------------------------------------------- 1 | language: node_js 2 | node_js: 3 | - 8 4 | os: 5 | - linux 6 | - osx 7 | install: 8 | - npm install --global esy@0.3.0 9 | - esy install 10 | script: 11 | - travis_wait 40 esy build 12 | cache: 13 | timeout: 360 14 | directories: 15 | - '$HOME/.esy/' 16 | -------------------------------------------------------------------------------- /esy.lock/overrides/af5fc8c4abb1f4c1dce1c179864522b6/README.md: -------------------------------------------------------------------------------- 1 | ### `esy` build status 2 | [![Build status](https://ci.appveyor.com/api/projects/status/54y3s6ip6ti7y3vm/branch/esy?svg=true)](https://ci.appveyor.com/project/bryphe/esy-openssl/branch/esy) 3 | [![Build Status](https://travis-ci.org/bryphe/esy-openssl.svg?branch=esy)](https://travis-ci.org/bryphe/esy-openssl) 4 | 5 | ----------- 6 | 7 | OpenSSL 1.1.1 11 Sep 2018 8 | 9 | Copyright (c) 1998-2018 The OpenSSL Project 10 | Copyright (c) 1995-1998 Eric A. Young, Tim J. Hudson 11 | All rights reserved. 12 | 13 | DESCRIPTION 14 | ----------- 15 | 16 | The OpenSSL Project is a collaborative effort to develop a robust, 17 | commercial-grade, fully featured, and Open Source toolkit implementing the 18 | Transport Layer Security (TLS) protocols (including SSLv3) as well as a 19 | full-strength general purpose cryptographic library. 20 | 21 | OpenSSL is descended from the SSLeay library developed by Eric A. Young 22 | and Tim J. Hudson. The OpenSSL toolkit is licensed under a dual-license (the 23 | OpenSSL license plus the SSLeay license), which means that you are free to 24 | get and use it for commercial and non-commercial purposes as long as you 25 | fulfill the conditions of both licenses. 26 | 27 | OVERVIEW 28 | -------- 29 | 30 | The OpenSSL toolkit includes: 31 | 32 | libssl (with platform specific naming): 33 | Provides the client and server-side implementations for SSLv3 and TLS. 34 | 35 | libcrypto (with platform specific naming): 36 | Provides general cryptographic and X.509 support needed by SSL/TLS but 37 | not logically part of it. 38 | 39 | openssl: 40 | A command line tool that can be used for: 41 | Creation of key parameters 42 | Creation of X.509 certificates, CSRs and CRLs 43 | Calculation of message digests 44 | Encryption and decryption 45 | SSL/TLS client and server tests 46 | Handling of S/MIME signed or encrypted mail 47 | And more... 48 | 49 | INSTALLATION 50 | ------------ 51 | 52 | See the appropriate file: 53 | INSTALL Linux, Unix, Windows, OpenVMS, ... 54 | NOTES.* INSTALL addendums for different platforms 55 | 56 | SUPPORT 57 | ------- 58 | 59 | See the OpenSSL website www.openssl.org for details on how to obtain 60 | commercial technical support. Free community support is available through the 61 | openssl-users email list (see 62 | https://www.openssl.org/community/mailinglists.html for further details). 63 | 64 | If you have any problems with OpenSSL then please take the following steps 65 | first: 66 | 67 | - Download the latest version from the repository 68 | to see if the problem has already been addressed 69 | - Configure with no-asm 70 | - Remove compiler optimization flags 71 | 72 | If you wish to report a bug then please include the following information 73 | and create an issue on GitHub: 74 | 75 | - OpenSSL version: output of 'openssl version -a' 76 | - Configuration data: output of 'perl configdata.pm --dump' 77 | - OS Name, Version, Hardware platform 78 | - Compiler Details (name, version) 79 | - Application Details (name, version) 80 | - Problem Description (steps that will reproduce the problem, if known) 81 | - Stack Traceback (if the application dumps core) 82 | 83 | Just because something doesn't work the way you expect does not mean it 84 | is necessarily a bug in OpenSSL. Use the openssl-users email list for this type 85 | of query. 86 | 87 | HOW TO CONTRIBUTE TO OpenSSL 88 | ---------------------------- 89 | 90 | See CONTRIBUTING 91 | 92 | LEGALITIES 93 | ---------- 94 | 95 | A number of nations restrict the use or export of cryptography. If you 96 | are potentially subject to such restrictions you should seek competent 97 | professional legal advice before attempting to develop or distribute 98 | cryptographic code. 99 | -------------------------------------------------------------------------------- /esy.lock/overrides/af5fc8c4abb1f4c1dce1c179864522b6/azure-pipelines.yml: -------------------------------------------------------------------------------- 1 | jobs: 2 | - template: .ci/build.yaml # Template reference 3 | parameters: 4 | host: macOS 5 | pool: 6 | vmImage: 'macOS-10.13' 7 | 8 | - template: .ci/build.yaml # Template reference 9 | parameters: 10 | host: Linux 11 | pool: 12 | vmImage: 'Ubuntu-16.04' 13 | 14 | - template: .ci/build.yaml # Template reference 15 | parameters: 16 | host: Windows 17 | pool: 18 | vmImage: 'vs2017-win2016' 19 | sign: true # Extra step on Windows only 20 | -------------------------------------------------------------------------------- /esy.lock/overrides/af5fc8c4abb1f4c1dce1c179864522b6/esy.lock.json: -------------------------------------------------------------------------------- 1 | { 2 | "hash": "d10585b707b5ab54802c6c85154328fd", 3 | "root": "root@path:./package.json", 4 | "node": { 5 | "root@path:./package.json": { 6 | "record": { 7 | "name": "root", 8 | "version": "path:./package.json", 9 | "source": "path:./package.json", 10 | "files": [], 11 | "opam": null 12 | }, 13 | "dependencies": [] 14 | } 15 | } 16 | } -------------------------------------------------------------------------------- /esy.lock/overrides/af5fc8c4abb1f4c1dce1c179864522b6/esy/test.c: -------------------------------------------------------------------------------- 1 | /* From: https://wiki.openssl.org/index.php/Libcrypto_API */ 2 | 3 | #include 4 | #include 5 | #include 6 | 7 | int main(int arc, char *argv[]) 8 | { 9 | /* Load the human readable error strings for libcrypto */ 10 | ERR_load_crypto_strings(); 11 | 12 | /* Load all digest and cipher algorithms */ 13 | OpenSSL_add_all_algorithms(); 14 | 15 | /* Load config file, and other important initialisation */ 16 | CONF_modules_load(NULL, NULL, 0); 17 | 18 | printf("OpenSSL successfully initialized.\n"); 19 | 20 | /* Clean up */ 21 | 22 | /* Removes all digests and ciphers */ 23 | EVP_cleanup(); 24 | 25 | /* if you omit the next, a small leak may be left when you make use of the BIO (low level API) for e.g. base64 transformations */ 26 | CRYPTO_cleanup_all_ex_data(); 27 | 28 | /* Remove error strings */ 29 | ERR_free_strings(); 30 | 31 | return 0; 32 | } 33 | -------------------------------------------------------------------------------- /esy.lock/overrides/af5fc8c4abb1f4c1dce1c179864522b6/esy/test.sh: -------------------------------------------------------------------------------- 1 | pwd 2 | mkdir -p _test 3 | cd _test 4 | 5 | if which x86_64-w64-mingw32-gcc; then 6 | CC=x86_64-w64-mingw32-gcc 7 | else 8 | CC=gcc 9 | fi 10 | 11 | echo "Using compiler: $CC" 12 | 13 | echo "include..." 14 | #ls -a $INCLUDE 15 | echo "lib.." 16 | #ls -a $cur__lib 17 | 18 | $CC ./../../esy/test.c -o ./test.exe -I$OPENSSL_INCLUDE_PATH -L$OPENSSL_LIB_PATH -lssl -lcrypto 19 | 20 | #export PATH=$PATH:$cur__bin:$cur__lib 21 | #export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$cur__lib 22 | 23 | #echo "Augmented path: $PATH" 24 | 25 | echo "Copying binaries..." 26 | #cp $cur__bin/*.dll . 27 | 28 | echo "Test executable path:" 29 | ls -a . 30 | 31 | ./test.exe 32 | -------------------------------------------------------------------------------- /esy.lock/overrides/af5fc8c4abb1f4c1dce1c179864522b6/files/openssl-1.1.1d-mingw.patch: -------------------------------------------------------------------------------- 1 | --- a/Configurations/unix-Makefile.tmpl 2019-09-10 13:13:07.000000000 +0000 2 | +++ b/Configurations/unix-Makefile.tmpl 2019-09-11 09:58:11.000000000 +0000 3 | @@ -547,78 +547,78 @@ 4 | install_docs: install_man_docs install_html_docs 5 | 6 | uninstall_docs: uninstall_man_docs uninstall_html_docs 7 | - $(RM) -r $(DESTDIR)$(DOCDIR) 8 | + $(RM) -r "$(DESTDIR)$(DOCDIR)" 9 | 10 | install_ssldirs: 11 | - @$(PERL) $(SRCDIR)/util/mkdir-p.pl $(DESTDIR)$(OPENSSLDIR)/certs 12 | - @$(PERL) $(SRCDIR)/util/mkdir-p.pl $(DESTDIR)$(OPENSSLDIR)/private 13 | - @$(PERL) $(SRCDIR)/util/mkdir-p.pl $(DESTDIR)$(OPENSSLDIR)/misc 14 | + @$(PERL) $(SRCDIR)/util/mkdir-p.pl "$(DESTDIR)$(OPENSSLDIR)/certs" 15 | + @$(PERL) $(SRCDIR)/util/mkdir-p.pl "$(DESTDIR)$(OPENSSLDIR)/private" 16 | + @$(PERL) $(SRCDIR)/util/mkdir-p.pl "$(DESTDIR)$(OPENSSLDIR)/misc" 17 | @set -e; for x in dummy $(MISC_SCRIPTS); do \ 18 | if [ "$$x" = "dummy" ]; then continue; fi; \ 19 | x1=`echo "$$x" | cut -f1 -d:`; \ 20 | x2=`echo "$$x" | cut -f2 -d:`; \ 21 | fn=`basename $$x1`; \ 22 | $(ECHO) "install $$x1 -> $(DESTDIR)$(OPENSSLDIR)/misc/$$fn"; \ 23 | - cp $$x1 $(DESTDIR)$(OPENSSLDIR)/misc/$$fn.new; \ 24 | - chmod 755 $(DESTDIR)$(OPENSSLDIR)/misc/$$fn.new; \ 25 | - mv -f $(DESTDIR)$(OPENSSLDIR)/misc/$$fn.new \ 26 | - $(DESTDIR)$(OPENSSLDIR)/misc/$$fn; \ 27 | + cp $$x1 "$(DESTDIR)$(OPENSSLDIR)/misc/$$fn.new"; \ 28 | + chmod 755 "$(DESTDIR)$(OPENSSLDIR)/misc/$$fn.new"; \ 29 | + mv -f "$(DESTDIR)$(OPENSSLDIR)/misc/$$fn.new" \ 30 | + "$(DESTDIR)$(OPENSSLDIR)/misc/$$fn"; \ 31 | if [ "$$x1" != "$$x2" ]; then \ 32 | ln=`basename "$$x2"`; \ 33 | : {- output_off() unless windowsdll(); "" -}; \ 34 | $(ECHO) "copy $(DESTDIR)$(OPENSSLDIR)/misc/$$ln -> $(DESTDIR)$(OPENSSLDIR)/misc/$$fn"; \ 35 | - cp $(DESTDIR)$(OPENSSLDIR)/misc/$$fn $(DESTDIR)$(OPENSSLDIR)/misc/$$ln; \ 36 | + cp "$(DESTDIR)$(OPENSSLDIR)/misc/$$fn" "$(DESTDIR)$(OPENSSLDIR)/misc/$$ln"; \ 37 | : {- output_on() unless windowsdll(); 38 | output_off() if windowsdll(); "" -}; \ 39 | $(ECHO) "link $(DESTDIR)$(OPENSSLDIR)/misc/$$ln -> $(DESTDIR)$(OPENSSLDIR)/misc/$$fn"; \ 40 | - ln -sf $$fn $(DESTDIR)$(OPENSSLDIR)/misc/$$ln; \ 41 | + ln -sf $$fn "$(DESTDIR)$(OPENSSLDIR)/misc/$$ln"; \ 42 | : {- output_on() if windowsdll(); "" -}; \ 43 | fi; \ 44 | done 45 | @$(ECHO) "install $(SRCDIR)/apps/openssl.cnf -> $(DESTDIR)$(OPENSSLDIR)/openssl.cnf.dist" 46 | - @cp $(SRCDIR)/apps/openssl.cnf $(DESTDIR)$(OPENSSLDIR)/openssl.cnf.new 47 | - @chmod 644 $(DESTDIR)$(OPENSSLDIR)/openssl.cnf.new 48 | - @mv -f $(DESTDIR)$(OPENSSLDIR)/openssl.cnf.new $(DESTDIR)$(OPENSSLDIR)/openssl.cnf.dist 49 | + @cp $(SRCDIR)/apps/openssl.cnf "$(DESTDIR)$(OPENSSLDIR)/openssl.cnf.new" 50 | + @chmod 644 "$(DESTDIR)$(OPENSSLDIR)/openssl.cnf.new" 51 | + @mv -f "$(DESTDIR)$(OPENSSLDIR)/openssl.cnf.new" "$(DESTDIR)$(OPENSSLDIR)/openssl.cnf.dist" 52 | @if [ ! -f "$(DESTDIR)$(OPENSSLDIR)/openssl.cnf" ]; then \ 53 | $(ECHO) "install $(SRCDIR)/apps/openssl.cnf -> $(DESTDIR)$(OPENSSLDIR)/openssl.cnf"; \ 54 | - cp $(SRCDIR)/apps/openssl.cnf $(DESTDIR)$(OPENSSLDIR)/openssl.cnf; \ 55 | - chmod 644 $(DESTDIR)$(OPENSSLDIR)/openssl.cnf; \ 56 | + cp $(SRCDIR)/apps/openssl.cnf "$(DESTDIR)$(OPENSSLDIR)/openssl.cnf"; \ 57 | + chmod 644 "$(DESTDIR)$(OPENSSLDIR)/openssl.cnf"; \ 58 | fi 59 | @$(ECHO) "install $(SRCDIR)/apps/ct_log_list.cnf -> $(DESTDIR)$(OPENSSLDIR)/ct_log_list.cnf.dist" 60 | - @cp $(SRCDIR)/apps/ct_log_list.cnf $(DESTDIR)$(OPENSSLDIR)/ct_log_list.cnf.new 61 | - @chmod 644 $(DESTDIR)$(OPENSSLDIR)/ct_log_list.cnf.new 62 | - @mv -f $(DESTDIR)$(OPENSSLDIR)/ct_log_list.cnf.new $(DESTDIR)$(OPENSSLDIR)/ct_log_list.cnf.dist 63 | + @cp $(SRCDIR)/apps/ct_log_list.cnf "$(DESTDIR)$(OPENSSLDIR)/ct_log_list.cnf.new" 64 | + @chmod 644 "$(DESTDIR)$(OPENSSLDIR)/ct_log_list.cnf.new" 65 | + @mv -f "$(DESTDIR)$(OPENSSLDIR)/ct_log_list.cnf.new" "$(DESTDIR)$(OPENSSLDIR)/ct_log_list.cnf.dist" 66 | @if [ ! -f "$(DESTDIR)$(OPENSSLDIR)/ct_log_list.cnf" ]; then \ 67 | $(ECHO) "install $(SRCDIR)/apps/ct_log_list.cnf -> $(DESTDIR)$(OPENSSLDIR)/ct_log_list.cnf"; \ 68 | - cp $(SRCDIR)/apps/ct_log_list.cnf $(DESTDIR)$(OPENSSLDIR)/ct_log_list.cnf; \ 69 | - chmod 644 $(DESTDIR)$(OPENSSLDIR)/ct_log_list.cnf; \ 70 | + cp $(SRCDIR)/apps/ct_log_list.cnf "$(DESTDIR)$(OPENSSLDIR)/ct_log_list.cnf"; \ 71 | + chmod 644 "$(DESTDIR)$(OPENSSLDIR)/ct_log_list.cnf"; \ 72 | fi 73 | 74 | install_dev: install_runtime_libs 75 | @[ -n "$(INSTALLTOP)" ] || (echo INSTALLTOP should not be empty; exit 1) 76 | @$(ECHO) "*** Installing development files" 77 | - @$(PERL) $(SRCDIR)/util/mkdir-p.pl $(DESTDIR)$(INSTALLTOP)/include/openssl 78 | + @$(PERL) $(SRCDIR)/util/mkdir-p.pl "$(DESTDIR)$(INSTALLTOP)/include/openssl" 79 | @ : {- output_off() unless grep { $_ eq "OPENSSL_USE_APPLINK" } (@{$target{defines}}, @{$config{defines}}); "" -} 80 | @$(ECHO) "install $(SRCDIR)/ms/applink.c -> $(DESTDIR)$(INSTALLTOP)/include/openssl/applink.c" 81 | - @cp $(SRCDIR)/ms/applink.c $(DESTDIR)$(INSTALLTOP)/include/openssl/applink.c 82 | - @chmod 644 $(DESTDIR)$(INSTALLTOP)/include/openssl/applink.c 83 | + @cp $(SRCDIR)/ms/applink.c "$(DESTDIR)$(INSTALLTOP)/include/openssl/applink.c" 84 | + @chmod 644 "$(DESTDIR)$(INSTALLTOP)/include/openssl/applink.c" 85 | @ : {- output_on() unless grep { $_ eq "OPENSSL_USE_APPLINK" } (@{$target{defines}}, @{$config{defines}}); "" -} 86 | @set -e; for i in $(SRCDIR)/include/openssl/*.h \ 87 | $(BLDDIR)/include/openssl/*.h; do \ 88 | fn=`basename $$i`; \ 89 | $(ECHO) "install $$i -> $(DESTDIR)$(INSTALLTOP)/include/openssl/$$fn"; \ 90 | - cp $$i $(DESTDIR)$(INSTALLTOP)/include/openssl/$$fn; \ 91 | - chmod 644 $(DESTDIR)$(INSTALLTOP)/include/openssl/$$fn; \ 92 | + cp $$i "$(DESTDIR)$(INSTALLTOP)/include/openssl/$$fn"; \ 93 | + chmod 644 "$(DESTDIR)$(INSTALLTOP)/include/openssl/$$fn"; \ 94 | done 95 | - @$(PERL) $(SRCDIR)/util/mkdir-p.pl $(DESTDIR)$(libdir) 96 | + @$(PERL) $(SRCDIR)/util/mkdir-p.pl "$(DESTDIR)$(libdir)" 97 | @set -e; for l in $(INSTALL_LIBS); do \ 98 | fn=`basename $$l`; \ 99 | $(ECHO) "install $$l -> $(DESTDIR)$(libdir)/$$fn"; \ 100 | - cp $$l $(DESTDIR)$(libdir)/$$fn.new; \ 101 | - $(RANLIB) $(DESTDIR)$(libdir)/$$fn.new; \ 102 | - chmod 644 $(DESTDIR)$(libdir)/$$fn.new; \ 103 | - mv -f $(DESTDIR)$(libdir)/$$fn.new \ 104 | - $(DESTDIR)$(libdir)/$$fn; \ 105 | + cp $$l "$(DESTDIR)$(libdir)/$$fn.new"; \ 106 | + $(RANLIB) "$(DESTDIR)$(libdir)/$$fn.new"; \ 107 | + chmod 644 "$(DESTDIR)$(libdir)/$$fn.new"; \ 108 | + mv -f "$(DESTDIR)$(libdir)/$$fn.new" \ 109 | + "$(DESTDIR)$(libdir)/$$fn"; \ 110 | done 111 | @ : {- output_off() if $disabled{shared}; "" -} 112 | @set -e; for s in $(INSTALL_SHLIB_INFO); do \ 113 | @@ -629,61 +629,61 @@ 114 | : {- output_off(); output_on() unless windowsdll() or sharedaix(); "" -}; \ 115 | if [ "$$fn1" != "$$fn2" ]; then \ 116 | $(ECHO) "link $(DESTDIR)$(libdir)/$$fn2 -> $(DESTDIR)$(libdir)/$$fn1"; \ 117 | - ln -sf $$fn1 $(DESTDIR)$(libdir)/$$fn2; \ 118 | + ln -sf $$fn1 "$(DESTDIR)$(libdir)/$$fn2"; \ 119 | fi; \ 120 | : {- output_off() unless windowsdll() or sharedaix(); output_on() if windowsdll(); "" -}; \ 121 | $(ECHO) "install $$s2 -> $(DESTDIR)$(libdir)/$$fn2"; \ 122 | - cp $$s2 $(DESTDIR)$(libdir)/$$fn2.new; \ 123 | - chmod 755 $(DESTDIR)$(libdir)/$$fn2.new; \ 124 | - mv -f $(DESTDIR)$(libdir)/$$fn2.new \ 125 | - $(DESTDIR)$(libdir)/$$fn2; \ 126 | + cp $$s2 "$(DESTDIR)$(libdir)/$$fn2.new"; \ 127 | + chmod 755 "$(DESTDIR)$(libdir)/$$fn2.new"; \ 128 | + mv -f "$(DESTDIR)$(libdir)/$$fn2.new" \ 129 | + "$(DESTDIR)$(libdir)/$$fn2"; \ 130 | : {- output_off() if windowsdll(); output_on() if sharedaix(); "" -}; \ 131 | - a=$(DESTDIR)$(libdir)/$$fn2; \ 132 | + a="$(DESTDIR)$(libdir)/$$fn2"; \ 133 | $(ECHO) "install $$s1 -> $$a"; \ 134 | - if [ -f $$a ]; then ( trap "rm -rf /tmp/ar.$$$$" INT 0; \ 135 | + if [ -f "$$a" ]; then ( trap "rm -rf /tmp/ar.$$$$" INT 0; \ 136 | mkdir /tmp/ar.$$$$; ( cd /tmp/ar.$$$$; \ 137 | - cp -f $$a $$a.new; \ 138 | - for so in `$(AR) t $$a`; do \ 139 | - $(AR) x $$a $$so; \ 140 | - chmod u+w $$so; \ 141 | - strip -X32_64 -e $$so; \ 142 | - $(AR) r $$a.new $$so; \ 143 | + cp -f "$$a" "$$a.new"; \ 144 | + for so in `$(AR) t "$$a"`; do \ 145 | + $(AR) x "$$a" "$$so"; \ 146 | + chmod u+w "$$so"; \ 147 | + strip -X32_64 -e "$$so"; \ 148 | + $(AR) r "$$a.new" "$$so"; \ 149 | done; \ 150 | )); fi; \ 151 | - $(AR) r $$a.new $$s1; \ 152 | - mv -f $$a.new $$a; \ 153 | + $(AR) r "$$a.new" "$$s1"; \ 154 | + mv -f "$$a.new" "$$a"; \ 155 | : {- output_off() if sharedaix(); output_on(); "" -}; \ 156 | done 157 | @ : {- output_on() if $disabled{shared}; "" -} 158 | - @$(PERL) $(SRCDIR)/util/mkdir-p.pl $(DESTDIR)$(libdir)/pkgconfig 159 | + @$(PERL) $(SRCDIR)/util/mkdir-p.pl "$(DESTDIR)$(libdir)/pkgconfig" 160 | @$(ECHO) "install libcrypto.pc -> $(DESTDIR)$(libdir)/pkgconfig/libcrypto.pc" 161 | - @cp libcrypto.pc $(DESTDIR)$(libdir)/pkgconfig 162 | - @chmod 644 $(DESTDIR)$(libdir)/pkgconfig/libcrypto.pc 163 | + @cp libcrypto.pc "$(DESTDIR)$(libdir)/pkgconfig" 164 | + @chmod 644 "$(DESTDIR)$(libdir)/pkgconfig/libcrypto.pc" 165 | @$(ECHO) "install libssl.pc -> $(DESTDIR)$(libdir)/pkgconfig/libssl.pc" 166 | - @cp libssl.pc $(DESTDIR)$(libdir)/pkgconfig 167 | - @chmod 644 $(DESTDIR)$(libdir)/pkgconfig/libssl.pc 168 | + @cp libssl.pc "$(DESTDIR)$(libdir)/pkgconfig" 169 | + @chmod 644 "$(DESTDIR)$(libdir)/pkgconfig/libssl.pc" 170 | @$(ECHO) "install openssl.pc -> $(DESTDIR)$(libdir)/pkgconfig/openssl.pc" 171 | - @cp openssl.pc $(DESTDIR)$(libdir)/pkgconfig 172 | - @chmod 644 $(DESTDIR)$(libdir)/pkgconfig/openssl.pc 173 | + @cp openssl.pc "$(DESTDIR)$(libdir)/pkgconfig" 174 | + @chmod 644 "$(DESTDIR)$(libdir)/pkgconfig/openssl.pc" 175 | 176 | uninstall_dev: uninstall_runtime_libs 177 | @$(ECHO) "*** Uninstalling development files" 178 | @ : {- output_off() unless grep { $_ eq "OPENSSL_USE_APPLINK" } (@{$target{defines}}, @{$config{defines}}); "" -} 179 | @$(ECHO) "$(RM) $(DESTDIR)$(INSTALLTOP)/include/openssl/applink.c" 180 | - @$(RM) $(DESTDIR)$(INSTALLTOP)/include/openssl/applink.c 181 | + @$(RM) "$(DESTDIR)$(INSTALLTOP)/include/openssl/applink.c" 182 | @ : {- output_on() unless grep { $_ eq "OPENSSL_USE_APPLINK" } (@{$target{defines}}, @{$config{defines}}); "" -} 183 | @set -e; for i in $(SRCDIR)/include/openssl/*.h \ 184 | $(BLDDIR)/include/openssl/*.h; do \ 185 | fn=`basename $$i`; \ 186 | $(ECHO) "$(RM) $(DESTDIR)$(INSTALLTOP)/include/openssl/$$fn"; \ 187 | - $(RM) $(DESTDIR)$(INSTALLTOP)/include/openssl/$$fn; \ 188 | + $(RM) "$(DESTDIR)$(INSTALLTOP)/include/openssl/$$fn"; \ 189 | done 190 | - -$(RMDIR) $(DESTDIR)$(INSTALLTOP)/include/openssl 191 | - -$(RMDIR) $(DESTDIR)$(INSTALLTOP)/include 192 | + -$(RMDIR) "$(DESTDIR)$(INSTALLTOP)/include/openssl" 193 | + -$(RMDIR) "$(DESTDIR)$(INSTALLTOP)/include" 194 | @set -e; for l in $(INSTALL_LIBS); do \ 195 | fn=`basename $$l`; \ 196 | $(ECHO) "$(RM) $(DESTDIR)$(libdir)/$$fn"; \ 197 | - $(RM) $(DESTDIR)$(libdir)/$$fn; \ 198 | + $(RM) "$(DESTDIR)$(libdir)/$$fn"; \ 199 | done 200 | @ : {- output_off() if $disabled{shared}; "" -} 201 | @set -e; for s in $(INSTALL_SHLIB_INFO); do \ 202 | @@ -693,35 +693,35 @@ 203 | fn2=`basename $$s2`; \ 204 | : {- output_off() if windowsdll(); "" -}; \ 205 | $(ECHO) "$(RM) $(DESTDIR)$(libdir)/$$fn2"; \ 206 | - $(RM) $(DESTDIR)$(libdir)/$$fn2; \ 207 | + $(RM) "$(DESTDIR)$(libdir)/$$fn2"; \ 208 | if [ "$$fn1" != "$$fn2" -a -f "$(DESTDIR)$(libdir)/$$fn1" ]; then \ 209 | $(ECHO) "$(RM) $(DESTDIR)$(libdir)/$$fn1"; \ 210 | - $(RM) $(DESTDIR)$(libdir)/$$fn1; \ 211 | + $(RM) "$(DESTDIR)$(libdir)/$$fn1"; \ 212 | fi; \ 213 | : {- output_on() if windowsdll(); "" -}{- output_off() unless windowsdll(); "" -}; \ 214 | $(ECHO) "$(RM) $(DESTDIR)$(libdir)/$$fn2"; \ 215 | - $(RM) $(DESTDIR)$(libdir)/$$fn2; \ 216 | + $(RM) "$(DESTDIR)$(libdir)/$$fn2"; \ 217 | : {- output_on() unless windowsdll(); "" -}; \ 218 | done 219 | @ : {- output_on() if $disabled{shared}; "" -} 220 | - $(RM) $(DESTDIR)$(libdir)/pkgconfig/libcrypto.pc 221 | - $(RM) $(DESTDIR)$(libdir)/pkgconfig/libssl.pc 222 | - $(RM) $(DESTDIR)$(libdir)/pkgconfig/openssl.pc 223 | - -$(RMDIR) $(DESTDIR)$(libdir)/pkgconfig 224 | - -$(RMDIR) $(DESTDIR)$(libdir) 225 | + $(RM) "$(DESTDIR)$(libdir)/pkgconfig/libcrypto.pc" 226 | + $(RM) "$(DESTDIR)$(libdir)/pkgconfig/libssl.pc" 227 | + $(RM) "$(DESTDIR)$(libdir)/pkgconfig/openssl.pc" 228 | + -$(RMDIR) "$(DESTDIR)$(libdir)/pkgconfig" 229 | + -$(RMDIR) "$(DESTDIR)$(libdir)" 230 | 231 | install_engines: install_runtime_libs build_engines 232 | @[ -n "$(INSTALLTOP)" ] || (echo INSTALLTOP should not be empty; exit 1) 233 | - @$(PERL) $(SRCDIR)/util/mkdir-p.pl $(DESTDIR)$(ENGINESDIR)/ 234 | + @$(PERL) $(SRCDIR)/util/mkdir-p.pl "$(DESTDIR)$(ENGINESDIR)/" 235 | @$(ECHO) "*** Installing engines" 236 | @set -e; for e in dummy $(INSTALL_ENGINES); do \ 237 | if [ "$$e" = "dummy" ]; then continue; fi; \ 238 | fn=`basename $$e`; \ 239 | $(ECHO) "install $$e -> $(DESTDIR)$(ENGINESDIR)/$$fn"; \ 240 | - cp $$e $(DESTDIR)$(ENGINESDIR)/$$fn.new; \ 241 | - chmod 755 $(DESTDIR)$(ENGINESDIR)/$$fn.new; \ 242 | - mv -f $(DESTDIR)$(ENGINESDIR)/$$fn.new \ 243 | - $(DESTDIR)$(ENGINESDIR)/$$fn; \ 244 | + cp $$e "$(DESTDIR)$(ENGINESDIR)/$$fn.new"; \ 245 | + chmod 755 "$(DESTDIR)$(ENGINESDIR)/$$fn.new"; \ 246 | + mv -f "$(DESTDIR)$(ENGINESDIR)/$$fn.new" \ 247 | + "$(DESTDIR)$(ENGINESDIR)/$$fn"; \ 248 | done 249 | 250 | uninstall_engines: 251 | @@ -733,18 +733,18 @@ 252 | continue; \ 253 | fi; \ 254 | $(ECHO) "$(RM) $(DESTDIR)$(ENGINESDIR)/$$fn"; \ 255 | - $(RM) $(DESTDIR)$(ENGINESDIR)/$$fn; \ 256 | + $(RM) "$(DESTDIR)$(ENGINESDIR)/$$fn"; \ 257 | done 258 | - -$(RMDIR) $(DESTDIR)$(ENGINESDIR) 259 | + -$(RMDIR) "$(DESTDIR)$(ENGINESDIR)" 260 | 261 | install_runtime: install_programs 262 | 263 | install_runtime_libs: build_libs 264 | @[ -n "$(INSTALLTOP)" ] || (echo INSTALLTOP should not be empty; exit 1) 265 | @ : {- output_off() if windowsdll(); "" -} 266 | - @$(PERL) $(SRCDIR)/util/mkdir-p.pl $(DESTDIR)$(libdir) 267 | + @$(PERL) $(SRCDIR)/util/mkdir-p.pl "$(DESTDIR)$(libdir)" 268 | @ : {- output_on() if windowsdll(); output_off() unless windowsdll(); "" -} 269 | - @$(PERL) $(SRCDIR)/util/mkdir-p.pl $(DESTDIR)$(INSTALLTOP)/bin 270 | + @$(PERL) $(SRCDIR)/util/mkdir-p.pl "$(DESTDIR)$(INSTALLTOP)/bin" 271 | @ : {- output_on() unless windowsdll(); "" -} 272 | @$(ECHO) "*** Installing runtime libraries" 273 | @set -e; for s in dummy $(INSTALL_SHLIBS); do \ 274 | @@ -752,40 +752,40 @@ 275 | fn=`basename $$s`; \ 276 | : {- output_off() unless windowsdll(); "" -}; \ 277 | $(ECHO) "install $$s -> $(DESTDIR)$(INSTALLTOP)/bin/$$fn"; \ 278 | - cp $$s $(DESTDIR)$(INSTALLTOP)/bin/$$fn.new; \ 279 | - chmod 755 $(DESTDIR)$(INSTALLTOP)/bin/$$fn.new; \ 280 | - mv -f $(DESTDIR)$(INSTALLTOP)/bin/$$fn.new \ 281 | - $(DESTDIR)$(INSTALLTOP)/bin/$$fn; \ 282 | + cp $$s "$(DESTDIR)$(INSTALLTOP)/bin/$$fn.new"; \ 283 | + chmod 755 "$(DESTDIR)$(INSTALLTOP)/bin/$$fn.new"; \ 284 | + mv -f "$(DESTDIR)$(INSTALLTOP)/bin/$$fn.new" \ 285 | + "$(DESTDIR)$(INSTALLTOP)/bin/$$fn"; \ 286 | : {- output_on() unless windowsdll(); "" -}{- output_off() if windowsdll(); "" -}; \ 287 | $(ECHO) "install $$s -> $(DESTDIR)$(libdir)/$$fn"; \ 288 | - cp $$s $(DESTDIR)$(libdir)/$$fn.new; \ 289 | - chmod 755 $(DESTDIR)$(libdir)/$$fn.new; \ 290 | - mv -f $(DESTDIR)$(libdir)/$$fn.new \ 291 | - $(DESTDIR)$(libdir)/$$fn; \ 292 | + cp $$s "$(DESTDIR)$(libdir)/$$fn.new"; \ 293 | + chmod 755 "$(DESTDIR)$(libdir)/$$fn.new"; \ 294 | + mv -f "$(DESTDIR)$(libdir)/$$fn.new" \ 295 | + "$(DESTDIR)$(libdir)/$$fn"; \ 296 | : {- output_on() if windowsdll(); "" -}; \ 297 | done 298 | 299 | install_programs: install_runtime_libs build_programs 300 | @[ -n "$(INSTALLTOP)" ] || (echo INSTALLTOP should not be empty; exit 1) 301 | - @$(PERL) $(SRCDIR)/util/mkdir-p.pl $(DESTDIR)$(INSTALLTOP)/bin 302 | + @$(PERL) $(SRCDIR)/util/mkdir-p.pl "$(DESTDIR)$(INSTALLTOP)/bin" 303 | @$(ECHO) "*** Installing runtime programs" 304 | @set -e; for x in dummy $(INSTALL_PROGRAMS); do \ 305 | if [ "$$x" = "dummy" ]; then continue; fi; \ 306 | fn=`basename $$x`; \ 307 | $(ECHO) "install $$x -> $(DESTDIR)$(INSTALLTOP)/bin/$$fn"; \ 308 | - cp $$x $(DESTDIR)$(INSTALLTOP)/bin/$$fn.new; \ 309 | - chmod 755 $(DESTDIR)$(INSTALLTOP)/bin/$$fn.new; \ 310 | - mv -f $(DESTDIR)$(INSTALLTOP)/bin/$$fn.new \ 311 | - $(DESTDIR)$(INSTALLTOP)/bin/$$fn; \ 312 | + cp $$x "$(DESTDIR)$(INSTALLTOP)/bin/$$fn.new"; \ 313 | + chmod 755 "$(DESTDIR)$(INSTALLTOP)/bin/$$fn.new"; \ 314 | + mv -f "$(DESTDIR)$(INSTALLTOP)/bin/$$fn.new" \ 315 | + "$(DESTDIR)$(INSTALLTOP)/bin/$$fn"; \ 316 | done 317 | @set -e; for x in dummy $(BIN_SCRIPTS); do \ 318 | if [ "$$x" = "dummy" ]; then continue; fi; \ 319 | fn=`basename $$x`; \ 320 | $(ECHO) "install $$x -> $(DESTDIR)$(INSTALLTOP)/bin/$$fn"; \ 321 | - cp $$x $(DESTDIR)$(INSTALLTOP)/bin/$$fn.new; \ 322 | - chmod 755 $(DESTDIR)$(INSTALLTOP)/bin/$$fn.new; \ 323 | - mv -f $(DESTDIR)$(INSTALLTOP)/bin/$$fn.new \ 324 | - $(DESTDIR)$(INSTALLTOP)/bin/$$fn; \ 325 | + cp $$x "$(DESTDIR)$(INSTALLTOP)/bin/$$fn.new"; \ 326 | + chmod 755 "$(DESTDIR)$(INSTALLTOP)/bin/$$fn.new"; \ 327 | + mv -f "$(DESTDIR)$(INSTALLTOP)/bin/$$fn.new" \ 328 | + "$(DESTDIR)$(INSTALLTOP)/bin/$$fn"; \ 329 | done 330 | 331 | uninstall_runtime: uninstall_programs uninstall_runtime_libs 332 | @@ -797,16 +797,16 @@ 333 | if [ "$$x" = "dummy" ]; then continue; fi; \ 334 | fn=`basename $$x`; \ 335 | $(ECHO) "$(RM) $(DESTDIR)$(INSTALLTOP)/bin/$$fn"; \ 336 | - $(RM) $(DESTDIR)$(INSTALLTOP)/bin/$$fn; \ 337 | + $(RM) "$(DESTDIR)$(INSTALLTOP)/bin/$$fn"; \ 338 | done; 339 | @set -e; for x in dummy $(BIN_SCRIPTS); \ 340 | do \ 341 | if [ "$$x" = "dummy" ]; then continue; fi; \ 342 | fn=`basename $$x`; \ 343 | $(ECHO) "$(RM) $(DESTDIR)$(INSTALLTOP)/bin/$$fn"; \ 344 | - $(RM) $(DESTDIR)$(INSTALLTOP)/bin/$$fn; \ 345 | + $(RM) "$(DESTDIR)$(INSTALLTOP)/bin/$$fn"; \ 346 | done 347 | - -$(RMDIR) $(DESTDIR)$(INSTALLTOP)/bin 348 | + -$(RMDIR) "$(DESTDIR)$(INSTALLTOP)/bin" 349 | 350 | uninstall_runtime_libs: 351 | @$(ECHO) "*** Uninstalling runtime libraries" 352 | @@ -815,7 +815,7 @@ 353 | if [ "$$s" = "dummy" ]; then continue; fi; \ 354 | fn=`basename $$s`; \ 355 | $(ECHO) "$(RM) $(DESTDIR)$(INSTALLTOP)/bin/$$fn"; \ 356 | - $(RM) $(DESTDIR)$(INSTALLTOP)/bin/$$fn; \ 357 | + $(RM) "$(DESTDIR)$(INSTALLTOP)/bin/$$fn"; \ 358 | done 359 | @ : {- output_on() unless windowsdll(); "" -} 360 | 361 | @@ -824,24 +824,24 @@ 362 | @[ -n "$(INSTALLTOP)" ] || (echo INSTALLTOP should not be empty; exit 1) 363 | @$(ECHO) "*** Installing manpages" 364 | $(PERL) $(SRCDIR)/util/process_docs.pl \ 365 | - --destdir=$(DESTDIR)$(MANDIR) --type=man --suffix=$(MANSUFFIX) 366 | + "--destdir=$(DESTDIR)$(MANDIR)" --type=man --suffix=$(MANSUFFIX) 367 | 368 | uninstall_man_docs: 369 | @$(ECHO) "*** Uninstalling manpages" 370 | $(PERL) $(SRCDIR)/util/process_docs.pl \ 371 | - --destdir=$(DESTDIR)$(MANDIR) --type=man --suffix=$(MANSUFFIX) \ 372 | + "--destdir=$(DESTDIR)$(MANDIR)" --type=man --suffix=$(MANSUFFIX) \ 373 | --remove 374 | 375 | install_html_docs: 376 | @[ -n "$(INSTALLTOP)" ] || (echo INSTALLTOP should not be empty; exit 1) 377 | @$(ECHO) "*** Installing HTML manpages" 378 | $(PERL) $(SRCDIR)/util/process_docs.pl \ 379 | - --destdir=$(DESTDIR)$(HTMLDIR) --type=html 380 | + "--destdir=$(DESTDIR)$(HTMLDIR)" --type=html 381 | 382 | uninstall_html_docs: 383 | @$(ECHO) "*** Uninstalling manpages" 384 | $(PERL) $(SRCDIR)/util/process_docs.pl \ 385 | - --destdir=$(DESTDIR)$(HTMLDIR) --type=html --remove 386 | + "--destdir=$(DESTDIR)$(HTMLDIR)" --type=html --remove 387 | 388 | 389 | # Developer targets (note: these are only available on Unix) ######### 390 | -------------------------------------------------------------------------------- /esy.lock/overrides/af5fc8c4abb1f4c1dce1c179864522b6/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "esy-openssl", 3 | "version": "0.1.0", 4 | "description": "Mirror of OpenSSL", 5 | "license": "Apache 2.0", 6 | "source": "https://github.com/openssl/openssl/archive/OpenSSL_1_1_1d.tar.gz#df0ee4811c87c209ebadb4e6b203d1e560d00f9a", 7 | "override": { 8 | "build": [ 9 | [ 10 | "bash", 11 | "-c", 12 | "#{os == 'windows' ? 'patch -p1 < openssl-1.1.1d-mingw.patch' : 'true'}" 13 | ], 14 | [ 15 | "bash", 16 | "-c", 17 | "#{os == 'windows' ? './configure mingw64 --prefix=$cur__install --cross-compile-prefix=x86_64-w64-mingw32-' : './config --prefix=$cur__install'}" 18 | ], 19 | [ 20 | "make" 21 | ] 22 | ], 23 | "install": [ 24 | [ 25 | "make", 26 | "install" 27 | ] 28 | ], 29 | "buildsInSource": true, 30 | "exportedEnv": { 31 | "OPENSSL_LIB_PATH": { 32 | "val": "#{self.lib}", 33 | "scope": "global" 34 | }, 35 | "OPENSSL_INCLUDE_PATH": { 36 | "val": "#{self.install / 'include'}", 37 | "scope": "global" 38 | }, 39 | "OPENSSL_BIN_PATH": { 40 | "val": "#{self.bin}", 41 | "scope": "global" 42 | }, 43 | "PKG_CONFIG_PATH": { 44 | "val": "#{self.lib / 'pkgconfig'}", 45 | "scope": "global" 46 | } 47 | }, 48 | "dependencies": { 49 | "@opam/conf-autoconf": "esy-packages/esy-autoconf:package.json#fb93edf", 50 | "@opam/conf-pkg-config": "*" 51 | } 52 | } 53 | } 54 | -------------------------------------------------------------------------------- /esy.lock/overrides/opam__s__conf_pkg_config_opam__c__1.1_opam_override/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "build": [ 3 | [ 4 | "pkg-config", 5 | "--help" 6 | ] 7 | ], 8 | "dependencies": { 9 | "yarn-pkg-config": "esy-ocaml/yarn-pkg-config#cca65f99674ed2d954d28788edeb8c57fada5ed0" 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /esy.lock/overrides/opam__s__dune_opam__c__1.11.3_opam_override/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "build": [ 3 | [ 4 | "ocaml", 5 | "bootstrap.ml" 6 | ], 7 | [ 8 | "./boot.exe", 9 | "--release", 10 | "-j", 11 | "4" 12 | ] 13 | ] 14 | } 15 | -------------------------------------------------------------------------------- /esy.lock/overrides/opam__s__num_opam__c__1.2_opam_override/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "build": [ 3 | [ 4 | "make" 5 | ] 6 | ], 7 | "install": [ 8 | [ 9 | "make", 10 | "findlib-install" 11 | ] 12 | ], 13 | "exportedEnv": { 14 | "CAML_LD_LIBRARY_PATH": { 15 | "val": "#{self.install / 'lib' / 'num' : $CAML_LD_LIBRARY_PATH}", 16 | "scope": "global" 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /esy.lock/overrides/opam__s__ocamlbuild_opam__c__0.14.0_opam_override/files/ocamlbuild-0.14.0.patch: -------------------------------------------------------------------------------- 1 | --- ./Makefile 2 | +++ ./Makefile 3 | @@ -213,7 +213,7 @@ 4 | rm -f man/ocamlbuild.1 5 | 6 | man/options_man.byte: src/ocamlbuild_pack.cmo 7 | - $(OCAMLC) $^ -I src man/options_man.ml -o man/options_man.byte 8 | + $(OCAMLC) -I +unix unix.cma $^ -I src man/options_man.ml -o man/options_man.byte 9 | 10 | clean:: 11 | rm -f man/options_man.cm* 12 | --- ./src/command.ml 13 | +++ ./src/command.ml 14 | @@ -148,9 +148,10 @@ 15 | let self = string_of_command_spec_with_calls call_with_tags call_with_target resolve_virtuals in 16 | let b = Buffer.create 256 in 17 | (* The best way to prevent bash from switching to its windows-style 18 | - * quote-handling is to prepend an empty string before the command name. *) 19 | + * quote-handling is to prepend an empty string before the command name. 20 | + * space seems to work, too - and the ouput is nicer *) 21 | if Sys.os_type = "Win32" then 22 | - Buffer.add_string b "''"; 23 | + Buffer.add_char b ' '; 24 | let first = ref true in 25 | let put_space () = 26 | if !first then 27 | @@ -260,7 +261,7 @@ 28 | 29 | let execute_many ?(quiet=false) ?(pretend=false) cmds = 30 | add_parallel_stat (List.length cmds); 31 | - let degraded = !*My_unix.is_degraded || Sys.os_type = "Win32" in 32 | + let degraded = !*My_unix.is_degraded in 33 | let jobs = !jobs in 34 | if jobs < 0 then invalid_arg "jobs < 0"; 35 | let max_jobs = if jobs = 0 then None else Some jobs in 36 | --- ./src/findlib.ml 37 | +++ ./src/findlib.ml 38 | @@ -66,9 +66,6 @@ 39 | (fun command -> lexer & Lexing.from_string & run_and_read command) 40 | command 41 | 42 | -let run_and_read command = 43 | - Printf.ksprintf run_and_read command 44 | - 45 | let rec query name = 46 | try 47 | Hashtbl.find packages name 48 | @@ -135,7 +132,8 @@ 49 | with Not_found -> s 50 | 51 | let list () = 52 | - List.map before_space (split_nl & run_and_read "%s list" ocamlfind) 53 | + let cmd = Shell.quote_filename_if_needed ocamlfind ^ " list" in 54 | + List.map before_space (split_nl & run_and_read cmd) 55 | 56 | (* The closure algorithm is easy because the dependencies are already closed 57 | and sorted for each package. We only have to make the union. We could also 58 | --- ./src/main.ml 59 | +++ ./src/main.ml 60 | @@ -162,6 +162,9 @@ 61 | Tags.mem "traverse" tags 62 | || List.exists (Pathname.is_prefix path_name) !Options.include_dirs 63 | || List.exists (Pathname.is_prefix path_name) target_dirs) 64 | + && ((* beware: !Options.build_dir is an absolute directory *) 65 | + Pathname.normalize !Options.build_dir 66 | + <> Pathname.normalize (Pathname.pwd/path_name)) 67 | end 68 | end 69 | end 70 | --- ./src/my_std.ml 71 | +++ ./src/my_std.ml 72 | @@ -271,13 +271,107 @@ 73 | try Array.iter (fun x -> if x = basename then raise Exit) a; false 74 | with Exit -> true 75 | 76 | +let command_plain = function 77 | +| [| |] -> 0 78 | +| margv -> 79 | + let rec waitpid a b = 80 | + match Unix.waitpid a b with 81 | + | exception (Unix.Unix_error(Unix.EINTR,_,_)) -> waitpid a b 82 | + | x -> x 83 | + in 84 | + let pid = Unix.(create_process margv.(0) margv stdin stdout stderr) in 85 | + let pid', process_status = waitpid [] pid in 86 | + assert (pid = pid'); 87 | + match process_status with 88 | + | Unix.WEXITED n -> n 89 | + | Unix.WSIGNALED _ -> 2 (* like OCaml's uncaught exceptions *) 90 | + | Unix.WSTOPPED _ -> 127 91 | + 92 | +(* can't use Lexers because of circular dependency *) 93 | +let split_path_win str = 94 | + let rec aux pos = 95 | + try 96 | + let i = String.index_from str pos ';' in 97 | + let len = i - pos in 98 | + if len = 0 then 99 | + aux (succ i) 100 | + else 101 | + String.sub str pos (i - pos) :: aux (succ i) 102 | + with Not_found | Invalid_argument _ -> 103 | + let len = String.length str - pos in 104 | + if len = 0 then [] else [String.sub str pos len] 105 | + in 106 | + aux 0 107 | + 108 | +let windows_shell = lazy begin 109 | + let rec iter = function 110 | + | [] -> [| "bash.exe" ; "--norc" ; "--noprofile" |] 111 | + | hd::tl -> 112 | + let dash = Filename.concat hd "dash.exe" in 113 | + if Sys.file_exists dash then [|dash|] else 114 | + let bash = Filename.concat hd "bash.exe" in 115 | + if Sys.file_exists bash = false then iter tl else 116 | + (* if sh.exe and bash.exe exist in the same dir, choose sh.exe *) 117 | + let sh = Filename.concat hd "sh.exe" in 118 | + if Sys.file_exists sh then [|sh|] else [|bash ; "--norc" ; "--noprofile"|] 119 | + in 120 | + split_path_win (try Sys.getenv "PATH" with Not_found -> "") |> iter 121 | +end 122 | + 123 | +let prep_windows_cmd cmd = 124 | + (* workaround known ocaml bug, remove later *) 125 | + if String.contains cmd '\t' && String.contains cmd ' ' = false then 126 | + " " ^ cmd 127 | + else 128 | + cmd 129 | + 130 | +let run_with_shell = function 131 | +| "" -> 0 132 | +| cmd -> 133 | + let cmd = prep_windows_cmd cmd in 134 | + let shell = Lazy.force windows_shell in 135 | + let qlen = Filename.quote cmd |> String.length in 136 | + (* old versions of dash had problems with bs *) 137 | + try 138 | + if qlen < 7_900 then 139 | + command_plain (Array.append shell [| "-ec" ; cmd |]) 140 | + else begin 141 | + (* it can still work, if the called command is a cygwin tool *) 142 | + let ch_closed = ref false in 143 | + let file_deleted = ref false in 144 | + let fln,ch = 145 | + Filename.open_temp_file 146 | + ~mode:[Open_binary] 147 | + "ocamlbuildtmp" 148 | + ".sh" 149 | + in 150 | + try 151 | + let f_slash = String.map ( fun x -> if x = '\\' then '/' else x ) fln in 152 | + output_string ch cmd; 153 | + ch_closed:= true; 154 | + close_out ch; 155 | + let ret = command_plain (Array.append shell [| "-e" ; f_slash |]) in 156 | + file_deleted:= true; 157 | + Sys.remove fln; 158 | + ret 159 | + with 160 | + | x -> 161 | + if !ch_closed = false then 162 | + close_out_noerr ch; 163 | + if !file_deleted = false then 164 | + (try Sys.remove fln with _ -> ()); 165 | + raise x 166 | + end 167 | + with 168 | + | (Unix.Unix_error _) as x -> 169 | + (* Sys.command doesn't raise an exception, so run_with_shell also won't 170 | + raise *) 171 | + Printexc.to_string x ^ ":" ^ cmd |> prerr_endline; 172 | + 1 173 | + 174 | let sys_command = 175 | - match Sys.os_type with 176 | - | "Win32" -> fun cmd -> 177 | - if cmd = "" then 0 else 178 | - let cmd = "bash --norc -c " ^ Filename.quote cmd in 179 | - Sys.command cmd 180 | - | _ -> fun cmd -> if cmd = "" then 0 else Sys.command cmd 181 | + if Sys.win32 then run_with_shell 182 | + else fun cmd -> if cmd = "" then 0 else Sys.command cmd 183 | 184 | (* FIXME warning fix and use Filename.concat *) 185 | let filename_concat x y = 186 | --- ./src/my_std.mli 187 | +++ ./src/my_std.mli 188 | @@ -69,3 +69,6 @@ 189 | 190 | val split_ocaml_version : (int * int * int * string) option 191 | (** (major, minor, patchlevel, rest) *) 192 | + 193 | +val windows_shell : string array Lazy.t 194 | +val prep_windows_cmd : string -> string 195 | --- ./src/ocamlbuild_executor.ml 196 | +++ ./src/ocamlbuild_executor.ml 197 | @@ -34,6 +34,8 @@ 198 | job_stdin : out_channel; 199 | job_stderr : in_channel; 200 | job_buffer : Buffer.t; 201 | + job_pid : int; 202 | + job_tmp_file: string option; 203 | mutable job_dying : bool; 204 | };; 205 | 206 | @@ -76,6 +78,61 @@ 207 | in 208 | loop 0 209 | ;; 210 | + 211 | +let open_process_full_win cmd env = 212 | + let (in_read, in_write) = Unix.pipe () in 213 | + let (out_read, out_write) = Unix.pipe () in 214 | + let (err_read, err_write) = Unix.pipe () in 215 | + Unix.set_close_on_exec in_read; 216 | + Unix.set_close_on_exec out_write; 217 | + Unix.set_close_on_exec err_read; 218 | + let inchan = Unix.in_channel_of_descr in_read in 219 | + let outchan = Unix.out_channel_of_descr out_write in 220 | + let errchan = Unix.in_channel_of_descr err_read in 221 | + let shell = Lazy.force Ocamlbuild_pack.My_std.windows_shell in 222 | + let test_cmd = 223 | + String.concat " " (List.map Filename.quote (Array.to_list shell)) ^ 224 | + "-ec " ^ 225 | + Filename.quote (Ocamlbuild_pack.My_std.prep_windows_cmd cmd) in 226 | + let argv,tmp_file = 227 | + if String.length test_cmd < 7_900 then 228 | + Array.append 229 | + shell 230 | + [| "-ec" ; Ocamlbuild_pack.My_std.prep_windows_cmd cmd |],None 231 | + else 232 | + let fln,ch = Filename.open_temp_file ~mode:[Open_binary] "ocamlbuild" ".sh" in 233 | + output_string ch (Ocamlbuild_pack.My_std.prep_windows_cmd cmd); 234 | + close_out ch; 235 | + let fln' = String.map (function '\\' -> '/' | c -> c) fln in 236 | + Array.append 237 | + shell 238 | + [| "-c" ; fln' |], Some fln in 239 | + let pid = 240 | + Unix.create_process_env argv.(0) argv env out_read in_write err_write in 241 | + Unix.close out_read; 242 | + Unix.close in_write; 243 | + Unix.close err_write; 244 | + (pid, inchan, outchan, errchan,tmp_file) 245 | + 246 | +let close_process_full_win (pid,inchan, outchan, errchan, tmp_file) = 247 | + let delete tmp_file = 248 | + match tmp_file with 249 | + | None -> () 250 | + | Some x -> try Sys.remove x with Sys_error _ -> () in 251 | + let tmp_file_deleted = ref false in 252 | + try 253 | + close_in inchan; 254 | + close_out outchan; 255 | + close_in errchan; 256 | + let res = snd(Unix.waitpid [] pid) in 257 | + tmp_file_deleted := true; 258 | + delete tmp_file; 259 | + res 260 | + with 261 | + | x when tmp_file <> None && !tmp_file_deleted = false -> 262 | + delete tmp_file; 263 | + raise x 264 | + 265 | (* ***) 266 | (*** execute *) 267 | (* XXX: Add test for non reentrancy *) 268 | @@ -130,10 +187,16 @@ 269 | (*** add_job *) 270 | let add_job cmd rest result id = 271 | (*display begin fun oc -> fp oc "Job %a is %s\n%!" print_job_id id cmd; end;*) 272 | - let (stdout', stdin', stderr') = open_process_full cmd env in 273 | + let (pid,stdout', stdin', stderr', tmp_file) = 274 | + if Sys.win32 then open_process_full_win cmd env else 275 | + let a,b,c = open_process_full cmd env in 276 | + -1,a,b,c,None 277 | + in 278 | incr jobs_active; 279 | - set_nonblock (doi stdout'); 280 | - set_nonblock (doi stderr'); 281 | + if not Sys.win32 then ( 282 | + set_nonblock (doi stdout'); 283 | + set_nonblock (doi stderr'); 284 | + ); 285 | let job = 286 | { job_id = id; 287 | job_command = cmd; 288 | @@ -143,7 +206,9 @@ 289 | job_stdin = stdin'; 290 | job_stderr = stderr'; 291 | job_buffer = Buffer.create 1024; 292 | - job_dying = false } 293 | + job_dying = false; 294 | + job_tmp_file = tmp_file; 295 | + job_pid = pid } 296 | in 297 | outputs := FDM.add (doi stdout') job (FDM.add (doi stderr') job !outputs); 298 | jobs := JS.add job !jobs; 299 | @@ -199,6 +264,7 @@ 300 | try 301 | read fd u 0 (Bytes.length u) 302 | with 303 | + | Unix.Unix_error(Unix.EPIPE,_,_) when Sys.win32 -> 0 304 | | Unix.Unix_error(e,_,_) -> 305 | let msg = error_message e in 306 | display (fun oc -> fp oc 307 | @@ -241,14 +307,19 @@ 308 | decr jobs_active; 309 | 310 | (* PR#5371: we would get EAGAIN below otherwise *) 311 | - clear_nonblock (doi job.job_stdout); 312 | - clear_nonblock (doi job.job_stderr); 313 | - 314 | + if not Sys.win32 then ( 315 | + clear_nonblock (doi job.job_stdout); 316 | + clear_nonblock (doi job.job_stderr); 317 | + ); 318 | do_read ~loop:true (doi job.job_stdout) job; 319 | do_read ~loop:true (doi job.job_stderr) job; 320 | outputs := FDM.remove (doi job.job_stdout) (FDM.remove (doi job.job_stderr) !outputs); 321 | jobs := JS.remove job !jobs; 322 | - let status = close_process_full (job.job_stdout, job.job_stdin, job.job_stderr) in 323 | + let status = 324 | + if Sys.win32 then 325 | + close_process_full_win (job.job_pid, job.job_stdout, job.job_stdin, job.job_stderr, job.job_tmp_file) 326 | + else 327 | + close_process_full (job.job_stdout, job.job_stdin, job.job_stderr) in 328 | 329 | let shown = ref false in 330 | 331 | --- ./src/ocamlbuild_unix_plugin.ml 332 | +++ ./src/ocamlbuild_unix_plugin.ml 333 | @@ -48,12 +48,22 @@ 334 | end 335 | 336 | let run_and_open s kont = 337 | + let s_orig = s in 338 | + let s = 339 | + (* Be consistent! My_unix.run_and_open uses My_std.sys_command and 340 | + sys_command uses bash. *) 341 | + if Sys.win32 = false then s else 342 | + let l = match Lazy.force My_std.windows_shell |> Array.to_list with 343 | + | hd::tl -> (Filename.quote hd)::tl 344 | + | _ -> assert false in 345 | + "\"" ^ (String.concat " " l) ^ " -ec " ^ Filename.quote (" " ^ s) ^ "\"" 346 | + in 347 | let ic = Unix.open_process_in s in 348 | let close () = 349 | match Unix.close_process_in ic with 350 | | Unix.WEXITED 0 -> () 351 | | Unix.WEXITED _ | Unix.WSIGNALED _ | Unix.WSTOPPED _ -> 352 | - failwith (Printf.sprintf "Error while running: %s" s) in 353 | + failwith (Printf.sprintf "Error while running: %s" s_orig) in 354 | let res = try 355 | kont ic 356 | with e -> (close (); raise e) 357 | --- ./src/options.ml 358 | +++ ./src/options.ml 359 | @@ -174,11 +174,24 @@ 360 | build_dir := Filename.concat (Sys.getcwd ()) s 361 | else 362 | build_dir := s 363 | + 364 | +let slashify = 365 | + if Sys.win32 then fun p -> String.map (function '\\' -> '/' | x -> x) p 366 | + else fun p ->p 367 | + 368 | +let sb () = 369 | + match Sys.os_type with 370 | + | "Win32" -> 371 | + (try set_binary_mode_out stdout true with _ -> ()); 372 | + | _ -> () 373 | + 374 | + 375 | let spec = ref ( 376 | let print_version () = 377 | + sb (); 378 | Printf.printf "ocamlbuild %s\n%!" Ocamlbuild_config.version; raise Exit_OK 379 | in 380 | - let print_vnum () = print_endline Ocamlbuild_config.version; raise Exit_OK in 381 | + let print_vnum () = sb (); print_endline Ocamlbuild_config.version; raise Exit_OK in 382 | Arg.align 383 | [ 384 | "-version", Unit print_version , " Display the version"; 385 | @@ -257,8 +270,8 @@ 386 | "-build-dir", String set_build_dir, " Set build directory (implies no-links)"; 387 | "-install-lib-dir", Set_string Ocamlbuild_where.libdir, " Set the install library directory"; 388 | "-install-bin-dir", Set_string Ocamlbuild_where.bindir, " Set the install binary directory"; 389 | - "-where", Unit (fun () -> print_endline !Ocamlbuild_where.libdir; raise Exit_OK), " Display the install library directory"; 390 | - "-which", String (fun cmd -> print_endline (find_tool cmd); raise Exit_OK), " Display path to the tool command"; 391 | + "-where", Unit (fun () -> sb (); print_endline (slashify !Ocamlbuild_where.libdir); raise Exit_OK), " Display the install library directory"; 392 | + "-which", String (fun cmd -> sb (); print_endline (slashify (find_tool cmd)); raise Exit_OK), " Display path to the tool command"; 393 | "-ocamlc", set_cmd ocamlc, " Set the OCaml bytecode compiler"; 394 | "-plugin-ocamlc", set_cmd plugin_ocamlc, " Set the OCaml bytecode compiler \ 395 | used when building myocamlbuild.ml (only)"; 396 | --- ./src/pathname.ml 397 | +++ ./src/pathname.ml 398 | @@ -84,6 +84,26 @@ 399 | | x :: xs -> x :: normalize_list xs 400 | 401 | let normalize x = 402 | + let x = 403 | + if Sys.win32 = false then 404 | + x 405 | + else 406 | + let len = String.length x in 407 | + let b = Bytes.create len in 408 | + for i = 0 to pred len do 409 | + match x.[i] with 410 | + | '\\' -> Bytes.set b i '/' 411 | + | c -> Bytes.set b i c 412 | + done; 413 | + if len > 1 then ( 414 | + let c1 = Bytes.get b 0 in 415 | + let c2 = Bytes.get b 1 in 416 | + if c2 = ':' && c1 >= 'a' && c1 <= 'z' && 417 | + ( len = 2 || Bytes.get b 2 = '/') then 418 | + Bytes.set b 0 (Char.uppercase_ascii c1) 419 | + ); 420 | + Bytes.unsafe_to_string b 421 | + in 422 | if Glob.eval not_normal_form_re x then 423 | let root, paths = split x in 424 | join root (normalize_list paths) 425 | --- ./src/shell.ml 426 | +++ ./src/shell.ml 427 | @@ -24,12 +24,26 @@ 428 | | 'a'..'z' | 'A'..'Z' | '0'..'9' | '.' | '-' | '/' | '_' | ':' | '@' | '+' | ',' -> loop (pos + 1) 429 | | _ -> false in 430 | loop 0 431 | + 432 | +let generic_quote quotequote s = 433 | + let l = String.length s in 434 | + let b = Buffer.create (l + 20) in 435 | + Buffer.add_char b '\''; 436 | + for i = 0 to l - 1 do 437 | + if s.[i] = '\'' 438 | + then Buffer.add_string b quotequote 439 | + else Buffer.add_char b s.[i] 440 | + done; 441 | + Buffer.add_char b '\''; 442 | + Buffer.contents b 443 | +let unix_quote = generic_quote "'\\''" 444 | + 445 | let quote_filename_if_needed s = 446 | if is_simple_filename s then s 447 | (* We should probably be using [Filename.unix_quote] except that function 448 | * isn't exported. Users on Windows will have to live with not being able to 449 | * install OCaml into c:\o'caml. Too bad. *) 450 | - else if Sys.os_type = "Win32" then Printf.sprintf "'%s'" s 451 | + else if Sys.os_type = "Win32" then unix_quote s 452 | else Filename.quote s 453 | let chdir dir = 454 | reset_filesys_cache (); 455 | @@ -37,7 +51,7 @@ 456 | let run args target = 457 | reset_readdir_cache (); 458 | let cmd = String.concat " " (List.map quote_filename_if_needed args) in 459 | - if !*My_unix.is_degraded || Sys.os_type = "Win32" then 460 | + if !*My_unix.is_degraded then 461 | begin 462 | Log.event cmd target Tags.empty; 463 | let st = sys_command cmd in 464 | -------------------------------------------------------------------------------- /esy.lock/overrides/opam__s__ocamlbuild_opam__c__0.14.0_opam_override/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "build": [ 3 | [ 4 | "bash", 5 | "-c", 6 | "#{os == 'windows' ? 'patch -p1 < ocamlbuild-0.14.0.patch' : 'true'}" 7 | ], 8 | [ 9 | "make", 10 | "-f", 11 | "configure.make", 12 | "all", 13 | "OCAMLBUILD_PREFIX=#{self.install}", 14 | "OCAMLBUILD_BINDIR=#{self.bin}", 15 | "OCAMLBUILD_LIBDIR=#{self.lib}", 16 | "OCAMLBUILD_MANDIR=#{self.man}", 17 | "OCAMLBUILD_NATIVE=true", 18 | "OCAMLBUILD_NATIVE_TOOLS=true" 19 | ], 20 | [ 21 | "make", 22 | "check-if-preinstalled", 23 | "all", 24 | "#{os == 'windows' ? 'install' : 'opam-install'}" 25 | ] 26 | ] 27 | } 28 | -------------------------------------------------------------------------------- /esy.lock/overrides/opam__s__ocamlfind_opam__c__1.8.1_opam_override/files/findlib-1.8.1.patch: -------------------------------------------------------------------------------- 1 | --- ./Makefile 2 | +++ ./Makefile 3 | @@ -57,16 +57,16 @@ 4 | cat findlib.conf.in | \ 5 | $(SH) tools/patch '@SITELIB@' '$(OCAML_SITELIB)' >findlib.conf 6 | if ./tools/cmd_from_same_dir ocamlc; then \ 7 | - echo 'ocamlc="ocamlc.opt"' >>findlib.conf; \ 8 | + echo 'ocamlc="ocamlc.opt$(EXEC_SUFFIX)"' >>findlib.conf; \ 9 | fi 10 | if ./tools/cmd_from_same_dir ocamlopt; then \ 11 | - echo 'ocamlopt="ocamlopt.opt"' >>findlib.conf; \ 12 | + echo 'ocamlopt="ocamlopt.opt$(EXEC_SUFFIX)"' >>findlib.conf; \ 13 | fi 14 | if ./tools/cmd_from_same_dir ocamldep; then \ 15 | - echo 'ocamldep="ocamldep.opt"' >>findlib.conf; \ 16 | + echo 'ocamldep="ocamldep.opt$(EXEC_SUFFIX)"' >>findlib.conf; \ 17 | fi 18 | if ./tools/cmd_from_same_dir ocamldoc; then \ 19 | - echo 'ocamldoc="ocamldoc.opt"' >>findlib.conf; \ 20 | + echo 'ocamldoc="ocamldoc.opt$(EXEC_SUFFIX)"' >>findlib.conf; \ 21 | fi 22 | 23 | .PHONY: install-doc 24 | --- ./src/findlib/findlib_config.mlp 25 | +++ ./src/findlib/findlib_config.mlp 26 | @@ -24,3 +24,5 @@ 27 | | "MacOS" -> "" (* don't know *) 28 | | _ -> failwith "Unknown Sys.os_type" 29 | ;; 30 | + 31 | +let exec_suffix = "@EXEC_SUFFIX@";; 32 | --- ./src/findlib/findlib.ml 33 | +++ ./src/findlib/findlib.ml 34 | @@ -28,15 +28,20 @@ 35 | let conf_ldconf = ref "";; 36 | let conf_ignore_dups_in = ref ([] : string list);; 37 | 38 | -let ocamlc_default = "ocamlc";; 39 | -let ocamlopt_default = "ocamlopt";; 40 | -let ocamlcp_default = "ocamlcp";; 41 | -let ocamloptp_default = "ocamloptp";; 42 | -let ocamlmklib_default = "ocamlmklib";; 43 | -let ocamlmktop_default = "ocamlmktop";; 44 | -let ocamldep_default = "ocamldep";; 45 | -let ocamlbrowser_default = "ocamlbrowser";; 46 | -let ocamldoc_default = "ocamldoc";; 47 | +let add_exec str = 48 | + match Findlib_config.exec_suffix with 49 | + | "" -> str 50 | + | a -> str ^ a ;; 51 | +let ocamlc_default = add_exec "ocamlc";; 52 | +let ocamlopt_default = add_exec "ocamlopt";; 53 | +let ocamlcp_default = add_exec "ocamlcp";; 54 | +let ocamloptp_default = add_exec "ocamloptp";; 55 | +let ocamlmklib_default = add_exec "ocamlmklib";; 56 | +let ocamlmktop_default = add_exec "ocamlmktop";; 57 | +let ocamldep_default = add_exec "ocamldep";; 58 | +let ocamlbrowser_default = add_exec "ocamlbrowser";; 59 | +let ocamldoc_default = add_exec "ocamldoc";; 60 | + 61 | 62 | 63 | let init_manually 64 | --- ./src/findlib/fl_package_base.ml 65 | +++ ./src/findlib/fl_package_base.ml 66 | @@ -133,7 +133,15 @@ 67 | List.find (fun def -> def.def_var = "exists_if") p.package_defs in 68 | let files = Fl_split.in_words def.def_value in 69 | List.exists 70 | - (fun file -> Sys.file_exists (Filename.concat d' file)) 71 | + (fun file -> 72 | + let fln = Filename.concat d' file in 73 | + let e = Sys.file_exists fln in 74 | + (* necessary for ppx executables *) 75 | + if e || Sys.os_type <> "Win32" || Filename.check_suffix fln ".exe" then 76 | + e 77 | + else 78 | + Sys.file_exists (fln ^ ".exe") 79 | + ) 80 | files 81 | with Not_found -> true in 82 | 83 | --- ./src/findlib/fl_split.ml 84 | +++ ./src/findlib/fl_split.ml 85 | @@ -126,10 +126,17 @@ 86 | | '/' | '\\' -> true 87 | | _ -> false in 88 | let norm_dir_win() = 89 | - if l >= 1 && s.[0] = '/' then 90 | - Buffer.add_char b '\\' else Buffer.add_char b s.[0]; 91 | - if l >= 2 && s.[1] = '/' then 92 | - Buffer.add_char b '\\' else Buffer.add_char b s.[1]; 93 | + if l >= 1 then ( 94 | + if s.[0] = '/' then 95 | + Buffer.add_char b '\\' 96 | + else 97 | + Buffer.add_char b s.[0] ; 98 | + if l >= 2 then 99 | + if s.[1] = '/' then 100 | + Buffer.add_char b '\\' 101 | + else 102 | + Buffer.add_char b s.[1]; 103 | + ); 104 | for k = 2 to l - 1 do 105 | let c = s.[k] in 106 | if is_slash c then ( 107 | --- ./src/findlib/frontend.ml 108 | +++ ./src/findlib/frontend.ml 109 | @@ -31,10 +31,18 @@ 110 | else 111 | Sys_error (arg ^ ": " ^ Unix.error_message code) 112 | 113 | +let is_win = Sys.os_type = "Win32" 114 | + 115 | +let () = 116 | + match Findlib_config.system with 117 | + | "win32" | "win64" | "mingw" | "cygwin" | "mingw64" | "cygwin64" -> 118 | + (try set_binary_mode_out stdout true with _ -> ()); 119 | + (try set_binary_mode_out stderr true with _ -> ()); 120 | + | _ -> () 121 | 122 | let slashify s = 123 | match Findlib_config.system with 124 | - | "mingw" | "mingw64" | "cygwin" -> 125 | + | "win32" | "win64" | "mingw" | "cygwin" | "mingw64" | "cygwin64" -> 126 | let b = Buffer.create 80 in 127 | String.iter 128 | (function 129 | @@ -49,7 +57,7 @@ 130 | 131 | let out_path ?(prefix="") s = 132 | match Findlib_config.system with 133 | - | "mingw" | "mingw64" | "cygwin" -> 134 | + | "win32" | "win64" | "mingw" | "mingw64" | "cygwin" -> 135 | let u = slashify s in 136 | prefix ^ 137 | (if String.contains u ' ' then 138 | @@ -273,11 +281,9 @@ 139 | 140 | 141 | let identify_dir d = 142 | - match Sys.os_type with 143 | - | "Win32" -> 144 | - failwith "identify_dir" (* not available *) 145 | - | _ -> 146 | - let s = Unix.stat d in 147 | + if is_win then 148 | + failwith "identify_dir"; (* not available *) 149 | + let s = Unix.stat d in 150 | (s.Unix.st_dev, s.Unix.st_ino) 151 | ;; 152 | 153 | @@ -459,6 +465,96 @@ 154 | ) 155 | packages 156 | 157 | +let rewrite_cmd s = 158 | + if s = "" || not is_win then 159 | + s 160 | + else 161 | + let s = 162 | + let l = String.length s in 163 | + let b = Buffer.create l in 164 | + for i = 0 to pred l do 165 | + match s.[i] with 166 | + | '/' -> Buffer.add_char b '\\' 167 | + | x -> Buffer.add_char b x 168 | + done; 169 | + Buffer.contents b 170 | + in 171 | + if (Filename.is_implicit s && String.contains s '\\' = false) || 172 | + Filename.check_suffix (String.lowercase s) ".exe" then 173 | + s 174 | + else 175 | + let s' = s ^ ".exe" in 176 | + if Sys.file_exists s' then 177 | + s' 178 | + else 179 | + s 180 | + 181 | +let rewrite_cmd s = 182 | + if s = "" || not is_win then s else 183 | + let s = 184 | + let l = String.length s in 185 | + let b = Buffer.create l in 186 | + for i = 0 to pred l do 187 | + match s.[i] with 188 | + | '/' -> Buffer.add_char b '\\' 189 | + | x -> Buffer.add_char b x 190 | + done; 191 | + Buffer.contents b 192 | + in 193 | + if (Filename.is_implicit s && String.contains s '\\' = false) || 194 | + Filename.check_suffix (String.lowercase s) ".exe" then 195 | + s 196 | + else 197 | + let s' = s ^ ".exe" in 198 | + if Sys.file_exists s' then 199 | + s' 200 | + else 201 | + s 202 | + 203 | +let rewrite_pp cmd = 204 | + if not is_win then cmd else 205 | + let module T = struct exception Keep end in 206 | + let is_whitespace = function 207 | + | ' ' | '\011' | '\012' | '\n' | '\r' | '\t' -> true 208 | + | _ -> false in 209 | + (* characters that triggers special behaviour (cmd.exe, not unix shell) *) 210 | + let is_unsafe_char = function 211 | + | '(' | ')' | '%' | '!' | '^' | '<' | '>' | '&' -> true 212 | + | _ -> false in 213 | + let len = String.length cmd in 214 | + let buf = Buffer.create (len + 4) in 215 | + let buf_cmd = Buffer.create len in 216 | + let rec iter_ws i = 217 | + if i >= len then () else 218 | + let cur = cmd.[i] in 219 | + if is_whitespace cur then ( 220 | + Buffer.add_char buf cur; 221 | + iter_ws (succ i) 222 | + ) 223 | + else 224 | + iter_cmd i 225 | + and iter_cmd i = 226 | + if i >= len then add_buf_cmd () else 227 | + let cur = cmd.[i] in 228 | + if is_unsafe_char cur || cur = '"' || cur = '\'' then 229 | + raise T.Keep; 230 | + if is_whitespace cur then ( 231 | + add_buf_cmd (); 232 | + Buffer.add_substring buf cmd i (len - i) 233 | + ) 234 | + else ( 235 | + Buffer.add_char buf_cmd cur; 236 | + iter_cmd (succ i) 237 | + ) 238 | + and add_buf_cmd () = 239 | + if Buffer.length buf_cmd > 0 then 240 | + Buffer.add_string buf (rewrite_cmd (Buffer.contents buf_cmd)) 241 | + in 242 | + try 243 | + iter_ws 0; 244 | + Buffer.contents buf 245 | + with 246 | + | T.Keep -> cmd 247 | 248 | let process_pp_spec syntax_preds packages pp_opts = 249 | (* Returns: pp_command *) 250 | @@ -549,7 +645,7 @@ 251 | None -> [] 252 | | Some cmd -> 253 | ["-pp"; 254 | - cmd ^ " " ^ 255 | + (rewrite_cmd cmd) ^ " " ^ 256 | String.concat " " (List.map Filename.quote pp_i_options) ^ " " ^ 257 | String.concat " " (List.map Filename.quote pp_archives) ^ " " ^ 258 | String.concat " " (List.map Filename.quote pp_opts)] 259 | @@ -625,9 +721,11 @@ 260 | in 261 | try 262 | let preprocessor = 263 | + rewrite_cmd ( 264 | resolve_path 265 | ~base ~explicit:true 266 | - (package_property predicates pname "ppx") in 267 | + (package_property predicates pname "ppx") ) 268 | + in 269 | ["-ppx"; String.concat " " (preprocessor :: options)] 270 | with Not_found -> [] 271 | ) 272 | @@ -895,6 +993,14 @@ 273 | switch (e.g. -L instead of -L ) 274 | *) 275 | 276 | +(* We may need to remove files on which we do not have complete control. 277 | + On Windows, removing a read-only file fails so try to change the 278 | + mode of the file first. *) 279 | +let remove_file fname = 280 | + try Sys.remove fname 281 | + with Sys_error _ when is_win -> 282 | + (try Unix.chmod fname 0o666 with Unix.Unix_error _ -> ()); 283 | + Sys.remove fname 284 | 285 | let ocamlc which () = 286 | 287 | @@ -1022,9 +1128,12 @@ 288 | 289 | "-intf", 290 | Arg.String (fun s -> pass_files := !pass_files @ [ Intf(slashify s) ]); 291 | - 292 | + 293 | "-pp", 294 | - Arg.String (fun s -> pp_specified := true; add_spec_fn "-pp" s); 295 | + Arg.String (fun s -> pp_specified := true; add_spec_fn "-pp" (rewrite_pp s)); 296 | + 297 | + "-ppx", 298 | + Arg.String (fun s -> add_spec_fn "-ppx" (rewrite_pp s)); 299 | 300 | "-thread", 301 | Arg.Unit (fun _ -> threads := threads_default); 302 | @@ -1237,7 +1346,7 @@ 303 | with 304 | any -> 305 | close_out initl; 306 | - Sys.remove initl_file_name; 307 | + remove_file initl_file_name; 308 | raise any 309 | end; 310 | 311 | @@ -1245,9 +1354,9 @@ 312 | at_exit 313 | (fun () -> 314 | let tr f x = try f x with _ -> () in 315 | - tr Sys.remove initl_file_name; 316 | - tr Sys.remove (Filename.chop_extension initl_file_name ^ ".cmi"); 317 | - tr Sys.remove (Filename.chop_extension initl_file_name ^ ".cmo"); 318 | + tr remove_file initl_file_name; 319 | + tr remove_file (Filename.chop_extension initl_file_name ^ ".cmi"); 320 | + tr remove_file (Filename.chop_extension initl_file_name ^ ".cmo"); 321 | ); 322 | 323 | let exclude_list = [ stdlibdir; threads_dir; vmthreads_dir ] in 324 | @@ -1493,7 +1602,9 @@ 325 | [ "-v", Arg.Unit (fun () -> verbose := Verbose); 326 | "-pp", Arg.String (fun s -> 327 | pp_specified := true; 328 | - options := !options @ ["-pp"; s]); 329 | + options := !options @ ["-pp"; rewrite_pp s]); 330 | + "-ppx", Arg.String (fun s -> 331 | + options := !options @ ["-ppx"; rewrite_pp s]); 332 | ] 333 | ) 334 | ) 335 | @@ -1672,7 +1783,9 @@ 336 | Arg.String (fun s -> add_spec_fn "-I" (slashify (resolve_path s))); 337 | 338 | "-pp", Arg.String (fun s -> pp_specified := true; 339 | - add_spec_fn "-pp" s); 340 | + add_spec_fn "-pp" (rewrite_pp s)); 341 | + "-ppx", Arg.String (fun s -> add_spec_fn "-ppx" (rewrite_pp s)); 342 | + 343 | ] 344 | ) 345 | ) 346 | @@ -1830,7 +1943,10 @@ 347 | output_string ch_out append; 348 | close_out ch_out; 349 | close_in ch_in; 350 | - Unix.utimes outpath s.Unix.st_mtime s.Unix.st_mtime; 351 | + (try Unix.utimes outpath s.Unix.st_mtime s.Unix.st_mtime 352 | + with Unix.Unix_error(e,_,_) -> 353 | + prerr_endline("Warning: setting utimes for " ^ outpath 354 | + ^ ": " ^ Unix.error_message e)); 355 | 356 | prerr_endline("Installed " ^ outpath); 357 | with 358 | @@ -1882,6 +1998,8 @@ 359 | Unix.openfile (Filename.concat dir owner_file) [Unix.O_RDONLY] 0 in 360 | let f = 361 | Unix.in_channel_of_descr fd in 362 | + if is_win then 363 | + set_binary_mode_in f false; 364 | try 365 | let line = input_line f in 366 | let is_my_file = (line = pkg) in 367 | @@ -2208,7 +2326,7 @@ 368 | let lines = read_ldconf !ldconf in 369 | let dlldir_norm = Fl_split.norm_dir dlldir in 370 | let dlldir_norm_lc = string_lowercase_ascii dlldir_norm in 371 | - let ci_filesys = (Sys.os_type = "Win32") in 372 | + let ci_filesys = is_win in 373 | let check_dir d = 374 | let d' = Fl_split.norm_dir d in 375 | (d' = dlldir_norm) || 376 | @@ -2356,7 +2474,7 @@ 377 | List.iter 378 | (fun file -> 379 | let absfile = Filename.concat dlldir file in 380 | - Sys.remove absfile; 381 | + remove_file absfile; 382 | prerr_endline ("Removed " ^ absfile) 383 | ) 384 | dll_files 385 | @@ -2365,7 +2483,7 @@ 386 | (* Remove the files from the package directory: *) 387 | if Sys.file_exists pkgdir then begin 388 | let files = Sys.readdir pkgdir in 389 | - Array.iter (fun f -> Sys.remove (Filename.concat pkgdir f)) files; 390 | + Array.iter (fun f -> remove_file (Filename.concat pkgdir f)) files; 391 | Unix.rmdir pkgdir; 392 | prerr_endline ("Removed " ^ pkgdir) 393 | end 394 | @@ -2415,7 +2533,9 @@ 395 | 396 | 397 | let print_configuration() = 398 | + let sl = slashify in 399 | let dir s = 400 | + let s = sl s in 401 | if Sys.file_exists s then 402 | s 403 | else 404 | @@ -2453,27 +2573,27 @@ 405 | if md = "" then "the corresponding package directories" else dir md 406 | ); 407 | Printf.printf "The standard library is assumed to reside in:\n %s\n" 408 | - (Findlib.ocaml_stdlib()); 409 | + (sl (Findlib.ocaml_stdlib())); 410 | Printf.printf "The ld.conf file can be found here:\n %s\n" 411 | - (Findlib.ocaml_ldconf()); 412 | + (sl (Findlib.ocaml_ldconf())); 413 | flush stdout 414 | | Some "conf" -> 415 | - print_endline (Findlib.config_file()) 416 | + print_endline (sl (Findlib.config_file())) 417 | | Some "path" -> 418 | - List.iter print_endline (Findlib.search_path()) 419 | + List.iter ( fun x -> print_endline (sl x)) (Findlib.search_path()) 420 | | Some "destdir" -> 421 | - print_endline (Findlib.default_location()) 422 | + print_endline ( sl (Findlib.default_location())) 423 | | Some "metadir" -> 424 | - print_endline (Findlib.meta_directory()) 425 | + print_endline ( sl (Findlib.meta_directory())) 426 | | Some "metapath" -> 427 | let mdir = Findlib.meta_directory() in 428 | let ddir = Findlib.default_location() in 429 | - print_endline 430 | - (if mdir <> "" then mdir ^ "/META.%s" else ddir ^ "/%s/META") 431 | + print_endline ( sl 432 | + (if mdir <> "" then mdir ^ "/META.%s" else ddir ^ "/%s/META")) 433 | | Some "stdlib" -> 434 | - print_endline (Findlib.ocaml_stdlib()) 435 | + print_endline ( sl (Findlib.ocaml_stdlib())) 436 | | Some "ldconf" -> 437 | - print_endline (Findlib.ocaml_ldconf()) 438 | + print_endline ( sl (Findlib.ocaml_ldconf())) 439 | | _ -> 440 | assert false 441 | ;; 442 | @@ -2481,7 +2601,7 @@ 443 | 444 | let ocamlcall pkg cmd = 445 | let dir = package_directory pkg in 446 | - let path = Filename.concat dir cmd in 447 | + let path = rewrite_cmd (Filename.concat dir cmd) in 448 | begin 449 | try Unix.access path [ Unix.X_OK ] 450 | with 451 | @@ -2647,6 +2767,10 @@ 452 | | Sys_error f -> 453 | prerr_endline ("ocamlfind: " ^ f); 454 | exit 2 455 | + | Unix.Unix_error (e, fn, f) -> 456 | + prerr_endline ("ocamlfind: " ^ fn ^ " " ^ f 457 | + ^ ": " ^ Unix.error_message e); 458 | + exit 2 459 | | Findlib.No_such_package(pkg,info) -> 460 | prerr_endline ("ocamlfind: Package `" ^ pkg ^ "' not found" ^ 461 | (if info <> "" then " - " ^ info else "")); 462 | --- ./src/findlib/Makefile 463 | +++ ./src/findlib/Makefile 464 | @@ -90,6 +90,7 @@ 465 | cat findlib_config.mlp | \ 466 | $(SH) $(TOP)/tools/patch '@CONFIGFILE@' '$(OCAMLFIND_CONF)' | \ 467 | $(SH) $(TOP)/tools/patch '@STDLIB@' '$(OCAML_CORE_STDLIB)' | \ 468 | + $(SH) $(TOP)/tools/patch '@EXEC_SUFFIX@' '$(EXEC_SUFFIX)' | \ 469 | sed -e 's;@AUTOLINK@;$(OCAML_AUTOLINK);g' \ 470 | -e 's;@SYSTEM@;$(SYSTEM);g' \ 471 | >findlib_config.ml 472 | -------------------------------------------------------------------------------- /esy.lock/overrides/opam__s__ocamlfind_opam__c__1.8.1_opam_override/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "build": [ 3 | [ 4 | "bash", 5 | "-c", 6 | "#{os == 'windows' ? 'patch -p1 < findlib-1.8.1.patch' : 'true'}" 7 | ], 8 | [ 9 | "./configure", 10 | "-bindir", 11 | "#{self.bin}", 12 | "-sitelib", 13 | "#{self.lib}", 14 | "-mandir", 15 | "#{self.man}", 16 | "-config", 17 | "#{self.lib}/findlib.conf", 18 | "-no-custom", 19 | "-no-topfind" 20 | ], 21 | [ 22 | "make", 23 | "all" 24 | ], 25 | [ 26 | "make", 27 | "opt" 28 | ] 29 | ], 30 | "install": [ 31 | [ 32 | "make", 33 | "install" 34 | ], 35 | [ 36 | "install", 37 | "-m", 38 | "0755", 39 | "ocaml-stub", 40 | "#{self.bin}/ocaml" 41 | ], 42 | [ 43 | "mkdir", 44 | "-p", 45 | "#{self.toplevel}" 46 | ], 47 | [ 48 | "install", 49 | "-m", 50 | "0644", 51 | "src/findlib/topfind", 52 | "#{self.toplevel}/topfind" 53 | ] 54 | ], 55 | "exportedEnv": { 56 | "OCAML_TOPLEVEL_PATH": { 57 | "val": "#{self.toplevel}", 58 | "scope": "global" 59 | } 60 | } 61 | } 62 | -------------------------------------------------------------------------------- /esy.lock/overrides/opam__s__ocplib_endian_opam__c__1.0_opam_override/files/esy-fix.patch: -------------------------------------------------------------------------------- 1 | --- ./setup.ml 2 | +++ ./setup.ml 3 | @@ -6331,9 +6331,7 @@ 4 | [ 5 | "-classic-display"; 6 | "-no-log"; 7 | - "-no-links"; 8 | - "-install-lib-dir"; 9 | - (Filename.concat (standard_library ()) "ocamlbuild") 10 | + "-no-links" 11 | ] 12 | else 13 | []; 14 | -------------------------------------------------------------------------------- /esy.lock/overrides/opam__s__ocplib_endian_opam__c__1.0_opam_override/files/ocplib-endian-0.8.patch: -------------------------------------------------------------------------------- 1 | --- ./myocamlbuild.ml 2 | +++ ./myocamlbuild.ml 3 | @@ -573,6 +573,24 @@ 4 | Add a dependency after dropping support for 4.01 and earlier. *) 5 | let dispatch_cppo = function 6 | | After_rules -> begin 7 | + let is_directory s = 8 | + let slen = String.length s in 9 | + let s = 10 | + if Sys.os_type <> "Win32" || slen < 2 then 11 | + s 12 | + else 13 | + match s.[slen-1] with 14 | + | '\\' | '/' -> 15 | + if slen <> 3 || s.[1] <> ':' then 16 | + String.sub s 0 (slen -1) 17 | + else 18 | + (match s.[0] with 19 | + | 'A' .. 'Z' | 'a' .. 'z' -> s 20 | + | _ -> String.sub s 0 (slen -1)) 21 | + | _ -> s 22 | + in 23 | + Pathname.is_directory s 24 | + in 25 | let cppo_rules ext = 26 | let dep = "%(name).cppo"-.-ext 27 | and prod1 = "%(name: <*> and not <*.cppo>)"-.-ext 28 | @@ -591,11 +609,11 @@ 29 | pflag ["cppo"] "cppo_D" (fun s -> S [A "-D"; A s]) ; 30 | pflag ["cppo"] "cppo_U" (fun s -> S [A "-U"; A s]) ; 31 | pflag ["cppo"] "cppo_I" (fun s -> 32 | - if Pathname.is_directory s then S [A "-I"; P s] 33 | + if is_directory s then S [A "-I"; P s] 34 | else S [A "-I"; P (Pathname.dirname s)] 35 | ) ; 36 | pdep ["cppo"] "cppo_I" (fun s -> 37 | - if Pathname.is_directory s then [] else [s]) ; 38 | + if is_directory s then [] else [s]) ; 39 | flag ["cppo"; "cppo_q"] (A "-q") ; 40 | flag ["cppo"; "cppo_s"] (A "-s") ; 41 | flag ["cppo"; "cppo_n"] (A "-n") ; 42 | -------------------------------------------------------------------------------- /esy.lock/overrides/opam__s__ocplib_endian_opam__c__1.0_opam_override/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "build": [ 3 | [ 4 | "bash", 5 | "-c", 6 | "#{os == 'windows' ? 'patch -p1 < ocplib-endian-0.8.patch' : 'true'}" 7 | ], 8 | [ 9 | "bash", 10 | "-c", 11 | "#{os == 'windows' ? 'patch -p1 < esy-fix.patch' : 'true'}" 12 | ], 13 | [ 14 | "ocaml", 15 | "setup.ml", 16 | "-configure", 17 | "--disable-debug", 18 | "--prefix", 19 | "#{self.install}" 20 | ], 21 | [ 22 | "ocaml", 23 | "setup.ml", 24 | "-build" 25 | ] 26 | ], 27 | "install": [ 28 | [ 29 | "ocaml", 30 | "setup.ml", 31 | "-install" 32 | ] 33 | ] 34 | } 35 | -------------------------------------------------------------------------------- /now.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "github-stars", 3 | "alias": "github-stars", 4 | "version": 2, 5 | "builds": [ 6 | { 7 | "src": "bootstrap", 8 | "use": "now-custom-runtime" 9 | } 10 | ], 11 | "routes": [ 12 | { 13 | "src": ".*", 14 | "dest": "/bootstrap" 15 | } 16 | ] 17 | } 18 | -------------------------------------------------------------------------------- /src/dune: -------------------------------------------------------------------------------- 1 | (executable 2 | (name lambda) 3 | (libraries lambda-runtime now h2-lwt-unix h2 lwt_ssl logs.fmt fmt.tty cow 4 | uri) 5 | (preprocess 6 | (pps graphql_ppx ppxlib.runner))) 7 | 8 | (env 9 | (static 10 | (flags 11 | (:standard -ccopt -static)))) 12 | -------------------------------------------------------------------------------- /src/lambda.re: -------------------------------------------------------------------------------- 1 | open Lwt.Infix; 2 | 3 | module Html = Cow.Html; 4 | module Json = { 5 | include Yojson.Safe.Util; 6 | 7 | let member_opt = (m, t) => 8 | try(Some(member(m, t))) { 9 | | _ => None 10 | }; 11 | }; 12 | 13 | type stargazer = { 14 | login: string, 15 | name: option(string), 16 | avatar: string, 17 | }; 18 | 19 | type starsInfo = { 20 | count: int, 21 | stargazers: list(stargazer), 22 | }; 23 | 24 | type repo = { 25 | nameWithOwner: string, 26 | stars: starsInfo, 27 | }; 28 | 29 | module MyQuery = [%graphql 30 | {| 31 | query ($name: String!, $owner: String!, $first: Int!, $token: String!) { 32 | gitHub( 33 | auths: { 34 | gitHubOAuthToken: $token 35 | } 36 | ) { 37 | repository( 38 | name: $name 39 | owner: $owner 40 | ) { 41 | id 42 | nameWithOwner 43 | stargazers( 44 | orderBy: { direction: DESC, field: STARRED_AT } 45 | first: $first 46 | ) { 47 | edges { 48 | node { 49 | id 50 | login 51 | avatarUrl 52 | name 53 | } 54 | } 55 | totalCount 56 | } 57 | } 58 | } 59 | } 60 | |} 61 | ]; 62 | 63 | let send_response = (reqd, body) => { 64 | open Now; 65 | let response = 66 | Response.create( 67 | ~headers=Headers.of_list([("content-type", "text/html")]), 68 | `OK, 69 | ); 70 | Now.Reqd.respond_with_string(reqd, response, body); 71 | }; 72 | 73 | let send_error_response = (reqd, msg) => { 74 | open Now; 75 | let response = 76 | Response.create( 77 | ~headers=Headers.of_list([("content-type", "text/html")]), 78 | `Bad_request, 79 | ); 80 | Now.Reqd.respond_with_string(reqd, response, msg); 81 | }; 82 | 83 | let getGraphQLResponse = (~first=?, ~name, ~owner) => { 84 | let first = 85 | switch (first) { 86 | | None => 10 87 | | Some(s) => 88 | switch (int_of_string_opt(s)) { 89 | | Some(n) => n 90 | | None => 10 91 | } 92 | }; 93 | let q = 94 | MyQuery.make( 95 | ~name, 96 | ~owner, 97 | ~first, 98 | ~token=Request.private_github_token, 99 | (), 100 | ); 101 | let queryJson = 102 | `Assoc([("query", `String(q#query)), ("variables", q#variables)]); 103 | let reqBody = Yojson.Safe.to_string(queryJson); 104 | let uri = "https://serve.onegraph.com/dynamic?app_id=eaf48ccf-cb5b-4a5b-866e-d223e60cfea7"; 105 | Request.send( 106 | uri, 107 | ~meth=`POST, 108 | ~body=reqBody, 109 | ~additional_headers=[ 110 | ("content-length", string_of_int(String.length(reqBody))), 111 | ], 112 | ) 113 | >|= ( 114 | res => { 115 | let json_result = Yojson.Safe.from_string(res); 116 | switch (Json.member_opt("data", json_result)) { 117 | | Some(data) => 118 | let data = q#parse(data); 119 | switch (data#gitHub) { 120 | | Some(github) => 121 | switch (github#repository) { 122 | | Some(repo) => 123 | let starsInfo = repo#stargazers; 124 | let starsCount = starsInfo#totalCount; 125 | switch (starsInfo#edges) { 126 | | Some(stargazers) => 127 | let stargazers = 128 | Array.fold_left( 129 | acc => 130 | fun 131 | | None => acc 132 | | Some(i) => { 133 | let node = i#node; 134 | [ 135 | { 136 | name: node#name, 137 | login: node#login, 138 | avatar: node#avatarUrl, 139 | }, 140 | ...acc, 141 | ]; 142 | }, 143 | [], 144 | stargazers, 145 | ); 146 | Ok({ 147 | nameWithOwner: repo#nameWithOwner, 148 | stars: { 149 | count: starsCount, 150 | stargazers: List.rev(stargazers), 151 | }, 152 | }); 153 | | None => Error("There was an error getting your data.") 154 | }; 155 | | None => Error("There was an error getting your data.") 156 | } 157 | | None => Error("There was an error getting your data.") 158 | }; 159 | | None => Error("There was an error getting your data.") 160 | }; 161 | } 162 | ); 163 | }; 164 | 165 | let handle_result = reqd => 166 | fun 167 | | Error(msg) => send_error_response(reqd, msg) 168 | | Ok({nameWithOwner, stars: {count, stargazers}, _}) => { 169 | let buf = Buffer.create(100); 170 | Html.( 171 | output_doc( 172 | `Buffer(buf), 173 | html( 174 | list([ 175 | head(meta(~charset="UTF-8", [])), 176 | body( 177 | list([ 178 | h1( 179 | string( 180 | Format.asprintf( 181 | "Stargazer summary for: %s", 182 | nameWithOwner, 183 | ), 184 | ), 185 | ), 186 | h2( 187 | string( 188 | Format.asprintf("Total number of stars: %d", count), 189 | ), 190 | ), 191 | list( 192 | List.map( 193 | ({avatar, login, name}) => 194 | div( 195 | ~attrs=[ 196 | ("style", "display:flex;align-items:center"), 197 | ], 198 | list([ 199 | img(~height=100, Uri.of_string(avatar)), 200 | span( 201 | ~attrs=[("style", "margin-left:20px")], 202 | string( 203 | switch (name) { 204 | | None 205 | | Some("") => login 206 | | Some(name) => 207 | Format.asprintf("%s (%s)", name, login) 208 | }, 209 | ), 210 | ), 211 | ]), 212 | ), 213 | stargazers, 214 | ), 215 | ), 216 | ]), 217 | ), 218 | ]), 219 | ), 220 | ) 221 | ); 222 | send_response(reqd, Buffer.contents(buf)); 223 | }; 224 | 225 | let handle = (~first=?, ~name, ~owner, reqd) => { 226 | getGraphQLResponse(~first?, ~name, ~owner) >|= handle_result(reqd); 227 | }; 228 | 229 | let handler = (reqd, _ctx) => { 230 | let {Httpaf.Request.target, _} = Now.Reqd.request(reqd); 231 | let usage = "Usage: github-stars.anmonteiro.now.sh/?repo=username/repo"; 232 | let uri = Uri.of_string(target); 233 | switch (Uri.(get_query_param(uri, "repo"))) { 234 | | Some(repo) => 235 | switch (String.split_on_char('/', repo)) { 236 | | [owner, name] => 237 | handle(~first=?Uri.get_query_param(uri, "first"), ~owner, ~name, reqd) 238 | | _ => Lwt.return(send_error_response(reqd, usage)) 239 | } 240 | | None => Lwt.return(send_error_response(reqd, usage)) 241 | }; 242 | }; 243 | 244 | let () = Now.io_lambda(handler); 245 | -------------------------------------------------------------------------------- /src/request.ml: -------------------------------------------------------------------------------- 1 | open Lwt.Infix 2 | open H2 3 | 4 | let () = begin 5 | Ssl_threads.init (); 6 | Ssl.init () 7 | end 8 | 9 | let default_ctx = Ssl.create_context Ssl.SSLv23 Ssl.Client_context 10 | let () = begin 11 | Ssl.disable_protocols default_ctx [Ssl.SSLv23]; 12 | Ssl.set_context_alpn_protos default_ctx [ "h2" ]; 13 | Ssl.honor_cipher_order default_ctx; 14 | (* Ssl.use_bug_workarounds default_ctx; *) 15 | end 16 | 17 | let connect ?(ctx=default_ctx) ?src ?hostname sa = 18 | fun fd -> 19 | (match src with 20 | | None -> Lwt.return_unit 21 | | Some src_sa -> Lwt_unix.bind fd src_sa 22 | ) >>= fun () -> 23 | Lwt_unix.connect fd sa >>= fun () -> 24 | begin match hostname with 25 | | Some host -> 26 | let s = Lwt_ssl.embed_uninitialized_socket fd ctx in 27 | Ssl.set_client_SNI_hostname 28 | (Lwt_ssl.ssl_socket_of_uninitialized_socket s) host; 29 | Lwt_ssl.ssl_perform_handshake s 30 | | None -> 31 | Lwt_ssl.ssl_connect fd ctx 32 | end 33 | 34 | type body = 35 | | Body of string 36 | | Response of Response.t * [`read] Body.t 37 | 38 | let send_request ~meth ~additional_headers ?body uri = 39 | let open H2_lwt_unix in 40 | let response_handler notify_response_received response response_body = 41 | Lwt.wakeup_later notify_response_received (Ok (Response (response, response_body))) 42 | in 43 | let error_handler notify_response_received error = 44 | let error_str = match error with 45 | | `Malformed_response s -> s 46 | | `Exn exn -> Printexc.to_string exn 47 | | `Protocol_error -> "Protocol Error" 48 | | `Invalid_response_body_length r -> Format.asprintf "%a" Response.pp_hum r 49 | in 50 | Lwt.wakeup notify_response_received (Error error_str) 51 | in 52 | let host = Uri.host_with_default uri in 53 | Lwt_unix.getaddrinfo host "443" [Unix.(AI_FAMILY PF_INET)] 54 | >>= fun addresses -> 55 | let sa = (List.hd addresses).Unix.ai_addr in 56 | let fd = Lwt_unix.socket Unix.PF_INET Unix.SOCK_STREAM 0 in 57 | 58 | connect 59 | ~hostname:host 60 | sa fd >>= fun ssl_client -> 61 | 62 | let request_headers = Request.create 63 | meth 64 | ~scheme:"https" 65 | (Uri.path_and_query uri) 66 | ~headers:(Headers.of_list ([ 67 | ":authority", host; 68 | ] @ additional_headers)) 69 | in 70 | 71 | let response_received, notify_response_received = Lwt.wait () in 72 | let response_handler = response_handler notify_response_received in 73 | let error_received, notify_error_received = Lwt.wait () in 74 | let error_handler = error_handler notify_error_received in 75 | 76 | Client.SSL.create_connection 77 | ~client:ssl_client 78 | ~error_handler 79 | fd 80 | >>= fun conn -> 81 | let request_body = 82 | Client.SSL.request 83 | conn 84 | request_headers 85 | ~error_handler 86 | ~response_handler 87 | in 88 | begin match body with 89 | | Some body -> Body.write_string request_body body 90 | | None -> () 91 | end; 92 | Body.flush request_body (fun () -> 93 | Body.close_writer request_body); 94 | Lwt.return(response_received, error_received) 95 | 96 | let read_response response_body = 97 | let buf = Buffer.create 0x2000 in 98 | let body_read, notify_body_read = Lwt.wait () in 99 | let rec read_fn () = 100 | Body.schedule_read 101 | response_body 102 | ~on_eof:(fun () -> 103 | Body.close_reader response_body; 104 | Lwt.wakeup_later notify_body_read (Ok (Body (Buffer.contents buf)))) 105 | ~on_read:(fun response_fragment ~off ~len -> 106 | let response_fragment_bytes = Bytes.create len in 107 | Lwt_bytes.blit_to_bytes 108 | response_fragment off 109 | response_fragment_bytes 0 110 | len; 111 | Buffer.add_bytes buf response_fragment_bytes; 112 | read_fn ()) 113 | in 114 | read_fn (); 115 | body_read 116 | 117 | let send ?(meth=`GET) ?(additional_headers=[]) ?body uri = 118 | send_request ~meth ~additional_headers ?body (Uri.of_string uri) >>= fun (resp, err) -> 119 | Lwt.choose [resp; err] >>= function 120 | | Ok (Response (_r, body)) -> 121 | Lwt.pick [read_response body; err] >|= (function 122 | | Ok (Body body_str) -> body_str 123 | | Ok (Response _) -> assert false 124 | | Error err_str -> err_str) 125 | | Ok (Body _) -> assert false 126 | | Error err_str -> Lwt.return err_str 127 | 128 | let private_github_token = Unix.getenv "GH_TOKEN" 129 | --------------------------------------------------------------------------------