From 83bae15bfbc0f6bd1e2d5689dd3a0b5781bd021e Mon Sep 17 00:00:00 2001 From: Kate Date: Fri, 20 Sep 2024 18:02:45 +0100 Subject: [PATCH 1/6] Fix the release script after the bump of dune lang to 2.6 Bump done in 1e79693bb30b1973de5170d91523535ea011e4bb Dune 2.6 makes the opam executables non-writeable so we have to chmod to strip the symbols --- master_changes.md | 1 + release/Dockerfile.in | 1 + release/Makefile | 1 + 3 files changed, 3 insertions(+) diff --git a/master_changes.md b/master_changes.md index 00be362c74e..366d80161d4 100644 --- a/master_changes.md +++ b/master_changes.md @@ -73,6 +73,7 @@ users) ## Infrastructure ## Release scripts + * Fix the release script after the bump of dune lang to 2.6 [#6204 @kit-ty-kate] ## Install script diff --git a/release/Dockerfile.in b/release/Dockerfile.in index bc21c687941..df94b4531ef 100644 --- a/release/Dockerfile.in +++ b/release/Dockerfile.in @@ -27,6 +27,7 @@ CMD { tar xz && \ ./configure --with-vendored-deps --with-mccs && \ echo "(${LINKING})" > src/client/linking.sexp && \ make opam && \ + chmod u+w _build/default/src/client/opamMain.exe && \ strip opam ; \ } >&2 && \ cat opam diff --git a/release/Makefile b/release/Makefile index 077acc9c0cb..39b5a2593bb 100644 --- a/release/Makefile +++ b/release/Makefile @@ -124,6 +124,7 @@ host: $(OUTDIR)/opam-full-$(VERSION).tar.gz build/$(HOST).env echo "$(call LINKING,$(HOST_OS))" >src/client/linking.sexp && \ $(MAKE) opam; \ ) + chmod u+w build/opam-full-$(VERSION)/_build/default/src/client/opamMain.exe cp build/opam-full-$(VERSION)/opam $(OUTDIR)/opam-$(VERSION)-$(HOST) strip $(OUTDIR)/opam-$(VERSION)-$(HOST) $(OUTDIR)/opam-$(VERSION)-$(HOST) --version From 897187c59583f57c93f196324b6e0b3627a421ed Mon Sep 17 00:00:00 2001 From: Kate Date: Fri, 20 Sep 2024 18:04:08 +0100 Subject: [PATCH 2/6] Fix the release script after the introduction of opam_core_stubs Introduced in 1e79693bb30b1973de5170d91523535ea011e4bb --- master_changes.md | 1 + release/Makefile | 7 +++---- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/master_changes.md b/master_changes.md index 366d80161d4..1061efdbbab 100644 --- a/master_changes.md +++ b/master_changes.md @@ -74,6 +74,7 @@ users) ## Release scripts * Fix the release script after the bump of dune lang to 2.6 [#6204 @kit-ty-kate] + * Fix the release script after the introduction of opam\_core\_stubs [#6204 @kit-ty-kate] ## Install script diff --git a/release/Makefile b/release/Makefile index 39b5a2593bb..85f527ffb73 100644 --- a/release/Makefile +++ b/release/Makefile @@ -53,22 +53,21 @@ build/%.image: build/Dockerfile.% # Actually, this is for alpine 3.13, and varies CLINKING_linux = \ -Wl,-Bstatic \ --lunix -lmccs_stubs -lmccs_glpk_stubs -lsha_stubs \ +-lunix -lmccs_stubs -lmccs_glpk_stubs -lsha_stubs -lopam_core_stubs \ -lstdc++ \ -static-libgcc \ -static # -Wl,-Bdynamic CLINKING_macos = \ --lunix -lmccs_stubs -lmccs_glpk_stubs -lsha_stubs \ +-lunix -lmccs_stubs -lmccs_glpk_stubs -lsha_stubs -lopam_core_stubs \ -lstdc++ CLINKING_openbsd = $(CLINKING_macos) CLINKING_freebsd = $(CLINKING_macos) CLINKING_windows = \ --lunix -lmccs_stubs -lmccs_glpk_stubs -lsha_stubs \ --lopam_stubs_win32_stubs \ +-lunix -lmccs_stubs -lmccs_glpk_stubs -lsha_stubs -lopam_core_stubs \ -l:libstdc++.a -l:libpthread.a \ -Wl,-static \ -ladvapi32 -lgdi32 -luser32 -lshell32 -lole32 -luuid -luserenv From fd571a7656d22aca00d42bc5ae823f5acfe82fc3 Mon Sep 17 00:00:00 2001 From: Kate Date: Fri, 20 Sep 2024 18:05:53 +0100 Subject: [PATCH 3/6] Improve the release script by ignoring interactive questions asked by the FreeBSD package manager This can happen when the current release is out-of-date (e.g. FreeBSD 13.2 vs 13.3) --- master_changes.md | 1 + release/release.sh | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/master_changes.md b/master_changes.md index 1061efdbbab..10c904d63bc 100644 --- a/master_changes.md +++ b/master_changes.md @@ -75,6 +75,7 @@ users) ## Release scripts * Fix the release script after the bump of dune lang to 2.6 [#6204 @kit-ty-kate] * Fix the release script after the introduction of opam\_core\_stubs [#6204 @kit-ty-kate] + * Improve the release script by ignoring interactive questions asked by the FreeBSD package manager [#6204 @kit-ty-kate] ## Install script diff --git a/release/release.sh b/release/release.sh index a74fb148332..ee2dd59d3e1 100755 --- a/release/release.sh +++ b/release/release.sh @@ -90,5 +90,5 @@ make JOBS="${JOBS}" TAG="$TAG" s390x-linux [ -f "${OUTDIR}/opam-$TAG-arm64-macos" ] || make TAG="$TAG" JOBS="${JOBS}" macos-local MACOS_ARCH=arm64 REMOTE_DIR=opam-release-$TAG GIT_URL="$CWD/.." [ -d ./qemu-base-images ] || git clone https://gitlab.com/kit-ty-kate/qemu-base-images.git [ -f "${OUTDIR}/opam-$TAG-x86_64-openbsd" ] || qemu_build 9999 OpenBSD-7.4-amd64 "pkg_add gmake curl bzip2" gmake x86_64 -[ -f "${OUTDIR}/opam-$TAG-x86_64-freebsd" ] || qemu_build 9998 FreeBSD-13.2-RELEASE-amd64 "pkg install -y gmake curl bzip2" gmake x86_64 +[ -f "${OUTDIR}/opam-$TAG-x86_64-freebsd" ] || qemu_build 9998 FreeBSD-13.2-RELEASE-amd64 "env IGNORE_OSVERSION=yes pkg install -y gmake curl bzip2" gmake x86_64 [ -f "${OUTDIR}/opam-$TAG-x86_64-windows" ] || windows_build 9997 Windows-10-x86_64 From 11592aaa0252576856a00ee3c7daf41b81111382 Mon Sep 17 00:00:00 2001 From: Kate Date: Fri, 20 Sep 2024 18:08:19 +0100 Subject: [PATCH 4/6] Improve the release script by leaving more time for Windows to boot up This leaves more time for the release manager to execute 'net stop sshd && net start sshd' when needed, as sometimes Windows will refuse to have users ssh into the machine without a password --- release/release.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/release/release.sh b/release/release.sh index ee2dd59d3e1..fa34171aadb 100755 --- a/release/release.sh +++ b/release/release.sh @@ -40,7 +40,7 @@ windows_build() { qemu-img convert -O raw "./${image}.qcow2" "./${image}.raw" # NOTE: -machine q35 seems to be required to avoid random but recurring crashes "qemu-system-x86_64" -drive "file=./${image}.raw,format=raw" -nic "user,hostfwd=tcp::${port}-:22" -m 6G -smp "${JOBS}" -machine q35 & - sleep 120 + sleep 240 fi # Disable Windows Defender before anything else (makes the build process faster) From efdba21b5fe316a2c1bbfc106c099c9e90632bc8 Mon Sep 17 00:00:00 2001 From: Kate Date: Fri, 20 Sep 2024 18:12:13 +0100 Subject: [PATCH 5/6] Bump the version of opam to 2.4.0~alpha1~dev --- configure | 18 +++++++++--------- configure.ac | 2 +- master_changes.md | 1 + opam-client.opam | 2 +- opam-core.opam | 2 +- opam-devel.opam | 2 +- opam-format.opam | 2 +- opam-installer.opam | 2 +- opam-repository.opam | 2 +- opam-solver.opam | 2 +- opam-state.opam | 2 +- 11 files changed, 19 insertions(+), 18 deletions(-) diff --git a/configure b/configure index 8ada0e003d5..10a0cd26ce9 100755 --- a/configure +++ b/configure @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.71 for opam 2.3.0~alpha1. +# Generated by GNU Autoconf 2.71 for opam 2.4.0~alpha1~dev. # # # Copyright (C) 1992-1996, 1998-2017, 2020-2021 Free Software Foundation, @@ -609,8 +609,8 @@ MAKEFLAGS= # Identity of this package. PACKAGE_NAME='opam' PACKAGE_TARNAME='opam' -PACKAGE_VERSION='2.3.0~alpha1' -PACKAGE_STRING='opam 2.3.0~alpha1' +PACKAGE_VERSION='2.4.0~alpha1~dev' +PACKAGE_STRING='opam 2.4.0~alpha1~dev' PACKAGE_BUGREPORT='' PACKAGE_URL='' @@ -1300,7 +1300,7 @@ if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures opam 2.3.0~alpha1 to adapt to many kinds of systems. +\`configure' configures opam 2.4.0~alpha1~dev to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1362,7 +1362,7 @@ fi if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of opam 2.3.0~alpha1:";; + short | recursive ) echo "Configuration of opam 2.4.0~alpha1~dev:";; esac cat <<\_ACEOF @@ -1478,7 +1478,7 @@ fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -opam configure 2.3.0~alpha1 +opam configure 2.4.0~alpha1~dev generated by GNU Autoconf 2.71 Copyright (C) 2021 Free Software Foundation, Inc. @@ -1595,7 +1595,7 @@ cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by opam $as_me 2.3.0~alpha1, which was +It was created by opam $as_me 2.4.0~alpha1~dev, which was generated by GNU Autoconf 2.71. Invocation command line was $ $0$ac_configure_args_raw @@ -7613,7 +7613,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by opam $as_me 2.3.0~alpha1, which was +This file was extended by opam $as_me 2.4.0~alpha1~dev, which was generated by GNU Autoconf 2.71. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -7668,7 +7668,7 @@ ac_cs_config_escaped=`printf "%s\n" "$ac_cs_config" | sed "s/^ //; s/'/'\\\\\\\\ cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_config='$ac_cs_config_escaped' ac_cs_version="\\ -opam config.status 2.3.0~alpha1 +opam config.status 2.4.0~alpha1~dev configured by $0, generated by GNU Autoconf 2.71, with options \\"\$ac_cs_config\\" diff --git a/configure.ac b/configure.ac index a5a2b1281cb..919416bd320 100644 --- a/configure.ac +++ b/configure.ac @@ -1,5 +1,5 @@ dnl The line below must be formatted AC_INIT([opam],[VERSION]) with no extra spaces -AC_INIT([opam],[2.3.0~alpha1]) +AC_INIT([opam],[2.4.0~alpha1~dev]) AC_COPYRIGHT(Copyright 2012-2019 OcamlPro SAS) AC_CONFIG_MACRO_DIR([m4]) diff --git a/master_changes.md b/master_changes.md index 10c904d63bc..10b180ac5a1 100644 --- a/master_changes.md +++ b/master_changes.md @@ -11,6 +11,7 @@ moved, etc.), please update the _API updates_ part (it helps opam library users) ## Version + * Bump the version of opam to 2.4.0~alpha1~dev [#6204 @kit-ty-kate] ## Global CLI diff --git a/opam-client.opam b/opam-client.opam index 45dc91582fc..ba8d870ca45 100644 --- a/opam-client.opam +++ b/opam-client.opam @@ -1,5 +1,5 @@ opam-version: "2.0" -version: "2.3.0~alpha1" +version: "2.4.0~alpha1~dev" synopsis: "Client library for opam 2.2" description: """ Actions on the opam root, switches, installations, and front-end. diff --git a/opam-core.opam b/opam-core.opam index c9ec726082f..57fba6b186b 100644 --- a/opam-core.opam +++ b/opam-core.opam @@ -1,5 +1,5 @@ opam-version: "2.0" -version: "2.3.0~alpha1" +version: "2.4.0~alpha1~dev" synopsis: "Core library for opam 2.2" description: "Small standard library extensions, and generic system interaction modules used by opam." diff --git a/opam-devel.opam b/opam-devel.opam index 6c9f0e9b63f..a39c8985702 100644 --- a/opam-devel.opam +++ b/opam-devel.opam @@ -1,5 +1,5 @@ opam-version: "2.0" -version: "2.3.0~alpha1" +version: "2.4.0~alpha1~dev" synopsis: "Bootstrapped development binary for opam 2.2" description: """ This package compiles (bootstraps) opam. For consistency and safety of the installation, the binaries are not installed into the PATH, but into lib/opam-devel, from where the user can manually install them system-wide. diff --git a/opam-format.opam b/opam-format.opam index 7fc85dd7fc2..402b69910f4 100644 --- a/opam-format.opam +++ b/opam-format.opam @@ -1,5 +1,5 @@ opam-version: "2.0" -version: "2.3.0~alpha1" +version: "2.4.0~alpha1~dev" synopsis: "Format library for opam 2.2" description: """ Definition of opam datastructures and its file interface. diff --git a/opam-installer.opam b/opam-installer.opam index 259d43c35ba..2523b72fd78 100644 --- a/opam-installer.opam +++ b/opam-installer.opam @@ -1,5 +1,5 @@ opam-version: "2.0" -version: "2.3.0~alpha1" +version: "2.4.0~alpha1~dev" synopsis: "Installation of files to a prefix, following opam conventions" description: """ opam-installer is a small tool that can read *.install files, as defined by opam [1], and execute them to install or remove package files without going through opam. diff --git a/opam-repository.opam b/opam-repository.opam index 0df391ddcbf..189d906fc50 100644 --- a/opam-repository.opam +++ b/opam-repository.opam @@ -1,5 +1,5 @@ opam-version: "2.0" -version: "2.3.0~alpha1" +version: "2.4.0~alpha1~dev" synopsis: "Repository library for opam 2.2" description: """ This library includes repository and remote sources handling, including curl/wget, rsync, git, mercurial, darcs backends. diff --git a/opam-solver.opam b/opam-solver.opam index ea99cae8153..00b1781b206 100644 --- a/opam-solver.opam +++ b/opam-solver.opam @@ -1,5 +1,5 @@ opam-version: "2.0" -version: "2.3.0~alpha1" +version: "2.4.0~alpha1~dev" synopsis: "Solver library for opam 2.2" description: """ Solver and Cudf interaction. This library is based on the Cudf and Dose libraries, and handles calls to the external solver from opam. diff --git a/opam-state.opam b/opam-state.opam index c6b7a173b0f..68763bfa725 100644 --- a/opam-state.opam +++ b/opam-state.opam @@ -1,5 +1,5 @@ opam-version: "2.0" -version: "2.3.0~alpha1" +version: "2.4.0~alpha1~dev" synopsis: "State library for opam 2.2" description: """ Handling of the ~/.opam hierarchy, repository and switch states. From 80aab0cd355ab935cb83451a14e6d2ea866a7758 Mon Sep 17 00:00:00 2001 From: Kate Date: Sat, 21 Sep 2024 20:14:44 +0100 Subject: [PATCH 6/6] Bump the requirement for dune to 2.8 dune 2.6 has a bug that prevents opam-core from being built --- dune-project | 2 +- master_changes.md | 1 + opam-client.opam | 2 +- opam-core.opam | 2 +- opam-devel.opam | 2 +- opam-format.opam | 2 +- opam-installer.opam | 2 +- opam-repository.opam | 2 +- opam-solver.opam | 2 +- opam-state.opam | 2 +- 10 files changed, 10 insertions(+), 9 deletions(-) diff --git a/dune-project b/dune-project index 15b75c2e8d0..e25aaf0d685 100644 --- a/dune-project +++ b/dune-project @@ -1,4 +1,4 @@ -(lang dune 2.6) +(lang dune 2.8) (name opam) (implicit_transitive_deps true) diff --git a/master_changes.md b/master_changes.md index 10b180ac5a1..797601f240d 100644 --- a/master_changes.md +++ b/master_changes.md @@ -70,6 +70,7 @@ users) ## VCS ## Build + * Bump the requirement for dune to 2.8 [#6204 @kit-ty-kate] ## Infrastructure diff --git a/opam-client.opam b/opam-client.opam index ba8d870ca45..d0d3358aed3 100644 --- a/opam-client.opam +++ b/opam-client.opam @@ -35,7 +35,7 @@ depends: [ "opam-repository" {= version} "re" {>= "1.10.0"} "cmdliner" {>= "1.1.0"} - "dune" {>= "2.6.0"} + "dune" {>= "2.8.0"} ] conflicts: [ "extlib" {< "1.7.8"} diff --git a/opam-core.opam b/opam-core.opam index 57fba6b186b..e9ab6da90b8 100644 --- a/opam-core.opam +++ b/opam-core.opam @@ -26,7 +26,7 @@ depends: [ "base-unix" "ocamlgraph" "re" {>= "1.9.0"} - "dune" {>= "2.6.0"} + "dune" {>= "2.8.0"} "sha" {>= "1.13"} "jsonm" "swhid_core" diff --git a/opam-devel.opam b/opam-devel.opam index a39c8985702..8bcffeda788 100644 --- a/opam-devel.opam +++ b/opam-devel.opam @@ -31,7 +31,7 @@ depends: [ "ocaml" {>= "4.08.0"} "opam-client" {= version} "cmdliner" {>= "1.1.0"} - "dune" {>= "2.6.0"} + "dune" {>= "2.8.0"} "conf-openssl" {with-test} "conf-diffutils" {with-test} ] diff --git a/opam-format.opam b/opam-format.opam index 402b69910f4..a8e3f6a3481 100644 --- a/opam-format.opam +++ b/opam-format.opam @@ -32,5 +32,5 @@ depends: [ "opam-core" {= version} "opam-file-format" {>= "2.1.4"} "re" {>= "1.9.0"} - "dune" {>= "2.6.0"} + "dune" {>= "2.8.0"} ] diff --git a/opam-installer.opam b/opam-installer.opam index 2523b72fd78..f4c5c7b8e4e 100644 --- a/opam-installer.opam +++ b/opam-installer.opam @@ -33,5 +33,5 @@ depends: [ "ocaml" {>= "4.08.0"} "opam-format" {= version} "cmdliner" {>= "0.9.8"} - "dune" {>= "2.6.0"} + "dune" {>= "2.8.0"} ] diff --git a/opam-repository.opam b/opam-repository.opam index 189d906fc50..96505f6887c 100644 --- a/opam-repository.opam +++ b/opam-repository.opam @@ -30,5 +30,5 @@ build: [ depends: [ "ocaml" {>= "4.08.0"} "opam-format" {= version} - "dune" {>= "2.6.0"} + "dune" {>= "2.8.0"} ] diff --git a/opam-solver.opam b/opam-solver.opam index 00b1781b206..976771e42b3 100644 --- a/opam-solver.opam +++ b/opam-solver.opam @@ -34,7 +34,7 @@ depends: [ "dose3" {>= "6.1"} "cudf" {>= "0.7"} "re" {>= "1.9.0"} - "dune" {>= "2.6.0"} + "dune" {>= "2.8.0"} "opam-0install-cudf" {>= "0.5.0"} ] depopts: [ diff --git a/opam-state.opam b/opam-state.opam index 68763bfa725..85f79d0e7a5 100644 --- a/opam-state.opam +++ b/opam-state.opam @@ -32,5 +32,5 @@ depends: [ "opam-repository" {= version} "re" {>= "1.9.0"} "spdx_licenses" {>= "1.0.0"} - "dune" {>= "2.6.0"} + "dune" {>= "2.8.0"} ]