gurhub / surmagic

🚀 Command Line Tool to create XCFramework for multiple platforms in one shot!
MIT License
310 stars 43 forks source link

Surmagic init - Illegal hardware instruction surmagic init #8

Closed miroslavkovac closed 3 years ago

miroslavkovac commented 3 years ago

Describe the bug Calling surmagic init while being in the Xcode project folder is throwing an error:

 📂 Created a directory: ./Surmagic 

Fatal error: could not load resource bundle: from /usr/local/bin/surmagic_surmagic.bundle or /Users/mgy/Developer/surmagic/surmagic/.build/x86_64-apple-macosx/release/surmagic_surmagic.bundle: file surmagic/resource_bundle_accessor.swift, line 11
[1]    82586 illegal hardware instruction  surmagic init

To Reproduce Steps to reproduce the behavior:

  1. cd to Xcode project directory
  2. run surmagic init
  3. See error

Expected behavior The Surfile is generated and no error thrown.

Screenshots ...

macOS (please complete the following information): ℹī¸ Printing the information:


1.2.2


Xcode 12.3 Build version 12C33


ProductName: macOS ProductVersion: 11.1 BuildVersion: 20C69


Additional context ...

gurhub commented 3 years ago

Hi miroslavkovac, thank you for the issue,

might be related to this issue:

https://forums.swift.org/t/swift-5-3-spm-resources-in-tests-uses-wrong-bundle-path/37051/16

...even if they're talking about the test targets. Our issue is related to the bundle path.

I'll watch that issue. Kindly, let me know If you'll find something useful about the case.

Till that time, stay healthy.

Best

Muhammed Gurhan Yerlikaya

stanislas-huma commented 3 years ago

I actually experienced this issue too

newstrong commented 3 years ago

I actually experienced this issue too

gurhub commented 3 years ago

Quick Note: init command it's just an easy way to create Surfile in the Surmagic directory. Since I couldn't fix this bug, you can easily create a Surmagic directory and a Surfile from the template:

https://github.com/gurhub/surmagic/wiki/What-is-the-Surfile

and use the library with ease 😊

Please check early comments on this page about the issue on SPM. I'll not wait for them to fix probably, I'm gonna switch the method for creating that file.

Thank you for your support.

Please feel free to contribute.

Best

gurhub commented 3 years ago

Thank you all for your passion 😊 Please check version 1.2.3: https://github.com/gurhub/surmagic/releases/tag/1.2.3. From now Surmagic will search Surfile under the "SM" directory.✌đŸģ