diff options
-rw-r--r-- | .gitlab-ci.yml | 13 | ||||
-rwxr-xr-x | .gitlab/ci.sh | 8 |
2 files changed, 12 insertions, 9 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 548fabef9f..7aa6f66c73 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -299,12 +299,11 @@ hadrian-ghc-in-ghci: tags: - x86_64-linux script: + - git clean -xdf && git submodule foreach git clean -xdf - .gitlab/ci.sh setup + - .gitlab/ci.sh configure - cabal update - cd hadrian; cabal new-build -j`../mk/detect-cpu-count.sh` --with-compiler=$GHC --project-file=ci.project; cd .. - - git clean -xdf && git submodule foreach git clean -xdf - - ./boot - - ./configure $CONFIGURE_ARGS # Load ghc-in-ghci then immediately exit and check the modules loaded - echo ":q" | hadrian/ghci -j`mk/detect-cpu-count.sh`| tail -n2 | grep "Ok," after_script: @@ -345,9 +344,13 @@ hadrian-ghc-in-ghci: lint-base: extends: .lint-params + variables: + BUILD_FLAVOUR: default script: - - hadrian/build -c -j stage1:lib:base - - hadrian/build -j lint:base + - .gitlab/ci.sh setup + - .gitlab/ci.sh configure + - .gitlab/ci.sh run_hadrian stage1:lib:base + - .gitlab/ci.sh run_hadrian lint:base ############################################################ # Validation via Pipelines (make) diff --git a/.gitlab/ci.sh b/.gitlab/ci.sh index 22253e974c..457db1c0fa 100755 --- a/.gitlab/ci.sh +++ b/.gitlab/ci.sh @@ -442,9 +442,6 @@ function test_make() { } function build_hadrian() { - if [ -z "$BUILD_FLAVOUR" ]; then - fail "BUILD_FLAVOUR not set" - fi if [ -z "$BIN_DIST_NAME" ]; then fail "BIN_DIST_NAME not set" fi @@ -506,6 +503,9 @@ function clean() { } function run_hadrian() { + if [ -z "$BUILD_FLAVOUR" ]; then + fail "BUILD_FLAVOUR not set" + fi if [ -z "$BIGNUM_BACKEND" ]; then BIGNUM_BACKEND="gmp"; fi if [ -n "$VERBOSE" ]; then HADRIAN_ARGS="$HADRIAN_ARGS -V"; fi run hadrian/build-cabal \ @@ -575,7 +575,7 @@ case $1 in test_hadrian || res=$? push_perf_notes exit $res ;; - run_hadrian) run_hadrian $@ ;; + run_hadrian) shift; run_hadrian $@ ;; perf_test) run_perf_test ;; clean) clean ;; shell) shell $@ ;; |