Coder Social home page Coder Social logo

Segmentation Fault about swiftgen HOT 8 CLOSED

swiftgen avatar swiftgen commented on May 22, 2024
Segmentation Fault

from swiftgen.

Comments (8)

AliSoftware avatar AliSoftware commented on May 22, 2024

That's probably because it has detected your Twitter name and want to troll you πŸ˜‰

But seriously, when installed via brew and especially if Homebrew did pour the "bottle" (= the precompiled version of swiftgen directly downloaded via a .tar.gz) instead of compiling it on your machine locally during installation, then swiftgen will have a @rpath set to some path inside /Applications/Xcode.app/… so that's where it's gonna look for the Swift dylibs to load. Even if that version installed at that path is in fact Xcode 6.

I added a protection in SwiftGen's formula to only use the bottle if the path /Applications/Xcode.app exist on your machine but didn't check that the version at that path was Xcode 7.0.1. I'll bet that's not the case for you and that's the cause of the SegFault because SwiftGen will then load Xcode 6's Swift libs instead of Xcode 7's ones, no matter what xcode-select -p you have.

from swiftgen.

AliSoftware avatar AliSoftware commented on May 22, 2024

Could you rename your Xcode 7.0.1 to /Applications/Xcode.app and try again?

from swiftgen.

esttorhe avatar esttorhe commented on May 22, 2024

Oh! The twitter handle irony πŸ˜‚

I do have a symlink pointing to 7.1; don't know if that's the issue or if it should be pointing to 7.0.1 instead.

I'll try changing it anyways.

Xcode.app -> /Applications/Xcode-7.1.app

from swiftgen.

esttorhe avatar esttorhe commented on May 22, 2024

Changing the symlink to 7.0.1 and «re-pouring» the bottle fixed it 🍻

Don't know if 7.1 doesn't work for this or what Β―_(ツ)_/Β―

I'm closing it. Thanks πŸ™‡

from swiftgen.

AliSoftware avatar AliSoftware commented on May 22, 2024

I don't like it. One more restriction when installing via homebrew.

I'll make a 0.5.1 that copies Swift libs over so it's independent of your Xcode install path and will hopefully solve this once and for all.

from swiftgen.

AliSoftware avatar AliSoftware commented on May 22, 2024

@esttorhe SwiftGen 0.5.1 just got merged into Homebrew; could you test it (with your symlink reset to 7.1 like when you had the issue) and tell if it fixed it?

Thx!

from swiftgen.

esttorhe avatar esttorhe commented on May 22, 2024

@AliSoftware just tested with the symlink back at 7.1.

Uninstalled swiftgen and reinstalled via homebrew and is working now πŸ‘Œ

from swiftgen.

AliSoftware avatar AliSoftware commented on May 22, 2024

πŸŽ‰

from swiftgen.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.