Ruffle — Flash Player Emulator built in Rust

With Adobe Flash now gone, there’s no way to play SWF files. For sites like The Web Archive this can be troublesome as many of the old Flash-built websites will no longer be viewable. Ruffle will help them out:

Ruffle is a Flash Player emulator written in Rust. Ruffle runs natively on all modern operating systems as a standalone application, and on all modern browsers through the use of WebAssembly. Leveraging the safety of the modern browser sandbox and the memory safety guarantees of Rust, we can confidently avoid all the security pitfalls that Flash had a reputation for. Ruffle puts Flash back on the web, where it belongs – including iOS and Android!

Note that this is still a Work in Progress. Actionscript 1 & 2 Support is just over halfway, but support for AS3 is still only at 5%.

Ruffle →

Fix for the Android Emulator (Android Simulator) crashing during launch

UPDATE 2017.08.03: This should be fixed with the release of HAXM 6.1.1. Make sure you’re running the latest version of Android Studio

On a recent project I was working on, I wasn’t able to start the Android Emulator/Simulator anymore from within Android Studio. Every time I launched it from Android Studio it would start, but then – without any errors or warnings – close all by itself.

When I switched to launching the Android Emulator from the Command Line instead, I finally got to see an error message:

$ cd $(dirname $(which emulator)) && ./emulator -avd Nexus_5X_API_25
emulator: WARNING: encryption is off
Hax is enabled
Hax ram_size 0x60000000
HAX is working and emulator runs in fast virt mode.
Failed to sync vcpu reg
Failed to sync vcpu reg
Failed to sync vcpu reg
Failed to sync vcpu reg
Failed to sync vcpu reg
Failed to sync HAX vcpu contextInternal error: Initial hax sync failed

Aha, a clue! One Google Search Coupon later it turns out the thing preventing the emulator from running was that other thing using vcpu’s, namely docker.

👉 Killing docker will let you run the Android Emulator without any problems.

I haven’t tested other suggested solutions (such as tweaking the settings of the virtual device), but at least this one did it for me.

Did this help you out? Like what you see?
Consider donating.

I don’t run ads on my blog nor do I do this for profit. A donation however would always put a smile on my face though. Thanks!

☕️ Buy me a Coffee ($3)

Launching the Android Emulator from the Command Line

I’m not sure which update exactly broke it, but recently I got this when trying to launch the Android Emulator from the CLI:

$ emulator -list-avds
Nexus_5X_API_25

$ emulator -avd Nexus_5X_API_25
[140735953220544]:ERROR:./android/qt/qt_setup.cpp:28:Qt library not found at ../emulator/lib64/qt/lib
Could not launch '../emulator/qemu/darwin-x86_64/qemu-system-i386': No such file or directory

Apparently there’s some relative path linking happening, which of course fails when running the emulator command from a project directory.

The fix is to run the emulator command from the directory in which it resides. Some command combinations later, this is the result (with Nexus_5X_API_25 being the name of the created virtual device):

cd $(dirname $(which emulator)) && ./emulator -avd Nexus_5X_API_25

UPDATE 2017-11-28: As mentioned by Piotr in the comments below, another way to fix it, is to include the path of the emulator binary in your $PATH environment variable.

If installed correctly, you will most likely find some references to $ANDROID_HOME in your .bash_profile. Below that block, add this line to it:

export PATH="$ANDROID_HOME/emulator:$PATH"
Did this help you out? Like what you see?
Consider donating.

I don’t run ads on my blog nor do I do this for profit. A donation however would always put a smile on my face though. Thanks!

☕️ Buy me a Coffee ($3)