Skip to content
Merged
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
11 changes: 10 additions & 1 deletion Package.swift
Original file line number Diff line number Diff line change
@@ -1,6 +1,14 @@
// swift-tools-version: 6.1
import PackageDescription
import Foundation
import CompilerPluginSupport
import class Foundation.ProcessInfo

// get environment variables
let environment = ProcessInfo.processInfo.environment
let dynamicLibrary = environment["SWIFT_BUILD_DYNAMIC_LIBRARY"] == "1"

// force building as dynamic library
let libraryType: PackageDescription.Product.Library.LibraryType? = dynamicLibrary ? .dynamic : nil

let package = Package(
name: "CoreModel-SQLite",
Expand All @@ -13,6 +21,7 @@ let package = Package(
products: [
.library(
name: "CoreModelSQLite",
type: libraryType,
targets: ["CoreModelSQLite"]
)
],
Expand Down
Loading