Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Split Build Steps for PG into seperate files. macOS / VS now should be easily built #450

Merged
merged 55 commits into from
Dec 18, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
55 commits
Select commit Hold shift + click to select a range
362c84f
macOS electron updates + scripts so we can build this easily cut it u…
danoli3 Dec 15, 2023
36f12a7
VS Project Generator Scripts / Front End / Security
danoli3 Dec 15, 2023
4efd266
Update npm files
danoli3 Dec 15, 2023
a896e21
npm no cache
danoli3 Dec 15, 2023
d17cdf9
macOS action
danoli3 Dec 15, 2023
907f5b4
VS Bash MSBuild find if local
danoli3 Dec 15, 2023
d23942c
macOS universal
danoli3 Dec 15, 2023
87a1e1c
Build all archs for commandLine
danoli3 Dec 15, 2023
a4dc00c
Front End osx make sure to copy app
danoli3 Dec 15, 2023
4ec736b
universal trouble
danoli3 Dec 15, 2023
c77dd1f
macos now working!
danoli3 Dec 15, 2023
d67fdb7
vs front end copy
danoli3 Dec 15, 2023
fb99ed7
workflow for bleeding test
danoli3 Dec 15, 2023
fd0b95a
Merge pull request #452 from danoli3/master
danoli3 Dec 15, 2023
db1c083
vs ci workflow fix
danoli3 Dec 16, 2023
14d407d
vs workflow
danoli3 Dec 16, 2023
ebfd7ec
vs workflow npm into actions
danoli3 Dec 16, 2023
cfa6b4f
vs zip
danoli3 Dec 16, 2023
f421674
macOS ci
danoli3 Dec 16, 2023
aae4e22
macOS action
danoli3 Dec 16, 2023
afb2035
Merge pull request #453 from danoli3/heads/bleeding
danoli3 Dec 16, 2023
27087e5
publish changes
danoli3 Dec 17, 2023
ecaa225
yml vs fix
danoli3 Dec 17, 2023
efce0e3
json fix
danoli3 Dec 17, 2023
4cc704c
vs ci cmd
danoli3 Dec 17, 2023
49c98d4
chmod execute permissions
danoli3 Dec 17, 2023
0755aa1
fix logic cmd exe
danoli3 Dec 17, 2023
db27add
fix publish setting and macOS remove library removal
danoli3 Dec 17, 2023
2576b64
Merge pull request #454 from danoli3/heads/bleeding
danoli3 Dec 17, 2023
36cb257
vs upload package
danoli3 Dec 17, 2023
e7f37e6
macOS location
danoli3 Dec 17, 2023
b7f672e
osx ci
danoli3 Dec 17, 2023
e11342c
osx ci exit
danoli3 Dec 17, 2023
7c76af3
macOS fix
danoli3 Dec 17, 2023
023b780
macOS fix copy ci
danoli3 Dec 17, 2023
a2f40c7
Merge pull request #455 from danoli3/heads/bleeding
danoli3 Dec 17, 2023
c2bb44a
macOS nightmare fix
danoli3 Dec 18, 2023
af97366
workflows on
danoli3 Dec 18, 2023
029e06e
Merge pull request #456 from danoli3/heads/bleeding
danoli3 Dec 18, 2023
8678aab
macOS copy missing settings
danoli3 Dec 18, 2023
6bfc1ff
Merge pull request #457 from danoli3/heads/bleeding
danoli3 Dec 18, 2023
370c840
macOS upload / sign dirs
danoli3 Dec 18, 2023
89d0fdb
Merge pull request #458 from danoli3/heads/bleeding
danoli3 Dec 18, 2023
03d7131
workflow fixes
danoli3 Dec 18, 2023
2da06c9
Merge pull request #459 from danoli3/heads/bleeding
danoli3 Dec 18, 2023
aca781d
cache issues must be
danoli3 Dec 18, 2023
7744080
Merge pull request #460 from danoli3/heads/bleeding
danoli3 Dec 18, 2023
489eeca
please
danoli3 Dec 18, 2023
c61eaa7
Merge pull request #461 from danoli3/heads/bleeding
danoli3 Dec 18, 2023
b5f7a26
Should solve it
danoli3 Dec 18, 2023
ca3b277
Merge pull request #462 from danoli3/heads/bleeding
danoli3 Dec 18, 2023
b95f1b6
so confusing
danoli3 Dec 18, 2023
1216c4f
Merge pull request #463 from danoli3/heads/bleeding
danoli3 Dec 18, 2023
27fae85
Update build-macos.yml
danoli3 Dec 18, 2023
348b573
Update build-macos.yml
danoli3 Dec 18, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
144 changes: 100 additions & 44 deletions .github/workflows/build-macos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,60 +3,116 @@ name: build-macos
on:
push:
paths-ignore:
- '**/README.md'
- '**/README.md'
pull_request:
paths-ignore:
- '**/README.md'
- '**/README.md'

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
build-osx:
runs-on: macos-12
runs-on: macos-13
strategy:
matrix:
cfg:
matrix:
cfg:
- {target: osx}
env:
TARGET: ${{matrix.cfg.target}}
TARGET: ${{ matrix.cfg.target }}
steps:
- uses: actions/checkout@v3
# - name: Cache OF
# id: cache-of
# uses: actions/cache@v3
# env:
# cache-name: cache-keep-of
# with:
# path: |
# /Users/runner/work/projectGenerator/openFrameworks/**
# key: ${{ runner.os }}-${{matrix.cfg.opt}}-${{ env.cache-name }}-${{ hashFiles('openFrameworks/**/*.cpp') }}
# restore-keys: |
# ${{ runner.os }}-${{matrix.cfg.opt}}-${{ env.cache-name }}-
- name: rm-dev
run: sudo rm -rf /Library/Developer
- name: Build
run:
./scripts/osx/buildPG.sh;
env:
DEVELOPER_DIR: "/Applications/Xcode_13.4.1.app/Contents/Developer"
SDKROOT: "/Applications/Xcode_13.4.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk"
# DEVELOPER_DIR: "/Applications/Xcode_14.2.app/Contents/Developer"
# SDKROOT: "/Applications/Xcode_14.2.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk"
GA_CI_SECRET: ${{ secrets.CI_SECRET }}
CERTIFICATE_OSX_APPLICATION: ${{ secrets.CERTIFICATE_OSX_APPLICATION }}
CERTIFICATE_PASSWORD: ${{ secrets.CERTIFICATE_PASSWORD }}
GA_APPLE_USERNAME: ${{ secrets.GA_APPLE_USERNAME }}
GA_APPLE_PASS: ${{ secrets.GA_APPLE_PASS }}
GA_NOTARIZE_PROVIDER: ${{ secrets.GA_NOTARIZE_PROVIDER }}
- name: Update Release
if: github.repository == 'openframeworks/projectGenerator' && github.ref == 'refs/heads/master'
uses: IsaacShelton/[email protected]
with:
token: ${{ secrets.GITHUB_TOKEN }}
tag: nightly
release: nightly
prerelease: false
replace: false
files: ../openFrameworks/apps/projectGenerator/projectGenerator-osx/projectGenerator-osx.zip ../openFrameworks/apps/projectGenerator/projectGenerator-ios/projectGenerator-ios.zip
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 16
- name: Setup
run: ./scripts/osx/setup_environment.sh
- name: Determine Release
id: vars
shell: bash
run: |
if [[ "${{ github.ref }}" == "refs/heads/master" ]]; then
echo "release=nightly" >> $GITHUB_ENV
echo "prerelease=false" >> $GITHUB_ENV
elif [[ "${{ github.ref }}" == "refs/heads/bleeding" ]]; then
echo "release=bleeding" >> $GITHUB_ENV
echo "prerelease=true" >> $GITHUB_ENV
fi
- name: Build PG macOS GUI and command line
run: |
echo "Current directory: (should be projectGenerator)"
pwd
echo "Directory contents:"
ls
echo "Setup CI setup environment / checkout oF "
./scripts/osx/ci_install_core.sh

