Hackintosh – running Apple OS/X inside VirtualBox (on Ubuntu or Windows)

I’ve done a LOT of web and software development in my career, one of the biggest problems I’v e had is doing proper testing on various platforms. VirtualBox can be run on most platforms, and allows for you to virtualize various operating systems. Apple’s OS X can be problematic to install, here’s some functioning instructions and settings that I’ve successfully used for my virtual Hackintosh test environment.

WARNING: As this uses an image of the software, it is advisable to also have a valid licenced copy as to use this without a licence would be “stealing”.

NOTE: this is a version of Snow Leopard, unfortunately you will NOT be able to update or add “fixes” to this test copy as it will usually break. I recommend making a copy of the VM if you wish to try!

My VirtualBox settings:

Mac OS X
Mac OS X Snow Leopard (64-bit)
1 core
Disable EFI
6MB+ video


  1. English, continue
  2. Utilities… disk Utilities… Select drive, Erase, name, erase… close
  3. continue
  4. Select disk… continue
  5. Customize (see instructions for: updates, kernels & bootloaders)
  6. NOTE: i only did 10.6.1 (an earlier 10.6.2 failed)

  7. Install
  8. Resolution fix – (I could not save file, but here are the instructions…

    Finder > OSX Drive (On desktop) > Extras > com.apple.Boot.plist (open with TextEdit – use the field to find)

<key>Graphics Mode</key>


meta viewport minimal-ui… a good idea in it’s time, just not useable…

Apple added this capability for fullscreen browser applications in Safari for IOS 7.1, unfortunately, they removed it in IOS 8.0

<meta name="viewport" content="width=device-width, minimal-ui" />


Preventing IOS/Safari from formatting numbers

There are many cases where your application may display numbers that “resemble” phone numbers, but are not, unfortunately Safari’s default behavior is for it to be “helpful” and format them into clickable/callable links for the user of Apple IOS devices.

Adding the following META tag can prevent that default behavior:

<meta name="format-detection" content="telephone=no" />

NOTE: I’ve seen some mention of using this method for ‘address=no’ and ’email=no’, but have not looked into or verified those implementation yet!


Apple IOS 6 Smart App Banners

If you have made an investment in creating a device specific application in addition to a traditional web application, there is also a good chance that you want to drive your users (customers) to use the native application.

With the release of Apple IOS 6 in September 2012, this ability was made possible with the use of a simple HTML <meta> tag on your web page. You will need to replace the x’s with your app-id from the Apple Store.

<meta name="apple-itunes-app" content="app-id=xxxxxxxxxx" />


Install Docky on Ubuntu Linux

One of the most immediate differences that typical computers notice between an Apple and other operating systems is the Dock Bar. This is a possible addition to any operating system (such as Windows or Linux). On Ubuntu Linux you can easily install Docky in just a few minutes.

sudo add-apt-repository ppa:docky-core/ppa
sudo apt-get install docky


Covert Flash to HTML5

Now that HTML5 support has grown, and Apple continues to resist Flash on their IOS devices, it may be advantageous to make use of the newer markup standard in your web applications.

There are currently three separate methods to convert your Flash applications:

Enable Sharing of Printers via Apple AirPrint

This is relevant only after you have updated to Apple IOS 4.2.x on your iPhone, iPod Touch or iPad device. With this release, the ability to print has been added, but it takes a bit of configuration to setup the printer sharing itself as it relies on the Apple Bonjour service/protocol!

I assume that this is all trivial if you are using a networked printer, particularly if it’s wireless…. but if you have a printer that is shared by another computer on the network, you’ll have to do the following.

  1. Install iTunes 10.1 (or newer) on the PC
  2. Install IOS 4.2.1 (or newer) on the mobile device
  3. Download AirPrint.zip (airprint.exe, libairprint.dll, XpdfPrint.dll)
  4. Unzip it.
  5. Make a folder, “C:\Program Files (x86)\AirPrint\” (NOTE: without the x86 for 32bit)
  6. Copy the files to “C:\Program Files (x86)\AirPrint\” (NOTE: without the x86 for 32bit)
  7. Run “cmd.exe” as administrator
  8. Run the following commands (There should be a space between ‘=’ and ‘”‘)
    • Windows 64bits:
      sc.exe create AirPrint binPath= "C:\Program Files (x86)\AirPrint\airprint.exe -s" depend= "Bonjour Service" start= auto
      sc.exe start AirPrint
    • Windows 32bits:
      sc.exe create AirPrint binPath= "C:\Program Files\AirPrint\airprint.exe -s" depend= "Bonjour Service" start= auto
      sc.exe start AirPrint
  9. Let Windows Firewall allow AirPrint to communicate on the networks (Double click on the airprint.exe)
  10. Now, open Safari or any other printing application on your device and try to Print, the first time will have to select the printer, and you may need to give user credentials for the printer.



Viewing Hidden Files and Folders on Apple OS/X

Most operating systems make this rather trivial to expose, Apple seems to have made it just a tiny bit more difficult… as such, I provide the simple steps here for my own memory as well as your benefit.

Open Terminal…

  • Launch Terminal, located at /Applications/Utilities/.
  • Type or copy/paste the following commands. Press the return key after you enter each line.
    defaults write com.apple.finder AppleShowAllFiles TRUE
    killall Finder

WARNING: Be particularly careful about the files you modify or delete, you could impact your system in very critical ways… there is a reason they are ‘hidden’, most often it is to keep less-technical users from breaking things 🙂

Return hidden files to their usual state.

Open Terminal…

  • Launch Terminal, located at /Applications/Utilities/.
  • Type or copy/paste the following commands. Press the return key after you enter each line.
    defaults write com.apple.finder AppleShowAllFiles FALSE
    killall Finder


Custom Webclip Icon for iPhone and iPod

I found a few references to this lately and just had to look into it. This is similar to the FAVICON approach used in browsers, but supports a (60×60), officially a 57×57 pixel icon.

The code is simple:

<link rel="apple-touch-icon" type="image/jpeg" href="/example.jpg" />

Old Reference (no longer works):