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

needle 0.18.1 #99203

Closed
wants to merge 1 commit into from
Closed

needle 0.18.1 #99203

wants to merge 1 commit into from

Conversation

cho-m
Copy link
Member

@cho-m cho-m commented Apr 13, 2022

  • Have you followed the guidelines for contributing?
  • Have you ensured that your commits follow the commit style guide?
  • Have you checked that there aren't other open pull requests for the same formula update/change?
  • Have you built your formula locally with brew install --build-from-source <formula>, where <formula> is the name of the formula you're submitting?
  • Is your test running fine brew test <formula>, where <formula> is the name of the formula you're submitting?
  • Does your build pass brew audit --strict <formula> (after doing brew install --build-from-source <formula>)? If this is a new formula, does it pass brew audit --new <formula>?

@cho-m cho-m added the CI-no-bottles Merge without publishing bottles label Apr 13, 2022
@BrewTestBot BrewTestBot added the no Linux bottle Formula has no Linux bottle label Apr 13, 2022
@cho-m cho-m force-pushed the needle-monterey branch from c199385 to 876ead7 Compare April 13, 2022 21:58
def install
system "make", "install", "BINARY_FOLDER_PREFIX=#{prefix}"
bin.install "./Generator/bin/needle"
libexec.install "./Generator/bin/lib_InternalSwiftSyntaxParser.dylib"
deuniversalize_machos libexec/"lib_InternalSwiftSyntaxParser.dylib"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we not patch make to build the correct one here?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makefile copies library from Xcode.app (https://github.com/uber/needle/blob/v0.17.2/Makefile#L49) and then just modifies RPATH.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think that allows us to ship it since XCode is proprietary

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We could use the one from the swift formula though. That is guaranteed open source

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll give that a try.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like swift might be taking over build from Xcode and causing some issues.

@cho-m cho-m force-pushed the needle-monterey branch from 876ead7 to f9f9250 Compare April 17, 2022 18:40
@Bo98
Copy link
Member

Bo98 commented Apr 17, 2022

There is a reason it ships with Xcode rather than the OS. lib_InternalSwiftSyntaxParser must match the Swift version used to compile. We ship Swift 5.6 so using that dylib but still compiling using whatever older Swift version ships with older Xcodes could cause problems:

You can either copy lib_InternalSwiftSyntaxParser.dylib/.so directly from the toolchain or even build it yourself from the Swift repository, as long as you are matching the same tags or branches in both the SwiftSyntax and Swift repositories.

https://github.com/apple/swift-syntax/blob/e22754fbe767bfb290199573309689acb24297ef/Documentation/README.md#embedding-swiftsyntax-in-an-application

@cho-m cho-m added the CI-no-fail-fast Continue CI tests despite failing GitHub Actions matrix builds. label Apr 18, 2022
@cho-m
Copy link
Member Author

cho-m commented Apr 18, 2022

I think the Makefile directly runs swift commands, so it might not be using Xcode in current state. Locally, I could build via Rosetta but not natively on M1.

Is there any extra licensing terms to allow us to just use pre-built from Xcode toolchain? I think that would reduce breakages as upstream will follow Xcode releases.

@cho-m cho-m force-pushed the needle-monterey branch from f9f9250 to 95514b7 Compare April 18, 2022 22:49
@cho-m cho-m removed the CI-no-bottles Merge without publishing bottles label Apr 18, 2022
@cho-m cho-m changed the title needle: fix build on Monterey needle 0.18.0 Apr 18, 2022
@Bo98
Copy link
Member

Bo98 commented Apr 18, 2022

Is there any extra licensing terms to allow us to just use pre-built from Xcode toolchain?

We've done stuff like that before, like JavaNativeFoundation in openjdk@11. Sean raises a fair point but I don't really have the answer to it, because no one has really properly raised it or looked into it until now.

@cho-m cho-m force-pushed the needle-monterey branch from 95514b7 to b601cd6 Compare April 19, 2022 08:00
@cho-m cho-m changed the title needle 0.18.0 needle 0.18.1 Apr 19, 2022
@SMillerDev
Copy link
Member

Filed: uber/needle#412

@cho-m cho-m added the build failure CI fails while building the software label Apr 22, 2022
@github-actions
Copy link
Contributor

This pull request has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

@github-actions github-actions bot added the stale No recent activity label May 13, 2022
@bayandin bayandin mentioned this pull request May 13, 2022
@github-actions github-actions bot closed this May 20, 2022
@github-actions github-actions bot added the outdated PR was locked due to age label Jun 20, 2022
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jun 20, 2022
@cho-m cho-m deleted the needle-monterey branch December 21, 2022 20:18
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
build failure CI fails while building the software CI-no-fail-fast Continue CI tests despite failing GitHub Actions matrix builds. no Linux bottle Formula has no Linux bottle outdated PR was locked due to age stale No recent activity
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants