@@ -107,14 +107,14 @@ final class PkgConfigParserTests: XCTestCase {
107
107
" /usr/lib/pkgconfig/foo.pc " ,
108
108
" /usr/local/opt/foo/lib/pkgconfig/foo.pc " ,
109
109
" /custom/foo.pc " )
110
- XCTAssertEqual ( " /custom/foo.pc " , try PCFileFinder ( diagnostics: diagnostics, brewPrefix: nil ) . locatePCFile ( name: " foo " , customSearchPaths: [ AbsolutePath ( " /custom " ) ] , fileSystem: fs) . pathString )
111
- XCTAssertEqual ( " /custom/foo.pc " , try PkgConfig ( name: " foo " , additionalSearchPaths: [ AbsolutePath ( " /custom " ) ] , diagnostics: diagnostics, fileSystem: fs, brewPrefix: nil ) . pcFile. pathString )
112
- XCTAssertEqual ( " /usr/lib/pkgconfig/foo.pc " , try PCFileFinder ( diagnostics: diagnostics, brewPrefix: nil ) . locatePCFile ( name: " foo " , customSearchPaths: [ ] , fileSystem: fs) . pathString )
110
+ XCTAssertEqual ( AbsolutePath ( " /custom/foo.pc " ) , try PCFileFinder ( diagnostics: diagnostics, brewPrefix: nil ) . locatePCFile ( name: " foo " , customSearchPaths: [ AbsolutePath ( " /custom " ) ] , fileSystem: fs) )
111
+ XCTAssertEqual ( AbsolutePath ( " /custom/foo.pc " ) , try PkgConfig ( name: " foo " , additionalSearchPaths: [ AbsolutePath ( " /custom " ) ] , diagnostics: diagnostics, fileSystem: fs, brewPrefix: nil ) . pcFile)
112
+ XCTAssertEqual ( AbsolutePath ( " /usr/lib/pkgconfig/foo.pc " ) , try PCFileFinder ( diagnostics: diagnostics, brewPrefix: nil ) . locatePCFile ( name: " foo " , customSearchPaths: [ ] , fileSystem: fs) )
113
113
try withCustomEnv ( [ " PKG_CONFIG_PATH " : " /usr/local/opt/foo/lib/pkgconfig " ] ) {
114
- XCTAssertEqual ( " /usr/local/opt/foo/lib/pkgconfig/foo.pc " , try PkgConfig ( name: " foo " , diagnostics: diagnostics, fileSystem: fs, brewPrefix: nil ) . pcFile. pathString )
114
+ XCTAssertEqual ( AbsolutePath ( " /usr/local/opt/foo/lib/pkgconfig/foo.pc " ) , try PkgConfig ( name: " foo " , diagnostics: diagnostics, fileSystem: fs, brewPrefix: nil ) . pcFile)
115
115
}
116
116
try withCustomEnv ( [ " PKG_CONFIG_PATH " : " /usr/local/opt/foo/lib/pkgconfig:/usr/lib/pkgconfig " ] ) {
117
- XCTAssertEqual ( " /usr/local/opt/foo/lib/pkgconfig/foo.pc " , try PkgConfig ( name: " foo " , diagnostics: diagnostics, fileSystem: fs, brewPrefix: nil ) . pcFile. pathString )
117
+ XCTAssertEqual ( AbsolutePath ( " /usr/local/opt/foo/lib/pkgconfig/foo.pc " ) , try PkgConfig ( name: " foo " , diagnostics: diagnostics, fileSystem: fs, brewPrefix: nil ) . pcFile)
118
118
}
119
119
}
120
120
@@ -142,6 +142,7 @@ final class PkgConfigParserTests: XCTestCase {
142
142
XCTAssertEqual ( PCFileFinder . pkgConfigPaths, [ AbsolutePath ( " /Volumes/BestDrive/pkgconfig " ) ] )
143
143
}
144
144
145
+ #if !os(Windows) // pkg-config is not compatible with Windows paths.
145
146
func testAbsolutePathDependency( ) throws {
146
147
147
148
let libffiPath = " /usr/local/opt/libffi/lib/pkgconfig/libffi.pc "
@@ -171,6 +172,7 @@ final class PkgConfigParserTests: XCTestCase {
171
172
fileSystem: fileSystem,
172
173
brewPrefix: AbsolutePath ( " /usr/local " ) ) )
173
174
}
175
+ #endif
174
176
175
177
func testUnevenQuotes( ) throws {
176
178
do {
0 commit comments