-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Package.swift
100 lines (91 loc) · 3.17 KB
/
Package.swift
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
// swift-tools-version:5.9
// The swift-tools-version declares the minimum version of Swift required to build this package.
import PackageDescription
import CompilerPluginSupport
let package = Package(
name: "swift-mc",
defaultLocalization: "en",
platforms: [
.macOS(.v13)
],
dependencies: [
// Networking & Server
.package(url: "https://github.com/apple/swift-nio", from: "2.76.1"),
.package(url: "https://github.com/vapor/vapor", from: "4.106.4"),
.package(url: "https://github.com/Kitura/BlueSocket", from: "2.0.4"),
.package(url: "https://github.com/apple/swift-asn1", from: "1.3.0"),
.package(url: "https://github.com/vapor/console-kit", from: "4.14.2"),
// Macros
.package(url: "https://github.com/apple/swift-syntax", from: "600.0.1"),
// Localization
.package(url: "https://github.com/RandomHashTags/swift-string-catalogs", from: "1.0.0")
],
targets: [
.macro(
name: "MinecraftMacros",
dependencies: [
.product(name: "SwiftSyntax", package: "swift-syntax"),
.product(name: "SwiftSyntaxMacros", package: "swift-syntax"),
.product(name: "SwiftCompilerPlugin", package: "swift-syntax")
]
),
.target(
name: "App",
dependencies: [
"MinecraftAPI",
//.product(name: "BlueSocket", package: "BlueSocket"),
.product(name: "Vapor", package: "vapor"),
.product(name: "Socket", package: "BlueSocket"),
.product(name: "SwiftASN1", package: "swift-asn1"),
.product(name: "SwiftStringCatalogs", package: "swift-string-catalogs")
],
resources: [
.process("Resources")
],
swiftSettings: [
.unsafeFlags(["-cross-module-optimization"], .when(configuration: .release))
]
),
.target(
name: "MinecraftUtilities",
dependencies: [
"MinecraftMacros"
]
),
.target(
name: "MinecraftPackets",
dependencies: [
"MinecraftMacros",
"MinecraftUtilities",
]
),
.target(
name: "MinecraftAPI",
dependencies: [
"MinecraftMacros",
"MinecraftPackets"
]
),
.target(
name: "MinecraftPacketsJava",
dependencies: [
"MinecraftMacros",
"MinecraftPackets",
.product(name: "NIO", package: "swift-nio")
]
),
.target(
name: "MinecraftAPIJava",
dependencies: [
"MinecraftAPI",
"MinecraftMacros",
"MinecraftPacketsJava"
]
),
.executableTarget(name: "Run", dependencies: [.target(name: "App")]),
.testTarget(name: "swift_gluon-serverTests", dependencies: [
.target(name: "App"),
.product(name: "XCTVapor", package: "vapor")
]),
]
)