echo "Current directory after moving up: (should be projectGenerator/projectGenerator)"
pwd
cd ../

echo "Current directory after moving up: (should be projectGenerator/)"
echo "------------------"
pwd
ls
echo "------------------"
if [ -f "openFrameworks/apps/projectGenerator/scripts/osx/ci_build_pg.sh" ]; then
echo "ci_build_pg.sh exists, running script..."
openFrameworks/apps/projectGenerator/scripts/osx/ci_build_pg.sh
else
echo "ci_build_pg.sh does not exist, checking Git status..."
if cd openFrameworks/apps/projectGenerator; then
echo "Current Git branch in projectGenerator:"
git rev-parse --abbrev-ref HEAD
echo "Latest commit hash in projectGenerator:"
git rev-parse HEAD
else
echo "Failed to change directory to openFrameworks/apps/projectGenerator"
fi
echo "Current directory: (should be openFrameworks/apps/projectGenerator)"
pwd
echo "Directory contents:"
ls
echo "------------------"
echo "Failure exit1"
exit 1
fi
env:
GA_CI_SECRET: ${{ secrets.CI_SECRET }}
CERTIFICATE_OSX_APPLICATION: ${{ secrets.CERTIFICATE_OSX_APPLICATION }}
CERTIFICATE_PASSWORD: ${{ secrets.CERTIFICATE_PASSWORD }}
GA_APPLE_USERNAME: ${{ secrets.GA_APPLE_USERNAME }}
GA_APPLE_PASS: ${{ secrets.GA_APPLE_PASS }}
GA_NOTARIZE_PROVIDER: ${{ secrets.GA_NOTARIZE_PROVIDER }}
- name: Check output
run: |
echo "Current directory: (should be projectGenerator)"
pwd
echo "Directory contents:"
ls
if [ -f "projectGenerator/projectGenerator-osx.zip" ]; then
echo "projectGenerator/projectGenerator-osx.zip found at level 1"
else
echo "projectGenerator/projectGenerator-osx.zip NOT found at level 1"
fi
if [ -f "projectGenerator/projectGenerator/projectGenerator-osx.zip" ]; then
echo "projectGenerator/projectGenerator/projectGenerator-osx.zip found at level 2"
else
echo "projectGenerator/projectGenerator/projectGenerator-osx.zip NOT found at level 2"
fi
if [ -f "projectGenerator-osx.zip" ]; then
echo "projectGenerator-osx.zip found at level 0"
else
echo "projectGenerator-osx.zip NOT found at level 0"
fi
- name: Update Release x86_64
if: github.repository == 'openframeworks/projectGenerator' && github.event_name == 'push' && (github.ref == 'refs/heads/master' || github.ref == 'refs/heads/bleeding')
uses: IsaacShelton/[email protected]
with:
token: ${{ secrets.GITHUB_TOKEN }}
tag: ${{ env.release }}
release: ${{ env.release }}
prerelease: ${{ env.prerelease }}
replace: false
files: projectGenerator-osx.zip
67 changes: 54 additions & 13 deletions .github/workflows/build-vs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,10 @@ jobs:
BITS: ${{ matrix.bits }}
steps:
- name: Clone repository
uses: actions/checkout@v3
uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 18
- uses: msys2/setup-msys2@v2
with:
update: true
Expand All @@ -39,28 +42,66 @@ jobs:
zip
rsync
wget
- name: Determine Release
id: vars
shell: bash
run: |
if [[ "${{ github.ref }}" == "refs/heads/master" ]]; then
echo "release=nightly" >> $GITHUB_ENV
echo "prerelease=false" >> $GITHUB_ENV
elif [[ "${{ github.ref }}" == "refs/heads/bleeding" ]]; then
echo "release=bleeding" >> $GITHUB_ENV
echo "prerelease=true" >> $GITHUB_ENV
fi
- name: Install dependencies
shell: msys2 {0}
shell: bash
run:
./scripts/vs/install.sh
./scripts/vs/ci_install.sh
- name: Setup MSBuild
uses: microsoft/[email protected]
- name: Build projectGenerator

