Enlightenment on OpenBSD

Until recently it wasn't possible to run e17 (more specifically eet) due to deficiencies in libc on OpenBSD. Changes in eet have conveniently worked around the OpenBSD limitation, so it should now run without issues.

All development is now done directly in OpenBSD -current ports tree. Information on how to get the OpenBSD and it's port tree:

and

The CVS repository has a cvsWeb style interface available at  http://www.openbsd.org/cgi-bin/cvsweb/ports/x11/e17/.

OpenBSD Reported Issues

additional reports:

Realm

Unfortunately the existing EFL/E17  packages are/(could be) quite outdated and also could contain no features, attractive for ordinary users (like "fribidi" support in "evas" to ensure proper UTF-8 handling). And the one could decide to build from scratch. The text below could be helpful for maintainers/individuals, who wish to have a latest E-svn running on OpenBSD. Please examine all OpenBSD related "tickets" before report a new issue. All comments/patches/improvements are always welcome!

Beginning

Building the E-svn is quite easy for those, who follow the  OpenBSD-current (it'd be nice to "pkg_delete xmlto" before update of "xenocara" - just in case). The rest should first install some packages to satisfy build dependencies. Some of them are strict (like "gmake", "intltool", "automake"), others depend on your requirements (like "librsvg" to get "svg" support). The list also depends on the components you wish to build and install from E-svn tree.

  • Build dependencies (+/-):
    • metaauto - wrapper for gnu auto*
    • libtool - generic shared library support script
    • automake - GNU standards-compliant Makefile generator
    • autoconf - automatically configure source code on many Un*x platforms
    • intltool - internationalization tool
    • gcc
    • gmake
    • subversion
    • libiconv - character set conversion library
    • gettext >= 0.17 - GNU gettext
    • jpeg - IJG's JPEG compression utilities
    • libtasn1 - Abstract Syntax Notation One structure parser library (may be it's optional)
    • lua - (needed for "edje") powerful, light-weight programming language
    • X-server/(xenocara)
    • imlib2 - image manipulation library (though you can build it from E-svn too)
  • Optional dependencies
    • a lot of. Depends on your "build from E-svn list". Some even have a substitutions (gnuTLS/openSSL). Below is just a sample list, no restrictions:
      gnuTLS/openSSL, png, librsvg, bison, glib2, doxygen, SDL*, 
      pango, cairo, tiff, libungif, fribidi(UTF-8 support), 
      libnotify, dbus, mpd/libmpd, etc...
      

It could be a nice idea to install "bash" and build E with it, instead of the default "ksh". Please take a look at the "gcc". Note, that the "default" gcc in OpenBSD has options/version, which differ from the ones used for ports/packages. This could have an impact on a various build options, most notable is the support/linking of "pthreads". The default OpenBSD compiler has: "Thread model: single, gcc version 3.3.5 (propolice)". Packaged versions of "gcc4" have posix thread model and a way different configuration parameters. You can build E-svn with any modern compiler, including the one shipped by default in OpenBSD, but anyway, YOU HAVE BEEN WARNED! "--disable-pthread" is the most safe option and probably should be used if you're building for a various architectures or if you're cooking the updates for E/EFL ports.

Build routine

  • fetch E-svn
    svn co http://svn.enlightenment.org/svn/e/trunk/$PACKAGES_YOU_WISH_TO_BUILD
    svn checkout http://itask-module.googlecode.com/svn/trunk/ itask-module  # optional!
    

You can create a simple bash script or just fetch required components one by one.

  • build order (just an EXAMPLE!):
    eina eet edb imlib2 evas ecore embryo efreet edje e_dbus 
    epsilon esmart emotion engrave epeg etk exml enhance 
    imlib2_loaders imlib2_tools etk_extra exchange elementary 
    ethumb E17/[e] emphasis entrance estickies elicit expedite 
    emprint edje_editor edje_viewer extrackt rage  itask-module 
    E-MODULES-EXTRA
    
  • list of E-MODULES-EXTRA which you can build without special patches (please note, that not all of them will WORK as you expect, due to the flavors of OpenBSD):
    alarm bling calendar configmenu cpu deskshow diskio drawer 
    efm_nav efm_path efm_pathbar emu execwatch flame forecasts 
    iiirk mail  moon mpdule net news notification penguins rain 
    screenshot slideshow snow taskbar tclock tiling uptime 
    winselector wlan
    
  • core EFL (list is not strict, "elementary" with all dependencies is coming):
    eina eet evas ecore embryo efreet edje [e_dbus] E17/[e]
    
  • declare build variables (values depend on your local installed packages versions!):
    export AUTOMAKE_VERSION=1.9
    export AUTOCONF_VERSION=2.62
    export PKG_CONFIG_PATH="/usr/X11R6/lib/pkgconfig:/usr/lib/pkgconfig:/usr/local/lib/pkgconfig:/lib/pkgconfig"
    export CFLAGS="-I/usr/include -I/usr/local/include -I/usr/X11R6/include $CFLAGS"
    export LDFLAGS="-L/usr/local/lib -L/usr/X11R6/lib -L/usr/lib -lintl -liconv $LDFLAGS"
    
  • a regular build routine:
     cd PATH_TO_SOURCES/
     ./autogen.sh
     ./configure $OPTIONAL_ARGUMENTS # if you're not happy with the defaults! otherwise this step is NOT NECESSARY!
     gmake
     gmake DESTDIR=YOUR_LOCAL_$HOME_DIR_TO_HAVE_A_LIST_OF_INSTALLED_FILES! install  # this will install files into your local !!!EMPTY!!! dir where you can later create a PKGLIST, etc...
     sudo gmake install
     gmake clean # or you can use "gmake maintainer-clean" to return the "clean" E-svn state
    

Package details

eina

If your ARCH/PC allow the safe "pthreads" usage - don't pass "--disable-pthread" to it's "./confugure"

eet

You need to choose between "gnutls" and "openssl". Both work. "They say" opinion is to use "openssl", because gnutls... you know... If you're Ъ (TRUE) OpenBSD user, you'll add "-lssl" to the "LDFLAGS" and pass " --disable-gnutls --enable-openssl" to the "./configure" script.

evas

You can pass "--enable-gl-x11" to the "./configure" along with various other options. Type:

 ./configure --help | less

to look at the full list. Please note, that you'll lose the UTF-8 support if "--disable-fribidi" argument is passed (that's exactly what we have today in the ports tree).

ecore

This one is tricky. You should pass "--with-iconv-link=-liconv --with-libiconv-prefix=/usr/local --with-x" arguments to the "./configure". The rest depends on your preferences. If you dislike the feature to download themes/wallpapers from www via "Settings Panel" - pass "--disable-curl" argument. Add/check "-lssl" for LDFLAGS (if you're using "openSSL") and compare Your "./configure" results with the ones below:

ecore 0.9.9.062

Optional Modules:
          
 Core:    
          
  Ecore........................: always
    GLib support...............: yes
  Ecore_Job....................: yes
  Ecore_Txt....................: yes
  Ecore_Con....................: yes
    OpenSSL....................: no  (disabled)   # by default "gnutls" is used, despite that... you know...
    GnuTLS.....................: yes
    CURL.......................: yes
    Abstract Sockets...........: yes
  Ecore_Ipc....................: yes
    OpenSSL....................: no  (disabled)
    GnuTLS.....................: yes
  Ecore_File...................: yes
    Inotify....................: no
    Poll.......................: yes
    CURL.......................: yes
  Ecore_Config.................: yes
  Ecore_IMF....................: yes
  Ecore_IMF_Evas...............: yes
  Ecore_Input..................: yes
          
 Graphic systems:
          
  Ecore_X (Xlib backend).......: yes         # if you have "no" here - don't go further! 
    Xcursor....................: yes
    Xkb........................: yes
    Xprint.....................: yes
    Xinerama...................: yes
    Xrandr.....................: yes
    Xscreensaver...............: yes
    Xrender....................: yes
    Xcomposite.................: yes
    Xfixes.....................: yes
    Xdamage....................: yes
    Xdpms......................: yes
    Xtest......................: yes
  Ecore_Win32..................: no
  Ecore_Quartz.................: no
  Ecore_SDL....................: no
  Ecore_FB.....................: no
  Ecore_DirectFB...............: no
  Ecore_WinCE..................: no

 Ecore Evas:
          
  Ecore_Evas...................: yes
    Software Memory Buffer.....: yes
    Software X11...............: yes (Xlib)
    XRender X11................: yes
    OpenGL X11.................: yes
    XRender XCB................: no
    Software GDI...............: no
    Software DirectDraw........: no
    Direct3D...................: no
    OpenGL Glew................: no
    Quartz.....................: no
    Software SDL...............: no
    DirectFB...................: no
    Software Framebuffer.......: no
    Software 16bit X11.........: yes
    Software 16bit DirectDraw..: no
    Software 16bit WinCE.......: no
          
 Documentation.................: yes
          
 Compilation...................: make (gmake on some systems)
 Build of the documentation....: make doc

 Installation..................: make install
          
    prefix.....................: /usr/local 

If you're happy with Your results - type "gmake".

edje

Check that you have a "lua" package installed.

E17/e

Please look at the Ticket #447 (we did our best and mark it as closed/fixed, but anyway you may need to pass "-lexecinfo" to CFLAGS), Note that you should also check/adjust the "$PATH_TO_SOURCES/e/data/themes/default.edc" file. Read about "default.edj" build in a ticket comments. You can remove'em or use a strict C comment-style instead of C++ one. Useful arguments for "./configure" are below:

./configure  --disable-battery --disable-temperature --disable-cpufreq --disable-mixer

If you're following the defaults - all stuff will be in a "/usr/local/". After installation you'd ensure that "/etc/enlightenment/" is present (create a symlink to the $PREFIX/etc/enlightenment) and you should adjust the "/etc/enlightenment/sysactions.conf" file (see the example below):

action:   halt      /sbin/halt -p
action:   reboot    /sbin/reboot
action:   suspend   /usr/sbin/zzz -S
action:   hibernate /usr/sbin/zzz -z
###
# optional, please read the comments.
###
group:   users  allow: *

entrance

Here you must pass "--with-random=/dev/urandom" to the "./configure" and (as "root") adjust some parameters after the installation (look at the check of a current variables below):

bash-4.0# entrance_edit

Entrance Daemon Settings
  attempts = 5
  xserver = "/usr/X11R6/bin/X -quiet -nolisten tcp vt5 -dpi 96 dpms"
Entrance Client Settings
  xsession = "/etc/X11/xdm/Xsession"
  auth = 0
  engine = 0
  reboot = 1
  halt = 1
  theme = "default.edj"
  background = ""
  pointer = "/usr/local/share/entrance/images/pointer.png"
  greeting-before = "Welcome to"
  greeting-after = ""
  date-format = "%A %B %e, %Y"
  time-format = "%l:%M:%S %p"
  autologin-mode = 0
  autologin-user = ""
  presel-mode = 1
  presel-prevuser = ""
  user-remember = 1
  user-remember-count = 5
  user-count = 0
  session-count = 2
  default-session = "default"
  default-session-title = "Default"
  default-session-icon = "default.png"

The most important thing is to change the "auth" settings:

sudo entrance_edit -auth=0
sudo entrance_edit -xserver="/usr/X11R6/bin/X -quiet -nolisten tcp vt5 -dpi 96 dpms"

Another important thing is the keyboard-layouts support enabled for "Entrance". Below is the example of an "en-ru" UI:

cat /etc/rc.local

# we're setting here our "locale" to allow kbd layout switch in terminals (eterm, xterm, etc.)
export LC_COLLATE=C LC_CTYPE=ru_RU.KOI8-R LC_MONETARY=C LC_NUMERIC=C LC_TIME=C
# starting the ''entrance'' daemon
/usr/local/sbin/entranced

etk

It's a known issue, that "edje_cc" fails to compile some "*.edj" files under OpenBSD (due to lack of UTF-8 support and so on...). If your build fail on "default.edj" - adjust appropriate "$PATH_TO/Makefile.am" file and run "make clean && ./autogen.sh" again. Example:

MAINTAINERCLEANFILES = Makefile.in
EXTRA_DIST = default.edc
SUBDIRS = icons
EDJE_CC = edje_cc
EDJE_FLAGS = \
-v \
-id $(top_srcdir)/data/icons/default/icons

filesdir = $(pkgdatadir)/icons
#files_DATA = default.edj  # here we comment the build of a "default.edj"

#default.edj: Makefile default.edc  # also we comment the "build section" as well
#    $(EDJE_CC) $(EDJE_FLAGS) \
#    $(top_srcdir)/data/icons/default/default.edc \
#    $(top_builddir)/data/icons/default/default.edj

clean-local:
    rm -f *.edj

You can take a missing/broken "*.edj" files from other sources (like Linux box) and use in OpenBSD.

edje_editor

The same error with compilation of "*.edj" file could happen. Example of error message:

edje_cc -v -id ../data/images -fd ../data/fonts \
        ../data/edje_editor.edc \
        ../data/edje_editor.edj
<stdin>:319: macro "FRAME" requires 7 arguments, but only 5 given
edje_cc: Opening "../data/edje_editor.edc" for input
edje_cc: Parsing input file
gmake[3]: *** [edje_editor.edj] Segmentation fault (core dumped)

The cure is :

> vim edje_editor/data/Makefile.am

desktopdir   = $(datadir)/applications
desktop_DATA = edje_editor.desktop

icondir = $(datadir)/icons
icon_DATA = edje_editor.png


#edje_editor.edj: edje_editor.edc Makefile
#   $(EDJE_CC) $(EDJE_FLAGS) \
#   $(top_srcdir)/data/edje_editor.edc \
#   $(top_builddir)/data/edje_editor.edj

blank.edj: blank.edc Makefile
    $(EDJE_CC) $(EDJE_FLAGS) \
    $(top_srcdir)/data/blank.edc \
    $(top_builddir)/data/blank.edj

and run "./autogen.sh" again. After installation you shout put a valid "edje_editor.edj" file (borrowed from Linux-box probably, or you can fix "edje_editor.edc" and submit a patch to the community) to the installation dir: "$INSTALL_PREFIX/share/edje_editor/edje_editor.edj".

E16

./configure --disable-docs

if you don't want to look at the patches used for existing OpenBSD port and wish to build a good old rocking E16 from E-svn quickly.

Summary

Things are quite easy and straight-forward. You can follow the  latest snapshots or  current E-svn without too much efforts. Please, don't forget to install a copy into the local empty folder to have an exact list of affected files at least. Don't turn Your system into the scrapyard. Delete an old files/components before a fresh E-svn build.

List of confirmed successful builds

i386 - confirmed by sda00 (Dmitry Serpokryl) for OpenBSD-current/OBSD-4.6
amd64 - confirmed by Aaron Stellman

Attachments