Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[SR-12215] swift package generate-xcodeproj emits non-relative header search path when using .headerSearchPath CSetting #4592

Closed
macdrevx opened this issue Feb 16, 2020 · 4 comments
Labels

Comments

@macdrevx
Copy link

Previous ID SR-12215
Radar rdar://problem/59496051
Original Reporter @macdrevx
Type Bug
Status Closed
Resolution Won't Do

Attachment: Download

Environment

Apple Swift version 5.1.3 (swiftlang-1100.0.282.1 clang-1100.0.33.15)
Target: x86_64-apple-darwin19.3.0

Additional Detail from JIRA
Votes 0
Component/s Package Manager
Labels Bug
Assignee None
Priority Medium

md5: 222f6fd77000af0c44ee69b9060e6230

Issue Description:

Discussion

Originally reported in GEOSwift/GEOSwift#194

The documentation comment for CSetting.headerSearchPath(_ path: String, _ condition: BuildSettingCondition? = nil) says

/// - path: The path of the directory that should be searched for headers. The path is relative to the target's directory.

However, in the following example, the corresponding target in the generated Xcode project does not translate the path into one that is relative to the target's directory.

Steps to reproduce:

  1. Open the attached project

  2. Run swift package update

  3. Run swift package generate-xcodeproj

  4. Open GeoZone.xcodeproj

Expected Result

  1. The Header Search Paths build setting for the geos target has the entry $(SRCROOT)/.build/checkouts/geos/Sources/geos/include

Actual Result

  1. The Header Search Paths build setting for the geos target has the entry include
@beccadax
Copy link
Contributor

@swift-ci create

@macdrevx
Copy link
Author

Perhaps a won't fix since generate-xcodeproj is being deprecated?

@swift-ci
Copy link
Contributor

swift-ci commented Mar 2, 2021

Comment by Jason Wray (JIRA)

generate-xcodeproj is indeed being deprecated — if there's a use-case not covered by Xcode's ability to directly open packages, please feel free to let us know here or in the forums.

@macdrevx
Copy link
Author

macdrevx commented Apr 5, 2021

friedbunny (JIRA User) there are 2 capabilities that my team needs before we can drop Xcode projects altogether:

  1. the ability to generate XCFrameworks (static or dynamic) for a Swift package without an Xcode project

  2. the ability to run tests in a host app (so that we can test our Swift package on AWS Device Farm)

For now, we're resorting to using XcodeGen for those workflows so that we don't need to maintain an Xcode project manually.

@swift-ci swift-ci transferred this issue from apple/swift-issues Apr 25, 2022
@shahmishal shahmishal transferred this issue from apple/swift May 4, 2022
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants