cue-ios: add xcode project config and build script
This commit is contained in:
parent
aee5a2e033
commit
bbfb008d1a
|
|
@ -0,0 +1,6 @@
|
|||
*.xcodeproj
|
||||
.swiftpm/
|
||||
.build/
|
||||
build/
|
||||
DerivedData/
|
||||
*.xcuserdata
|
||||
|
|
@ -0,0 +1,11 @@
|
|||
{
|
||||
"colors" : [
|
||||
{
|
||||
"idiom" : "universal"
|
||||
}
|
||||
],
|
||||
"info" : {
|
||||
"author" : "xcode",
|
||||
"version" : 1
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,14 @@
|
|||
{
|
||||
"images" : [
|
||||
{
|
||||
"filename" : "appicon-1024.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "ios",
|
||||
"size" : "1024x1024"
|
||||
}
|
||||
],
|
||||
"info" : {
|
||||
"author" : "xcode",
|
||||
"version" : 1
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
{
|
||||
"info" : {
|
||||
"author" : "xcode",
|
||||
"version" : 1
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,5 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
||||
<plist version="1.0">
|
||||
<dict/>
|
||||
</plist>
|
||||
|
|
@ -0,0 +1,14 @@
|
|||
{
|
||||
"pins" : [
|
||||
{
|
||||
"identity" : "grdb.swift",
|
||||
"kind" : "remoteSourceControl",
|
||||
"location" : "https://github.com/groue/GRDB.swift.git",
|
||||
"state" : {
|
||||
"revision" : "36e30a6f1ef10e4194f6af0cff90888526f0c115",
|
||||
"version" : "7.10.0"
|
||||
}
|
||||
}
|
||||
],
|
||||
"version" : 2
|
||||
}
|
||||
|
|
@ -0,0 +1,51 @@
|
|||
#!/usr/bin/env bash
|
||||
set -euo pipefail
|
||||
cd "$(dirname "$0")"
|
||||
|
||||
SVG_SRC="../cue/assets/cue.svg"
|
||||
ICON_DIR="CueIOS/Assets.xcassets/AppIcon.appiconset"
|
||||
BUILD_DIR="build"
|
||||
|
||||
# Generate app icon from SVG
|
||||
if [ -f "$SVG_SRC" ] && command -v rsvg-convert &>/dev/null; then
|
||||
echo "Generating app icon from $SVG_SRC"
|
||||
rsvg-convert -w 1024 -h 1024 "$SVG_SRC" -o /tmp/cue-icon-raw.png
|
||||
if command -v magick &>/dev/null; then
|
||||
magick /tmp/cue-icon-raw.png -filter Point -gravity center \
|
||||
-background none -extent 1024x1024 \
|
||||
"$ICON_DIR/appicon-1024.png"
|
||||
else
|
||||
cp /tmp/cue-icon-raw.png "$ICON_DIR/appicon-1024.png"
|
||||
fi
|
||||
rm -f /tmp/cue-icon-raw.png
|
||||
echo "App icon generated"
|
||||
elif [ ! -f "$ICON_DIR/appicon-1024.png" ]; then
|
||||
echo "Warning: No app icon. Place appicon-1024.png in $ICON_DIR or install rsvg-convert."
|
||||
fi
|
||||
|
||||
# Regenerate xcodeproj if xcodegen available
|
||||
if command -v xcodegen &>/dev/null; then
|
||||
xcodegen generate --quiet
|
||||
fi
|
||||
|
||||
mkdir -p "$BUILD_DIR"
|
||||
|
||||
# Build for iOS device (release)
|
||||
xcodebuild \
|
||||
-project CueIOS.xcodeproj \
|
||||
-scheme CueIOS \
|
||||
-configuration Release \
|
||||
-sdk iphoneos \
|
||||
-derivedDataPath "$BUILD_DIR/DerivedData" \
|
||||
CODE_SIGN_IDENTITY="Apple Development" \
|
||||
CODE_SIGN_STYLE=Automatic \
|
||||
-quiet \
|
||||
build
|
||||
|
||||
APP_PATH=$(find "$BUILD_DIR/DerivedData" -name "CueIOS.app" -type d | head -1)
|
||||
if [ -n "$APP_PATH" ]; then
|
||||
cp -R "$APP_PATH" "$BUILD_DIR/"
|
||||
echo "Built: $BUILD_DIR/CueIOS.app"
|
||||
else
|
||||
echo "Build completed but .app not found in DerivedData"
|
||||
fi
|
||||
|
|
@ -0,0 +1,39 @@
|
|||
name: CueIOS
|
||||
options:
|
||||
bundleIdPrefix: org.elseif
|
||||
deploymentTarget:
|
||||
iOS: "17.0"
|
||||
xcodeVersion: "16.0"
|
||||
generateEmptyDirectories: true
|
||||
packages:
|
||||
GRDB:
|
||||
url: https://github.com/groue/GRDB.swift
|
||||
from: "7.0.0"
|
||||
targets:
|
||||
CueIOS:
|
||||
type: application
|
||||
platform: iOS
|
||||
sources:
|
||||
- path: CueIOS
|
||||
excludes:
|
||||
- Info.plist
|
||||
settings:
|
||||
base:
|
||||
PRODUCT_BUNDLE_IDENTIFIER: org.elseif.cue
|
||||
INFOPLIST_FILE: CueIOS/Info.plist
|
||||
DEVELOPMENT_TEAM: ""
|
||||
SWIFT_VERSION: "6.0"
|
||||
CODE_SIGN_STYLE: Automatic
|
||||
TARGETED_DEVICE_FAMILY: "1,2"
|
||||
ASSETCATALOG_COMPILER_APPICON_NAME: AppIcon
|
||||
ENABLE_USER_SCRIPT_SANDBOXING: false
|
||||
configs:
|
||||
Debug:
|
||||
DEBUG_INFORMATION_FORMAT: dwarf-with-dsym
|
||||
SWIFT_OPTIMIZATION_LEVEL: -Onone
|
||||
Release:
|
||||
SWIFT_OPTIMIZATION_LEVEL: -O
|
||||
dependencies:
|
||||
- package: GRDB
|
||||
entitlements:
|
||||
path: CueIOS/CueIOS.entitlements
|
||||
Loading…
Reference in New Issue