stepanhruda / PostgreSQL-Swift

Swift PostgreSQL driver
MIT License
105 stars 15 forks source link

Swift Package Manager Issues #19

Open ChrisChares opened 8 years ago

ChrisChares commented 8 years ago

I'm sure this is somehow a user error on my end but I can't figure it out. Just started using the Swift Package Manager last night.

My Package.swift

import PackageDescription
let package = Package(
        dependencies: [
                .Package(url: "https://github.com/stepanhruda/PostgreSQL-Swift.git", majorVersion: 0)
            ]
)

Steps:

Receive error: ld: library not found for -lvenice for architecture x86_64

What is venice and how did it become a dependency anyway? It's not in my project, it's not a dependency of PostgreSQL-Swift and it's not a dependency of libpq-darwin. Furthermore what architecture would brew even install for if not x86_64.

ChrisChares commented 8 years ago

Resolved this with the help of everyone over in the Zewo slack team. Seems there's an issue with the Swift Package Manager in the 2/8 snapshot. Instead of swift build, you have to build with swift build -Xswiftc -I/usr/local/include -Xlinker -L/usr/local/lib in order to explicitly set search paths.

More on the issue: https://github.com/apple/swift-package-manager/pull/165

stepanhruda commented 8 years ago

Yep, will add a convenient command to Makefile, we already have one in an upstream project.