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-2649] Depending on self in targets declarations produces assertion #5217

Closed
ankitspd opened this issue Sep 15, 2016 · 1 comment
Closed
Labels

Comments

@ankitspd
Copy link
Member

Previous ID SR-2649
Radar rdar://problem/28998272
Original Reporter @aciidb0mb3r
Type Bug
Status Resolved
Resolution Done
Additional Detail from JIRA
Votes 0
Component/s Package Manager
Labels Bug, StarterBug
Assignee None
Priority Medium

md5: b634d0f0209ea71263dafae2da8c4552

Issue Description:

For eg this in Package.swift resulted in an assertion below. We should diagnose and report a proper message.

Target(
name: "XcodeprojTests",
dependencies: ["XcodeprojTests", "TestSupport"]),

      • bootstrap: note: building self-hosted 'swift-build': env SWIFT_EXEC=/Users/ankit/workspace/opensource/swift.org/swiftpm/.build/debug/swiftc SWIFT_BUILD_PATH=/Users/ankit/workspace/opensource/swift.org/swiftpm/.build SYSROOT=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.12.sdk /Users/ankit/workspace/opensource/swift.org/swiftpm/.build/debug/swift-build-stage1 -Xlinker -rpath -Xlinker @executable_path/../lib/swift/macosx --build-tests
        fatal error: 'try!' expression unexpectedly raised an error: Basic.GraphError.unexpectedCycle: file /Library/Caches/com.apple.xbs/Sources/swiftlang/swiftlang-800.0.46.2/src/swift/stdlib/public/core/ErrorType.swift, line 178
        Current stack trace:
        0 libswiftCore.dylib 0x0000000105c37580 swift_reportError + 132
        1 libswiftCore.dylib 0x0000000105c54730 _swift_stdlib_reportFatalErrorInFile + 112
        2 libswiftCore.dylib 0x0000000105c03700 partial apply for (_assertionFailed(StaticString, String, StaticString, UInt, flags : UInt32) -> Never).(closure Add missing steps to creating a C library package. #1).(closure Add missing steps to creating a C library package. #1).(closure Add missing steps to creating a C library package. #1) + 99
        3 libswiftCore.dylib 0x0000000105a50550 specialized specialized StaticString.withUTF8Buffer<A> ((UnsafeBufferPointer<UInt8>) -> A) -> A + 355
        4 libswiftCore.dylib 0x0000000105c03640 partial apply for (_assertionFailed(StaticString, StaticString, StaticString, UInt, flags : UInt32) -> Never).(closure Add missing steps to creating a C library package. #1).(closure Add missing steps to creating a C library package. #1) + 144
        5 libswiftCore.dylib 0x0000000105a50a60 specialized specialized String._withUnsafeBufferPointerToUTF8<A> ((UnsafeBufferPointer<UInt8>) throws -> A) throws -> A + 124
        6 libswiftCore.dylib 0x0000000105ba9290 partial apply for (_assertionFailed(StaticString, String, StaticString, UInt, flags : UInt32) -> Never).(closure Add missing steps to creating a C library package. #1) + 185
        7 libswiftCore.dylib 0x0000000105a50550 specialized specialized StaticString.withUTF8Buffer<A> ((UnsafeBufferPointer<UInt8>) -> A) -> A + 355
        8 libswiftCore.dylib 0x0000000105a50330 _assertionFailed(StaticString, String, StaticString, UInt, flags : UInt32) -> Never + 144
        9 libswiftCore.dylib 0x0000000105a74000 swift_unexpectedError_merged + 585
        10 swift-build-stage1 0x000000010582e380 Module.recursiveDependencies.getter + 224
        11 swift-build-stage1 0x00000001057a00d0 Module.XccFlags(AbsolutePath) -> [String] + 43
        12 swift-build-stage1 0x00000001057a5d60 static Command.compile(swiftModule : SwiftModule, configuration : Configuration, prefix : AbsolutePath, otherArgs : [String], compilerExec : AbsolutePath) throws -> Command + 226
        13 swift-build-stage1 0x00000001057b5300 describe(AbsolutePath, Configuration, PackageGraph, flags : BuildFlags, toolchain : Toolchain) throws -> AbsolutePath + 2784
        14 swift-build-stage1 0x00000001056f3d30 SwiftBuildTool.run() -> () + 2335
        15 swift-build-stage1 0x00000001056eaf20 main + 114
        16 libdyld.dylib 0x00007fff9900f5ac start + 1

      • bootstrap: error: build failed with exit status -4

@ankitspd
Copy link
Member Author

#670

@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

1 participant