From 72d3fe42a036c88bed054e1260f85c7b3d3ffe1f Mon Sep 17 00:00:00 2001 From: David Braun <2096055+DBraun@users.noreply.github.com> Date: Thu, 4 Apr 2024 16:34:44 -0400 Subject: [PATCH] update --- .github/workflows/all.yml | 11 +++++++++++ faust2td.py | 5 +++-- 2 files changed, 14 insertions(+), 2 deletions(-) diff --git a/.github/workflows/all.yml b/.github/workflows/all.yml index 39d751d..077e746 100644 --- a/.github/workflows/all.yml +++ b/.github/workflows/all.yml @@ -1,5 +1,7 @@ env: CMAKE_XCODE_ATTRIBUTE_DEVELOPMENT_TEAM: ${{ secrets.CMAKE_XCODE_ATTRIBUTE_DEVELOPMENT_TEAM }} + MACOS_CERTIFICATE: ${{ secrets.MACOS_CERTIFICATE }} + MACOS_CERTIFICATE_PASSWORD: ${{ secrets.MACOS_CERTIFICATE_PASSWORD }} name: Compile on: pull_request: {} @@ -83,6 +85,15 @@ jobs: with: submodules: true + - name: Install Certificate + run: | + echo "$MACOS_CERTIFICATE" | base64 --decode > certificate.p12 + security create-keychain -p "" build.keychain + security default-keychain -s build.keychain + security unlock-keychain -p "" build.keychain + security import certificate.p12 -k build.keychain -P "$MACOS_CERTIFICATE_PASSWORD" -T /usr/bin/codesign + security set-key-partition-list -S apple-tool:,apple:,codesign: -s -k "" build.keychain + - name: Setup Python uses: actions/setup-python@v5 with: diff --git a/faust2td.py b/faust2td.py index ce2a952..8e3264d 100644 --- a/faust2td.py +++ b/faust2td.py @@ -299,10 +299,11 @@ def add_toggle(item) -> str: # execute CMake and build build_dir = 'build_faust2touchdesigner' - subprocess.call(shlex.split(f'cmake faust2touchdesigner -{build_dir} -DOP_TYPE={op_type} -DAUTHOR_NAME="{author_name}" -DLIBFAUST_DIR="{libfaust_dir}" {cmake_osx_deployment_target} {cmake_build_arch}')) + generator = " -G Xcode " if platform.system() == 'Darwin' else '' + subprocess.call(shlex.split(f'cmake faust2touchdesigner -B{build_dir} {generator} -DOP_TYPE={op_type} -DAUTHOR_NAME="{author_name}" -DLIBFAUST_DIR="{libfaust_dir}" {cmake_osx_deployment_target} {cmake_build_arch}')) subprocess.call(shlex.split(f'cmake --build {build_dir} --config Release')) if platform.system() == 'Darwin': - subprocess.call(shlex.split(f'cp -r {build_dir}/{op_type}.plugin Plugins')) + subprocess.call(shlex.split(f'cp -r {build_dir}/Release/{op_type}.plugin Plugins')) print('All done!')