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

Build error #106

Open
dave256 opened this issue Jan 30, 2021 · 8 comments
Open

Build error #106

dave256 opened this issue Jan 30, 2021 · 8 comments

Comments

@dave256
Copy link

dave256 commented Jan 30, 2021

On macOS 11.1 with Xcode 12.4 on an M1 Mac, I get this linker error:

The linked framework 'CoreSimulator.framework' is missing one or more architectures required by this target: arm64.

Am I missing an extra step or is something wrong with the Xcode installation on my Mac?

@twostraws
Copy link
Owner

I haven't tried on M1, I'm afraid. @dchakarov checked something recently and it seemed okay, so I'm not sure what the fix might be here.

@dave256
Copy link
Author

dave256 commented Jan 30, 2021

@twostraws, ok thanks. Just wanted to make certain I wasn't missing some extra step needed.

@AvdLee
Copy link

AvdLee commented Jan 30, 2021

@dave256 check out this issue: #103 (comment)

@dave256
Copy link
Author

dave256 commented Jan 31, 2021

@AvdLee @twostraws I had tried that but got a bunch of errors. I looked at them and they seem to be related to the SwiftUI previews.

/Users/dreed/Projects/ControlRoom/ControlRoom/About UI/AboutView.swift:68:1: Type Name Violation: Type name should only contain alphanumeric characters: 'AboutView_Previews' (type_name)

So I commented out the Previews that had issues and now I get this:

Showing All Messages
PhaseScriptExecution SwiftLint /Users/dreed/Library/Developer/Xcode/DerivedData/ControlRoom-eygwvexwtqvpkhbccnxzwaazpzen/Build/Intermediates.noindex/ControlRoom.build/Debug/ControlRoom.build/Script-551F8CFA23F4CB770006D1BD.sh (in target 'ControlRoom' from project 'ControlRoom')

Loading configuration from '.swiftlint.yml'
Configuration contains invalid keys:
["identifier_name"]
Linting Swift files in current working directory
Linting 'LoadingFailedView.swift' (1/54)
Linting 'LoadingView.swift' (2/54)
Linting 'PreferencesView.swift' (3/54)
Linting 'AboutView.swift' (4/54)
Linting 'Contributors.swift' (5/54)
Could not cast value of type 'Swift.Int64' (0x10925ef70) to 'Swift.String' (0x1092654c8).
/Users/dreed/Library/Developer/Xcode/DerivedData/ControlRoom-eygwvexwtqvpkhbccnxzwaazpzen/Build/Intermediates.noindex/ControlRoom.build/Debug/ControlRoom.build/Script-551F8CFA23F4CB770006D1BD.sh: line 6: 13476 Abort trap: 6 swiftlint
Command PhaseScriptExecution failed with a nonzero exit code

then I looked and realized I don't have SwiftLint so I commented out the script in the build phase for it and it now builds.

I'm leaving this open in case you want to look at the issue with Previews but you can close it if you want.

@allSwiftUI
Copy link

On macOS 11.2 (RC3) with Xcode 12.4(12D4e) on an MacBook Air M1 and selected schema "My Mac (Rosetta)", successful build is achieved.

@cadenkriese
Copy link

cadenkriese commented Jan 31, 2021

Rosetta emulation works fine for me too, but I tried just removing CoreSimulator.framework from the frameworks group in Xcode out of sheer curiosity. To my utter surprise, it actually created a mostly working Apple Silicon native binary (every feature I tried worked, but there was quite a bit of console spam).

Now I know nothing about Xcode, swift, or this core simulator framework, but I have a native apple silicon binary that works for my purposes, so I'm happy.

@ygee07
Copy link

ygee07 commented Feb 2, 2021

Rosetta emulation works fine for me too, but I tried just removing CoreSimulator.framework from the frameworks group in Xcode out of sheer curiosity. To my utter surprise, it actually created a mostly working Apple Silicon native binary (every feature I tried worked, but there was quite a bit of console spam).

Now I know nothing about Xcode, swift, or this core simulator framework, but I have a native apple silicon binary that works for my purposes, so I'm happy.

This works, thanks. Maybe, just maybe, because M1 is already native ARM, it doesn't need to run a simulator.

@nashysolutions
Copy link
Contributor

See #118

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants