Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
87dc419
Create symlinks on Windows when available
dra27 Aug 29, 2022
2f03ad6
Set MSYS and CYGWIN permanently
dra27 May 17, 2023
7f569b0
Avoid an undefined variable warning from Make
MisterDA Sep 6, 2025
6ff8729
Add the missing `$(EXE)` for `stripdebug` invocations
shym Oct 1, 2024
52adfb2
Fix backslashes in runtime/build_config.h
dra27 Feb 8, 2025
a94915c
Set FLEXDIR when bootstrapping flexlink
dra27 Jan 9, 2025
cb48ea0
Merge pull request PR#13988 from dra27/unified-header
nojb Jun 28, 2025
2d3de3e
Merge pull request PR#14243 from dra27/ld.conf
Octachron Nov 28, 2025
c4281e4
Merge pull request PR#14244 from dra27/enable-relative
gasche Dec 8, 2025
15602d4
Adapt the build for lack of bootstrap
dra27 Jun 12, 2026
3e2b055
Adapt to OCaml 5.3
dra27 Jun 12, 2026
1510bd7
Merge pull request PR#14245 from dra27/runtime-searching
nojb Dec 12, 2025
8d39c7d
Adapt the build for lack of bootstrap
dra27 Jun 13, 2026
73d01a7
Adapt to OCaml 5.3
dra27 Jun 13, 2026
1a58be7
Backporting - reduce interface changes
dra27 Jun 13, 2026
ba1eae1
Backporting - reduce runtime header changes
dra27 Jun 18, 2026
7c14d00
Change the default for --enable-suffixing
dra27 Nov 13, 2024
b67571c
Revert change to Cmo_format.library
dra27 Jun 13, 2026
1887161
Revert change to Cmx_format.unit_infos
dra27 Jun 18, 2026
ed36457
Bootstrap
dra27 Jun 13, 2026
a0591e9
Clean-up post-bootstrap
dra27 Jun 13, 2026
47b5868
Merge pull request PR#14246 from dra27/opam-install-file
NickBarnes Dec 17, 2025
c8ee9a8
Don't backport process.sh
dra27 Jul 19, 2025
1a1a642
Merge pull request PR#14152 from dra27/export-ignore
dra27 Feb 17, 2026
cbe13b4
OCaml 5.3.1+relocatable base version commit
dra27 Sep 27, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
50 changes: 47 additions & 3 deletions .depend
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,8 @@ utils/clflags.cmx : \
utils/clflags.cmi
utils/clflags.cmi : \
utils/profile.cmi \
utils/misc.cmi
utils/misc.cmi \
utils/config.cmi
utils/compression.cmo : \
utils/compression.cmi
utils/compression.cmx : \
Expand Down Expand Up @@ -2304,6 +2305,7 @@ bytecomp/bytelibrarian.cmo : \
utils/linkdeps.cmi \
utils/format_doc.cmi \
bytecomp/emitcode.cmi \
bytecomp/dll.cmi \
utils/config.cmi \
file_formats/cmo_format.cmi \
utils/clflags.cmi \
Expand All @@ -2316,6 +2318,7 @@ bytecomp/bytelibrarian.cmx : \
utils/linkdeps.cmx \
utils/format_doc.cmx \
bytecomp/emitcode.cmx \
bytecomp/dll.cmx \
utils/config.cmx \
file_formats/cmo_format.cmi \
utils/clflags.cmx \
Expand Down Expand Up @@ -2430,14 +2433,17 @@ bytecomp/bytesections.cmi :
bytecomp/dll.cmo : \
utils/misc.cmi \
utils/config.cmi \
file_formats/cmo_format.cmi \
utils/binutils.cmi \
bytecomp/dll.cmi
bytecomp/dll.cmx : \
utils/misc.cmx \
utils/config.cmx \
file_formats/cmo_format.cmi \
utils/binutils.cmx \
bytecomp/dll.cmi
bytecomp/dll.cmi :
bytecomp/dll.cmi : \
file_formats/cmo_format.cmi
bytecomp/emitcode.cmo : \
parsing/unit_info.cmi \
lambda/translmod.cmi \
Expand Down Expand Up @@ -5162,6 +5168,7 @@ middle_end/flambda/closure_conversion.cmo : \
middle_end/flambda/flambda.cmi \
lambda/debuginfo.cmi \
middle_end/convert_primitives.cmi \
middle_end/compilenv.cmi \
middle_end/compilation_unit.cmi \
middle_end/flambda/base_types/closure_origin.cmi \
middle_end/flambda/base_types/closure_id.cmi \
Expand Down Expand Up @@ -5190,6 +5197,7 @@ middle_end/flambda/closure_conversion.cmx : \
middle_end/flambda/flambda.cmx \
lambda/debuginfo.cmx \
middle_end/convert_primitives.cmx \
middle_end/compilenv.cmx \
middle_end/compilation_unit.cmx \
middle_end/flambda/base_types/closure_origin.cmx \
middle_end/flambda/base_types/closure_id.cmx \
Expand Down Expand Up @@ -7886,6 +7894,17 @@ lex/table.cmo : \
lex/table.cmx : \
lex/table.cmi
lex/table.cmi :
tools/byterntm.cmo : \
utils/misc.cmi \
bytecomp/bytesections.cmi \
tools/byterntm.cmi
tools/byterntm.cmx : \
utils/misc.cmx \
bytecomp/bytesections.cmx \
tools/byterntm.cmi
tools/byterntm.cmi : \
utils/misc.cmi \
bytecomp/bytesections.cmi
tools/cmpbyt.cmo : \
bytecomp/bytesections.cmi \
tools/cmpbyt.cmi
Expand Down Expand Up @@ -7981,13 +8000,17 @@ tools/objinfo.cmo : \
typing/ident.cmi \
utils/format_doc.cmi \
middle_end/flambda/export_info.cmi \
bytecomp/dll.cmi \
utils/config.cmi \
middle_end/compilenv.cmi \
middle_end/compilation_unit.cmi \
file_formats/cmxs_format.cmi \
file_formats/cmx_format.cmi \
file_formats/cmt_format.cmi \
file_formats/cmo_format.cmi \
file_formats/cmi_format.cmi \
bytecomp/bytesections.cmi \
tools/byterntm.cmi \
utils/binutils.cmi \
tools/objinfo.cmi
tools/objinfo.cmx : \
Expand All @@ -8004,13 +8027,17 @@ tools/objinfo.cmx : \
typing/ident.cmx \
utils/format_doc.cmx \
middle_end/flambda/export_info.cmx \
bytecomp/dll.cmx \
utils/config.cmx \
middle_end/compilenv.cmx \
middle_end/compilation_unit.cmx \
file_formats/cmxs_format.cmi \
file_formats/cmx_format.cmi \
file_formats/cmt_format.cmx \
file_formats/cmo_format.cmi \
file_formats/cmi_format.cmx \
bytecomp/bytesections.cmx \
tools/byterntm.cmx \
utils/binutils.cmx \
tools/objinfo.cmi
tools/objinfo.cmi :
Expand Down Expand Up @@ -10375,9 +10402,11 @@ testsuite/lib/testing.cmx : \
testsuite/lib/testing.cmi :
testsuite/tools/cmdline.cmo : \
testsuite/tools/harness.cmi \
utils/config.cmi \
testsuite/tools/cmdline.cmi
testsuite/tools/cmdline.cmx : \
testsuite/tools/harness.cmx \
utils/config.cmx \
testsuite/tools/cmdline.cmi
testsuite/tools/cmdline.cmi : \
testsuite/tools/harness.cmi
Expand Down Expand Up @@ -10413,6 +10442,7 @@ testsuite/tools/environment.cmo : \
file_formats/cmt_format.cmi \
file_formats/cmo_format.cmi \
bytecomp/bytesections.cmi \
tools/byterntm.cmi \
testsuite/tools/environment.cmi
testsuite/tools/environment.cmx : \
otherlibs/unix/unix.cmx \
Expand All @@ -10423,6 +10453,7 @@ testsuite/tools/environment.cmx : \
file_formats/cmt_format.cmx \
file_formats/cmo_format.cmi \
bytecomp/bytesections.cmx \
tools/byterntm.cmx \
testsuite/tools/environment.cmi
testsuite/tools/environment.cmi : \
testsuite/tools/harness.cmi
Expand Down Expand Up @@ -10466,13 +10497,20 @@ testsuite/tools/expect.cmi : \
parsing/location.cmi
testsuite/tools/harness.cmo : \
otherlibs/unix/unix.cmi \
utils/misc.cmi \
utils/config.cmi \
tools/byterntm.cmi \
testsuite/tools/harness.cmi
testsuite/tools/harness.cmx : \
otherlibs/unix/unix.cmx \
utils/misc.cmx \
utils/config.cmx \
tools/byterntm.cmx \
testsuite/tools/harness.cmi
testsuite/tools/harness.cmi :
testsuite/tools/harness.cmi : \
utils/misc.cmi \
utils/config.cmi \
tools/byterntm.cmi
testsuite/tools/lexcmm.cmo : \
testsuite/tools/parsecmm.cmi \
utils/misc.cmi \
Expand Down Expand Up @@ -10531,12 +10569,14 @@ testsuite/tools/parsecmmaux.cmi : \
middle_end/backend_var.cmi
testsuite/tools/testBytecodeBinaries.cmo : \
otherlibs/unix/unix.cmi \
utils/misc.cmi \
testsuite/tools/harness.cmi \
testsuite/tools/environment.cmi \
utils/config.cmi \
testsuite/tools/testBytecodeBinaries.cmi
testsuite/tools/testBytecodeBinaries.cmx : \
otherlibs/unix/unix.cmx \
utils/misc.cmx \
testsuite/tools/harness.cmx \
testsuite/tools/environment.cmx \
utils/config.cmx \
Expand Down Expand Up @@ -10580,13 +10620,15 @@ testsuite/tools/testRelocation.cmo : \
testsuite/tools/harness.cmi \
testsuite/tools/environment.cmi \
utils/config.cmi \
bytecomp/bytelink.cmi \
testsuite/tools/testRelocation.cmi
testsuite/tools/testRelocation.cmx : \
otherlibs/unix/unix.cmx \
testsuite/tools/toolchain.cmx \
testsuite/tools/harness.cmx \
testsuite/tools/environment.cmx \
utils/config.cmx \
bytecomp/bytelink.cmx \
testsuite/tools/testRelocation.cmi
testsuite/tools/testRelocation.cmi : \
testsuite/tools/harness.cmi \
Expand Down Expand Up @@ -10640,11 +10682,13 @@ testsuite/tools/test_in_prefix.cmx : \
testsuite/tools/test_in_prefix.cmi
testsuite/tools/test_in_prefix.cmi :
testsuite/tools/test_ld_conf.cmo : \
otherlibs/unix/unix.cmi \
testsuite/tools/harness.cmi \
testsuite/tools/environment.cmi \
utils/config.cmi \
testsuite/tools/test_ld_conf.cmi
testsuite/tools/test_ld_conf.cmx : \
otherlibs/unix/unix.cmx \
testsuite/tools/harness.cmx \
testsuite/tools/environment.cmx \
utils/config.cmx \
Expand Down
15 changes: 15 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,21 @@
# the lines involved in the conflict, which is arguably worse
#/Changes merge=union

