Introduction
This document describes how to build e17 as an X11 window manager on MacOS-X 10.5.8 (Leopard) and 10.6.8 (Snow Leopard) without Fink or Macports installed.
If you are looking for instructions to install e17 with Fink or Macports, click here: http://trac.enlightenment.org/e/wiki/Installation_MacOSX
This document was last updated 5 December 2011.
Enlightenment 17 is in active development and ongoing code changes may affect MacOS users. Please notify me of any errors or problems. I try to keep this document current.
David Ray, apple ( at ) jonive ( dot ) com
Setting up an optimum development environment
If you have not already done so, you will first need to set up a few tools that are needed to build open-source software on MacOS.
First, install the latest Xcode package from Apple. This includes the latest Apple-compatible gcc-4.2. To download XCode you will need to register with Apple (for free) from this page: http://developer.apple.com/programs/register/
For Leopard 10.5, use XCode 3.1.4. For Snow Leopard 10.6, use XCode 3.2.5 or later. Apple no longer has links to these versions from its main pages, but you can access links to older versions of XCode after logging in to Apple Developer Connection. XCode 4 has not been tested for this installation.
Set up your environment variables by editing /etc/bashrc, or equivalent where you define your environment. The following examples are from my system. You may need to adjust the directory paths for your system so they all point to valid directories.
For Leopard 10.5:
export CFLAGS="-Wall -O2 -I/usr/local/include -I/usr/include -I/usr/X11/include" export CPPFLAGS="-Wall -O2 -I/usr/local/include -I/usr/include -I/usr/X11/include" export LDFLAGS="-L/usr/lib -L/usr/X11/lib -L/usr/local/lib" export LD_LIBRARY_PATH="/lib:/usr/lib:/usr/X11/lib:/usr/local/lib" export PKG_CONFIG_PATH="/usr/X11/lib/pkgconfig:/usr/local/lib/pkgconfig" export ACLOCAL_FLAGS="-I /usr/X11/share/aclocal -I /usr/local/share/aclocal -I /usr/share/aclocal" export PATH="/usr/local/bin:/sbin:/bin:/usr/bin:/usr/sbin:/usr/X11/bin:/usr/X11/libexec" export MANPATH="/usr/share/man:/usr/local/share/man:/usr/X11/share/man" export MACOSX_DEPLOYMENT_TARGET="10.5"
For Snow Leopard 10.6:
export CFLAGS="-Wall -O2 -arch x86_64 -pipe -I/opt -I/usr/local/include -I/opt/X11/include -I/usr/include" export CPPFLAGS="-Wall -O2 -arch x86_64 -pipe -I/opt -I/usr/local/include -I/opt/X11/include -I/usr/include" export LDFLAGS="-arch x86_64 -L/usr/local/lib -L/usr/lib -L/opt -L/opt/X11/lib" export LD_LIBRARY_PATH="/usr/local/lib:/lib:/usr/lib:/opt:/opt/X11/lib" export PKG_CONFIG_PATH="/usr/local/lib/pkgconfig:/usr/lib/pkgconfig:/opt/X11/lib/pkgconfig:/opt/X11/share/pkgconfig" export ACLOCAL_FLAGS="-I /usr/local/share/aclocal-1.11 -I /usr/local/share/aclocal -I /opt/X11/share/aclocal -I /usr/share/aclocal" export PATH="/usr/local/bin:/sbin:/bin:/usr/bin:/usr/sbin:/opt/X11/bin:/usr/libexec:." export MANPATH="/usr/local/share/man:/usr/share/man:/opt/X11/share/man" export MACOSX_DEPLOYMENT_TARGET="10.6"
if DYLD_LIBRARY_PATH is set, unset it!
For Leopard 10.5, gcc and cc might be linked to gcc-4.0. You can check this with the command
cd /usr/bin ls -al cc gcc
If those are linked to gcc-4.0, delete those links and create new ones that link to gcc-4.2:
cd /usr/bin sudo rm cc gcc sudo ln -s gcc-4.2 gcc sudo ln -s gcc-4.2 cc
Download the latest stable development XQuartz X11 package from: http://xquartz.macosforge.org/trac/wiki There are separate downloads for Leopard and Snow Leopard.
For Snow Leopard 10.6, I use XQuartz 2.7.0 released 2011.11.04. Leopard support was dropped in XQuartz 2.7, Leopard 10.5 users can download XQuartz 2.6.1 released 2011.03.18.
On Leopard 10.5, XQuartz must be re-installed after any OS update, security update, or XCode update, since those clobber some of its libraries.
On Snow Leopard 10.6, remove /usr/X11 from all environment variables, it can cause conflicts with X libraries. Also, run the following commands after XQuartz installation to prevent /usr/X11 from being found when building programs:
sudo mkdir /etc/paths.d-disabled sudo mv /etc/paths.d/X11 /etc/paths.d-disabled/ sudo mv /usr/X11 /usr/X11-orig sudo ln -s /opt/X11 /usr/X11
If you have a multi-core processor, you can speed up the build process by specifying an argument to the 'make' command. For example, if you have an Intel Core 2 Duo processor you can use "make -j 2" which almost doubles the speed compared to "make". For a quad core processor use "make -j 4", etc.
Install pkg-config 0.25 or later
http://pkg-config.freedesktop.org/releases/
./configure, make, sudo make install
Note: do not install versions more recent than pkg-config 0.25. Starting at 0.26, Glib must first be installed.
Install autoconf 2.68 or later
http://ftp.gnu.org/gnu/autoconf/
./configure, make, sudo make install
Install automake 1.11 or later
http://ftp.gnu.org/gnu/automake/
./configure, make, sudo make install
Install e17 prerequisite libraries
Note: libpng and fontconfig do not need to be installed as these are included with XQuartz.
libjpeg 8b [not version 7]
http://www.ijg.org/
./configure, make, sudo make install
libtiff 3.9.4
http://www.remotesensing.org/libtiff/
./configure, make, sudo make install
giflib 4.1.6
http://sourceforge.net/projects/giflib/files/
./configure, make, sudo make install
lua 5.1.4:
http://www.lua.org/download.html
make macosx, sudo make install, sudo ranlib -a /usr/local/lib/liblua.a
dbus:
http://dbus.freedesktop.org/releases/dbus/
./configure --disable-static --with-dbus-user=root --enable-console-owner-file --disable-asserts --disable-tests --enable-checks --enable-kqueue --enable-launchd --disable-userdb-cache --disable-ansi --with-xml=expat --disable-xml-docs --disable-doxygen-docs --disable-dependency-tracking --without-x ac_cv_func_poll=no --with-system-pid-file=/var/run/dbus_pid --with-system-socket=/var/run/dbus_system_bus_socket --with-session-socket-dir=/tmp --enable-verbose-mode --localstatedir=/var make, sudo make install sudo mv /usr/local/lib/dbus-1.0/include/dbus/dbus-arch-deps.h /usr/local/include/dbus-1.0/dbus/ sudo /usr/local/bin/dbus-uuidgen --ensure
Technical notes about dbus:
On Linux and other Unix variants, dbus is one of many shared resources that runs under its own UID and GID like many other daemons. MacOSX however provides its own equivalents, and the dbus component that runs along side e17 does so under the user's UID. As a result it is not necessary to create a special UID and GID.
E17 requires a component of dbus, dbus-session, for IPC. The dbus installation described here satisfies this. Although it is possible to set up working daemons for dbus-system and HAL, these provide no benefit to e17 on MacOS other than eliminating e_dbus console warnings. On Intel-based MacOS systems, hardware modules are not supported through HAL.
E17 developers are actively working on hardware support for MacOS, through eeze, an alternative to dbus.
Compiling EFL Libs and e17
In the terminal, change directories to the location that you want the e17 SVN repository to be stored. Download the latest source code for E17 with the following command:
svn co http://svn.enlightenment.org/svn/e
Compile in this order with the following flags:
eina
./autogen.sh, make, sudo make install
eet
./autogen.sh, make, sudo make install
evas
./autogen.sh --disable-cpu-sse3
make, sudo make install
ecore:
./autogen.sh --enable-ecore_x --enable-ecore-evas-software-x11 --enable-simple-x11 --disable-nls --disable-ecore-cocoa --disable-glib
make, sudo make install
embryo
./autogen.sh, make, sudo make install
edje
./autogen.sh, make, sudo make install
efreet
./autogen.sh, make, sudo make install
e_dbus
./autogen.sh --disable-ebluez --disable-econnman --disable-eofono --disable-edbus-bluez-test --disable-edbus-connman-test --disable-edbus-ofono-test
make, sudo make install
e:
./autogen.sh --disable-nls --disable-battery --disable-temperature --disable-cpufreq --disable-mixer --disable-connman --disable-bluez --disable-ofono --disable-device-hal --disable-mount-hal --enable-simple-x11
make, sudo make install
Starting up e17
If everything compiles and installs then you are ready to test.
XQuartz will by default launch quartz-wm, Apple's default window manager. The easiest way to change the X11 window manager to e17 is to create an X11 startup script in your home directory. The simplest way to do this is to create a file named .xinitrc in your home folder. (Note: if you already have a directory of X11 startup scripts in ~/.xinit.d/, you should instead edit the startup script within that folder that sets the window manager.) Edit this file so that it contains the following:
. /etc/profile cd /Users/YOUR-HOME-DIR-NAME exec /usr/local/bin/enlightenment_start
Apple X11 can be started several ways: (1) running 'startx' at the command-line, (2) clicking the XQuartz icon in the Finder, (3) clicking the XQuartz icon in the dock, or (4) launching another app that requires X11, causing X11 to start up automatically when needed through launchd. If you run into any problems starting e17, you can launch X11 from 'startx' at a terminal. This makes it easy to view error messages and it prevents a possible runaway condition if there are any problems with startup scripts. After e17 launches correctly, it is best to invoke X11 by just launching the X11-based app you want to use.
On the very first run, e17 presents some initial setup screens including language selection, theme selection, etc. Continue through the setup screens until you have the e17 desktop. On the first run click "Disable" on dialogs that warn about unsupported modules.
Some modules will not work on MacOS, although they cause no harm being loaded. If you want, you can disable these modules:
Main -> Settings -> Modules -> Settings: Input Control Settings, Screen
If you want to reset your e17 environment and start over, you can just run "rm -r ~/.e/".
The console error for e_dbus comes from the module 'Files: EFM Starter'. That module does work despite the console message and the error message is harmless. If you want to eliminate the error you can disable that module.
Building EFL apps
Most EFL libraries and apps can be built and installed after e17 is installed and working. Some of these require additional open-source libraries.
As of this writing, the following EFL libs and apps are working on MacOSX Snow Leopard 10.6.8. A future version of this wiki will provide more details.
Libs: eina, eet, evas, ecore, embryo, edje, efreet, e_dbus, elementary, ethumb, epdf, eio, enlil, libeweather, emotion
Apps: e17, ephoto, enki, enjoy, envision, eyelight, e_phys_demo, econcentration
The attached screen capture shows these in action.
Suggested build order:
eio
epdf
libeweather
ethumb - use ./autogen.sh --disable-libexif
elementary - use: ./autogen.sh --disable-nls --disable-emotion
ephoto - use: ./autogen.sh --disable-nls
envision
e17 extra modules: alarm, flame, eweather, forecasts
libiconv
gstreamer + plugins: base, good,ffmpeg (bad, ugly not needed)
emotion
eyelight
eyelight-edit
Background and long description
This document describes how to run Enlightenment 17 as the window manager for Apple's X11.app, replacing Apple's default window manager, quartz-wm. Apple's default window manager is sufficient for many users and integrates well with Apple's version of the multiple desktop selector, "Spaces". However the GUI in quartz-wm lacks many features found in X11 window managers popular on Linux and other *nix platforms, such as working pagers. MacOS users who are experienced on other platforms may want an X11 window manager with more familiar features. E17 is a good alternative because it has a robust set of features and runs on a single process.
Apple's X11 implementation, XQuartz, provides a wrapper for X11 programs to be displayed on Apple's native GUI, the Quartz engine. This is the most common way to use X11 on a Mac because it allows you to have native MacOS apps and X11 apps in windows side-by-side, easily switching between them and sharing the copy/paste buffer. The world of X11 apps becomes an enhancement to the MacOS environment, which is the primary GUI. This is the X11 configuration that this document describes.
A second way to run Enlightenment window manager on MacOS is with a true Xorg X11 server. A Mac can be set up to boot into command-line mode, such as with Apple servers, "Safe Boot", or "run level 3". A true xorg X11 can then be set up to run under a standard MacOS, which for the most part is open-source Darwin. The down-side of doing this is that one loses the ability to run MacOS apps that expect Quartz, which means almost all of them. This is a more interesting option for Enlightenment code developers because more features of e17 can be used, but less useful for most Mac users because ordinary MacOS apps won't run. Perhaps one could set up a wrapper to allow quartz-based MacOS apps to display on a true Xorg X11 server. I don't know if this has been done, I'm guessing this would violate Apple's licensing.
A third way to run Enlightenment on a Mac is to boot natively into another OS on the Mac hardware, by setting up different hard drive partitions with OS'es pre-installed. Instructions to install Enlightenment window manager would be for whatever OS being used. It is not difficult, for example, to set up an Apple Macbook Pro to triple-boot to Windows, Ubuntu Linux and MacOS.
A fourth way to use Enlightenment Foundation Libraries on a Mac is to build Cocoa apps that don't use X11 or e17 window manager. Many of the EFL's are Cocoa and Quartz compatible. I don't know if this has been done, but is possible in principle.
There are two main ways to install Enlightenment 17 under XQuartz, each with some advantages and disadvantages. The first is the "Fink-Macports" way, and the second is the "usr/local" way which this document describes.
Macports ( http://www.Macports.org/) and Fink ( http://www.finkproject.org/) provide the fastest, most bug-free way to install Enlightenment 17. However these require a large pre-installation with a full X11-like environment and many background daemons that are typical of a different OS, and an older, pre-packaged version of e17 compatible with their distribution. Fink and Macports are well-managed distributions that were developed several years ago when Apple's X11 implementation had problematic compatibility issues. At the time, they were the only way to get e17 and many open-source apps running.
In the last 3 years, Apple's X11 development releases (XQuartz) and underlying Darwin and compiler environment have made a remarkable shift to being highly compatible with latest open source apps. Macports and Fink still provide an great service of pre-packaged binaries, but are not appropriate for developers who want to use the latest source and POSIX-compliant installations (/usr/local). Fink and Macports provide a large list of available X11 packages and have many merits. Which E17 installation method is better for a given person (Fink versus this page) will vary depending on their experience and needs.
I prefer to dual-boot into Ubuntu natively if I need a full X11 environment, and to use Apple's X11 when running a quick task in a MacOS work environment. From this perspective a full X11-like environment running along side MacOS is not needed or desirable. This page provides an alternative method for installing open-source X11 apps which involves a simpler installation, more up-to-date software, fewer OS-specific patches, more POSIX compliance and fewer unnecessary processes.
So in summary, I would recommend the following:
Install and use the pre-packaged e17 with Fink or Macports if:
- You already have installed, or really want to use Fink or Macports, for whatever reason
- You aren't comfortable building apps at the command line
- You want to check out a bunch of different X11 window managers and software to see what they are like
Install e17 using the /usr/local method (this page) if:
- You already have other programs and libs installed in /usr/local without the use of Fink or Macports
- You haven't invested in either approach, and are comfortable building apps yourself, and want to use the latest software
Binary Installers
In preparation for a binary e17 installer, I have made a DMG installer for Snow Leopard 10.6 with e16, Eterm and esound. These are older, retired EFL applications that were predecessors to e17. The purpose of this installer is to use older, stable software so that I can check compatability on the installer and file structure, without having to worry about stability issues. Please test and report any issues.
Download: http://trac.enlightenment.org/e/raw-attachment/wiki/MACOSX/e16%20Installer.dmg
Attachments
-
e.jpeg
(348.4 KB) -
added by daveray 10 months ago.
e17 on Snow Leopard
-
e17_apr2011.m4v
(63.0 MB) -
added by daveray 10 months ago.
-
e16 Installer.dmg
(11.9 MB) -
added by daveray 7 months ago.
e16 binary installer for MacOS 10.6
