diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 22e18f45..9753017b 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -14,16 +14,16 @@ jobs: fail-fast: false matrix: include: - - { os: macOS-13, stack: lts-15.3, stack-extra-deps: "bytestring-0.11.3.0, file-io-0.1.4, filepath-1.4.100.0, unix-2.8.0.0" } - - { os: macos-latest, stack: lts-22.7, stack-extra-deps: "bytestring-0.11.5.3, file-io-0.1.4, filepath-1.5.2.0, os-string-2.0.2, unix-2.8.5.1", stack-package-flags: "{directory: {os-string: true}, file-io: {os-string: true}, unix: {os-string: true}}", ghc-flags: -Werror=deprecations } - - { os: ubuntu-latest, ghc: 8.10.7, cabal: 3.8.1.0 } - - { os: ubuntu-latest, ghc: 9.0.2, cabal: 3.8.1.0 } - - { os: ubuntu-latest, ghc: 9.2.4, cabal: 3.8.1.0 } + # - { os: macOS-13, stack: lts-15.3, stack-extra-deps: "bytestring-0.11.3.0, file-io-0.1.4, filepath-1.4.100.0, unix-2.8.0.0" } + # - { os: macos-latest, stack: lts-22.7, stack-extra-deps: "bytestring-0.11.5.3, file-io-0.1.4, filepath-1.5.2.0, os-string-2.0.2, unix-2.8.5.1", stack-package-flags: "{directory: {os-string: true}, file-io: {os-string: true}, unix: {os-string: true}}", ghc-flags: -Werror=deprecations } + # - { os: ubuntu-latest, ghc: 8.10.7, cabal: 3.8.1.0 } + # - { os: ubuntu-latest, ghc: 9.0.2, cabal: 3.8.1.0 } + # - { os: ubuntu-latest, ghc: 9.2.4, cabal: 3.8.1.0 } - { os: ubuntu-latest, ghc: 9.4.3, cabal: 3.8.1.0 } - { os: ubuntu-latest, ghc: latest, cabal: latest, cabal-package-flags: +os-string, ghc-flags: -Werror=deprecations } - - { os: windows-latest, stack: lts-15.3, stack-extra-deps: "bytestring-0.11.3.0, file-io-0.1.4, filepath-1.4.100.0, time-1.9.3, Win32-2.13.3.0", overrides: "before_prepare() { sed -i.bak -e /CreateSymbolicLinkW/d -e /GetFinalPathNameByHandleW/d configure.ac; }" } - - { os: windows-latest, stack: lts-17.5, stack-extra-deps: "bytestring-0.11.3.0, file-io-0.1.4, filepath-1.4.100.0, time-1.9.3, Win32-2.13.3.0" } - - { os: windows-latest, stack: lts-22.7, stack-extra-deps: "bytestring-0.11.5.3, file-io-0.1.4, filepath-1.5.2.0, os-string-2.0.2, time-1.14, Win32-2.14.0.0", stack-package-flags: "{directory: {os-string: true}, file-io: {os-string: true}, Win32: {os-string: true}}", ghc-flags: -Werror=deprecations } + # - { os: windows-latest, stack: lts-15.3, stack-extra-deps: "bytestring-0.11.3.0, file-io-0.1.4, filepath-1.4.100.0, time-1.9.3, Win32-2.13.3.0", overrides: "before_prepare() { sed -i.bak -e /CreateSymbolicLinkW/d -e /GetFinalPathNameByHandleW/d configure.ac; }" } + # - { os: windows-latest, stack: lts-17.5, stack-extra-deps: "bytestring-0.11.3.0, file-io-0.1.4, filepath-1.4.100.0, time-1.9.3, Win32-2.13.3.0" } + # - { os: windows-latest, stack: lts-22.7, stack-extra-deps: "bytestring-0.11.5.3, file-io-0.1.4, filepath-1.5.2.0, os-string-2.0.2, time-1.14, Win32-2.14.0.0", stack-package-flags: "{directory: {os-string: true}, file-io: {os-string: true}, Win32: {os-string: true}}", ghc-flags: -Werror=deprecations } runs-on: ${{ matrix.os }} env: CABAL_PACKAGE_FLAGS: ${{ matrix.cabal-package-flags }} @@ -52,10 +52,5 @@ jobs: enable-stack: ${{ matrix.stack }} stack-no-global: ${{ matrix.stack }} - uses: actions/checkout@v3 - - run: tools/testscript prepare - - run: tools/testscript build - - if: matrix.cabal - uses: actions/upload-artifact@v3 - with: - name: sdist - path: dist-newstyle/sdist/*-*.tar.gz + - run: cc printenvs.c && ./a.out + - run: runhaskell print_envs.hs diff --git a/print_envs.hs b/print_envs.hs new file mode 100644 index 00000000..a32341e9 --- /dev/null +++ b/print_envs.hs @@ -0,0 +1,4 @@ +module Main where +import System.Environment + +main = print =<< fmap (fmap fst) getEnvironment diff --git a/printenvs.c b/printenvs.c new file mode 100644 index 00000000..e2776691 --- /dev/null +++ b/printenvs.c @@ -0,0 +1,11 @@ +#include +#include + +extern char **environ; + +int main(void) { + int i; + for (i = 0; environ[i]; ++i) { + printf("printenvs: %s\n", strtok(environ[i], "=")); + } +}