testsuite/Makefile export-subst

# Files and directories excluded from git-generated tarballs.
.github export-ignore
manual export-ignore
release-info export-ignore
testsuite/tests export-ignore
tools/ci export-ignore
.gitattributes export-ignore
.gitignore export-ignore
.gitmodules export-ignore
.mailmap export-ignore
ocaml-variants.install export-ignore
ocaml-variants.opam export-ignore

# No header for text and META files (would be too obtrusive).
*.md typo.missing-header
README* typo.missing-header
Expand Down
50 changes: 42 additions & 8 deletions .github/workflows/build-msvc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,10 +33,13 @@ jobs:
with:
script: |
// # Always test cl and clang-cl
let compilers = ['cl', 'clang-cl'];
let compilers = ['clang-cl'];
// # Also test i686 MSVC
let include = [
{cc: 'cl', arch: 'i686'}];
{os: 'windows-latest', cc: 'cl', arch: 'i686', opam: 'false', prefix: '$PROGRAMFILES/Бактріан🐫', libdir: 'relative'},
{os: 'windows-2025', cc: 'cl', arch: 'x86_64', opam: 'true', prefix: 'C:\\\\Бактріан🐫'},
{os: 'windows-2025', cc: 'cl', arch: 'i686', opam: 'true', prefix: 'C:\\\\Бактріан🐫'}];
let libdir = ['absolute'];
// # If this is a pull request, see if the PR has the
// # 'CI: Full matrix' label. This is done using an API request,
// # rather than from context.payload.pull_request.labels, since we
Expand All @@ -52,10 +55,14 @@ jobs:
// # Test Cygwin as well
compilers.push('gcc');
// # Test bytecode-only Cygwin
include.push({cc: 'gcc', arch: 'x86_64', config_arg: '--disable-native-toplevel --disable-native-compiler'});
include.push({os: 'windows-latest', prefix: '$PROGRAMFILES/Бактріан🐫', opam: ['false'], cc: 'gcc', arch: 'x86_64', libdir: 'absolute', config_arg: '--disable-native-toplevel --disable-native-compiler'});
// # Test i686 MSVC absolute
include.push({os: 'windows-latest', prefix: '$PROGRAMFILES/Бактріан🐫', opam: ['false'], cc: 'cl', arch: 'i686', libdir: 'absolute'});
// # Expand the main matrix to include relative testing
libdir.push('relative');
}
}
return {config_arg: [''], arch: ['x86_64'], cc: compilers, include: include};
return {os: ['windows-latest'], prefix: ['$PROGRAMFILES/Бактріан🐫'], opam: ['false'], config_arg: [''], arch: ['x86_64'], cc: compilers, libdir: libdir, include: include};
- name: Determine if the testsuite should be skipped
id: skip
uses: actions/github-script@v7
Expand All @@ -73,13 +80,13 @@ jobs:
build:
permissions: {}

