From SailfishOS Documentation
Revision as of 08:05, 20 July 2016 by Chriadam (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)


Sailfish OS is a Linux mobile operating system built on Mer.

The Sailfish OS architecture is primarily made up of three areas — the base kernel layer, the middleware layer and the app/UI layer:

Hardware adaptation components

Android application compatibility
Qt application framework
Other middleware libraries and services

Lipstick Homescreen and UI management

Base layer

In the base layer, Sailfish OS uses a Linux kernel with hardware-specific additions. Hardware support is implemented by the Board Support Package (BSP) and Hardware Abstraction Layer (HAL) and is project-specific, and is typically kept private for commercial ports.

Middleware layer

In the middleware layer, Mer provides the core system components for building services above the hardware and kernel level. Android emulation is provided by libhybris, which bridges Linux libraries based on GNU C with those based on Bionic, such as Android.

The Qt C++ application development framework provides the primary development libraries. Aside from the main Qt modules, Sailfish OS uses add-on modules such as Qt Maps, Qt Sensors and Qt Contacts. Also, all Sailfish applications are written with QML, a Qt technology for easily building user interfaces into C++ applications.

Sailfish OS also includes a large range of middleware libraries and frameworks that service the application layer, many of which are hosted on the Mer GitLab server. They are written in C/C++, and libraries that are directly accessed by the UI layer include QML modules to allow them to be used by QML-based applications without additional QML/C++ bindings. Some of these build on well-known Linux open-source projects for middleware services; for example, there are adaptations of oFono, ConnMan and BlueZ.

For more information on the areas covered by middleware libraries and services, see Core Areas and APIs.

Application and UI layer

Sailfish OS applications are written in a combination of C++ and QML/Qt Quick. QML is a Qt technology primarily used to declaratively assemble application user interfaces and connect them to C++ backend code, and Qt Quick is a core part of the QML framework for UI creation. A Sailfish OS app typically defines the UI in QML, and if necessary, includes C++ utility code to execute further functionality that is otherwise unavailable from the QML layer.

Application launching and lifetime is controlled by Lipstick, which provides the essential user-session UI with an application launcher and other main screens, and also acts as the window manager.

Key Architectural Areas

An overview of some architectural areas and the APIs which expose the related functionality can be found in the page describing Core Areas and APIs . Some more in-depth documentation about key architectural areas follow:

  • Cellular Telephony Architecture talks in detail about the mobile phone functionality
  • Audio Architecture describes audio routing and sharing
  • Screen display and application compositing is described in the Graphical Architecture
  • Multimedia Architecture covers the camera and video subsystems
  • The Qt Framework explains which Qt components applications should use to access features
  • Android compatibility is enabled by the Android Emulation Framework