Css For Firefox Mac Os

Posted onby

This document will help you get set up to build Firefox on your owncomputer. Getting set up won’t be difficult, but it can take a while -we need to download a lot of bytes! Even on a fast connection, this cantake ten to fifteen minutes of work, spread out over an hour or two.

  1. Firefox For Mac Os
  2. Firefox For Mac Os 10.5
  3. Firefox Os X

The details are further down this page, but this quick-start guideshould get you up and running:

Quick start (Try this first!)

Firefox Mac OS X 10.9, 10.10 and 10.11 users move to Extended Support Release; Installing Firefox on Mac. Visit the Firefox download page in any browser (for example, Safari). It will automatically detect the platform and language on your computer and recommend the best version of Firefox for you. Firefox version 78 is the last supported Firefox version for Mac users of OS X 10.9 Mavericks, OS X 10.10 Yosemite and OS X 10.11 El Capitan. These users will be moved to the Firefox Extended Support Release (ESR) channel by an application update. This will provide security updates until the next ESR update in July 2021, after which the affected users will no longer receive security updates.


You will need:

  • an Apple ID to download and install Apple-distributed developer toolsmentioned below

  • from 5 minutes to 1 hour to download and install Xcode, which islarge

  • download and install a local copy of specific macOS SDK version

FWIW, viewing the contatta.com site in Opera (v12.14) on OS X shows rendering that looks very much like Firefox's. With Opera switching from Presto to Webkit, I suppose that's likely to change, but it serves to demonstrate that this isn't really a Firefox issue, it's an OS X font-rasterizer issue. Discover how to build your website by learning HTML and CSS on your Mac. It's pretty easy to get started with web coding in OS X, and there are plenty of great courses to help you learn HTML and CSS. Download Mozilla Firefox, a free Web browser. Firefox is created by a global non-profit dedicated to putting individuals in control online. Get Firefox for Windows, macOS, Linux, Android and iOS today!

You will need administrator permissions on your machine to install theseprerequisites. (You can verify that you have these permissions in SystemPreferences -> Users & Groups.)

See 1.1 Install Xcode and Xcode command line tools and 1.2Get the local macOS SDK for more information on how toinstall these prerequisites.

Getting the source

Firstly you need to prepare a directory and get the bootstrap scriptthat will do the rest:


If you don’t have Python 3.6 or later or Mercurial installed, see 2.1a Installdependencies via Homebrew for more information on howto do so. Then in your terminal from above start the bootstrapper like this:

… and follow the prompts. This will use mercurial to checkout thesource code. If you prefer to work with git, use this command instead:

If you don’t have Homebrew orPorts installed - software packagemanagers that will let us install some programs we’ll need - you’ll beasked to pick one. Either will work, but most Mozilla developers useHomebrew.

If you don’t let the bootstrap.py script clone the source for youmake sure you do it manually afterward before moving onto the next step.

Build Firefox!

Now we tie it all together.

In your terminal window, cd to your Mozilla source directory chosenbefore and type:

The ./machbootstrap step is a catch-all for any dependencies notcovered in this documentation. If you are working on Firefox frontendsor building Firefox without any changes, select Artifact Builds inthe first question in ./machbootstrap. Artifact builds willcomplete more quickly! Artifact builds are unsuitable for those workingon C++ code.

You’re on your way. Don’t be discouraged if this takes a while; it takessome time even on the fastest modern machines and as much as two hoursor more on older hardware. Firefox is pretty big, because the Web isbig.

Now the Fun Starts

You have the code, you’ve compiled Firefox. Fire it up with./machrun and you’re ready to start hacking.

Build steps (details)¶

Building on macOS is divided into the following steps:

  1. Install Apple-distributed developer tools - Xcode, Xcode cli toolsand macOS SDK locally

  2. Install supplementary build tools

  3. Obtain a copy of the Mozilla source code

  4. Configure the Mozilla source tree to suit your needs

  5. Build Firefox

