Setup Zephyr Development Env on Manjaro Linux and Building Sample Application for X86 Qemu

Install the dependuncies using yaourt:

$ yaourt -S ninja ccache cmake gperf doxygen dfu-util dtc autoconf automake libtool

Clone the zephyr repo and install requirements.

$ cd ~
$ git clone
$ cd zephyr/
$ pip3 install --user -r scripts/requirements.txt
$ cd ..

download the zephyr sdk.

$ wget

After downloading the zephyr sdk installer, run the setup and install the sdk in ~/.zephyr

$ sudo

This will ask for the path of directory to install zephyr sdk.

Create ~/.zephyrrc and put following data into it.

export ZEPHYR_SDK_INSTALL_DIR=~/.zephyr/

to use these environment variables,

$ source .zephyrrc

To start zephyr development, go to the zephyr repo that you have just cloned and run

$ cd ~/zephyr
$ source

Once this is done, you can now start building zephyr projects. To build the hello_world for x86_qemu.

$ cd samples/hello_world
$ mkdir build && cd build
$ cmake -GNinja -DBOARD=qemu_x86 ..
$ ninja

Now run this using,

$ ninja run
[0/1] To exit from QEMU enter: 'CTRL+a, x'[QEMU] CPU: qemu32,+nx,+pae
qemu-system-i386: warning: Unknown firmware file in legacy mode: genroms/multiboot.bin

***** Booting Zephyr OS zephyr-v1.13.0-954-gd696a56cf *****
Hello World! qemu_x86

To exit from qemu hit ctrl+a and then x.