flowkey / UIKit-cross-platform

Cross-platform Swift implementation of UIKit, mostly for Android
MIT License
595 stars 40 forks source link

Couldn't find swift 4.1.3 #280

Closed JosmerDelgado closed 5 years ago

JosmerDelgado commented 5 years ago

Current behavior

when I try to build the app Error:could not find the swiftc at expected path /Users/*****/Documents/Proyectos/Swift/Misterio2/MisterioHelper/UIKit/swift-android-toolchain/usr/bin/swiftc

Expected behavior

must build correctly

michaelknoch commented 5 years ago

have you correctly installed your git submodules? git submodule update --init --recursive UIKit @JosmerDelgado

ephemer commented 5 years ago

@JosmerDelgado can you provide more details. If you’re on Mac, do you have Xcode installed and accepted the licence agreement?

JosmerDelgado commented 5 years ago

I have mac, I follow the steps : " This project includes a DemoApp which runs on iOS, Android and Mac.

How to run it on different platforms:

Clone this project, cd into it and run git submodule update --init --recursive Open ./samples/getting-started/DemoApp.xcodeproj in Xcode Run DemoApp target for the iOS App Run DemoAppMac target for the Mac App Open ./samples/getting-started/android with Android Studio (install Android SDKs if necessary) Connect an Android device and press "Run" for the Android App "

step by step.

JosmerDelgado commented 5 years ago

Yes I did

have you correctly installed your git submodules? git submodule update --init --recursive UIKit

ephemer commented 5 years ago

When you say you tried to build the app, do you mean with android studio? With gradle directly? With Xcode? Sorry but we need more details to be able to help you effectively!

At which point in the instructions does it fail?

JosmerDelgado commented 5 years ago

I try to run the app from Android studio and show me this error:

Error:could not find the swiftc at expected path /Users/*****/Documents/Proyectos/Swift/Misterio2/MisterioHelper/UIKit/swift-android-toolchain/usr/bin/swiftc

ephemer commented 5 years ago

Ok, can you try going into the directory listed ending in swift-android-toolchain/ and running the setup.sh that’s in there from the command line? It should always be run automatically but maybe there’s an error being hidden by android studio

JosmerDelgado commented 5 years ago

When I run setup.sh show me this error. But i Already have installed swift

[swift-android-toolchain] Couldn't find swift 4.1.3 [swift-android-toolchain] Download and install it from https://swift.org/download [swift-android-toolchain] e.g. for macOS: https://swift.org/builds/swift-4.1.3-release/xcode/swift-4.1.3-RELEASE/swift-4.1.3-RELEASE-osx.pkg [swift-android-toolchain] If you have the toolchain installed at a non-standard path (e.g. on Linux), 'export HOST_SWIFT_BIN_PATH=your/path/usr/bin' and try again

ephemer commented 5 years ago

Thanks, we may need to update the docs on this point: we need you to download that specific version of the Swift toolchain to be compatible with the version of Swift we use on Android. Just download and run the file linked next to "e.g. for macOS" and try to build in Android Studio again. The version shipped with Xcode isn't enough- you need that exact version.

ephemer commented 5 years ago

@JosmerDelgado did that solve the issue?