Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
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
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,13 @@ local.properties
signing.properties

build/
.build/
.swiftpm/
*/Podfile.lock
*/Pods/*
*/Flare.xcworkspace/*
*/Flare.xcodeproj/*
/flareUI/demo/appleApp/FlareUIDemo.xcodeproj/
shared/shared.podspec
.kotlin
.history
Expand Down
8 changes: 8 additions & 0 deletions apple-shared/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@ import dev.dimension.flare.buildlogic.FlarePlatform
import dev.dimension.flare.buildlogic.flare
import org.jetbrains.kotlin.gradle.plugin.mpp.KotlinNativeTarget

val flareUiVersion = "0.1.0-SNAPSHOT"
val flareUiCore = "dev.dimension.flareui:core:$flareUiVersion"
val flareUiAppleRuntime = "dev.dimension.flareui:apple-runtime:$flareUiVersion"

plugins {
id("dev.dimension.flare.multiplatform-library")
alias(libs.plugins.kotlin.multiplatform)
Expand Down Expand Up @@ -51,6 +55,8 @@ kotlin {
commonExportedProjects.forEach { exportedProject ->
export(exportedProject)
}
export(flareUiCore)
export(flareUiAppleRuntime)

if (appleTarget.name.startsWith("ios")) {
export(projects.social.nostr)
Expand All @@ -74,6 +80,8 @@ kotlin {
api(projects.feature.subscription)
api(projects.feature.tab)
api(projects.feature.agent)
api(flareUiCore)
api(flareUiAppleRuntime)
implementation(libs.compose.runtime)
// START Non-FOSS component
implementation(libs.crashkios.crashlytics)
Expand Down
42 changes: 42 additions & 0 deletions appleApp/project.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,8 @@ settings:
VALIDATE_PRODUCT: YES

packages:
FlareUI:
path: ../flareUI/apple
ChatLayout:
url: https://github.com/ekazaev/ChatLayout
exactVersion: 2.4.2
Expand Down Expand Up @@ -173,6 +175,10 @@ targets:
destinationFilters: [iOS]
- target: FlareAppleUI
destinationFilters: [iOS]
- package: FlareUI
product: FlareUISwiftUI
- target: FlareUIKotlinBridge
destinationFilters: [iOS]
- target: FlareAppleResource
embed: true
link: false
Expand Down Expand Up @@ -253,6 +259,10 @@ targets:
destinationFilters: [macOS]
- target: FlareAppleUI
destinationFilters: [macOS]
- package: FlareUI
product: FlareUISwiftUI
- target: FlareUIKotlinBridge
destinationFilters: [macOS]
- target: FlareAppleResource
embed: true
link: false
Expand Down Expand Up @@ -378,6 +388,38 @@ targets:
OTHER_LDFLAGS: "$(inherited) -lsqlite3"
PRODUCT_BUNDLE_IDENTIFIER: dev.dimension.flare.appleui

FlareUIKotlinBridge:
type: framework.static
platform: auto
supportedDestinations: [iOS, macOS]
sources:
- path: ../flareUI/apple/Sources/KotlinBridge
dependencies:
- package: FlareUI
product: FlareUIRuntime
preBuildScripts:
- name: Compile Kotlin
basedOnDependencyAnalysis: false
script: |
cd "$SRCROOT/.."
if [ -n "${GRADLE_JVM_ARGS:-}" ]; then
./gradlew "-Dorg.gradle.jvmargs=$GRADLE_JVM_ARGS" :apple-shared:embedAndSignAppleFrameworkForXcode
else
./gradlew :apple-shared:embedAndSignAppleFrameworkForXcode
fi
settings:
base:
CLANG_ENABLE_MODULE_VERIFIER: YES
DEAD_CODE_STRIPPING: YES
FRAMEWORK_SEARCH_PATHS:
- "$(inherited)"
- "$(SRCROOT)/../apple-shared/build/xcode-frameworks/$(CONFIGURATION)/$(SDK_NAME)"
GENERATE_INFOPLIST_FILE: YES
OTHER_SWIFT_FLAGS: "$(inherited) -module-alias FlareUIKotlinRuntime=KotlinSharedUI"
PRODUCT_BUNDLE_IDENTIFIER: dev.dimension.flare.flareui.kotlinbridge
PRODUCT_MODULE_NAME: FlareUIKotlinBridge
PRODUCT_NAME: FlareUIKotlinBridge

schemes:
iOS:
build:
Expand Down
Loading
Loading