fork/oculante

git clone https://git.julia.blue/fork/oculante

Johann WoelperMerge pull request #464 from woelper/improve_checks6b4d770

0.9.2
9.6 KiB138 linesraw
1on:
2  push:
3    branches: [ "master" ]
4  pull_request:
5    # The branches below must be a subset of the branches above
6    branches: [ "master" ]
7
8env:
9  CARGO_TERM_COLOR: always
10  MACOS_DEPLOYMENT_TARGET: 10.15
11
12name: Check OSX
13jobs:
14  check:
15    strategy:
16      matrix:
17        os: [macos-14]
18    runs-on: ${{ matrix.os }}
19    steps:
20      - uses: actions/checkout@v4
21      - uses: ilammy/setup-nasm@v1
22      - uses: Swatinem/rust-cache@v2
23
24      # - name: Check without default features
25      #   run: cargo check --no-default-features --features notan/shaderc
26      #   if: matrix.os == 'macos-14'
27
28      - name: intel heif test
29        run: |
30          rustc --version --verbose
31          brew install libheif
32          cargo install cargo-bundle
33          cargo bundle --release --features "notan/shaderc heif"
34          otool -L target/release/bundle/osx/oculante.app/Contents/MacOS/oculante
35          mkdir target/release/bundle/osx/oculante.app/Contents/Frameworks/
36          cp /usr/local/opt/libheif/lib/libheif.1.dylib target/release/bundle/osx/oculante.app/Contents/Frameworks/
37          cp /usr/local/opt/x265/lib/libx265.209.dylib target/release/bundle/osx/oculante.app/Contents/Frameworks/
38          cp /usr/local/opt/libde265/lib/libde265.0.dylib target/release/bundle/osx/oculante.app/Contents/Frameworks/
39          cp /usr/local/opt/aom/lib/libaom.3.dylib target/release/bundle/osx/oculante.app/Contents/Frameworks/
40          cp /usr/local/opt/webp/lib/libsharpyuv.0.dylib target/release/bundle/osx/oculante.app/Contents/Frameworks/
41          cp /usr/local/opt/libvmaf/lib/libvmaf.3.dylib target/release/bundle/osx/oculante.app/Contents/Frameworks/
42          install_name_tool -change /usr/local/opt/libheif/lib/libheif.1.dylib "@executable_path/../Frameworks/libheif.1.dylib" target/release/bundle/osx/oculante.app/Contents/MacOS/oculante
43          install_name_tool -add_rpath "@executable_path/../Frameworks/libx265.209.dylib" target/release/bundle/osx/oculante.app/Contents/MacOS/oculante
44          install_name_tool -add_rpath "@executable_path/../Frameworks/libde265.0.dylib" target/release/bundle/osx/oculante.app/Contents/MacOS/oculante
45          install_name_tool -add_rpath "@executable_path/../Frameworks/libaom.3.dylib" target/release/bundle/osx/oculante.app/Contents/MacOS/oculante
46          install_name_tool -add_rpath "@executable_path/../Frameworks/libsharpyuv.0.dylib" target/release/bundle/osx/oculante.app/Contents/MacOS/oculante
47          install_name_tool -add_rpath "@executable_path/../Frameworks/libvmaf.3.dylib" target/release/bundle/osx/oculante.app/Contents/MacOS/oculante
48          install_name_tool -change /usr/local/opt/x265/lib/libx265.209.dylib "@executable_path/../Frameworks/libx265.209.dylib" target/release/bundle/osx/oculante.app/Contents/Frameworks/libheif.1.dylib
49          install_name_tool -change /usr/local/opt/libde265/lib/libde265.0.dylib "@executable_path/../Frameworks/libde265.0.dylib" target/release/bundle/osx/oculante.app/Contents/Frameworks/libheif.1.dylib
50          install_name_tool -change /usr/local/opt/aom/lib/libaom.3.dylib "@executable_path/../Frameworks/libaom.3.dylib" target/release/bundle/osx/oculante.app/Contents/Frameworks/libheif.1.dylib
51          install_name_tool -change /usr/local/opt/webp/lib/libsharpyuv.0.dylib "@executable_path/../Frameworks/libsharpyuv.0.dylib" target/release/bundle/osx/oculante.app/Contents/Frameworks/libheif.1.dylib
52          install_name_tool -change /usr/local/opt/libvmaf/lib/libvmaf.3.dylib "@executable_path/../Frameworks/libvmaf.3.dylib" target/release/bundle/osx/oculante.app/Contents/Frameworks/libaom.3.dylib
53          codesign -s "-" -fv target/release/bundle/osx/oculante.app/Contents/Frameworks/libvmaf.3.dylib
54          codesign -s "-" -fv target/release/bundle/osx/oculante.app/Contents/Frameworks/libsharpyuv.0.dylib
55          codesign -s "-" -fv target/release/bundle/osx/oculante.app/Contents/Frameworks/libaom.3.dylib
56          codesign -s "-" -fv target/release/bundle/osx/oculante.app/Contents/Frameworks/libde265.0.dylib
57          codesign -s "-" -fv target/release/bundle/osx/oculante.app/Contents/Frameworks/libx265.209.dylib
58          codesign -s "-" -fv target/release/bundle/osx/oculante.app/Contents/Frameworks/libheif.1.dylib
59          otool -L target/release/bundle/osx/oculante.app/Contents/MacOS/oculante
60          cp Info.plist target/release/bundle/osx/oculante.app/Contents/Info.plist
61        if: matrix.os == 'macos-12'
62
63      - name: Zip Mac Intel Bundle
64        run: mv target/release/bundle/osx/oculante.app . && zip -r oculante_app_intel.zip oculante.app
65        if: matrix.os == 'macos-12'
66
67      - name: Archive intel build
68        uses: actions/upload-artifact@v4
69        with:
70          name: intel_build
71          path: oculante_app_intel.zip
72        if: matrix.os == 'macos-12'
73
74      # - name: arm heif test
75      #   run: |
76      #     rustc --version --verbose
77      #     brew install libheif
78      #     cargo install cargo-bundle
79      #     cargo bundle --release --features "notan/shaderc heif"
80      #     otool -L target/release/bundle/osx/oculante.app/Contents/MacOS/oculante
81      #     mkdir target/release/bundle/osx/oculante.app/Contents/Frameworks/
82      #     cp /opt/homebrew/opt/libheif/lib/libheif.1.dylib target/release/bundle/osx/oculante.app/Contents/Frameworks/
83      #     cp /opt/homebrew/opt/x265/lib/libx265.209.dylib target/release/bundle/osx/oculante.app/Contents/Frameworks/
84      #     cp /opt/homebrew/opt/libde265/lib/libde265.0.dylib target/release/bundle/osx/oculante.app/Contents/Frameworks/
85      #     cp /opt/homebrew/opt/aom/lib/libaom.3.dylib target/release/bundle/osx/oculante.app/Contents/Frameworks/
86      #     cp /opt/homebrew/opt/webp/lib/libsharpyuv.0.dylib target/release/bundle/osx/oculante.app/Contents/Frameworks/
87      #     cp /opt/homebrew/opt/libvmaf/lib/libvmaf.3.dylib target/release/bundle/osx/oculante.app/Contents/Frameworks/
88      #     install_name_tool -change /opt/homebrew/opt/libheif/lib/libheif.1.dylib "@executable_path/../Frameworks/libheif.1.dylib" target/release/bundle/osx/oculante.app/Contents/MacOS/oculante
89      #     install_name_tool -add_rpath "@executable_path/../Frameworks/libx265.209.dylib" target/release/bundle/osx/oculante.app/Contents/MacOS/oculante
90      #     install_name_tool -add_rpath "@executable_path/../Frameworks/libde265.0.dylib" target/release/bundle/osx/oculante.app/Contents/MacOS/oculante
91      #     install_name_tool -add_rpath "@executable_path/../Frameworks/libaom.3.dylib" target/release/bundle/osx/oculante.app/Contents/MacOS/oculante
92      #     install_name_tool -add_rpath "@executable_path/../Frameworks/libsharpyuv.0.dylib" target/release/bundle/osx/oculante.app/Contents/MacOS/oculante
93      #     install_name_tool -add_rpath "@executable_path/../Frameworks/libvmaf.3.dylib" target/release/bundle/osx/oculante.app/Contents/MacOS/oculante
94      #     install_name_tool -change /opt/homebrew/opt/x265/lib/libx265.209.dylib "@executable_path/../Frameworks/libx265.209.dylib" target/release/bundle/osx/oculante.app/Contents/Frameworks/libheif.1.dylib
95      #     install_name_tool -change /opt/homebrew/opt/libde265/lib/libde265.0.dylib "@executable_path/../Frameworks/libde265.0.dylib" target/release/bundle/osx/oculante.app/Contents/Frameworks/libheif.1.dylib
96      #     install_name_tool -change /opt/homebrew/opt/aom/lib/libaom.3.dylib "@executable_path/../Frameworks/libaom.3.dylib" target/release/bundle/osx/oculante.app/Contents/Frameworks/libheif.1.dylib
97      #     install_name_tool -change /opt/homebrew/opt/webp/lib/libsharpyuv.0.dylib "@executable_path/../Frameworks/libsharpyuv.0.dylib" target/release/bundle/osx/oculante.app/Contents/Frameworks/libheif.1.dylib
98      #     install_name_tool -change /opt/homebrew/opt/libvmaf/lib/libvmaf.3.dylib "@executable_path/../Frameworks/libvmaf.3.dylib" target/release/bundle/osx/oculante.app/Contents/Frameworks/libaom.3.dylib
99      #     codesign -s "-" -fv target/release/bundle/osx/oculante.app/Contents/Frameworks/libvmaf.3.dylib
100      #     codesign -s "-" -fv target/release/bundle/osx/oculante.app/Contents/Frameworks/libsharpyuv.0.dylib
101      #     codesign -s "-" -fv target/release/bundle/osx/oculante.app/Contents/Frameworks/libaom.3.dylib
102      #     codesign -s "-" -fv target/release/bundle/osx/oculante.app/Contents/Frameworks/libde265.0.dylib
103      #     codesign -s "-" -fv target/release/bundle/osx/oculante.app/Contents/Frameworks/libx265.209.dylib
104      #     codesign -s "-" -fv target/release/bundle/osx/oculante.app/Contents/Frameworks/libheif.1.dylib
105      #     otool -L target/release/bundle/osx/oculante.app/Contents/MacOS/oculante
106      #     cp Info.plist target/release/bundle/osx/oculante.app/Contents/Info.plist
107      #   if: matrix.os == 'macos-14'
108
109      # - name: Zip Mac Arm Bundle
110      #   run: mv target/release/bundle/osx/oculante.app . && zip -r oculante_app_arm.zip oculante.app
111      #   if: matrix.os == 'macos-14'
112
113      # - name: Archive arm build
114      #   uses: actions/upload-artifact@v4
115      #   with:
116      #     name: arm_build
117      #     path: oculante_app_arm.zip
118      #   if: matrix.os == 'macos-14'
119
120      - name: Cargo build on Apple Silicon
121        run: |
122          rustc --version --verbose
123          # cargo install cargo-bundle
124          cargo build
125        if: matrix.os == 'macos-14'
126
127      # - name: Zip Mac Arm Bundle
128      #   run: |
129      #     rm -rf oculante.app
130      #     mv target/release/bundle/osx/oculante.app . && zip -r oculante_app_arm_noheif.zip oculante.app
131      #   if: matrix.os == 'macos-14'
132
133      # - name: Archive arm build
134      #   uses: actions/upload-artifact@v4
135      #   with:
136      #     name: arm_build2
137      #     path: oculante_app_arm_noheif.zip
138      #   if: matrix.os == 'macos-14'