-
Notifications
You must be signed in to change notification settings - Fork 19
BES-1236: Add gha workflow for building on mac #1234
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
39 commits
Select commit
Hold shift + click to select a range
bb6856d
add gha workflow for building on mac
hannahilea 564995a
add more deps
hannahilea 1933136
minimal build for testing
hannahilea bea905d
build libdap
hannahilea feb79ac
fix path var
hannahilea c258a9d
add git credentials
hannahilea cc46a22
udpate name of aws cred vars
hannahilea c9545d3
remove duplicate dep
hannahilea 4f35929
Update s3 bucket for hyrax-deps
hannahilea 8fb0985
fix tar command
hannahilea d3ada23
set PATH by gha methods
hannahilea 2984be1
fix var
hannahilea cdea56f
add missing libtool dep
hannahilea 47ca429
add homebrew to path
hannahilea 652bcaa
add bison to path
hannahilea 520a34f
add libdap dep
hannahilea e5a3855
update compiler flags for libdap
hannahilea b0bf75b
split libdap
hannahilea d74796e
attempt to fix prefix
hannahilea b4a81c6
prefix must be root b/c hyrax-deps
hannahilea b45ef1e
argh
hannahilea 40cb3fc
Merge branch 'master' into hr/gha
hannahilea 8aeb2af
attempt to fix prefix
hannahilea 9f3c12a
try try again
hannahilea 260f1cd
try try again again
hannahilea 4be9f7e
big sigh
hannahilea a0b7667
omg
hannahilea f78fd92
one more try before changing approach
hannahilea 0d67e16
trouble-shooting
hannahilea dc15a26
do not check out all history
hannahilea 358d657
i give up
hannahilea dd6976f
attempt to fix openssl flags
hannahilea fff5f19
Merge branch 'master' into hr/gha
hannahilea e97adc8
display test output failure
hannahilea 9dc182c
Merge branch 'master' into hr/gha
hannahilea 4797f18
update to use new aws creds
hannahilea 088d716
re-enable other jobs
hannahilea 89b50da
Comment out failure-only step
hannahilea eba5611
fix braces for gha var
hannahilea File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,117 @@ | ||
| # Build the bes for the same architecture as OPeNDAP developer | ||
| # machines, to ensure code changes won't break local development | ||
|
|
||
| on: | ||
| # For now, run only on manually triggered builds (workflow_dispatch). | ||
| # Uncomment the "push" and "pull_request" to build on all non-draft PRs | ||
| workflow_dispatch: | ||
| push: | ||
| branches: | ||
| - master | ||
| - main | ||
| - /^(.*-test-deploy)$/ | ||
| pull_request: | ||
| types: [opened, synchronize, reopened, ready_for_review] | ||
| concurrency: | ||
| # Cancel intermediate builds only on pull requests | ||
| group: ${{ github.workflow }}-${{ github.ref }} | ||
| cancel-in-progress: ${{ startsWith(github.ref, 'refs/pull/') }} | ||
|
|
||
| jobs: | ||
| build: | ||
| # Run on pushes or non-draft PRs | ||
| if: (github.event_name == 'push') || (github.event.pull_request.draft == false) || (github.event_name == 'workflow_dispatch') | ||
| name: Build on ${{ matrix.runs-on }} | ||
| runs-on: ${{ matrix.runs-on }} | ||
| env: | ||
| GDAL_OPTION: "--without-gdal" | ||
| CMAC_ID: "${{ secrets.AWS_GHA_BES_ID }}" | ||
| CMAC_ACCESS_KEY: "${{ secrets.AWS_GHA_BES_SECRET_KEY }}" | ||
| CMAC_URL: "https://s3.amazonaws.com/cloudydap/" | ||
| CMAC_REGION: "us-east-1" | ||
| CMAC_ON: "yes" | ||
| LDFLAGS: "-L/opt/homebrew/opt/bison/lib -L/opt/homebrew/opt/jpeg/lib -L/opt/homebrew/opt/openssl/lib" | ||
| CPPFLAGS: "-I/opt/homebrew/opt/jpeg/include -I/opt/homebrew/opt/openssl/include" | ||
| strategy: | ||
| fail-fast: false | ||
| matrix: | ||
| runs-on: | ||
| # See https://github.com/actions/runner-images/blob/main/images/macos/macos-13-Readme.md for pre-installed software | ||
| - macos-15 | ||
| - macos-15-intel | ||
| steps: | ||
| - uses: actions/checkout@v4 | ||
| with: | ||
| fetch-depth: 1 | ||
| - name: Install system dependencies | ||
| run: | | ||
| brew install bison \ | ||
| jpeg \ | ||
| cppunit \ | ||
| autoconf \ | ||
| automake \ | ||
| libgeotiff \ | ||
| libtool \ | ||
| groff \ | ||
| openssl | ||
| shell: bash | ||
| - name: Install hyrax-dependencies | ||
| run: | | ||
| aws s3 cp "s3://opendap.github.actions.build/hyrax-dependencies-${{ matrix.runs-on }}.tgz" $HOME | ||
| tar -C $HOME -xzvf $HOME/hyrax-dependencies-${{ matrix.runs-on }}.tgz | ||
| env: | ||
| AWS_ACCESS_KEY_ID: ${{ secrets.AWS_GHA_BES_ID }} | ||
| AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_GHA_BES_SECRET_KEY }} | ||
| - name: Update PATH | ||
| run: | | ||
| export prefix="$HOME/install" | ||
| echo -e "$prefix/bin:$prefix/deps/bin:/opt/homebrew/opt/bison/bin:/opt/homebrew/opt/jpeg/bin:$(cat $GITHUB_PATH)" > $GITHUB_PATH | ||
| echo "prefix: $prefix" | ||
| echo "PATH: $(cat $GITHUB_PATH)" | ||
| ls $prefix | ||
| shell: bash | ||
| - name: Build, check, and install libdap | ||
| run: | | ||
| # In the future, consider moving this to the libdap repo... | ||
| set -x | ||
| export prefix="$HOME/install" | ||
| git clone https://github.com/opendap/libdap4 | ||
| cd libdap4 | ||
| autoreconf -fiv | ||
| ./configure --prefix=$prefix --enable-developer | ||
| make -j16 | ||
| make check | ||
| make install | ||
| ls $prefix | ||
| shell: bash | ||
| - name: Configure bes build | ||
| run: | | ||
| set -x | ||
| export prefix="$HOME/install" | ||
| pwd | ||
| autoreconf --force --install --verbose | ||
| ./configure --disable-dependency-tracking --prefix=$prefix --with-dependencies=$prefix/deps $GDAL_OPTION --enable-developer | ||
| set +x | ||
| shell: bash | ||
| - name: Build and test bes | ||
| run: | | ||
| set -x | ||
| export prefix="$HOME/install" | ||
| export LD_LIBRARY_PATH="$prefix/deps/lib:$LD_LIBRARY_PATH" | ||
| make -j16 | ||
| make install | ||
| besctl start | ||
| make check -j16 | ||
| besctl stop | ||
| set +x | ||
| shell: bash | ||
| # Are the tests failing for some reason that is not locally reproducible? | ||
| # Uncomment the following lines and replace the *.log file with the file of interest. | ||
| # Don't forget to uncomment it again when you're done, or the job will always | ||
| # fail! | ||
| # continue-on-error: true | ||
| # - name: Show log for failing test | ||
| # run: | | ||
| # cat "$GITHUB_WORKSPACE/http/unit-tests/test-suite.log" | ||
| # exit 1 | ||
| # shell: bash | ||
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yup