Version 13 (modified by 9 years ago) ( diff ) | ,
---|
With the introduction of OS X El Capitan and the System Integrity Protection security feature, WebKit nightlies no longer work. They still launch, but the latest WebKit frameworks included inside are ignored and the system version of WebKit is used. This is because our use of DYLD_FRAMEWORK_PATH
is ignored when launching the system Safari (specifically the SafariForWebKitDevelopment
binary in the Safari app bundle). We are preparing a fix for this in a Safari update, but until then you can apply the following workaround.
Note: This workaround is not for the faint of heart, and requires you to run commands while booted into the system recovery partition. Proceed with caution.
Steps
- Print out this page or load it up on a different device for reference.
- Reboot the machine you want to apply the workaround to with the Command and R keys held down. (See About OS X Recovery.)
- When the Mac OS X Utilities window appears, select the Utilities menu in the menubar and pick Terminal.
- Note: FileVault users will need to go to Disk Utility or use
diskutil
first to unlock their secure partitions.
- In the Terminal window, type:
cd /Volumes && ls -l
- Find the name of your main boot partition, it is usually something like Macintosh HD.
- Type:
cd "Macintosh HD"
(or whatever name your boot partition is called). - Type:
mkdir -p "Library/Application Support/Apple/Safari"
- Then type:
cp "Applications/Safari.app/Contents/MacOS/SafariForWebKitDevelopment" "Library/Application Support/Apple/Safari/SafariForWebKitDevelopment"
- Finally type:
ln -sf "/Library/Application Support/Apple/Safari/SafariForWebKitDevelopment" "Applications/Safari.app/Contents/MacOS/SafariForWebKitDevelopment"
- Note: The first path of the
ln
command has a slash in front of Library and the second path does not have a slash in front of Applications, that is correct. The symbolic links needs to point to the boot location, not the booted recovery partition location in /Volumes.
- Now you can select Restart from the menu.
A new issue was introduced with OS X El Capitan version 10.11.4. If you upgrade a Mac from a previous version of El Capitan to 10.11.4, the SafariForWebKitDevelopment binary gets flagged as "restricted", preventing the WebKit nightly from loading its bundled WebKit frameworks.
To resolve this:
Steps
- Repeat steps 1-6 above to get to the appropriate volume while booted into your system recovery partition.
- Type:
chflags norestricted Library/Application\ Support/Apple/Safari/SafariForWebKitDevelopment
- Now you can select Restart from the menu.
The WebKit nightlies should work as expected after you restart. This workaround will persist and not interfere with future software updates, so there is no need to revert it later. However, you will need to reapply this workaround after updating to 10.11.1.