aboutsummaryrefslogtreecommitdiffstats
path: root/.github/workflows/mac_release.yml
diff options
context:
space:
mode:
Diffstat (limited to '.github/workflows/mac_release.yml')
-rw-r--r--.github/workflows/mac_release.yml106
1 files changed, 106 insertions, 0 deletions
diff --git a/.github/workflows/mac_release.yml b/.github/workflows/mac_release.yml
new file mode 100644
index 0000000..109b31b
--- /dev/null
+++ b/.github/workflows/mac_release.yml
@@ -0,0 +1,106 @@
+env:
+ QT_VERSION: '5.15.2'
+ TCL_VERSION: '8.6'
+ SQLITE_VERSION: '3350400'
+ SQLITE_RELEASE_YEAR: '2021'
+ PORTABLE_DIR: ${{ github.workspace }}/output/portable/SQLiteStudio
+
+name: MaxOSX release build
+
+on:
+ repository_dispatch:
+ types: [mac_release]
+
+jobs:
+ build:
+ runs-on: macos-latest
+
+ steps:
+ # - name: Debug
+ # run: |
+ # ls -l /usr/local/
+ # ls -l /usr/local/include
+ # ls -l /usr/local/opt/
+ # ls -l /usr/local/opt/openssl/include/
+ # ls -l /usr/local/opt/expat/include
+
+ - name: Cache Qt
+ id: cache-qt
+ uses: actions/cache@v1
+ with:
+ path: ${{ github.workspace }}/../Qt
+ key: ${{ runner.os }}-Qt-${{ env.QT_VERSION }}-Mac-Cache
+
+ - name: Install Qt
+ uses: jurplel/install-qt-action@v2
+ with:
+ cached: ${{ steps.cache-qt.outputs.cache-hit }}
+ version: ${{ env.QT_VERSION }}
+ host: 'mac'
+ dir: '${{ github.workspace }}/..'
+ modules: 'qtscript'
+
+ - name: Clone repo
+ uses: actions/checkout@v2
+ with:
+ ref: ${{ github.event.client_payload.branch }}
+
+ - name: Install SQLite3
+ run: |
+ wget http://sqlite.org/$SQLITE_RELEASE_YEAR/sqlite-amalgamation-$SQLITE_VERSION.zip
+ unzip sqlite-amalgamation-$SQLITE_VERSION.zip
+ cd sqlite-amalgamation-$SQLITE_VERSION
+ gcc sqlite3.c -lpthread -ldl -lm -Os -fpic -shared -o libsqlite3.0.dylib \
+ -DSQLITE_ENABLE_UPDATE_DELETE_LIMIT \
+ -DSQLITE_ENABLE_DBSTAT_VTAB \
+ -DSQLITE_ENABLE_BYTECODE_VTAB \
+ -DSQLITE_ENABLE_COLUMN_METADATA \
+ -DSQLITE_ENABLE_EXPLAIN_COMMENTS \
+ -DSQLITE_ENABLE_FTS3 \
+ -DSQLITE_ENABLE_FTS4 \
+ -DSQLITE_ENABLE_FTS5 \
+ -DSQLITE_ENABLE_GEOPOLY \
+ -DSQLITE_ENABLE_JSON1 \
+ -DSQLITE_ENABLE_RTREE \
+ -DSQLITE_ENABLE_MATH_FUNCTIONS
+ sudo cp libsqlite3.0.dylib /usr/local/lib/
+ sudo ln -f -s /usr/local/lib/libsqlite3.0.dylib /usr/local/lib/libsqlite3.dylib
+ sudo cp *.h /usr/local/include/
+ echo "DYLD_LIBRARY_PATH=/usr/local/lib" >> $GITHUB_ENV
+
+ - name: Prepare deps
+ run: |
+ mkdir ../lib ../include
+ cp /usr/local/lib/libsqlite3* ../lib
+ cp /usr/local/include/sqlite3* ../include
+
+ - name: Prepare output dir
+ run: mkdir output output/build output/build/Plugins
+
+ - name: Compile SQLiteStudio3
+ working-directory: output/build
+ run: |
+ qmake CONFIG+=portable ../../SQLiteStudio3
+ make -j 2
+
+ - name: Compile Plugins
+ working-directory: output/build/Plugins
+ run: |
+ qmake CONFIG+=portable ../../../Plugins
+ make -j 2
+
+ - name: Build packages
+ working-directory: output/build
+ run: |
+ make pkg
+
+ - name: Determine SQLiteStudio version
+ working-directory: output/SQLiteStudio
+ run: |
+ echo "SQLITESTUDIO_VERSION=$(SQLiteStudio.app/Contents/MacOS/sqlitestudiocli -v | awk '{print $2}')" >> $GITHUB_ENV
+
+ - name: Upload package artifact
+ uses: actions/upload-artifact@v1
+ with:
+ name: sqlitestudio-${{ env.SQLITESTUDIO_VERSION }}.dmg
+ path: output/SQLiteStudio/sqlitestudio-${{ env.SQLITESTUDIO_VERSION }}.dmg