Skip to content

Commit

Permalink
CI changes to update Perl versions on Windows
Browse files Browse the repository at this point in the history
more CI stuff

Appveyor: enable BD tests
GH: cleanup commented code

GH CI windows cache

more appveyoring

GH CI: quieter windows

more appveyor shenanigans

GH CI windows: cache ./local

shogo82148/actions-setup-perl sends modules there,
overriding the env settings

CI appveyor full build again

CI appveyor partial build to trigger cache

CI probing

GH CI: windows use strawberry

GH CI: use shogo82148/actions-setup-perl on windows

GH CI: use perl 5.40 on windows

GH CI: refresh windows cache

GH CI: cache and checkout actions to v4

CI: appveyor to perl 5.38
  • Loading branch information
shawnlaffan committed Sep 6, 2024
1 parent 89efbf8 commit c9f98b9
Show file tree
Hide file tree
Showing 4 changed files with 37 additions and 69 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/linux_de_locale.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4

- uses: shogo82148/actions-setup-perl@v1
with:
Expand Down Expand Up @@ -65,7 +65,7 @@ jobs:
ls -l perlversion.txt
- name: Cache CPAN modules
uses: actions/cache@v3
uses: actions/cache@v4
with:
path: ~/perl5
key: ${{ runner.os }}-build-${{ hashFiles('perlversion.txt') }}
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/macos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
runs-on: macOS-latest

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4

- name: Set up Perl
run: |
Expand All @@ -47,7 +47,7 @@ jobs:
ls -l perlversion.txt
- name: Cache CPAN modules
uses: actions/cache@v3
uses: actions/cache@v4
with:
path: ~/perl5
key: ${{ runner.os }}-build-${{ hashFiles('perlversion.txt') }}
Expand Down
82 changes: 24 additions & 58 deletions .github/workflows/windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@ on:
pull_request:

env:
PERL5LIB: c:\cx\lib\perl5
PERL_LOCAL_LIB_ROOT: c:/cx
PERL_MB_OPT: --install_base C:/cx
PERL_MM_OPT: INSTALL_BASE=C:/cx
# PERL5LIB: c:\cx\lib\perl5
# PERL_LOCAL_LIB_ROOT: c:/cx
# PERL_MB_OPT: --install_base C:/cx
# PERL_MM_OPT: INSTALL_BASE=C:/cx
#ALIEN_BUILD_PRELOAD: Fetch::Cache
AUTOMATED_TESTING: 1

Expand All @@ -21,74 +21,40 @@ jobs:
runs-on: windows-latest

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4

- name: Set up Perl
run: |
choco install strawberryperl
echo "C:\strawberry\c\bin;C:\strawberry\perl\site\bin;C:\strawberry\perl\bin" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
##echo $env:PATH
- uses: shogo82148/actions-setup-perl@v1
with:
perl-version: "5.38"
distribution: strawberry

#- name: Check path
# run: |
# echo $env:PATH
# echo "glargglarg"
# echo $GITHUB_PATH
# echo "zogzogzog"
# $env:PATH = "C:\strawberry\c\bin;C:\strawberry\perl\site\bin;C:\strawberry\perl\bin;$env:PATH"
# echo $env:PATH
# echo "zigzig"
# echo "C:\strawberry\c\bin;C:\strawberry\perl\site\bin;C:\strawberry\perl\bin;$env:PATH" > $GITHUB_PATH
# echo $GITHUB_PATH

- name: perl -V
run: perl -V

- name: Prepare for CPAN cache
run: |
perl -V > perlversion.txt
echo "20220920" >> perlversion.txt
echo "20240906b" >> perlversion.txt
dir perlversion.txt
- name: Cache CPAN modules
uses: actions/cache@v3
uses: actions/cache@v4
with:
path: c:\cx
path: D:\a\biodiverse\biodiverse\local
key: ${{ runner.os }}-build-${{ hashFiles('perlversion.txt') }}
restore-keys: |
${{ runner.os }}-build-${{ hashFiles('perlversion.txt') }}
- name: Prepare for Alien cache
# Was giving grief. Hurts not to leave here.
- name: Install dependencies Sereal
run: |
perl -V > aliencache.txt
echo 'aliens' >> aliencache.txt
dir aliencache.txt
- name: Cache Alien downloads
uses: actions/cache@v3
with:
path: $HOMEPATH\.alienbuild
key: ${{ runner.os }}-build-${{ hashFiles('aliencache.txt') }}
restore-keys: |
${{ runner.os }}-build-${{ hashFiles('aliencache.txt') }}
#- name: Install Dependencies
# run: curl -sL https://git.io/cpm | perl - install -g --show-build-log-on-failure


