Mailing list for all users of the OCaml language and system.
 help / color / mirror / Atom feed
From: Alan Schmitt <alan.schmitt@polytechnique.org>
To: "lwn" <lwn@lwn.net>, caml-list@inria.fr
Subject: [Caml-list] Attn: Development Editor, Latest OCaml Weekly News
Date: Tue, 08 Oct 2024 12:56:22 +0200	[thread overview]
Message-ID: <m2wmii278p.fsf@petitepomme.net> (raw)

[-- Attachment #1: Type: text/plain, Size: 31022 bytes --]

Hello

Here is the latest OCaml Weekly News, for the week of October 01 to 08,
2024.

Table of Contents
─────────────────

Releases of fpath-sexplib0, fpath-base, loc, file-rewriter, sexps-rewriter and provider
Build a project without Stdlib
obatcher: Framework for building efficient concurrent services
DBLP query program and library
cudajit: Bindings to the `cuda' and `nvrtc' libraries
YOCaml, a framework for static site generator
oepub 0.1.0 : A library to parse epub files
ppx_deriving_router — type safe routing for Dream and Melange
Mica, a PPX that automates differential testing for OCaml modules
Simplified Android cross-compiler with DkML
Other OCaml News
Old CWN


Releases of fpath-sexplib0, fpath-base, loc, file-rewriter, sexps-rewriter and provider
═══════════════════════════════════════════════════════════════════════════════════════

  Archive:
  <https://discuss.ocaml.org/t/releases-of-fpath-sexplib0-fpath-base-loc-file-rewriter-sexps-rewriter-and-provider/15364/1>


Mathieu Barbin announced
────────────────────────

  I wanted to announce the initial release of 6 utility packages to the
  opam-repository. They are dependencies to some other ongoing projects
  I have, perhaps some will find them useful.

  These are very early days for this software. Please feel welcome to
  opening issues or discussions tickets if you are inclined.

  Thank you @mseri , @avsm & @shonfeder for your help in making these
  libraries available!

  Below you'll find short descriptions with links to the packages home
  pages. Thank you!

  [Fpath_sexplib0] only depends on `fpath' and `sexplib0'. It defines a
  single module, `Fpath_sexplib0', which is designed to be opened to
  shadow the `Fpath' module to add small helpers and a `sexp_of'
  serializer to it. The package also introduces three new modules to the
  scope: `Fpart', `Absolute_path' and `Relative_path' to increase
  type-safety when manipulating paths that are known to be relative or
  absolute.

  [Fpath_base] further extends `fpath-sexplib0' and adds a dependency on
  base. It is designed to be compatible with Base-style containers such
  as `Map', `Set', `Hashtbl', `Hash_set'.

  [Loc] is an OCaml library to manipulate code locations, which are
  ranges of lexing positions from a parsed file.

  [File_rewriter] is an OCaml library for applying small rewrites to
  tweak or refactor your files. It provides a convenient interface to
  apply surgical textual substitutions on the fly, while navigating the
  contents of a file through an abstract representation containing code
  locations.

  [Sexps_rewriter] is a specialized version of the `file-rewriter'
  library dedicated to rewriting sexp files, such as dune config files.

  [Provider] is an OCaml library for creating Traits and Interfaces. It
  allows you to define the functionality needed by a library without
  committing to a specific implementation - in essence : dynamic
  dispatch. Provider is a pattern featured in the `Eio' project
  (`Eio.Resource'). I wanted to make it reusable in other projects - in
  particular I am currently using it as the parametrization story of
  `vcs'. This package had already been available for a little while
  already but was still unannounced.


[Fpath_sexplib0] <https://github.com/mbarbin/fpath-base>

[Fpath_base] <https://github.com/mbarbin/fpath-base>

[Loc] <https://github.com/mbarbin/loc>

[File_rewriter] <https://github.com/mbarbin/file-rewriter>

[Sexps_rewriter] <https://github.com/mbarbin/file-rewriter>

[Provider] <https://github.com/mbarbin/provider>


Build a project without Stdlib
══════════════════════════════

  Archive:
  <https://discuss.ocaml.org/t/build-a-project-without-stdlib/15374/1>


Mikhail announced
─────────────────

  I decided to experiment with compiling a project without the standard
  library. Why? I don't know. But I could save ~50K. Just sharing my
  note about it.

  You can find an example in my [repository].

  I found the `-nostdlib' and `-nopervasives' (undocumented) flags and
  after a lot of trying I was able to do what I wanted. It doesn't
  disable absolutely everything (lists and other types like `option' are
  available).

  ┌────
  │ (flags
  │   :standard
  │   -nostdlib
  │   -nopervasives
  │   ; add runtime
  │   -cclib
  │   -lasmrun
  │   -ccopt
  │   "-L %{ocaml_where}"
  │   -ccopt
  │   "-lm -ldl")
  └────

  ┌────
  │ (* stdlib.ml *)
  │ external print_endline : string -> unit = "caml_print_endline" [@@noalloc]
  │ 
  │ (* main.ml *)
  │ open Stdlib
  │ let () = print_endline "hello from my stdlib"
  └────

  Hello World program:

  ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
           with Stdlib  without Stdlib 
  ─────────────────────────────────────
   *size*  349K         302K           
  ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━


[repository] <https://github.com/dx3mod/ocaml-without-stdlib>


obatcher: Framework for building efficient concurrent services
══════════════════════════════════════════════════════════════

  Archive:
  <https://discuss.ocaml.org/t/ann-obatcher-framework-for-building-efficient-concurrent-services/15384/1>


Lee Koon Wen announced
──────────────────────

  Hot on the heels of the paper [/"Concurrent Data Structures Made
  Easy"/] appearing at [OOPSLA 2024] on the 24th October, I'm pleased to
  announce release of *obatcher* - a _picos_ compatible library for
  implementing efficient batched services in OCaml.

  *obatcher* proposes a *new* way to approach the design and
   implementation of concurrent services. It's key benefits are:

  • Incremental optimization and parallelism of services
  • Easy to control and reason about concurrency
  • Retains atomic-style interface with your services while batching
    happens implicitly
  • Thread-safety for cheap!

  Available on opam today, install with
  ┌────
  │ opam install obatcher
  └────

  For more details, check out the source and README on GitHub:
  [obatcher].

  Feedback, contributions, and discussions are welcome!


[/"Concurrent Data Structures Made Easy"/]
<https://koonwen.github.io/assets/pdf/concurrent-structures-made-easy.pdf>

[OOPSLA 2024]
<https://2024.splashcon.org/details/splash-2024-oopsla/118/Concurrent-Data-Structures-Made-Easy>

[obatcher] <https://github.com/koonwen/obatcher>


DBLP query program and library
══════════════════════════════

  Archive:
  <https://discuss.ocaml.org/t/ann-dblp-query-program-and-library/15385/1>


Samuel Mimram announced
───────────────────────

  I am happy to announce the first realease of [ocaml-dblp], which
  provides both a program and a library to query the [DBLP]
  bibliographic database. In practice, it is mostly useful for
  retrieving bibtex entries with commands such as

  ┌────
  │ dblp bibtex girard locus solum
  └────

  which will spit out

  ┌────
  │ @article{DBLP:journals/mscs/Girard01,
  │   author       = {Jean{-}Yves Girard},
  │   title        = {Locus Solum: From the rules of logic to the logic of rules},
  │   journal      = {Math. Struct. Comput. Sci.},
  │   volume       = {11},
  │   number       = {3},
  │   pages        = {301--506},
  │   year         = {2001},
  │   url          = {https://doi.org/10.1017/S096012950100336X},
  │   doi          = {10.1017/S096012950100336X},
  │   timestamp    = {Wed, 01 Apr 2020 08:48:47 +0200},
  │   biburl       = {https://dblp.org/rec/journals/mscs/Girard01.bib},
  │   bibsource    = {dblp computer science bibliography, https://dblp.org}
  │ }
  └────

  (or, even better, use `dblp bib' to directly add this at the end of
  the `.bib' file in the current directory).

  It might still need some polishing, feel free to reach out if you
  encounter some problems.


[ocaml-dblp] <https://github.com/smimram/ocaml-dblp>

[DBLP] <https://dblp.org/>


cudajit: Bindings to the `cuda' and `nvrtc' libraries
═════════════════════════════════════════════════════

  Archive:
  <https://discuss.ocaml.org/t/ann-cudajit-bindings-to-the-cuda-and-nvrtc-libraries/15010/2>


Lukasz Stafiniak announced
──────────────────────────

  cudajit 0.5.0 is now available in the opam repository. It's organized
  into [modules], and it adds support for CUDA events.


[modules]
<https://lukstafi.github.io/ocaml-cudajit/cudajit/Cudajit/index.html>


YOCaml, a framework for static site generator
═════════════════════════════════════════════

  Archive:
  <https://discuss.ocaml.org/t/ann-yocaml-a-framework-for-static-site-generator/15393/1>


Xavier Van de Woestyne announced
────────────────────────────────

  :wave: Hello everyone! We, the YOCaml development team, are very
  pleased to announce the release of [version 2], freshly merged into
  [opam-repository] :champagne:!

  *YOCaml is a framework for describing static site generators* (a very
   small applicative build-system whose API is tailor-made for creating
   web pages ) and its internal model is very similar to [Hakyll] (the
   3th version), another Haskell framework. (a presentation was given to
   the OCaml user Group in Paris and you can find the video, [in French,
   here]).


[version 2] <https://github.com/xhtmlboi/yocaml/releases/tag/v2.0.0>

[opam-repository] <https://github.com/ocaml/opam-repository>

[Hakyll] <https://jaspervdj.be/hakyll/>

[in French, here]
<https://www.irill.org/videos/OUPS/2023-01/xavier-van-de-woestyne.html>

Changes with 1.0.0
╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌

  Historically, YOCaml was written very, very quickly to give examples
  of slightly exotic uses of the library [Preface]. Due to its
  experimental nature, the API was a bit laborious, but we did find some
  users! We took advantage of the redesign to stop relying on Preface
  (and yes, YOCaml was already more widely used than Preface), move to
  OCaml 5.x and take advantage of _user-defined-effects_ and support
  dynamic dependencies. In other words, YOCaml `2.0.0' is not at all
  compatible with version 1…


[Preface] <https://github.com/xvw/preface>


Plugins and runtimes
╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌

  The aim of YOCaml is to be very generic and to allow users to bring
  their own dependencies, but we've taken the opportunity to release it
  with several plugins and runtimes so that it can be used directly.


◊ Runtimes

  A Runtime is an ‘execution context’ and generally exposes the
  primitive used to execute a YOCaml program. YOCaml 2 is bundled with 3
  Runtimes:

  • *Yocaml_unix*: the default runtime, whose preview server is
     implemented on top of the brand new [httpcats]!

  • *Yocaml_eio*: a runtime iso to Unix but based on [eio] and whose
     preview server is described by [cohttp_eio].

  • *Yocaml_git*: a parameterised runtime for generating a site directly
     in a git repository, which can be served, for example, by a
     [Mirage] ([unipi]), very well documented in this [excellent
     article] by @dinosaure!


  [httpcats] <https://github.com/robur-coop/httpcats>

  [eio] <https://github.com/ocaml-multicore/eio>

  [cohttp_eio] <https://github.com/mirage/ocaml-cohttp>

  [Mirage] <https://mirage.io/>

  [unipi] <https://github.com/robur-coop/unipi>

  [excellent article] <https://blog.osau.re/articles/blog_requiem.html>


◊ Plugins

  • *Yocaml_cmarkit* provides a convenient API (via YOCaml) for
     converting Markdown files to HTML via the excellent [cmarkit]
     library.

  • *Yocaml_omd* provides a convenient API (via YOCaml) for converting
     Markdown files to HTML via the excellent [OMD] library (but we
     recommend `yocaml_cmarkit').

  • *yocaml_yaml* provides a convenient API (via YOCaml) for reading
     Yaml via the excellent library [ocaml-yaml]

  • *yocaml_otoml* provides a convenient API (for YOCaml) for reading
     TOML via the excellent library [Otoml]

  • *yocaml_mustache* provides a convenient API (via YOCaml) for using
     [Mustache] as a template language via the excellent library
     [ocaml-mustache]

  • *yocaml_jingoo* provides a convenient API (via YOCaml) for using
     [Jingoo] as a template language via the excellent library [jingoo]

  • *yocaml_syndication* that gives tool to generate feeds
     ([Atom](<https://en.wikipedia.org/wiki/Atom_(web_standard)>), [RSS]
     1 and 2 and [OPML]). The library is inspired by [Syndic] but does
     not depend directly on it.


  [cmarkit] <https://github.com/dbuenzli/cmarkit>

  [OMD] <https://github.com/ocaml/omd>

  [ocaml-yaml] <https://github.com/avsm/ocaml-yaml>

  [Otoml] <https://github.com/dmbaturin/otoml>

  [Mustache] <https://mustache.github.io/>

  [ocaml-mustache] <https://github.com/rgrinberg/ocaml-mustache>

  [Jingoo] <http://tategakibunko.github.io/jingoo/>

  [jingoo] <https://github.com/tategakibunko/jingoo>

  [RSS] <https://en.wikipedia.org/wiki/RSS>

  [OPML] <https://opml.org/>

  [Syndic] <https://github.com/Cumulus/Syndic>


A final word
╌╌╌╌╌╌╌╌╌╌╌╌

  YOCaml 2 was mainly written by [xhtmlboi], helped by [gr-im], [mspwn]
  and [dinosaure] with occasional support from [maiste]. It has already
  been used experimentally in a number of small projects:

  • [Ring.muhokama] a very small webring - [sources]
  • [Maiste.fr] - [sources]
  • [gr-im.github.io] - [sources]

  You will also find extensively documented examples in the [examples]
  directory.

  To conclude, we find (not very objectively) that YOCaml is a lot of
  fun to use, and it's very cool to make your site using as much OCaml
  as possible.

  Happy Hacking!

  • [Yocaml on OPAM]
  • [Dev repository]


[xhtmlboi] <https://github.com/xhtmlboi>

[gr-im] <https://github.com/gr-im>

[mspwn] <https://github.com/mspwn>

[dinosaure] <https://github.com/dinosaure>

[maiste] <https://github.com/maiste>

[Ring.muhokama] <https://ring.muhokama.fun>

[sources] <https://github.com/muhokama/ring>

[Maiste.fr] <https://maiste.fr>

[sources] <https://github.com/maiste/maiste.fr>

[gr-im.github.io] <https://gr-im.github.io>

[sources] <https://github.com/gr-im/site>

[examples] <https://github.com/xhtmlboi/yocaml/tree/main/examples>

[Yocaml on OPAM] <https://ocaml.org/p/yocaml/latest>

[Dev repository] <https://github.com/xhtmlboi/yocaml>


oepub 0.1.0 : A library to parse epub files
═══════════════════════════════════════════

  Archive:
  <https://discuss.ocaml.org/t/ann-oepub-0-1-0-a-library-to-parse-epub-files/15394/1>


EruEri announced
────────────────

  I humbly announce oepub a small library to parse epub files and to
  some extend create a list of chapters from the epub archive.

  You can find the repository at [Codeberg - Oepub]


[Codeberg - Oepub] <https://codeberg.org/EruEri/oepub>


ppx_deriving_router — type safe routing for Dream and Melange
═════════════════════════════════════════════════════════════

  Archive:
  <https://discuss.ocaml.org/t/ann-ppx-deriving-router-type-safe-routing-for-dream-and-melange/15401/1>


Andrey Popp announced
─────────────────────

  It's my pleasure to announce a new ppx for deriving [Dream] routers
  based on variant type declarations, [ppx_deriving_router].

  A small example. First we define routes (the signature showcases the
  generated code):
  ┌────
  │ module Pages : sig
  │   ...
  │ 
  │   val href : t -> string
  │   (** generate URL from the route *)
  │ 
  │   val http_method : t -> [ `DELETE | `GET | `POST | `PUT ]
  │   (** HTTP method for the route *)
  │ 
  │   val handle : (t -> Dream.handler) -> Dream.handler
  │   (** create a route handler *)
  │ end = struct
  │   open Ppx_deriving_router_runtime.Primitives
  │ 
  │   type t =
  │     | Home [@GET "/"]
  │     | About
  │     | Hello of { name : string; repeat : int option } [@GET "/hello/:name"]
  │     [@@deriving router]
  │ end
  └────

  Then we describe how we handle each route:
  ┌────
  │ let handle =
  │   Pages.handle (fun route _req ->
  │       match route with
  │       | Home -> Dream.respond "Home page!"
  │       | About -> Dream.respond "About page!"
  │       | Hello { name; repeat } ->
  │           let name =
  │             match repeat with
  │             | Some repeat ->
  │                 List.init repeat (fun _ -> name) |> String.concat ", "
  │             | None -> name
  │           in
  │           Dream.respond (Printf.sprintf "Hello, %s" name))
  │ 
  │ let () = Dream.run ~interface:"127.0.0.1" ~port:8080 handle
  └────

  Using generated `Pages.href' function we can generate URLs for routes:
  ┌────
  │ let () =
  │   assert (Pages.href Home = "/");
  │   assert (Pages.href About = "/about");
  │   assert (Pages.href (Hello { name = "world"; repeat = None }) = "/hello/world");
  │   assert (Pages.href (Hello { name = "world"; repeat = Some 3 }) = "/hello/world?repeat=3")
  └────

  The URL matching is done by [routes] library.

  There's also support for [routes that track their response types] and
  the ppx automatically derives JSON encoders and decoders for them (by
  using [melange-json.ppx]).

  On top of that a [separate ppx is provided] for [Melange] which allows
  to construct type safe HTTP clients (route defintions are shared
  between server and client).

  Happy hacking!


[Dream] <https://aantron.github.io/dream/>

[ppx_deriving_router]
<https://github.com/andreypopp/ppx_deriving_router>

[routes] <https://anuragsoni.github.io/routes/>

[routes that track their response types]
<https://github.com/andreypopp/ppx_deriving_router#routes-with-typed-responses>

[melange-json.ppx]
<https://github.com/melange-community/melange-json?tab=readme-ov-file#ppx-for-melange>

[separate ppx is provided]
<https://github.com/andreypopp/ppx_deriving_router#using-with-melange>

[Melange] <https://melange.re/>


Mica, a PPX that automates differential testing for OCaml modules
═════════════════════════════════════════════════════════════════

  Archive:
  <https://discuss.ocaml.org/t/ann-mica-a-ppx-that-automates-differential-testing-for-ocaml-modules/15406/1>


Ernest Ng announced
───────────────────

  I'm delighted to announce the initial release of [Mica], a PPX deriver
  that automates differential testing for a pair of OCaml modules
  implementing the same signature. Users annotate module signatures with
  the directive `[@@deriving mica]', and at compile-time, Mica derives
  specialized [property-based testing] (PBT) code that checks if two
  modules implementing the signature are observationally
  equivalent. (Under the hood, Mica uses Jane Street's
  [`Core.Quickcheck'] PBT library.)

  Mica was presented at the OCaml Workshop '24 ([paper]) and the ICFP
  '23 Student Research Competition ([poster]).

  *Note*: Mica is currently a research tool and should not be used in
   production code, although contributions are very welcome!

  Mica is available on Opam:
  ┌────
  │ opam update 
  │ opam install ppx_mica
  └────
  (OCaml 5.1 or newer is required.)

  Docs are available [here], and a simple web app demo-ing Mica is
  available [here].


[Mica] <https://github.com/ngernest/mica>

[property-based testing] <https://www.youtube.com/watch?v=qmA9qhaECcE>

[`Core.Quickcheck'] <https://blog.janestreet.com/quickcheck-for-core/>

[paper] <https://arxiv.org/abs/2408.14561>

[poster] <https://ngernest.github.io/pdfs/mica_icfp23src_poster.pdf>

[here] <https://ngernest.github.io/mica/ppx_mica/index.html>

[here] <https://ngernest.github.io/mica/demo.html>


Simplified Android cross-compiler with DkML
═══════════════════════════════════════════

  Archive:
  <https://discuss.ocaml.org/t/ann-simplified-android-cross-compiler-with-dkml/15407/1>


jbeckford announced
───────────────────

  DkML has had a cross-compiler for years, but I have cleaned it up so
  that it is much easier to use for Android developers. It *now works
  with a regular opam installation in a custom repository*. Also
  included are patches to the OCaml compiler to work with Android NDK
  21+ (currently Google is at NDK 27).

  Try it out if you do Android development … just copy-and-paste the
  instructions below … but please read the notes and cautions below. And
  if you are still interested in Android development, tell me so I can
  decide if I'll merge the packages into the regular opam repository.

  Trimmed slightly from the [dkml-compiler Quick Start]:

  • Docker container is used below for Windows and macOS users, and
    because it is easy to get the Android NDK from CircleCI.
  • Apple Silicon does not support 32-bit. The net effect is that Apple
    Silicon users cannot cross-compile `android_arm32v7a'.

  ┌────
  │ $ docker run -it --rm cimg/android:2024.10.1-ndk
  │ 
  │ # Install opam if you don't have it
  │ ~/project$ sudo apt-get update && sudo apt-get install build-essential curl git patch rsync unzip -y
  │ ~/project$ echo /usr/local/bin | sudo bash -c "sh <(curl -fsSL https://opam.ocaml.org/install.sh) --version 2.2.1"
  │ 
  │ # Initialize opam if you haven't already. No sandboxing is needed in containers.
  │ ~/project$ opam init --cli=2.1 --no-setup --bare --disable-sandboxing
  │ 
  │ # Two Android options to set. ANDROID_PLATFORM is the minimum API level ("targetSdkVersion" in the Android manifest)
  │ ~/project$ opam var --cli=2.1 --global ANDROID_NDK=/home/circleci/android-sdk/ndk/27.1.12297006
  │ ~/project$ opam var --cli=2.1 --global ANDROID_PLATFORM=android-34
  │ 
  │ # PICK ONE: Android arm64-v8a switch
  │ ~/project$ opam switch create android34-ndk27-arm64-v8a --cli=2.1 \
  │   --packages dkml-base-compiler,dkml-host-abi-linux_x86_64,dkml-target-abi-android_arm64v8a,ocamlfind,conf-dkml-cross-toolchain \
  │   --repos default,diskuv-4d79e732=git+https://github.com/diskuv/diskuv-opam-repository.git#4d79e732
  │ 
  │ # PICK ONE: Android armeabi-v7a switch. You will need a 32-bit C/C++ compiler.
  │ ~/project$ sudo apt-get install gcc-multilib g++-multilib -y
  │ ~/project$ opam switch create android34-ndk27-armeabi-v7a --cli=2.1 \
  │   --packages dkml-base-compiler,dkml-host-abi-linux_x86,dkml-target-abi-android_arm32v7a,ocamlfind,conf-dkml-cross-toolchain \
  │   --repos default,diskuv-4d79e732=git+https://github.com/diskuv/diskuv-opam-repository.git#4d79e732
  │ 
  │ # PICK ONE: Android x86_64 switch
  │ ~/project$ opam switch create android34-ndk27-x86_64 --cli=2.1 \
  │   --packages dkml-base-compiler,dkml-host-abi-linux_x86_64,dkml-target-abi-android_x86_64,ocamlfind,conf-dkml-cross-toolchain \
  │   --repos default,diskuv-4d79e732=git+https://github.com/diskuv/diskuv-opam-repository.git#4d79e732
  │ 
  │ # THEN: Get and cross-compile your source code. Here we use Dune and assume 'android34-ndk27-arm64-v8a'
  │ ~/project$ opam install --cli=2.1 --switch android34-ndk27-arm64-v8a dune
  │ ~/project$ git clone https://github.com/avsm/hello-world-action-ocaml hello
  │ ~/project$ cd hello
  │ ~/project/hello$ opam exec --cli=2.1 --switch android34-ndk27-arm64-v8a -- \
  │   dune build -x android_arm64v8a world.exe
  │ 
  │ ~/project/hello$ file _build/default*/world.exe
  │ _build/default.android_arm64v8a/world.exe: ELF 64-bit LSB pie executable, ARM aarch64, version 1 (SYSV), dynamically linked, interpreter /system/bin/linker64, with debug_info, not stripped
  │ _build/default/world.exe:                  ELF 64-bit LSB pie executable, x86-64, version 1 (SYSV), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, BuildID[sha1]=1731ad9ce0fdeff69df28af0b1217e843eabe26e, for GNU/Linux 3.2.0, with debug_info, not stripped
  │ 
  │ # You can also directly use the ocamlfind -toolchain
  │ 
  │ ~/project$ opam exec --cli=2.1 --switch android34-ndk27-arm64-v8a -- \
  │   ocamlfind ocamlc -config-var native_c_compiler
  │ gcc -O2 -fno-strict-aliasing -fwrapv -pthread -fPIC  -D_FILE_OFFSET_BITS=64
  │ 
  │ ~/project$ opam exec --cli=2.1 --switch android34-ndk27-arm64-v8a -- \
  │   ocamlfind -toolchain android_arm64v8a ocamlc -config-var native_c_compiler
  │ /home/circleci/android-sdk/ndk/27.1.12297006/toolchains/llvm/prebuilt/linux-x86_64/bin/aarch64-linux-android34-clang -O2 -fno-strict-aliasing -fwrapv -pthread -fPIC  -D_FILE_OFFSET_BITS=64
  └────

  DkML supports three out of the four supported Android ABIs. The three
  ABIs (all but `x86') were chosen based on [statistics for a large game
  on Aug 29, 2023]:

  ━━━━━━━━━━━━━━━━━━━━━━
   Arch         Percent 
  ──────────────────────
   arm64-v8a      68.66 
   armeabi-v7a    30.38 
   x86_64          0.71 
   x86             0.26 
  ━━━━━━━━━━━━━━━━━━━━━━

  and also [Google's recommendation]:

  *Note*: While 64-bit-only devices will grow in popularity with phones
   joining Android Auto in this group, 32-bit-only devices will continue
   to be important for Android Go, Android TV, and Android Wear. Please
   continue supporting 32-bit ABIs; Google Play will continue serving
   32-bit apps to 32-bit-only devices.

  Finally, a word of *CAUTION*. The Android cross-compiler /can never/
  use OCaml 5+ because [OCaml 5 will never bring back the 32-bit
  instruction set]. That means if you don't want to drop a large percent
  of your users or drop new Android categories over the next five (?)
  years, you will have a critical dependency on DkML.


[dkml-compiler Quick Start]
<https://github.com/diskuv/dkml-compiler?tab=readme-ov-file#quick-start>

[statistics for a large game on Aug 29, 2023]
<https://github.com/android/ndk/issues/1772#issuecomment-1697831518>

[Google's recommendation]
<https://android-developers.googleblog.com/2022/10/64-bit-only-devices.html>

[OCaml 5 will never bring back the 32-bit instruction set]
<https://discuss.ocaml.org/t/32-bit-native-code-support-for-ocaml-5/12583/13?u=jbeckford>


Other OCaml News
════════════════

From the ocaml.org blog
───────────────────────

  Here are links from many OCaml blogs aggregated at [the ocaml.org
  blog].

  • [Developer education at Jane Street]
  • [Solving Puzzles in Production with Liora Friedberg]
  • [MetAcsl v0.7 for Frama-C 29.0~ Copper]
  • [Introducing the Dune Developer Preview: A New Era for OCaml
    Development]
  • [Unlock your Team’s Potential with Expert Training in OCaml,
    Cybersecurity Fundamentals, Functional Programming, and More]
  • [Alt-Ergo 2.6 is Out!]
  • [Happy eyeballs?!]


[the ocaml.org blog] <https://ocaml.org/blog/>

[Developer education at Jane Street]
<https://blog.janestreet.com/developer-education-at-jane-street-index/>

[Solving Puzzles in Production with Liora Friedberg]
<https://signals-threads.simplecast.com/episodes/solving-puzzles-in-production-with-liora-friedberg-dk6vYnK2>

[MetAcsl v0.7 for Frama-C 29.0~ Copper]
<https://frama-c.com/fc-plugins/metacsl.html>

[Introducing the Dune Developer Preview: A New Era for OCaml
Development]
<https://tarides.com/blog/2024-10-03-introducing-the-dune-developer-preview-a-new-era-for-ocaml-development>

[Unlock your Team’s Potential with Expert Training in OCaml,
Cybersecurity Fundamentals, Functional Programming, and More]
<https://tarides.com/blog/2024-10-01-unlock-your-team-s-potential-with-expert-training-in-ocaml-cybersecurity-fundamentals-functional-programming-and-more>

[Alt-Ergo 2.6 is Out!]
<https://ocamlpro.com/blog/2024_09_01_alt_ergo_2_6_0_released>

[Happy eyeballs?!] <https://blog.osau.re/articles/happy_eyeballs.html>


Old CWN
═══════

  If you happen to miss a CWN, you can [send me a message] and I'll mail
  it to you, or go take a look at [the archive] or the [RSS feed of the
  archives].

  If you also wish to receive it every week by mail, you may subscribe
  to the [caml-list].

  [Alan Schmitt]


[send me a message] <mailto:alan.schmitt@polytechnique.org>

[the archive] <https://alan.petitepomme.net/cwn/>

[RSS feed of the archives] <https://alan.petitepomme.net/cwn/cwn.rss>

[caml-list] <https://sympa.inria.fr/sympa/info/caml-list>

[Alan Schmitt] <https://alan.petitepomme.net/>


[-- Attachment #2: Type: text/html, Size: 48034 bytes --]

             reply	other threads:[~2024-10-08 10:56 UTC|newest]

Thread overview: 236+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-08 10:56 Alan Schmitt [this message]
  -- strict thread matches above, loose matches on Subject: below --
2025-04-15  9:51 Alan Schmitt
2025-04-08 13:14 Alan Schmitt
2025-04-01  9:12 Alan Schmitt
2025-03-25  8:06 Alan Schmitt
2025-03-18 10:18 Alan Schmitt
2025-03-11 15:00 Alan Schmitt
2025-03-04 14:01 Alan Schmitt
2025-02-25 10:36 Alan Schmitt
2025-02-18 14:33 Alan Schmitt
2025-02-11  7:17 Alan Schmitt
2025-02-04 12:05 Alan Schmitt
2025-01-28 13:24 Alan Schmitt
2025-01-21 15:47 Alan Schmitt
2025-01-14  8:20 Alan Schmitt
2025-01-07 17:26 Alan Schmitt
2024-12-31  8:03 Alan Schmitt
2024-12-24  8:55 Alan Schmitt
2024-12-17 13:05 Alan Schmitt
2024-12-10 13:48 Alan Schmitt
2024-12-03 14:44 Alan Schmitt
2024-11-26  8:30 Alan Schmitt
2024-11-19  6:52 Alan Schmitt
2024-11-12 15:00 Alan Schmitt
2024-11-05 13:22 Alan Schmitt
2024-10-29 13:30 Alan Schmitt
2024-10-22 12:42 Alan Schmitt
2024-10-15 13:31 Alan Schmitt
2024-10-01 13:37 Alan Schmitt
2024-09-24 13:18 Alan Schmitt
2024-09-17 14:02 Alan Schmitt
2024-09-10 13:55 Alan Schmitt
2024-09-03  8:24 Alan Schmitt
2024-08-27  9:02 Alan Schmitt
2024-08-20  9:29 Alan Schmitt
2024-08-13 13:21 Alan Schmitt
2024-08-06  9:00 Alan Schmitt
2024-07-30 13:26 Alan Schmitt
2024-07-23 13:30 Alan Schmitt
2024-07-16  6:24 Alan Schmitt
2024-07-09  9:19 Alan Schmitt
2024-07-02  7:30 Alan Schmitt
2024-06-25 13:58 Alan Schmitt
2024-06-18 13:05 Alan Schmitt
2024-06-11 15:04 Alan Schmitt
2024-06-04 13:26 Alan Schmitt
2024-05-28  9:07 Alan Schmitt
2024-05-21 13:07 Alan Schmitt
2024-05-14 13:25 Alan Schmitt
2024-05-07  7:30 Alan Schmitt
2024-04-30  7:22 Alan Schmitt
2024-04-23 12:17 Alan Schmitt
2024-04-16 12:00 Alan Schmitt
2024-04-09  9:15 Alan Schmitt
2024-04-02 14:31 Alan Schmitt
2024-03-26  6:32 Alan Schmitt
2024-03-19 15:09 Alan Schmitt
2024-03-12 10:31 Alan Schmitt
2024-03-05 14:50 Alan Schmitt
2024-02-27 13:53 Alan Schmitt
2024-02-20  9:12 Alan Schmitt
2024-02-13  8:42 Alan Schmitt
2024-02-06 15:14 Alan Schmitt
2024-01-30 14:16 Alan Schmitt
2024-01-23  9:45 Alan Schmitt
2024-01-16 10:01 Alan Schmitt
2024-01-09 13:40 Alan Schmitt
2024-01-02  8:59 Alan Schmitt
2023-12-26 10:12 Alan Schmitt
2023-12-19 10:10 Alan Schmitt
2023-12-12 10:20 Alan Schmitt
2023-12-05 10:13 Alan Schmitt
2023-11-28  9:09 Alan Schmitt
2023-11-21  7:47 Alan Schmitt
2023-11-14 13:42 Alan Schmitt
2023-11-07 10:31 Alan Schmitt
2023-10-31 10:43 Alan Schmitt
2023-10-24  9:17 Alan Schmitt
2023-10-17  7:46 Alan Schmitt
2023-10-10  7:48 Alan Schmitt
2023-10-03 13:00 Alan Schmitt
2023-09-19  8:54 Alan Schmitt
2023-09-12 13:21 Alan Schmitt
2023-09-05  9:00 Alan Schmitt
2023-08-29 13:04 Alan Schmitt
2023-08-22  9:20 Alan Schmitt
2023-08-15 16:33 Alan Schmitt
2023-08-08  8:53 Alan Schmitt
2023-08-01  7:13 Alan Schmitt
2023-07-25  8:45 Alan Schmitt
2023-07-11  8:45 Alan Schmitt
2023-07-04  9:18 Alan Schmitt
2023-06-27  8:38 Alan Schmitt
2023-06-20  9:52 Alan Schmitt
2023-06-13  7:09 Alan Schmitt
2023-06-06 14:22 Alan Schmitt
2023-05-30 15:43 Alan Schmitt
2023-05-23  9:41 Alan Schmitt
2023-05-16 13:05 Alan Schmitt
2023-05-09 11:49 Alan Schmitt
2023-05-02  8:01 Alan Schmitt
2023-04-25  9:25 Alan Schmitt
2023-04-18  8:50 Alan Schmitt
2023-04-11 12:41 Alan Schmitt
2023-04-04  8:45 Alan Schmitt
2023-03-28  7:21 Alan Schmitt
2023-03-21 10:07 Alan Schmitt
2023-03-14  9:52 Alan Schmitt
2023-03-07  9:02 Alan Schmitt
2023-02-28 14:38 Alan Schmitt
2023-02-21 10:19 Alan Schmitt
2023-02-14  8:12 Alan Schmitt
2023-02-07  8:16 Alan Schmitt
2023-01-31  6:44 Alan Schmitt
2023-01-24  8:57 Alan Schmitt
2023-01-17  8:37 Alan Schmitt
2022-11-29 14:53 Alan Schmitt
2022-09-27  7:17 Alan Schmitt
2022-09-20 14:01 Alan Schmitt
2022-09-13  8:40 Alan Schmitt
2022-08-23  8:06 Alan Schmitt
2022-08-16  8:51 Alan Schmitt
2022-08-09  8:02 Alan Schmitt
2022-08-02  9:51 Alan Schmitt
2022-07-26 17:54 Alan Schmitt
2022-07-19  8:58 Alan Schmitt
2022-07-12  7:59 Alan Schmitt
2022-07-05  7:42 Alan Schmitt
2022-06-28  7:37 Alan Schmitt
2022-06-21  8:06 Alan Schmitt
2022-06-14  9:29 Alan Schmitt
2022-06-07 10:15 Alan Schmitt
2022-05-31 12:29 Alan Schmitt
2022-05-24  8:04 Alan Schmitt
2022-05-17  7:12 Alan Schmitt
2022-05-10 12:30 Alan Schmitt
2022-05-03  9:11 Alan Schmitt
2022-04-26  6:44 Alan Schmitt
2022-04-19  5:34 Alan Schmitt
2022-04-12  8:10 Alan Schmitt
2022-04-05 11:50 Alan Schmitt
2022-03-29  7:42 Alan Schmitt
2022-03-22 13:01 Alan Schmitt
2022-03-15  9:59 Alan Schmitt
2022-03-01 13:54 Alan Schmitt
2022-02-22 12:43 Alan Schmitt
2022-02-08 13:16 Alan Schmitt
2022-02-01 13:00 Alan Schmitt
2022-01-25 12:44 Alan Schmitt
2022-01-11  8:20 Alan Schmitt
2022-01-04  7:56 Alan Schmitt
2021-12-28  8:59 Alan Schmitt
2021-12-21  9:11 Alan Schmitt
2021-12-14 11:02 Alan Schmitt
2021-11-30 10:51 Alan Schmitt
2021-11-16  8:41 Alan Schmitt
2021-11-09 10:08 Alan Schmitt
2021-11-02  8:50 Alan Schmitt
2021-10-19  8:23 Alan Schmitt
2021-09-28  6:37 Alan Schmitt
2021-09-21  9:09 Alan Schmitt
2021-09-07 13:23 Alan Schmitt
2021-08-24 13:44 Alan Schmitt
2021-08-17  6:24 Alan Schmitt
2021-08-10 16:47 Alan Schmitt
2021-07-27  8:54 Alan Schmitt
2021-07-20 12:58 Alan Schmitt
2021-07-06 12:33 Alan Schmitt
2021-06-29 12:24 Alan Schmitt
2021-06-22  9:04 Alan Schmitt
2021-06-01  9:23 Alan Schmitt
2021-05-25  7:30 Alan Schmitt
2021-05-11 14:47 Alan Schmitt
2021-05-04  8:57 Alan Schmitt
2021-04-27 14:26 Alan Schmitt
2021-04-20  9:07 Alan Schmitt
2021-04-06  9:42 Alan Schmitt
2021-03-30 14:55 Alan Schmitt
2021-03-23  9:05 Alan Schmitt
2021-03-16 10:31 Alan Schmitt
2021-03-09 10:58 Alan Schmitt
2021-02-23  9:51 Alan Schmitt
2021-02-16 13:53 Alan Schmitt
2021-02-02 13:56 Alan Schmitt
2021-01-26 13:25 Alan Schmitt
2021-01-19 14:28 Alan Schmitt
2021-01-12  9:47 Alan Schmitt
2021-01-05 11:22 Alan Schmitt
2020-12-29  9:59 Alan Schmitt
2020-12-22  8:48 Alan Schmitt
2020-12-15  9:51 Alan Schmitt
2020-12-01  8:54 Alan Schmitt
2020-11-03 15:15 Alan Schmitt
2020-10-27  8:43 Alan Schmitt
2020-10-20  8:15 Alan Schmitt
2020-10-06  7:22 Alan Schmitt
2020-09-29  7:02 Alan Schmitt
2020-09-22  7:27 Alan Schmitt
2020-09-08 13:11 Alan Schmitt
2020-09-01  7:55 Alan Schmitt
2020-08-18  7:25 Alan Schmitt
2020-07-28 16:57 Alan Schmitt
2020-07-21 14:42 Alan Schmitt
2020-07-14  9:54 Alan Schmitt
2020-07-07 10:04 Alan Schmitt
2020-06-30  7:00 Alan Schmitt
2020-06-16  8:36 Alan Schmitt
2020-06-09  8:28 Alan Schmitt
2020-05-19  9:52 Alan Schmitt
2020-05-12  7:45 Alan Schmitt
2020-05-05  7:45 Alan Schmitt
2020-04-28 12:44 Alan Schmitt
2020-04-21  8:58 Alan Schmitt
2020-04-14  7:28 Alan Schmitt
2020-04-07  7:51 Alan Schmitt
2020-03-31  9:54 Alan Schmitt
2020-03-24  9:31 Alan Schmitt
2020-03-17 11:04 Alan Schmitt
2020-03-10 14:28 Alan Schmitt
2020-03-03  8:00 Alan Schmitt
2020-02-25  8:51 Alan Schmitt
2020-02-18  8:18 Alan Schmitt
2020-02-04  8:47 Alan Schmitt
2020-01-28 10:53 Alan Schmitt
2020-01-21 14:08 Alan Schmitt
2020-01-14 14:16 Alan Schmitt
2020-01-07 13:43 Alan Schmitt
2019-12-31  9:18 Alan Schmitt
2019-12-17  8:52 Alan Schmitt
2019-12-10  8:21 Alan Schmitt
2019-12-03 15:42 Alan Schmitt
2019-11-26  8:33 Alan Schmitt
2019-11-12 13:21 Alan Schmitt
2019-11-05  6:55 Alan Schmitt
2019-10-15  7:28 Alan Schmitt
2019-09-03  7:35 Alan Schmitt

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=m2wmii278p.fsf@petitepomme.net \
    --to=alan.schmitt@polytechnique.org \
    --cc=caml-list@inria.fr \
    --cc=lwn@lwn.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox