RSS Feed

Running EFL Apps on Tizen

Posted on

Hello everyone,

I’m excited to report that I’ve got a demo of a native App running on Tizen! And what I mean by native is, compiled C programs and not HTML5 + Javascript Apps. The App is  EFL (Enlightenment Foundation Libraries) based, alsoa good point to notice here is that all the Apps that come with your phone ( Calendar, Dialer, Contacts, etc.) are EFL based as well. And the best part of it is that the company that I work at (ProFUSION) is a big EFL project contributor, so we have plenty of in-house experience with it.

The App is  called Econcentration and it is a memory game. Although the App is already coded and working, I had to make some modifications to make it look better in the small device’s screen, like changing the images and the layout of the game. I will not explain the code in this post because I’m explaining how to run the game in the phone and not how to write EFL based programs. But you can take a look at the source code.

Before we start, make sure you have alien installed. It will be used to generate the deb packages. If you are using Ubuntu or a Debian distro you should install using this command:

sudo apt-get install alien

Also we must compile our game using a tool called SBS. But don’t panic, you can check the installation instruction and exactly what SBS is here:

  • Emulator

First we need to install the elementary dev package:

sbs -A i386 -et apt-get install libelm-dev

Then we go to the game’s source folder and execute the following commands:

sbs -A i386 -e ./ --prefix=/usr
sbs -A i386 -e make
sbs -A i386 -e make install DESTDIR=$(pwd)/tmp

Now that we have the game compiled we must generate the debian package:

cd tmp
tar -czf econcentration.tar.gz .
cd ..
fakeroot alien econcentration.tar.gz

Then, we send the .deb package to the emulator, install it and we’re ready:

sdb push econcentration_1-2_all.deb /tmp
sdb dpkg -i /tmp/econcentration_1-2_all.deb
sdb shell econcentration --mobile
  • Dev Phone

To generate the deb package to the device we will have to modify our sbs commands, because the phone is ARM based and not x86. But it’s basically the same thing.

Install the elementary library for the ARM environment

sbs -et apt-get install libelm-dev

Game’s source folder:

sbs -e ./ --prefix=/usr
sbs -e make
sbs -e make install DESTDIR=$(pwd)/tmp

Creating the deb package

cd tmp
tar -czf econcentration-arm.tar.gz .
cd ..
fakeroot alien econcentration-arm.tar.gz

Pushing, installing and execute it:

sdb push econcentration-arm_1-2_all.deb /tmp
sdb dpkg -i /tmp/econcentration-arm_1-2_all.deb
sdb shell econcentration --mobile

And these are the picture of the game running in the emulator and in the phone:

That’s it, now that we are able to run native Apps things might be more interesting. 🙂

The Debian package for ARM device and the images:

The source code: – To see in the browser

svn clone: svn co

git-svn clone: git svn clone


9 responses »

  1. Great 🙂 Here is the Korean translation. Thanks!

  2. I am not able to install the required packages:

    sbs -A i386 -et apt-get install libelm-dev

    Err slp2-target/main libelm-dev 1.0.0+svn.67547slp2+build01.d20120227191
    Undetermined Error

    Is there any workaround to bypass the package installation?

  3. After the debian package generation using the alien, I received the following errors when trying to install it:

    desktop:~/devel/econcentration$ sdb shell dpkg -i /tmp/econcentration_1-2_all.deb
    (Reading database … 18978 files and directories currently installed.)
    Preparing to replace econcentration 1-2 (using …/tmp/econcentration_1-2_all.deb) …
    Unpacking replacement econcentration …
    dpkg: dependency problems prevent configuration of econcentration:
    econcentration depends on libecore1 (>= 201207301603); however:
    Package libecore1 is not installed.
    econcentration depends on libelementary; however:
    Package libelementary is not installed.
    econcentration depends on libevas1; however:
    Package libevas1 is not installed.
    dpkg: error processing econcentration (–install):
    dependency problems – leaving unconfigured
    Errors were encountered while processing:

    Installing with the option to ignore the dependencies worked, by I think that this is not the right way:

    desktop:~/devel/econcentration$ sdb shell dpkg –ignore-depends=libecore1,libelementary,libevas1 -i /tmp/econcentration_1-2_all.deb
    (Reading database … 18978 files and directories currently installed.)
    Preparing to replace econcentration 1-2 (using …/tmp/econcentration_1-2_all.deb) …
    Unpacking replacement econcentration …
    Setting up econcentration (1-2) …

  4. Is it possible to write native apps in other languages, than C like, Go or C++?

    • If you install everything you need, yes. Let’s say that you want to write programs in Python. You must install everything manually, maybe you will need to do some hacks to be able to do this.

  5. Hi Íscaro –

    This document is out of date because Tizen no longer supports SBS :
    “No Tizen is moving from deb to rpm and SBS to OBS.
    Tizen 1.0 : deb + SBS
    Tizen 2.0 : rpm + OBS

    They now use OBS.


    • Hello Carlos,

      Yeah, I’m aware of that. However currently I’m out of time to create a new tutorial.
      I hope that I will make a new one this mounth or by the next.

      thanks for reading and for your commnent!

  6. Pingback: Native Cross-Platform Development Demystified, Tweak how to | Pointers of View

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: