在 Linux 中模拟/模拟 iOS

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/6311289/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-08-04 01:04:40  来源:igfitidea点击:

Emulate/Simulate iOS in Linux

linuxiosubuntu-10.04

提问by YOMorales

I'm developing a web app that apparently is having problems in iOS devices. The problem is that I don't own an iOS device and I develop in Linux Ubuntu. I'm looking for a way to emulate/simulate this OS in Linux (especially the browser), but haven't found anything.

我正在开发一个显然在 iOS 设备中存在问题的网络应用程序。问题是我没有 iOS 设备,我在 Linux Ubuntu 中开发。我正在寻找一种在 Linux(尤其是浏览器)中模拟/模拟这个操作系统的方法,但没有找到任何东西。

So far, what I've found is the iOS SDK's Simulator, but that is meant for the Mac. And also some emulator for Windows. Has anyone done this before?

到目前为止,我发现的是 iOS SDK 的模拟器,但这适用于 Mac。还有一些适用于 Windows 的模拟器。以前有人这样做过吗?

采纳答案by Fredrik

The only solution I can think of is to install VMWare or any other VT then install OSX on a VM.

我能想到的唯一解决方案是安装 VMWare 或任何其他 VT,然后在 VM 上安装 OSX。

It works pretty good for testing.

它非常适合测试。

回答by Ali1S232

As far as I know, there is no such a thing as iOS emulator on windows or linux, there are only some gameengines that enable you to compile same code for both iOS and windows or linux and there is a toolchain to compile iOS application using linux. none of them are realy emulator/simulator things. and to use that toolchain you need a jailbreaked iOS device to test binary file created using toolchain. I mean linux itself can't run the binary created itself. and by the way even in mac simulator is just an intermediate program which runs mac-compiled binary, since if you change compiling for iOS from simulator or the other way, all the files are rebuild. and also there are some real differences, like iOS is a case-sensitive operation while simulator is not.

据我所知,在 windows 或 linux 上没有 iOS 模拟器这样的东西,只有一些游戏引擎可以让你为 iOS 和 windows 或 linux 编译相同的代码,并且有一个工具链可以使用 linux 编译 iOS 应用程序. 它们都不是真正的模拟器/模拟器。要使用该工具链,您需要一个越狱的 iOS 设备来测试使用工具链创建的二进制文件。我的意思是 linux 本身不能运行自己创建的二进制文件。顺便说一下,即使在 mac 模拟器中也只是一个运行 mac 编译二进制文件的中间程序,因为如果您从模拟器或其他方式更改为 iOS 编译,所有文件都会重建。并且还有一些真正的区别,例如 iOS 是区分大小写的操作,而模拟器则不是。

so the best solution is to buy an iOS device yourself.

所以最好的解决方案是自己购买iOS设备。

回答by stepanVich

BrowserStack.com
On this site, you can emulate a lot of iOS's devices online.

BrowserStack.com
在这个网站上,你可以在线模拟很多 iOS 设备。

回答by martinbrambati

Maybe, this approach is better, https://saucelabs.com/mobile, mobile testing in the cloud with selenium

也许,这种方法更好,https://saucelabs.com/mobile,使用 selenium 在云中进行移动测试

回答by wviana

On linux you can check epiphany-browser, resizes the windows you'll get same bugs as in ios. Both browsers uses Webkit.

在 linux 上,您可以检查 Epiphany-browser,调整窗口大小,您将遇到与 ios 中相同的错误。两种浏览器都使用Webkit

Ubuntu/Mint:

Ubuntu/薄荷:

sudo apt install epiphany-browser

sudo apt install epiphany-browser

回答by Neel

  1. Run Ripple emulator(retired as of 2015-12-06) on Chrome
  2. Run iPadianon WineHQ
  3. Run QMoleon Linux or Android
  4. Run XCode on PureDarwin
  1. 在 Chrome 上运行Ripple 模拟器(自 2015 年 12 月 6 日起停用)
  2. 在 WineHQ 上运行iPadian
  3. 在 Linux 或 Android 上运行QMole
  4. PureDarwin上运行 XCode

回答by Sjaure

You might want to try screenfly. It worked great for me.

您可能想尝试screenfly。它对我很有用。