Skip to content

Commit

Permalink
CI: try to coerce cpack to install to user home on mac
Browse files Browse the repository at this point in the history
  • Loading branch information
phandasm committed Sep 11, 2022
1 parent 40635d9 commit 4c4fce3
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ jobs:
cmake --install ${{github.workspace}}/deps/obs-studio/build --config=Release
- name: 'Cmake'
run: cmake -B ${{github.workspace}}/build -DCMAKE_OSX_DEPLOYMENT_TARGET=11.0 -DCMAKE_OSX_ARCHITECTURES="arm64" -DMAKE_BUNDLE=ON -DDISABLE_X86_SIMD=ON -DBUILTIN_FFTW=ON -DCMAKE_PREFIX_PATH="${{github.workspace}}/deps/obs-deps;${{github.workspace}}/deps/obs-studio/build" -DCMAKE_INSTALL_PREFIX="${{github.workspace}}/bin" -DCPACK_PACKAGING_INSTALL_PREFIX="$HOME/Library/Application Support/obs-studio/plugins"
run: cmake -B ${{github.workspace}}/build -DCMAKE_OSX_DEPLOYMENT_TARGET=11.0 -DCMAKE_OSX_ARCHITECTURES="arm64" -DMAKE_BUNDLE=ON -DDISABLE_X86_SIMD=ON -DBUILTIN_FFTW=ON -DCMAKE_PREFIX_PATH="${{github.workspace}}/deps/obs-deps;${{github.workspace}}/deps/obs-studio/build" -DCMAKE_INSTALL_PREFIX="${{github.workspace}}/bin"

- name: 'Build'
run: |
Expand Down
6 changes: 6 additions & 0 deletions cmake/package_macos.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,12 @@ set(CPACK_PRODUCTBUILD_IDENTIFIER "com.github.phandasm.waveform")

if(NOT DEFINED CPACK_PACKAGING_INSTALL_PREFIX)
set(CPACK_PACKAGING_INSTALL_PREFIX "/Library/Application Support/obs-studio/plugins")
if(${CMAKE_OSX_ARCHITECTURES} STREQUAL "arm64")
set(CPACK_PRODUCTBUILD_DOMAINS ON)
set(CPACK_PRODUCTBUILD_DOMAINS_USER ON)
set(CPACK_PRODUCTBUILD_DOMAINS_ROOT OFF)
set(CPACK_PRODUCTBUILD_DOMAINS_ANYWHERE OFF)
endif()
endif()

set(CPACK_GENERATOR "productbuild")
Expand Down

0 comments on commit 4c4fce3

Please sign in to comment.