runs-on: windows-latest
runs-on: ${{ matrix.os }}

needs: config

timeout-minutes: ${{ matrix.cc == 'gcc' && 90 || 60 }}

name: ${{ matrix.cc == 'cl' && 'MSVC' || matrix.cc == 'gcc' && 'Cygwin' || 'clang-cl' }} ${{ matrix.arch }} ${{ matrix.config_arg != '' && format('({0})', matrix.config_arg) || '' }}
name: ${{ matrix.cc == 'cl' && 'MSVC' || matrix.cc == 'gcc' && 'Cygwin' || 'clang-cl' }} ${{ matrix.arch }} ${{ matrix.libdir }} ${{ matrix.config_arg != '' && format('({0})', matrix.config_arg) || '' }}

strategy:
matrix: ${{ fromJSON(needs.config.outputs.matrix) }}
Expand All @@ -102,7 +109,7 @@ jobs:
- name: Install Cygwin
uses: cygwin/cygwin-install-action@v3
with:
packages: make,${{ matrix.cc != 'gcc' && 'mingw64-x86_64-' || 'gcc-fortran,' }}gcc-core
packages: make,${{ matrix.cc != 'gcc' && 'mingw64-x86_64-' || 'gcc-fortran,' }}gcc-core,rsync,unzip
install-dir: 'D:\cygwin'

