mirror of
https://github.com/Stirling-Tools/Stirling-PDF.git
synced 2025-04-19 11:11:18 +00:00
MacOS x86_64
installer fix 🙏🏾 (#3333)
- Forced Gradle to build MacOS `x86_64` distribution with `x86_64` architecture in workflows - Corrected pathing for signed artefacts  --- ## Checklist ### General - [x] I have read the [Contribution Guidelines](https://github.com/Stirling-Tools/Stirling-PDF/blob/main/CONTRIBUTING.md) - [x] I have read the [Stirling-PDF Developer Guide](https://github.com/Stirling-Tools/Stirling-PDF/blob/main/DeveloperGuide.md) (if applicable) - [x] I have read the [How to add new languages to Stirling-PDF](https://github.com/Stirling-Tools/Stirling-PDF/blob/main/HowToAddNewLanguage.md) (if applicable) - [x] I have performed a self-review of my own code - [x] My changes generate no new warnings ### Documentation - [x] I have updated relevant docs on [Stirling-PDF's doc repo](https://github.com/Stirling-Tools/Stirling-Tools.github.io/blob/main/docs/) (if functionality has heavily changed) - [x] I have read the section [Add New Translation Tags](https://github.com/Stirling-Tools/Stirling-PDF/blob/main/HowToAddNewLanguage.md#add-new-translation-tags) (for new translation tags only) ### UI Changes (if applicable) - [x] Screenshots or videos demonstrating the UI changes are attached (e.g., as comments or direct attachments in the PR) ### Testing (if applicable) - [x] I have tested my changes locally. Refer to the [Testing Guide](https://github.com/Stirling-Tools/Stirling-PDF/blob/main/DeveloperGuide.md#6-testing) for more details.
This commit is contained in:
parent
7fa302f322
commit
4220a28276
27
.github/workflows/multiOSReleases.yml
vendored
27
.github/workflows/multiOSReleases.yml
vendored
@ -4,6 +4,11 @@ on:
|
|||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
release:
|
release:
|
||||||
types: [created]
|
types: [created]
|
||||||
|
inputs:
|
||||||
|
test_mode:
|
||||||
|
description: "Run in test mode (skips release step)"
|
||||||
|
required: false
|
||||||
|
default: "false"
|
||||||
|
|
||||||
permissions:
|
permissions:
|
||||||
contents: read
|
contents: read
|
||||||
@ -170,6 +175,23 @@ jobs:
|
|||||||
STIRLING_PDF_DESKTOP_UI: true
|
STIRLING_PDF_DESKTOP_UI: true
|
||||||
BROWSER_OPEN: true
|
BROWSER_OPEN: true
|
||||||
|
|
||||||
|
- name: ☕ Set up JDK (x86_64)
|
||||||
|
if: matrix.os == 'macos-latest'
|
||||||
|
run: |
|
||||||
|
curl -L -o jdk.tar.gz https://cdn.azul.com/zulu/bin/zulu17.56.15-ca-jdk17.0.14-macosx_x64.tar.gz
|
||||||
|
mkdir -p zulu17
|
||||||
|
tar -xzf jdk.tar.gz -C zulu17 --strip-components=1
|
||||||
|
echo "JAVA_HOME=$PWD/zulu17" >> $GITHUB_ENV
|
||||||
|
echo "$PWD/zulu17/bin" >> $GITHUB_PATH
|
||||||
|
|
||||||
|
- name: Verify JDK architecture
|
||||||
|
if: matrix.os == 'macos-latest'
|
||||||
|
run: file $JAVA_HOME/bin/java
|
||||||
|
|
||||||
|
- name: Build project and run jpackage (x86_64)
|
||||||
|
if: matrix.os == 'macos-latest'
|
||||||
|
run: arch -x86_64 ./gradlew jpackageMacX64
|
||||||
|
|
||||||
# Rename and collect artifacts based on OS
|
# Rename and collect artifacts based on OS
|
||||||
- name: Prepare artifacts
|
- name: Prepare artifacts
|
||||||
id: prepare
|
id: prepare
|
||||||
@ -181,7 +203,7 @@ jobs:
|
|||||||
mv "./build/jpackage/Stirling-PDF-${{ needs.read_versions.outputs.version }}.exe" "./binaries/Stirling-PDF-win-installer.exe"
|
mv "./build/jpackage/Stirling-PDF-${{ needs.read_versions.outputs.version }}.exe" "./binaries/Stirling-PDF-win-installer.exe"
|
||||||
elif [ "${{ matrix.os }}" = "macos-latest" ]; then
|
elif [ "${{ matrix.os }}" = "macos-latest" ]; then
|
||||||
mv "./build/jpackage/Stirling-PDF-${{ needs.read_versions.outputs.versionMac }}.dmg" "./binaries/Stirling-PDF-mac-installer.dmg"
|
mv "./build/jpackage/Stirling-PDF-${{ needs.read_versions.outputs.versionMac }}.dmg" "./binaries/Stirling-PDF-mac-installer.dmg"
|
||||||
mv "./build/jpackage/Stirling-PDF-x86_64-${{ needs.read_versions.outputs.versionMac }}.dmg" "./binaries/Stirling-PDF-mac-x86_64-installer.dmg"
|
mv "./build/jpackage/x86_64/Stirling-PDF (x86_64)-${{ needs.read_versions.outputs.versionMac }}.dmg" "./binaries/Stirling-PDF-mac-x86_64-installer.dmg"
|
||||||
else
|
else
|
||||||
mv "./build/jpackage/stirling-pdf_${{ needs.read_versions.outputs.version }}-1_amd64.deb" "./binaries/Stirling-PDF-linux-installer.deb"
|
mv "./build/jpackage/stirling-pdf_${{ needs.read_versions.outputs.version }}-1_amd64.deb" "./binaries/Stirling-PDF-linux-installer.deb"
|
||||||
fi
|
fi
|
||||||
@ -264,10 +286,11 @@ jobs:
|
|||||||
name: ${{ matrix.platform }}signed
|
name: ${{ matrix.platform }}signed
|
||||||
path: |
|
path: |
|
||||||
./Stirling-PDF-${{ matrix.platform }}installer.*
|
./Stirling-PDF-${{ matrix.platform }}installer.*
|
||||||
./Stirling-PDF-${{ matrix.platform }}-x86_64-installer.*
|
./Stirling-PDF-${{ matrix.platform }}x86_64-installer.*
|
||||||
!cosign.*
|
!cosign.*
|
||||||
|
|
||||||
create-release:
|
create-release:
|
||||||
|
if: github.event_name != 'workflow_dispatch' || github.event.inputs.test_mode != 'true'
|
||||||
needs: [read_versions, sign_verify, sign_verify-portable]
|
needs: [read_versions, sign_verify, sign_verify-portable]
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
permissions:
|
permissions:
|
||||||
|
20
build.gradle
20
build.gradle
@ -164,14 +164,12 @@ jpackage {
|
|||||||
appVersion = getMacVersion(project.version.toString())
|
appVersion = getMacVersion(project.version.toString())
|
||||||
icon = "src/main/resources/static/favicon.icns"
|
icon = "src/main/resources/static/favicon.icns"
|
||||||
type = "dmg"
|
type = "dmg"
|
||||||
macPackageIdentifier = "com.stirling.software.pdf"
|
macPackageIdentifier = "Stirling-PDF"
|
||||||
macPackageName = "Stirling-PDF-aarch64"
|
macPackageName = "Stirling-PDF"
|
||||||
macAppCategory = "public.app-category.productivity"
|
macAppCategory = "public.app-category.productivity"
|
||||||
macSign = false // Enable signing
|
macSign = false // Enable signing
|
||||||
macAppStore = false // Not targeting App Store initially
|
macAppStore = false // Not targeting App Store initially
|
||||||
//
|
|
||||||
// //installDir = "Applications"
|
|
||||||
//
|
|
||||||
// // Add license and other documentation to DMG
|
// // Add license and other documentation to DMG
|
||||||
// /*macDmgContent = [
|
// /*macDmgContent = [
|
||||||
// "README.md",
|
// "README.md",
|
||||||
@ -252,16 +250,16 @@ tasks.register('jpackageMacX64') {
|
|||||||
def result = exec {
|
def result = exec {
|
||||||
commandLine 'jpackage',
|
commandLine 'jpackage',
|
||||||
'--type', 'dmg',
|
'--type', 'dmg',
|
||||||
'--name', 'Stirling-PDF-x86_64',
|
'--name', 'Stirling-PDF (x86_64)',
|
||||||
'--input', 'build/libs',
|
'--input', 'build/libs',
|
||||||
'--main-jar', "Stirling-PDF-${project.version}.jar",
|
'--main-jar', "Stirling-PDF-${project.version}.jar",
|
||||||
'--main-class', 'stirling.software.SPDF.SPDFApplication',
|
'--main-class', 'org.springframework.boot.loader.launch.JarLauncher',
|
||||||
'--runtime-image', file(jrePath + "/zulu-17.jre/Contents/Home"),
|
'--runtime-image', file(jrePath + "/zulu-17.jre/Contents/Home"),
|
||||||
'--dest', 'build/jpackage',
|
'--dest', 'build/jpackage/x86_64',
|
||||||
'--icon', 'src/main/resources/static/favicon.icns',
|
'--icon', 'src/main/resources/static/favicon.icns',
|
||||||
'--app-version', getMacVersion(project.version.toString()),
|
'--app-version', getMacVersion(project.version.toString()),
|
||||||
'--mac-package-name', 'Stirling-PDF',
|
'--mac-package-name', 'Stirling-PDF (x86_64)',
|
||||||
'--mac-package-identifier', 'com.stirling.software.pdf',
|
'--mac-package-identifier', 'Stirling-PDF (x86_64)',
|
||||||
'--mac-app-category', 'public.app-category.productivity'
|
'--mac-app-category', 'public.app-category.productivity'
|
||||||
standardOutput = outputStream
|
standardOutput = outputStream
|
||||||
errorOutput = errorStream
|
errorOutput = errorStream
|
||||||
@ -281,7 +279,7 @@ tasks.register('jpackageMacX64') {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
jpackage.finalizedBy(jpackageMacX64)
|
//jpackage.finalizedBy(jpackageMacX64)
|
||||||
|
|
||||||
tasks.register('downloadTempJre') {
|
tasks.register('downloadTempJre') {
|
||||||
group = 'distribution'
|
group = 'distribution'
|
||||||
|
Loading…
x
Reference in New Issue
Block a user