- name: Build projectGenerator CMDLine with oF
working-directory: ${{env.GITHUB_WORKSPACE}}
run:
msbuild ../openFrameworks/apps/projectGenerator/commandLine/commandLine.vcxproj /p:configuration=release /p:platform=${{ matrix.platform }} /p:PlatformToolset=v142
- name: Create zip
if: github.repository == 'openframeworks/projectGenerator' && github.ref == 'refs/heads/master'

- name: Create projectGenerator cmd zip
shell: msys2 {0}
run:
./scripts/vs/create_package.sh
- name: Update Release
if: github.repository == 'openframeworks/projectGenerator' && github.ref == 'refs/heads/master'
uses: IsaacShelton/[email protected]
../openFrameworks/apps/projectGenerator/scripts/vs/ci_cmd_package.sh

- name: Build and Package projectGenerator VS GUI
shell: bash
run: |
cd ../openFrameworks/apps/projectGenerator/frontend
npm install
npm update
npm run dist:win64
cd dist
pwd
ls
- name: Create projectGenerator VS GUI package
shell: msys2 {0}
run:
../openFrameworks/apps/projectGenerator/scripts/vs/ci_frontend_package.sh

- name: Update CMD Gen Release
if: github.repository == 'openframeworks/projectGenerator' && github.event_name == 'push' && (github.ref == 'refs/heads/master' || github.ref == 'refs/heads/bleeding')
uses: IsaacShelton/[email protected]
with:
token: ${{ secrets.GITHUB_TOKEN }}
tag: nightly
release: nightly
prerelease: false
tag: ${{ env.release }}
release: ${{ env.release }}
prerelease: ${{ env.release }}
replace: false
files: ../openFrameworks/apps/projectGenerator/commandLine/bin/projectGenerator-vs.zip
- name: Update Project Gen GUI Release
if: github.repository == 'openframeworks/projectGenerator' && github.event_name == 'push' && (github.ref == 'refs/heads/master' || github.ref == 'refs/heads/bleeding')
uses: IsaacShelton/[email protected]
with:
token: ${{ secrets.GITHUB_TOKEN }}
tag: ${{ env.release }}
release: ${{ env.release }}
prerelease: ${{ env.release }}
replace: false
files: ../openFrameworks/apps/projectGenerator/frontend/dist/projectGenerator-vs-gui.zip
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -96,3 +96,4 @@ Temporary Items
commandLine/bin/projectGenerator*
frontend/app/projectGenerator*

