mirror of
https://github.com/wolfSSL/wolfssl.git
synced 2026-07-05 19:00:49 +02:00
Merge pull request #9807 from julek-wolfssl/msmtp-1.8.28
Add msmtp action
This commit is contained in:
@@ -0,0 +1,108 @@
|
||||
name: msmtp Tests
|
||||
|
||||
# START OF COMMON SECTION
|
||||
on:
|
||||
push:
|
||||
branches: [ 'master', 'main', 'release/**' ]
|
||||
pull_request:
|
||||
branches: [ '*' ]
|
||||
|
||||
concurrency:
|
||||
group: ${{ github.workflow }}-${{ github.ref }}
|
||||
cancel-in-progress: true
|
||||
# END OF COMMON SECTION
|
||||
|
||||
jobs:
|
||||
build_wolfssl:
|
||||
name: Build wolfSSL
|
||||
# Just to keep it the same as the testing target
|
||||
if: github.repository_owner == 'wolfssl'
|
||||
runs-on: ubuntu-24.04
|
||||
# This should be a safe limit for the tests to run.
|
||||
timeout-minutes: 4
|
||||
steps:
|
||||
- name: Build wolfSSL
|
||||
uses: wolfSSL/actions-build-autotools-project@v1
|
||||
with:
|
||||
path: wolfssl
|
||||
configure: --enable-opensslextra --enable-opensslall
|
||||
install: true
|
||||
|
||||
- name: tar build-dir
|
||||
run: tar -zcf build-dir.tgz build-dir
|
||||
|
||||
- name: Upload built lib
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: wolf-install-msmtp
|
||||
path: build-dir.tgz
|
||||
retention-days: 5
|
||||
|
||||
msmtp_check:
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
ref: [ 1.8.28 ]
|
||||
name: ${{ matrix.ref }}
|
||||
if: github.repository_owner == 'wolfssl'
|
||||
runs-on: ubuntu-24.04
|
||||
# This should be a safe limit for the tests to run.
|
||||
timeout-minutes: 10
|
||||
needs: build_wolfssl
|
||||
steps:
|
||||
- name: Download lib
|
||||
uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: wolf-install-msmtp
|
||||
|
||||
- name: untar build-dir
|
||||
run: tar -xf build-dir.tgz
|
||||
|
||||
- name: Checkout OSP
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
repository: wolfssl/osp
|
||||
path: osp
|
||||
|
||||
- name: Install dependencies
|
||||
run: |
|
||||
sudo apt-get update
|
||||
sudo apt-get install -y \
|
||||
autoconf automake libtool pkg-config gettext \
|
||||
libidn2-dev libsecret-1-dev autopoint
|
||||
|
||||
- name: Checkout msmtp
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
repository: marlam/msmtp
|
||||
ref: msmtp-${{ matrix.ref }}
|
||||
path: msmtp-${{ matrix.ref }}
|
||||
|
||||
- name: Apply wolfSSL patch
|
||||
working-directory: msmtp-${{ matrix.ref }}
|
||||
run: patch -p1 < $GITHUB_WORKSPACE/osp/msmtp/${{ matrix.ref }}/wolfssl-msmtp-${{ matrix.ref }}.patch
|
||||
|
||||
- name: Regenerate build system
|
||||
working-directory: msmtp-${{ matrix.ref }}
|
||||
run: autoreconf -ivf
|
||||
|
||||
- name: Configure msmtp with wolfSSL
|
||||
working-directory: msmtp-${{ matrix.ref }}
|
||||
run: |
|
||||
PKG_CONFIG_PATH=$GITHUB_WORKSPACE/build-dir/lib/pkgconfig \
|
||||
./configure --with-tls=wolfssl
|
||||
|
||||
- name: Build msmtp
|
||||
working-directory: msmtp-${{ matrix.ref }}
|
||||
run: make -j$(nproc)
|
||||
|
||||
- name: Run msmtp tests
|
||||
working-directory: msmtp-${{ matrix.ref }}
|
||||
run: LD_LIBRARY_PATH=$GITHUB_WORKSPACE/build-dir/lib make check
|
||||
|
||||
- name: Confirm msmtp built with wolfSSL
|
||||
run: ldd msmtp-${{ matrix.ref }}/src/msmtp | grep wolfssl
|
||||
|
||||
- name: Print test logs on failure
|
||||
if: ${{ failure() }}
|
||||
run: tail -n +1 msmtp-${{ matrix.ref }}/tests/*.log
|
||||
Reference in New Issue
Block a user