1.1 Install Xcode and Xcode command line tools¶

You first need to install Xcode, for which you have two options but bothrequire you to sign in with an Apple ID:

  • From Apple Developer Download page - directlink. Install thelatest release (non-beta) version of Xcode, open Xcode.xip,and then beforerunning the extracted Xcode.app, move it fromthe download folder to /Applications. (Running it from anotherlocation may screw up various build paths, homebrew builds, etc. Fixby running sudoxcode-select-switch/Applications/Xcode.app )

  • From the Mac App Store - directlink.

Open /Applications/Xcode.app and let it do its initial first run andsetup stuff.

Install the Xcode command line tools byrunning xcode-select--install in your terminal.

1.2 Get the local macOS SDK¶

Firefox currently requires a local copy of macOS 10.11 SDK to build (allyour other apps will still use your more recent version of this SDK,most probably matching your macOS version).

There are various issues when building the Mozilla source code withother SDKs and that’s why we recommend this specific version.

To get the 10.11 SDK, first download Xcode 7.3.1 from the MoreDownloads for AppleDevelopers page. Oncedownloaded, mount the .dmg file. Then in the Terminal run the following:

2. Install supplementary build tools¶

Css for firefox mac os versions

Mozilla’s source tree requires a number of third-party tools andapplications to build it. You will need to install these before you canbuild anything.


You have the choice of how to install all these components. You can usea package manager like Homebrew or Ports. Or, you can obtain, compile,and install them individually. For simplicity and to save your time,using a package manager is recommended. The following sections describehow to install the packages using existing package managers. Choosewhatever package manager you prefer.

2.1a Install dependencies via Homebrew¶

Homebrew is “the missing package manager formacOS.” It provides a simple command-line interface to install packages,typically by compiling them from source.

The first step is to install Homebrew. See https://brew.sh/

Once you have Homebrew installed, you’ll need to run the following:

Python 2 is never necessary solely to build Firefox, but it is still requiredfor some development tasks (including testing and pushing to try). If yoursystem does not already have a Python 2 installed, you can use brew toinstall one:

2.1b Install Dependencies via MacPorts¶

MacPorts is a package manager for macOS. If you are running Homebrew,you can ignore this section.

To install MacPorts, go to their installpage, download the .dmg foryour platform, and install it. If you already have MacPorts installed,ensure it is up to date by running:

The first of these commands will ask for your root password.

Common errors include:

  • sudo doesn’t accept a blank password: create a password for youraccount in System Preferences.

  • port command not found: add it to your path (see thetroubleshooting section below).

Use MacPorts to install the packages needed for building Firefox:

You’ll then see lots of output as MacPorts builds and installs thesepackages and their dependencies – it takes a while, so go grab a cup ofcoffee.

Note: By default, this will install Python 2.7, which in turn willpull in all of the X11 libraries, which may take a while to build. Youdon’t need any of those to build Firefox; you may want to consideradding +no_tkinter to the install line to build a python withoutsupport for the X11 UI packages. This should result in a much fasterinstall.

Note: With older versions of Xcode (eg 6.4) you may need to useMacPorts to get the proper version of clang, such as clang-3.6 or later.See bugs in Core, Build Config referring to clang.

2.2 Install Mercurial¶

Mozilla’s source code is hosted in Mercurial repositories. You useMercurial to interact with these repositories. There are many ways toinstall Mercurial on macOS:

  1. Install official builds fromSelenic

  2. Install via Homebrew:

  1. Install via MacPorts:

  1. Install via Pip:

Once you have installed Mercurial, test it by running:

If this works, congratulations! You’ll want to configure your Mercurialsettings to match other developers. See Getting Mozilla Source CodeUsing Mercurial.

If this fails with the error “ValueError:unknownlocale:UTF-8”,then see theworkaroundson the Mercurial wiki’s Unix Install page.

