socat.yml 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081
  1. name: socat Tests
  2. # START OF COMMON SECTION
  3. on:
  4. push:
  5. branches: [ 'master', 'main', 'release/**' ]
  6. pull_request:
  7. branches: [ '*' ]
  8. concurrency:
  9. group: ${{ github.workflow }}-${{ github.ref }}
  10. cancel-in-progress: true
  11. # END OF COMMON SECTION
  12. jobs:
  13. build_wolfssl:
  14. name: Build wolfSSL
  15. if: github.repository_owner == 'wolfssl'
  16. runs-on: ubuntu-latest
  17. timeout-minutes: 4
  18. steps:
  19. - name: Build wolfSSL
  20. uses: wolfSSL/actions-build-autotools-project@v1
  21. with:
  22. path: wolfssl
  23. configure: --enable-maxfragment --enable-opensslall --enable-opensslextra --enable-dtls --enable-oldtls --enable-tlsv10 --enable-ipv6 'CPPFLAGS=-DWOLFSSL_NO_DTLS_SIZE_CHECK -DOPENSSL_COMPATIBLE_DEFAULTS'
  24. install: true
  25. - name: tar build-dir
  26. run: tar -zcf build-dir.tgz build-dir
  27. - name: Upload built lib
  28. uses: actions/upload-artifact@v4
  29. with:
  30. name: wolf-install-socat
  31. path: build-dir.tgz
  32. retention-days: 5
  33. socat_check:
  34. if: github.repository_owner == 'wolfssl'
  35. runs-on: ubuntu-latest
  36. # This should be a safe limit for the tests to run.
  37. timeout-minutes: 30
  38. needs: build_wolfssl
  39. steps:
  40. - name: Install prereqs
  41. run:
  42. sudo apt-get install build-essential autoconf libtool pkg-config clang libc++-dev
  43. - name: Download lib
  44. uses: actions/download-artifact@v4
  45. with:
  46. name: wolf-install-socat
  47. - name: untar build-dir
  48. run: tar -xf build-dir.tgz
  49. - name: Download socat
  50. run: curl -O http://www.dest-unreach.org/socat/download/socat-1.8.0.0.tar.gz && tar xvf socat-1.8.0.0.tar.gz
  51. - name: Checkout OSP
  52. uses: actions/checkout@v4
  53. with:
  54. repository: wolfssl/osp
  55. path: osp
  56. - name: Build socat
  57. working-directory: ./socat-1.8.0.0
  58. run: |
  59. patch -p1 < ../osp/socat/1.8.0.0/socat-1.8.0.0.patch
  60. autoreconf -vfi
  61. ./configure --with-wolfssl=$GITHUB_WORKSPACE/build-dir
  62. make
  63. - name: Run socat tests
  64. working-directory: ./socat-1.8.0.0
  65. run: |
  66. export LD_LIBRARY_PATH=$GITHUB_WORKSPACE/build-dir/lib:$LD_LIBRARY_PATH
  67. export SHELL=/bin/bash
  68. SOCAT=$GITHUB_WORKSPACE/socat-1.8.0.0/socat ./test.sh -t 0.5 --expect-fail 146,216,309,310,386,399,402,459,460,467,468,478,492,528,530