Skip to content

Commit

Permalink
Use checkout action to clone opus; Better quoting
Browse files Browse the repository at this point in the history
  • Loading branch information
OoLunar committed Mar 21, 2024
1 parent b3626c3 commit b9f6ae9
Showing 1 changed file with 11 additions and 8 deletions.
19 changes: 11 additions & 8 deletions .github/workflows/opus.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ jobs:
- {
name: "MacOS x64",
os: macos-latest,
install-deps: "brew install autoconf automake libtool git gcc cmake make",
install-deps: "brew install autoconf automake libtool git gcc cmake make && export PATH=\"/usr/local/opt/make/libexec/gnubin:$PATH\"",
args: "",
find-file: "libopus.*.*.*.dylib",
file: "libopus.dylib"
Expand All @@ -47,28 +47,31 @@ jobs:
}
steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
submodules: recursive
- name: Checkout Opus
uses: actions/checkout@v4
with:
repository: https://gitlab.xiph.org/xiph/opus.git
path: libs/opus
submodules: recursive
- name: Set up MSBuild
if: matrix.config.os == 'windows-latest'
uses: microsoft/setup-msbuild@v2
with:
msbuild-architecture: x64
- name: Install dependencies
run: ${{ matrix.config.install-deps }}
- name: Checkout Opus
- name: Build on ${{ matrix.config.name }}
run: |
git clone https://gitlab.xiph.org/xiph/opus libs/opus
cd libs/opus
echo "OPUS_VERSION=$(git describe --tags $(git rev-list --tags --max-count=1))" >> $GITHUB_ENV
git checkout "$OPUS_VERSION"
- name: Build on ${{ matrix.config.name }}
run: |
cmake -S . -B build ${{ matrix.config.args }} -DBUILD_SHARED_LIBS=ON -DCMAKE_BUILD_TYPE=Release
cmake -S . -B build ${{ matrix.config.args }} -DBUILD_SHARED_LIBS=ON -DCMAKE_BUILD_TYPE=Release -Wno-dev
cmake --build build --config Release
rm "${{ github.workspace }}/libs/libopus/${{ matrix.config.find-file }}"
mv build/${{ matrix.config.find-file }} "${{ github.workspace }}/libs/libopus/${{ matrix.config.file }}"
mv "build/${{ matrix.config.find-file }}" "${{ github.workspace }}/libs/libopus/${{ matrix.config.file }}"
- name: "Update ${{ matrix.config.file }}"
uses: EndBug/add-and-commit@v9
with:
Expand Down

0 comments on commit b9f6ae9

Please sign in to comment.