When trying to clone a repository you may get an HTTP 500 error(internal server error). This seems to be due to something that MacMercurial sends to the server (it’s been observed both with MacPort andselenic.com Mercurial binaries). Try restarting your shell, yourcomputer, or reinstall Mercurial (in that order), then report back herewhat worked, please.

3. Obtain a copy of the Mozilla source code¶

You may want to read Getting Mozilla Source CodeUsing Mercurial for thecomplete instructions.

If you are interested in Firefox development only then run the followingcommand, which will create a new directory, mozilla-central, in thecurrent one with the contents of the remote repository.

Below command will take many minutes to run, as it will be copying acouple hundred megabytes of data over the internet.

(If you are building Firefox for Android, you should now return to theAndroid build instructions.)

4. Configure the build options¶

In your checked out source tree create a new file, mozconfig, whichwill contain your build options. For more on this file, see Configuring Build Options.

To get started quickly, create the file with the following contents:

Css For Firefox Mac Os

Firefox no longer builds with gcc 4.8 or earlier, but the build systemshould automatically select clang if it is available in the PATH. Ifthat is not the case, you need to set CC and CXX. For instance, if youinstalled Clang 9 via Homebrew, then you need to have this in yourmozconfig:

5. Build¶

Once you have your mozconfig file in place, you should be able tobuild!

If the build step works, you should be able to find the builtapplication inside obj-ff-dbg/dist/. If building the browser with--enable-debug, the name of the application is NightlyDebug.app.To launch the application, try running the following:

Note: The compiled application may also be named after the branchyou’re building; for example, if you changed these instructions to fetchthe mozilla-1.9.2 branch, the application will be namedNamoroka.app or NamorokaDebug.app.

Hardware requirements¶

There are no specific hardware requirements, provided that the hardwareaccommodates all of the software requiredto build Firefox. Firefox can take a long time to build, so more CPU,more RAM and lots of fast disk space are always recommended.

  • Processor: Intel CPUs are required. Building for PowerPC chips isnot supported.

  • Memory: 2GB RAM minimum, 8GB recommended.

  • Disk Space: At least 30GB of free disk space.

Software requirements¶

  • Operating System: macOS 10.11 or later. It is advisable toupgrade to the latest “point” release by running Software Update,found in the Apple menu. You will need administrative privileges toset up your development environment

  • Development Environment: Xcode. You can obtain this from the AppStore.

  • Package Management: Either Homebrew orMacPorts.

These options are specific to Mozilla builds for macOS. For a moregeneral overview of build options and the mozconfig file, seeConfiguring Build Options.

  • Compiler: Firefox releases are no longer built with gcc-4.8 orearlier. A recent copy of clang is needed.

    • There are some options on where to get clang:

      • Newer versions of Xcode.

      • Following the instructions in the clangwebsite forinformation on how to get it.

      • Using some of the package managers (see above).

    • Once clang is installed, make sure it is on the PATH and configureshould use it.

The following options, specified with ac_add_options, are lines thatare intended to be added to your mozconfig file.

  • macOS SDK: This selects the version of the system headers andlibraries to build against, ensuring that the product you build willbe able to run on older systems with less complete APIs available.Selecting an SDK with this option overrides the default headers andlibraries in /usr/include, /usr/lib, and /System/Library.

    Official trunk builds use MacOSX10.11.sdk. Checkbuild/macosx/universal/mozconfig.commonfor the SDK version used for official builds of any particular sourcerelease.

    Applications built against a particular SDK will usually run onearlier versions of macOS as long as they are careful not to usefeatures or frameworks only available on later versions. Note thatsome frameworks (notably AppKit) behave differently at runtimedepending on which SDK was used at build time. This may be the sourceof bugs that only appear on certain platforms or in certain builds.

For macOS builds, defines are set up as follows:

  • XP_MACOSX is defined

  • XP_UNIX is defined

  • XP_MAC is not defined. XP_MAC is obsolete and has beenremoved from the source tree (see {{ Bug(281889) }}). It was used forCFM (non-Mach-O) builds for the classic (pre-X) Mac OS.

