From 6a8a29067287303821489aa0b313ce7984eaea95 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Felix=20F=C3=B6rtsch?= Date: Fri, 13 Mar 2026 22:23:31 +0100 Subject: [PATCH] add XcodeGen project config with iOS and macOS targets, resource directories --- Resources/Models/.gitkeep | 0 Resources/Voices/.gitkeep | 0 project.yml | 166 ++++++++++++++------------------------ 3 files changed, 62 insertions(+), 104 deletions(-) create mode 100644 Resources/Models/.gitkeep create mode 100644 Resources/Voices/.gitkeep diff --git a/Resources/Models/.gitkeep b/Resources/Models/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/Resources/Voices/.gitkeep b/Resources/Voices/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/project.yml b/project.yml index 2bf68ca..932c0b9 100644 --- a/project.yml +++ b/project.yml @@ -1,110 +1,68 @@ name: Vorleser options: - bundleIdPrefix: de.felixfoertsch - developmentLanguage: en - deploymentTarget: - iOS: 26.0 - macOS: 15.0 - createIntermediateGroups: true -settings: - base: - SWIFT_VERSION: 5.9 - CURRENT_PROJECT_VERSION: 1 - MARKETING_VERSION: 0.1.0 + bundleIdPrefix: de.felixfoertsch + deploymentTarget: + iOS: "18.0" + macOS: "15.0" + xcodeVersion: "16.0" + createIntermediateGroups: true + packages: - ZipFoundation: - path: Vendor/ZipFoundation - SwiftSoup: - path: Vendor/SwiftSoup + VorleserKit: + path: VorleserKit targets: - Vorleser: - type: application - platform: iOS - sources: - - path: Vorleser - configFiles: - Debug: Config/Signing.xcconfig - Release: Config/Signing.xcconfig - settings: - base: - PRODUCT_BUNDLE_IDENTIFIER: de.felixfoertsch.vorleser - IPHONEOS_DEPLOYMENT_TARGET: 26.0 - GENERATE_INFOPLIST_FILE: true - INFOPLIST_KEY_CFBundleVersion: "1" - INFOPLIST_KEY_CFBundleShortVersionString: "0.1.0" - INFOPLIST_KEY_UIBackgroundModes: [audio, processing] - INFOPLIST_KEY_LSSupportsOpeningDocumentsInPlace: true - INFOPLIST_KEY_UIFileSharingEnabled: true - dependencies: - - package: ZipFoundation - product: ZIPFoundation - - package: SwiftSoup - product: SwiftSoup + Vorleser-iOS: + type: application + platform: iOS + sources: + - Vorleser-iOS + dependencies: + - package: VorleserKit + product: VorleserKit + - package: VorleserKit + product: BookParser + - package: VorleserKit + product: Storage + - package: VorleserKit + product: Synthesizer + - package: VorleserKit + product: AudioEngine + settings: + base: + PRODUCT_BUNDLE_IDENTIFIER: de.felixfoertsch.vorleser + INFOPLIST_VALUES: >- + UIBackgroundModes=(audio); + UILaunchScreen={}; + UIFileSharingEnabled=YES; + LSSupportsOpeningDocumentsInPlace=YES; + resources: + - path: Resources/Models + buildPhase: resources + - path: Resources/Voices + buildPhase: resources - VorleserMac: - type: application - platform: macOS - sources: - - path: VorleserMac - resources: - - path: VorleserMac/Resources/Models - - path: VorleserMac/Resources/Voices - - path: VorleserMac/Resources/Config - - path: VorleserMac/Resources/Tools - dependencies: - - package: ZipFoundation - product: ZIPFoundation - - package: SwiftSoup - product: SwiftSoup - configFiles: - Debug: Config/Signing.xcconfig - Release: Config/Signing.xcconfig - postBuildScripts: - - name: Bundle espeak-ng - script: | - set -euo pipefail - BIN_SRC="/opt/homebrew/bin/espeak-ng" - DATA_SRC="/opt/homebrew/share/espeak-ng-data" - DYLIB_SRC="/opt/homebrew/lib/libespeak-ng.dylib" - - if [ ! -x "$BIN_SRC" ]; then - echo "espeak-ng not found at $BIN_SRC. Install via: brew install espeak-ng" - exit 1 - fi - if [ ! -d "$DATA_SRC" ]; then - echo "espeak-ng data not found at $DATA_SRC" - exit 1 - fi - if [ ! -f "$DYLIB_SRC" ]; then - echo "libespeak-ng.dylib not found at $DYLIB_SRC" - exit 1 - fi - - RES_DIR="${BUILT_PRODUCTS_DIR}/${PRODUCT_NAME}.app/Contents/Resources" - TOOL_DIR="${RES_DIR}/Tools" - FRAMEWORK_DIR="${BUILT_PRODUCTS_DIR}/${PRODUCT_NAME}.app/Contents/Frameworks" - mkdir -p "$TOOL_DIR" "$FRAMEWORK_DIR" - - cp -f "$BIN_SRC" "$TOOL_DIR/espeak-ng" - chmod +x "$TOOL_DIR/espeak-ng" - rsync -a "$DATA_SRC/" "$TOOL_DIR/espeak-ng-data/" - cp -f "$DYLIB_SRC" "$FRAMEWORK_DIR/libespeak-ng.dylib" - - install_name_tool -id "@rpath/libespeak-ng.dylib" "$FRAMEWORK_DIR/libespeak-ng.dylib" - install_name_tool -change "$DYLIB_SRC" "@rpath/libespeak-ng.dylib" "$TOOL_DIR/espeak-ng" - install_name_tool -add_rpath "@executable_path/../Frameworks" "$TOOL_DIR/espeak-ng" || true - - codesign --force --sign - --timestamp=none "$FRAMEWORK_DIR/libespeak-ng.dylib" - codesign --force --sign - --timestamp=none "$TOOL_DIR/espeak-ng" - outputFiles: - - ${BUILT_PRODUCTS_DIR}/${PRODUCT_NAME}.app/Contents/Resources/Tools/espeak-ng - - ${BUILT_PRODUCTS_DIR}/${PRODUCT_NAME}.app/Contents/Resources/Tools/espeak-ng-data/phondata - - ${BUILT_PRODUCTS_DIR}/${PRODUCT_NAME}.app/Contents/Frameworks/libespeak-ng.dylib - settings: - base: - PRODUCT_BUNDLE_IDENTIFIER: de.felixfoertsch.vorleser.mac - MACOSX_DEPLOYMENT_TARGET: 15.0 - GENERATE_INFOPLIST_FILE: true - INFOPLIST_KEY_CFBundleVersion: "1" - INFOPLIST_KEY_CFBundleShortVersionString: "0.1.0" + Vorleser-macOS: + type: application + platform: macOS + sources: + - Vorleser-macOS + dependencies: + - package: VorleserKit + product: VorleserKit + - package: VorleserKit + product: BookParser + - package: VorleserKit + product: Storage + - package: VorleserKit + product: Synthesizer + - package: VorleserKit + product: AudioEngine + settings: + base: + PRODUCT_BUNDLE_IDENTIFIER: de.felixfoertsch.vorleser.mac + resources: + - path: Resources/Models + buildPhase: resources + - path: Resources/Voices + buildPhase: resources