aboutsummaryrefslogtreecommitdiffhomepage
path: root/dev/build/windows
diff options
context:
space:
mode:
Diffstat (limited to 'dev/build/windows')
-rwxr-xr-x[-rw-r--r--]dev/build/windows/MakeCoq_MinGW.bat8
-rw-r--r--dev/build/windows/makecoq_mingw.sh64
2 files changed, 70 insertions, 2 deletions
diff --git a/dev/build/windows/MakeCoq_MinGW.bat b/dev/build/windows/MakeCoq_MinGW.bat
index f960ff008..5af0fcff3 100644..100755
--- a/dev/build/windows/MakeCoq_MinGW.bat
+++ b/dev/build/windows/MakeCoq_MinGW.bat
@@ -255,6 +255,7 @@ IF NOT "%~0" == "" (
IF NOT EXIST %SETUP% (
ECHO The cygwin setup program %SETUP% doesn't exist. You must download it from https://cygwin.com/install.html.
+ ECHO If the setup is in a different folder, set the full path to %SETUP% using the -setup option.
GOTO :EOF
)
@@ -385,7 +386,6 @@ IF "%RUNSETUP%"=="Y" (
MKDIR "%CYGWIN_INSTALLDIR_WFMT%\build\buildlogs"
)
-
IF NOT "%CYGWIN_QUIET%" == "Y" (
REM Like most setup programs, cygwin setup starts the real setup as a separate process, so wait for it.
REM This is not required with the -cygquiet=Y and the resulting --no-admin option.
@@ -396,6 +396,12 @@ IF NOT "%CYGWIN_QUIET%" == "Y" (
ECHO ========== CONFIGURE CYGWIN USER ACCOUNT ==========
+REM In case this batch file is called from a cygwin bash (e.g. a git repo) we need to clear
+REM HOME (otherwise we get to the home directory of the other installation)
+REM PROFILEREAD (this is set to true if the /etc/profile has been read, which creates user)
+SET "HOME="
+SET "PROFILEREAD="
+
copy "%BATCHDIR%\configure_profile.sh" "%CYGWIN_INSTALLDIR_WFMT%\var\tmp" || GOTO ErrorExit
%BASH% --login "%CYGWIN_INSTALLDIR_CFMT%\var\tmp\configure_profile.sh" "%PROXY%" || GOTO ErrorExit
diff --git a/dev/build/windows/makecoq_mingw.sh b/dev/build/windows/makecoq_mingw.sh
index a59afb8f6..a4e60744f 100644
--- a/dev/build/windows/makecoq_mingw.sh
+++ b/dev/build/windows/makecoq_mingw.sh
@@ -118,6 +118,9 @@ mkdir -p "$PREFIX/bin"
mkdir -p "$PREFIXCOQ/bin"
mkdir -p "$PREFIXOCAML/bin"
+# This is required for building addons and plugins
+export COQBIN=$RESULT_INSTALLDIR_CFMT/bin/
+
###################### Copy Cygwin Setup Info #####################
# Copy Cygwin repo ini file and installed files db to tarballs folder.
@@ -1209,6 +1212,10 @@ function make_coq {
# 2.) clean of test suites fails with "cannot run complexity tests (no bogomips found)"
# make clean
+ # Copy these files somewhere the plugin builds can find them
+ cp dev/ci/ci-basic-overlay.sh /build/
+ cp -r dev/ci/user-overlays /build/
+
build_post
fi
}
@@ -1376,8 +1383,16 @@ function make_coq_installer {
###################### ADDONS #####################
+# The bignums library
+# Provides BigN, BigZ, BigQ that used to be part of Coq standard library
+
function make_addon_bignums {
- if build_prep https://github.com/coq/bignums/archive/ V8.8+beta1 zip 1 bignums-8.8+beta1; then
+ bignums_SHA=$(git ls-remote "$bignums_CI_GITURL" "refs/heads/$bignums_CI_BRANCH" | cut -f 1)
+ if [[ "$bignums_SHA" == "" ]]; then
+ # $bignums_CI_BRANCH must have been a tag and not a branch
+ bignums_SHA="$bignums_CI_BRANCH"
+ fi
+ if build_prep "${bignums_CI_GITURL}/archive" "$bignums_SHA" zip 1 "bignums-$bignums_SHA"; then
# To make command lines shorter :-(
echo 'COQ_SRC_SUBDIRS:=$(filter-out plugins/%,$(COQ_SRC_SUBDIRS)) plugins/syntax' >> Makefile.coq.local
log1 make all
@@ -1386,7 +1401,54 @@ function make_addon_bignums {
fi
}
+# Ltac-2 plugin
+# A new (experimental) tactic language
+
+function make_addon_ltac2 {
+ ltac2_SHA=$(git ls-remote "$ltac2_CI_GITURL" "refs/heads/$ltac2_CI_BRANCH" | cut -f 1)
+ if [[ "$ltac2_SHA" == "" ]]; then
+ # $ltac2_CI_BRANCH must have been a tag and not a branch
+ ltac2_SHA="$ltac2_CI_BRANCH"
+ fi
+ if build_prep "${ltac2_CI_GITURL}/archive" "$ltac2_SHA" zip 1 "ltac2-$ltac2_SHA"; then
+ log1 make all
+ log2 make install
+ build_post
+ fi
+}
+
+# Equations plugin
+# A function definition plugin
+
+function make_addon_equations {
+ Equations_SHA=$(git ls-remote "$Equations_CI_GITURL" "refs/heads/$Equations_CI_BRANCH" | cut -f 1)
+ if [[ "$Equations_SHA" == "" ]]; then
+ # $Equations_CI_BRANCH must have been a tag and not a branch
+ Equations_SHA="$Equations_CI_BRANCH"
+ fi
+ if build_prep "${Equations_CI_GITURL}/archive" "$Equations_SHA" zip 1 "Equations-$Equations_SHA"; then
+ # Note: PATH is autmatically saved/restored by build_prep / build_post
+ PATH=$COQBIN:$PATH
+ logn coq_makefile ${COQBIN}coq_makefile -f _CoqProject -o Makefile
+ log1 make
+ log2 make install
+ build_post
+ fi
+}
+
function make_addons {
+ if [ -n "${GITLAB_CI}" ]; then
+ export CI_BRANCH="$CI_COMMIT_REF_NAME"
+ if [[ ${CI_BRANCH#pr-} =~ ^[0-9]*$ ]]
+ then
+ export CI_PULL_REQUEST="${CI_BRANCH#pr-}"
+ fi
+ fi
+ . /build/ci-basic-overlay.sh
+ for overlay in /build/user-overlays/*.sh; do
+ . "$overlay"
+ done
+
for addon in $COQ_ADDONS; do
"make_addon_$addon"
done