Css for firefox mac os 10.10

This requires care when writing code for Unix platforms that excludeMac:


  • If configure (or generally building with clang) fails with``fatal error: ‘stdio.h’ file not found``: Make sure the Xcodecommand line tools are installed by running.xcode-select--install.

  • For inexplicable errors in the configure phase: Review allmodifications of your PATH in .bash_profile, .bash_rc or whateverconfiguration file you’re using for your chosen shell. Removing allmodifications and then re-adding them one-by-one can narrow downproblems.

Clever technique to help you on CSS hacks.

Last updated: November 02, 2010 (v0.4.0)

CSS Browser Selector is a very small javascript with just one line which empower CSS selectors. It gives you the ability to write specific CSS code for each operating system and each browser.


The JavaScript support is disabled on your browser. Please, enable JavaScript and refresh this page.

The color of this box will change on different os/browsers:

  • Internet Explorer - yellow
  • Internet Explorer 7 - orange
  • Gecko Engine on Windows (Firefox, Mozilla, Camino) - red
  • Gecko Engine on Linux (Firefox, Mozilla, Camino) - pink
  • Gecko Engine on Other OS (Firefox, Mozilla, Camino) - gray
  • Opera - green
  • Konqueror - blue
  • Safari - black
  • Chrome - cyan

If the box is white, and you are using one of browsers above, something is wrong :-/
Help us in this case!

Source of this example:

Screenshots on Browsercam

Chris Preece contributed with some images


I need to update this script every time a browser is released with new UserAgent string.

This is a little effort, but certainly with your donation I will do it happier :)


git clone git://github.com/rafaelp/css_browser_selector.git


1. Copy and paste the line below, inside <head> and </head> tag

<script src='css_browser_selector.js' type='text/javascript'></script>

2. Set CSS attributes with the code of each browser/os you want to hack


  • html.gecko div#header { margin: 1em; }
  • .opera #header { margin: 1.2em; }
  • .ie .mylink { font-weight: bold; }
  • .mac.ie .mylink { font-weight: bold; }
  • .[os].[browser] .mylink { font-weight: bold; } -> without space between .[os] and .[browser]

Available OS Codes [os]:

  • win - Microsoft Windows (all versions)
  • vista - Microsoft Windows Vista new
  • linux - Linux (x11 and linux)
  • mac - Mac OS
  • freebsd - FreeBSD
  • ipod - iPod Touch
  • iphone - iPhone
  • ipad - iPad new
  • webtv - WebTV
  • j2me - J2ME Devices (ex: Opera mini) changed from mobile to j2me
  • blackberry - BlackBerry new
  • android - Google Android new
  • mobile - All mobile devices new

Available Browser Codes [browser]:

  • ie - Internet Explorer (All versions)
  • ie8 - Internet Explorer 8.x
  • ie7 - Internet Explorer 7.x
  • ie6 - Internet Explorer 6.x
  • ie5 - Internet Explorer 5.x
  • gecko - Mozilla, Firefox (all versions), Camino
  • ff2 - Firefox 2
  • ff3 - Firefox 3
  • ff3_5 - Firefox 3.5
  • ff3_6 - Firefox 3.6 new
  • opera - Opera (All versions)
  • opera8 - Opera 8.x
  • opera9 - Opera 9.x
  • opera10 - Opera 10.x
  • konqueror - Konqueror
  • webkit or safari - Safari, NetNewsWire, OmniWeb, Shiira, Google Chrome
  • safari3 - Safari 3.x
  • chrome - Google Chrome
  • iron - SRWare Iron

Extra Codes:

  • js - Will be available when js is enable, so you can show/hide some stuffs


Original idea by 37signals.


Ruby on Rails Plugin by Reid MacDonald

PHP CSS Browser Selector by Bastian Allgeier