#- name: Install dependencies 1
# run: |
# #cpanm --notest local::lib
# #eval "$(perl -Mlocal::lib=${PWD}/perl_modules)"
# cpanm --quiet --notest Alien::Build
# cpanm --quiet --notest Alien::Build::MM
# cpanm --quiet --notest Sort::Versions
# cpanm --quiet --notest PkgConfig
# cpanm --quiet --notest Alien::Build::Plugin::Cleanse::BuildDir
# cpanm --quiet --notest File::Find::Rule
# cpanm --quiet --notest Alien::Build::Plugin::Fetch::Cache
# cpanm --quiet --notest Env::ShellWords
# cpanm --quiet --notest Test2::Suite
#echo $env:PATH
echo $env:PERL5LIB
cpanm --installdeps Sereal::Decoder
cpanm Sereal::Decoder
cpanm --installdeps Sereal::Encoder
cpanm Sereal::Encoder
cpanm Sereal
- name: Install dependencies Alien::MSYS
run: |
Expand All @@ -99,7 +65,7 @@ jobs:
run: |
echo $env:PATH
cpanm --notest --installdeps Alien::sqlite
cpanm -v Alien::sqlite~1.05
cpanm -v Alien::sqlite
- name: Install dependencies Alien::proj
run: |
Expand All @@ -117,7 +83,7 @@ jobs:
cpanm --notest --installdeps Alien::gdal
echo "ALIEN_GDAL_CONFIG_ARGS=--with-hide_internal_symbols" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
# qhull issues on gdal 3.5, maybe fixed in 3.6
$env:ALIEN_GDAL_CONFIG_ARGS = "--with-hide-internal-symbols=yes --without-gnm --without-qhull"
# $env:ALIEN_GDAL_CONFIG_ARGS = "--with-hide-internal-symbols=yes --without-gnm --without-qhull"
Get-PSDrive C | Select-Object Used,Free
# clunky path override
# $env:PATH = "C:\strawberry\c\bin;C:\strawberry\perl\site\bin;C:\strawberry\perl\bin;$env:PATH"
Expand All @@ -134,5 +100,5 @@ jobs:
# Runs a set of commands using the runners shell
- name: Run tests
run: |
prove
prove -l
16 changes: 9 additions & 7 deletions appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,15 @@ branches:
skip_tags: true

cache:
- C:\Strawberry
- C:\Strawberry538
#- C:\Strawberry -> appveyor.yml

install:
- if not exist "C:\strawberry" appveyor-retry choco install strawberryperl --version 5.30.2.1
#- appveyor-retry choco upgrade strawberryperl --version 5.28.1.1
- set ST=C:\Strawberry
- set ST=C:\Strawberry538
- if exist %ST% del /Q %ST%
- if not exist %ST% appveyor-retry choco install strawberryperl --version 5.38.0 --install-arguments="INSTALLDIR=""C:\Strawberry538"""
# - appveyor-retry choco upgrade strawberryperl --version 5.38.0
- refreshenv
- set PATH=%ST%\perl\bin;%ST%\perl\site\bin;%ST%\c\bin;%PATH%
- path
- cd C:\projects\%APPVEYOR_PROJECT_NAME%
Expand All @@ -31,14 +33,14 @@ install:
- cpanm -v Alien::libtiff
- cpanm -v Alien::proj

- set ALIEN_GDAL_CONFIG_ARGS=--without-spatialite --without-gnm --without-qhull
# - set ALIEN_GDAL_CONFIG_ARGS=--without-spatialite --without-gnm --without-qhull
- cpanm -v Alien::gdal

- cpanm --notest --installdeps .
- cpanm --installdeps .


build_script:
- prove -l
#- perl -e "1"
# - perl -e "1"

0 comments on commit c9f98b9

Please sign in to comment.