diff --git a/.github/workflows/pipeline.yml b/.github/workflows/pipeline.yml index 27448a2c..2fbc2226 100644 --- a/.github/workflows/pipeline.yml +++ b/.github/workflows/pipeline.yml @@ -118,13 +118,6 @@ jobs: file: devkitpro.tgz out: /opt token: ${{ secrets.SWITCH_BUILD_TOKEN }} - - - name: Cache LibAtrac9 - if: matrix.os_name != 'switch' - uses: actions/cache@v3 - with: - key: libatrac9 | ${{ matrix.os_name }} - path: vendor/LibAtrac9 - uses: lukka/get-cmake@latest - name: Setup vcpkg @@ -140,30 +133,7 @@ jobs: run: | ./build-deps.ps1 -Arg1 x64 shell: pwsh - - name: Setup Dependencies Linux/MacOS/Android - if: contains(matrix.os_name, 'macos') || contains(matrix.os_name, 'linux') || contains(matrix.os_name, 'android') - run: |- - pushd vendor - if [ ! -d "LibAtrac9" ]; then - git clone https://github.com/Thealexbarney/LibAtrac9.git --depth 1 - fi - cd LibAtrac9/C - if [[ "${{ matrix.os_name }}" == "macos"* ]]; then - sed -i '' -e 's/,--version-script=libatrac9.version//g' Makefile - fi - if [ -z "${CC}" ]; then - make - else - make CC="$CC" - fi - - mkdir -p ../include/libatrac9 - mkdir -p ../libs - cp bin/libatrac9.* ../libs/ - cp src/libatrac9.h ../include/libatrac9/ - popd - echo "LIBATRAC9DIR=${{ github.workspace }}/vendor/LibAtrac9" >> $GITHUB_ENV - find "${{ github.workspace }}/vendor/LibAtrac9" + - name: Install Dependencies Linux run: sudo apt-get install nasm libx11-dev libxft-dev libxext-dev libwayland-dev libxkbcommon-dev libegl1-mesa-dev libibus-1.0-dev libxrandr-dev if: matrix.os_name == 'linux' || matrix.os_name == 'android' diff --git a/build-deps.ps1 b/build-deps.ps1 index b173c459..6a804546 100644 --- a/build-deps.ps1 +++ b/build-deps.ps1 @@ -13,54 +13,6 @@ function SetEnv() { } } -function BuildLibatrac9() { - echo "Starting LibAtrac9 Build..." - if (!(Get-Command msbuild -ErrorAction SilentlyContinue)) { - SetEnv - } - - - pushd "vendor" - $repo_root = "LibAtrac9" - $libatrac9_exists = Test-Path $repo_root - if (-not $libatrac9_exists) { - echo "Cloning LibAtrac9..." - & git clone https://github.com/Thealexbarney/LibAtrac9.git --depth 1 - } - pushd $repo_root - pushd "C" - if ($env:AZURE_EXTENSION_DIR -eq $null -or -not $libatrac9_exists) { - echo "Upgrading LibAtrac9 project..." - & devenv /Upgrade libatrac9.sln - } - - $args = @( - "/m", - "/p:Configuration=Release", - "/p:Platform=$Arch", - "/p:WindowsTargetPlatformVersion=10.0", - "/p:PlatformToolset=v142" - ) - echo "Building LibAtrac9..." - & msbuild $args - popd - - echo "Copying LibAtrac9 dlls and headers..." - $includedir = "include/libatrac9" - mkdir $includedir -Force | Out-Null - Get-ChildItem -Path "./C/src/*" -Include *.h | Copy-Item -Destination $includedir - mkdir "bin/x86" -Force | Out-Null - mkdir "bin/x64" -Force | Out-Null - if(Test-Path "./C/Release") { - Get-ChildItem -Path "./C/Release/*" -Include *.dll,*.lib | Copy-Item -Destination "bin/x86" - } - if(Test-Path "./C/x64/Release") { - Get-ChildItem -Path "./C/x64/Release/*" -Include *.dll,*.lib | Copy-Item -Destination "bin/x64" - } - popd - popd -} - function InstallPackages() { $vcpkg = "$env:VCPKG_ROOT/vcpkg.exe" if (!(Get-Command $vcpkg -ErrorAction SilentlyContinue)) { @@ -91,5 +43,4 @@ function InstallPackages() { } } -BuildLibatrac9 InstallPackages \ No newline at end of file