Skip to content

Commit

Permalink
tested on macOS.
Browse files Browse the repository at this point in the history
  • Loading branch information
RockfordWei committed Jun 28, 2022
1 parent 252a222 commit 972a7a5
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 3 deletions.
23 changes: 22 additions & 1 deletion Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,27 @@

import PackageDescription

let czLibExcludes: [String] = [
"CMakeLists.txt", "ChangeLog", "FAQ", "INDEX",
"Makefile", "Makefile.in", "README",
"amiga/Makefile.pup", "amiga/Makefile.sas", "configure", "configure.log",
"doc/algorithm.txt", "doc/rfc1950.txt", "doc/rfc1951.txt",
"doc/rfc1952.txt", "doc/txtvsbin.txt", "make_vms.com",
"msdos/Makefile.bor", "msdos/Makefile.dj2",
"msdos/Makefile.emx", "msdos/Makefile.msc", "msdos/Makefile.tc",
"nintendods/Makefile", "nintendods/README",
"old/Makefile.emx", "old/Makefile.riscos", "old/README",
"old/descrip.mms", "old/os2/Makefile.os2", "old/visual-basic.txt",
"os400/README400", "os400/bndsrc", "os400/make.sh", "os400/zlib.inc",
"qnx/package.qpg", "treebuild.xml",
"watcom/watcom_f.mak", "watcom/watcom_l.mak",
"win32/DLL_FAQ.txt", "win32/Makefile.bor", "win32/Makefile.gcc",
"win32/Makefile.msc", "win32/README-WIN32.txt",
"win32/VisualC.txt", "win32/zlib1.rc",
"zconf.h.cmakein", "zconf.h.in", "zlib.3", "zlib.3.pdf",
"zlib.map", "zlib.pc", "zlib.pc.cmakein", "zlib.pc.in", "zlib2ansi"
]

#if os(Linux)
let osdep: [Target.Dependency] = ["LinuxBridge"]
let ostag: [Target] = [.target(name: "LinuxBridge"), .target(name: "PerfectCSQLite3")]
Expand Down Expand Up @@ -34,7 +55,7 @@ let package = Package(
.target(name: "COpenSSL"),
.target(name: "cURL"),
.target(name: "PerfectAuth", dependencies: ["PerfectCrypto"]),
.target(name: "PerfectCZlib"),
.target(name: "PerfectCZlib", exclude: czLibExcludes),
.target(name: "PerfectCHTTPParser"),
.target(name: "PerfectLib", dependencies: osdep),
.target(name: "PerfectThread", dependencies: osdep),
Expand Down
4 changes: 2 additions & 2 deletions Sources/PerfectCRUD/Coding/CodingNames.swift
Original file line number Diff line number Diff line change
Expand Up @@ -331,8 +331,8 @@ struct SubTable<T: Decodable, R: Decodable>: SubTableProto {
}

extension Decodable where Self: Encodable {
// !FIX! causing ciompiler crash
func makeSubTable(name: String, decoder: CRUDColumnNameDecoder) -> some SubTableProto {
@available(macOS 10.15.0, *)
func makeSubTable(name: String, decoder: CRUDColumnNameDecoder) -> some SubTableProto {
return SubTable(name: name, type: Self.self, decoder: decoder, realType: Self.self)
}

Expand Down

0 comments on commit 972a7a5

Please sign in to comment.