Wordpress Plugin by Adrian hanft



  • 0.4.0 - (November 02, 2010) Adding 'vista', 'j2me', 'ff3_6', 'ipad', 'blackberry' and 'android' codes See commit on Github
  • 0.3.5 - (February 05, 2010) Implementing paulirish suggestion os issue #1
  • 0.3.4 - (September 29, 2009) Fix support of Opera 10.10
  • 0.3.3 - (September 06, 2009) Adding 'iron' code for SRWare Iron browser and 'ff3_5' for Firefox 3.5 because it renders litle bit different from Firefox 3.0x
  • 0.3.2 - (April 22, 2009) Removing 'safari' code for Chrome browser
  • 0.3.1 - (January 04, 2009) 'mobile' selector for j2me devices
  • 0.3.0 - (January 04, 2009) Complete rewrite, now with tests and new OS selectors
  • 0.2.9 - (September 17, 2008) Changes whitespace to s on regexp to avoid problems on minifier process
  • 0.2.8 - (September 03, 2008) Added 'chrome' browser code for Google Chrome
  • 0.2.7 - (May 21, 2008) Added 'ff2' and 'ff3' browser codes
  • 0.2.6 - (April 11, 2008) Removed unecessary spaces
  • 0.2.5 - (October 5, 2006) Removed permanently ieMac code, bug on Opera 9 detection and now you must use '.[os].[browser]' instead of '.os .browser'
  • 0.2.4 - Added support for opera versions: 'opera8', 'opera9', etc
  • 0.2.3 - Added 'js' code to know when JS is disabled or not
  • 0.2.2 - Added OS codes to be used with browser codes - [email protected] McCray
  • 0.2.1 - Corrected small javascript bug in IE 5.01 - Daniel Westermann-Clark
  • 0.2.0 - Good refactoring, small and fast script! - Steve Clay
  • 0.1.8 - Added support for Internet Explorer on Mac OS (ieMac) - Jeff Bellsey
  • 0.1.7 - Added 'webkit' as alias of 'safari' and well written syntax with less bytes - Jean Pierre and Micah Snyder
  • 0.1.6 - Striped some spaces to make the file smaller and solved IE for Mac bug - Derek
  • 0.1.5 - Added support for ie6 and appends the class names to be non-destructive - Jesse Scott
  • 0.1.4 - Working on Safari, applewebkit was misspelled, without an p - Alex Wiltschko and Moises Kirsch
  • 0.1.3 - Changed the js a litle to get the html tag by TagName instead of having one id - Chris Warren and Tony Nelson
  • 0.1.2 - Changed from 'safari' to 'applewebkit/' and from 'firefox' to 'gecko/' - glasser
  • 0.1.1 - Initial release (2006-07-19)

Firefox For Mac Os



Rafael Lima



  • Niyaz (http://github.com/niyazpk)
  • Marcio Trindade (http://github.com/marciotrindade)
  • rbottarelli (http://github.com/rbottarelli)
  • Bryan Chow (http://github.com/bryanchow)
  • Derek Lio (http://github.com/dereklio)
  • Paul Irish (http://github.com/paulirish)
  • Preston Badeer
  • Upekshapriya
  • André Lopes
  • Tazio Mirandola - copiaincolla pubblicità
  • Reid MacDonald (http://geminstallthat.wordpress.com)
  • Vinicius Braga (http://viniciusbraga.com)
  • Chris Preece (http://www.mmtdigital.co.uk)
  • Dominykas
  • [email protected] McCray
  • Daniel Westermann-Clark
  • Steve Clay (http://mrclay.org/)
  • Jeff Bellsey
  • Jean Pierre
  • Micah Snyder
  • Derek (http://amphibian.info)
  • Jesse Scott
  • Moises Kirsch (http://www.moiblog.com/)
  • Alex Wiltschko
  • Chris Warren and Tony Nelson (http://www.imagetrend.com)
  • glasser

Firefox For Mac Os 10.5


Firefox Os X

css javascript script cascading style sheets cross browser cross-browser browsers bug ie internet explorer konqueror safari opera firefox chrome hack tip trick selector