- name: Save Cygwin cache
Expand All @@ -118,6 +125,13 @@ jobs:
arch: ${{ matrix.arch == 'x86_64' && 'x64' || 'x86' }}
if: matrix.cc != 'gcc'

- name: Install opam
if: matrix.opam == 'true'
shell: pwsh
run: |
winget install opam --accept-source-agreements
Add-Content -Path $env:GITHUB_PATH -Value "$env:LOCALAPPDATA\Microsoft\WinGet\Links"

- name: Compute a key to cache configure results
id: autoconf-cache-key
env:
Expand All @@ -136,11 +150,14 @@ jobs:
env:
CONFIG_ARGS: >-
--cache-file=config.cache
--prefix "${{ matrix.cc != 'gcc' && '$PROGRAMFILES/Бактріан🐫' || '$(cygpath "$PROGRAMFILES/Бактріан🐫")'}}"
--prefix ${{ matrix.cc != 'gcc' && format('"{0}/_opam"', matrix.prefix) || format('"$(cygpath "{0}")"', matrix.prefix) }}
--docdir ${{ format((matrix.cc != 'gcc' && '"{0}/_opam/doc/ocaml"' || '"$(cygpath "{0}/doc/ocaml")"'), matrix.prefix) }}
${{ matrix.cc != 'gcc' && format('--host={0}-pc-windows', matrix.arch) || '' }}
${{ matrix.cc != 'gcc' && format('CC={0}', matrix.cc) || '' }}
--enable-ocamltest
${{ endsWith(matrix.arch, '64') && '--enable-native-toplevel' || '--disable-native-toplevel' }}
${{ matrix.libdir == 'relative' && '--with-relative-libdir' || '--without-relative-libdir' }}
${{ matrix.libdir == 'relative' && '--enable-runtime-search --enable-runtime-search-target=fallback' || '--disable-runtime-search --disable-runtime-search-target' }}
${{ matrix.config_arg }}
run: |
eval $(tools/msvs-promote-path)
Expand Down Expand Up @@ -193,8 +210,25 @@ jobs:
make tests

- name: Install the compiler
if: matrix.opam != 'true'
run: make install

- name: Create opam switch
if: matrix.opam == 'true'
env:
OPAMSWITCH: ${{ matrix.prefix }}
run: |
make OPAM_PACKAGE_NAME=ocaml-variants INSTALL_MODE=opam install
opam init --cli=2.4 --bare --yes --disable-sandboxing --auto-setup --cygwin-local-install
# These commands intentionally run using opam's "default" CLI
opam switch create '${{ env.OPAMSWITCH }}' --empty
opam pin add --no-action --kind=path ocaml-variants .
opam pin add --no-action flexdll flexdll
opam pin add --no-action winpthreads winpthreads
opam install --yes flexdll winpthreads
opam install --yes --assume-built ocaml-variants
opam exec -- ocamlc -v

- name: Test in prefix
run: |
eval $(tools/msvs-promote-path)
Expand Down
Loading
Loading