commandLine/.vs/commandLine/xs
6 changes: 5 additions & 1 deletion commandLine/commandLine.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -282,7 +282,7 @@
buildActionMask = 2147483647;
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "if test -f \"$TARGET_BUILD_DIR/projectGenerator\"; then rm \"$TARGET_BUILD_DIR/projectGenerator\"; fi; cp \"$TARGET_BUILD_DIR/$PRODUCT_NAME.app/Contents/MacOS/$PRODUCT_NAME\" \"$TARGET_BUILD_DIR/projectGenerator\"";
shellScript = "if test -f \"$TARGET_BUILD_DIR/projectGenerator\"; then rm \"$TARGET_BUILD_DIR/projectGenerator\"; fi; cp \"$TARGET_BUILD_DIR/$PRODUCT_NAME.app/Contents/MacOS/$PRODUCT_NAME\" \"$TARGET_BUILD_DIR/projectGenerator\"\n";
showEnvVarsInLog = 0;
};
E42962A92163ECCD00A6A9E2 /* Run Script — Compile OF */ = {
Expand Down Expand Up @@ -342,6 +342,7 @@
"$(OF_CORE_HEADERS)",
src,
);
ONLY_ACTIVE_ARCH = NO;
OTHER_CPLUSPLUSFLAGS = "-D__MACOSX_CORE__";
};
name = Debug;
Expand All @@ -358,6 +359,7 @@
"$(OF_CORE_HEADERS)",
src,
);
ONLY_ACTIVE_ARCH = NO;
OTHER_CPLUSPLUSFLAGS = "-D__MACOSX_CORE__";
};
name = Release;
Expand All @@ -381,6 +383,7 @@
src/uuidxx/src,
);
LIBRARY_SEARCH_PATHS = "$(inherited)";
ONLY_ACTIVE_ARCH = NO;
OTHER_LDFLAGS = (
"$(OF_CORE_LIBS)",
"$(OF_CORE_FRAMEWORKS)",
Expand All @@ -407,6 +410,7 @@
src/uuidxx/src,
);
LIBRARY_SEARCH_PATHS = "$(inherited)";
ONLY_ACTIVE_ARCH = NO;
OTHER_LDFLAGS = (
"$(OF_CORE_LIBS)",
"$(OF_CORE_FRAMEWORKS)",
Expand Down
Loading