summaryrefslogtreecommitdiffstats
path: root/imx/README
blob: a13915f077e9e0a14384f4f04b25c3f62f2fade7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
i.MX Linux Yocto Project BSP 4.9.88-2.0.0_ga Release
=====================================================

The following boards were tested in this release.

   * NXP i.MX 6QuadPlus SABRE Device (imx6qpsabresd)
   * NXP i.MX 6QuadPlus SABRE Auto (imx6qpsabreauto)
   * NXP i.MX 6UltraLite EVK (imx6ulevk)
   * NXP i.MX 6ULL EVK (imx6ull14x14evk)
   * NXP i.MX 7Dual SABRE Smart Device (imx7dsabresd)
   * NXP i.MX 6SoloX SABRE Smart Device (imx6sxsabresd)
   * NXP i.MX 6SoloX SABRE Auto (imx6sxsabreauto)
   * NXP i.MX 6Quad SABRE Smart Device (imx6qsabresd)
   * NXP i.MX 6Quad SABRE Auto (imx6qsabreauto)
   * NXP i.MX 6DualLite SABRE Smart Device (imx6dlsabresd)
   * NXP i.MX 6DualLite SABRE Auto (iEmx6dlsabreauto)
   * NXP i.MX 6SoloLite EVK (imx6slevk)
   * NXP i.MX 6SoloX SABRE Smart Device (imx6sxsabresd)
   * NXP i.MX 6SoloX SABRE Auto (imx6sxsabreauto)
   * NXP i.MX 6SOLO SABRE Smart Device (imx6solosabresd )
   * NXP i.MX 6SOLO SABRE Auto (imx6solosabreauto )
   * NXP i.MX 7ULP EVK (imx7ulpevk)
   * NXP i.MX 8MQuad EVK (imx8mqevk)

Note the following i.MX 8 boards are not supported in this release.
   * NXP i.MX 8QuadMax MEK (imx8qmmek)
   * NXP i.MX 8QuadXPllus (imx8qxpmek)

 * i.MX Device Tree configurations for each machine
    Each machine files lists the associated device trees for that machine.

 * i.MX U-Boot configurations for each machine
    imx6qpsabresd - sd, sata
    imx6qpsabreauto - sd, eim-nor, nand, spi-nor, sata
    imx7dsabresd - sd, qspi1, nand, epdc
    imx6ulevk - sd, qspi1
    imx6ullevk - sd
    imx6sxsabresd - sd, qspi2, m4fastup, emmc
    imx6sxsabreauto - sd, qspi1, nand
    imx6qsabresd - sd, sata
    imx6qsabreauto - sd, eim-nor, spi-nor, nand, sata
    imx6dlsabresd - sd, epdc
    imx6dlsabreauto - sd, eim-nor, spi-nor, nand
    imx6solosabresd - sd
    imx6solosabreauto - sd, eim-nor, spi-nor, nand
    imx6slevk - sd, spi-nor, epdc
    imx6sllevk - sd, epdc
    imx7ulpevk - sd, emmc
    imx8mqevk - sd


Quick Start Guide
-----------------
See the i.MX Yocto Project User's Guide for instructions on installing repo.

First install the i.MX Linux BSP repo
$: repo init -u git://source.codeaurora.org/external/imx/imx-manifest.git -b imx-linux-rocko -m imx-4.9.88-2.0.0_ga.xml

Download the Yocto Project Layers:
$: repo sync

If errors on repo init, remove the .repo directory and try repo init again.

Run i.MX Linux Yocto Project Setup:
$: [MACHINE=<machine>] [DISTRO=fsl-imx-<backend>] source ./fsl-setup-release.sh -b <build folder>

where
 <machine> defaults to imx6qsabresd
 <build folder> specifies the build folder name 

After this your system will be configured to start a Yocto Project build.

Build images
---------------------
Each graphical backend X11, Frame buffer and Wayland must be in a separate build 
directory, so the setup script above must be run for each backend to configure the build 
correctly. In this release two image recipes are provided that work on almost all backends.

DISTROs are new and the way to configure for any backends.  Use DISTRO= instead of the -e on the setup script.
The -e parameter gets converted to the appropriate distro configuration.

Note: 
DirectFB is no longer supported in i.MX graphic builds.
The X11 and Framebuffer distros are only supported for i.MX 6 and i.MX 7.  i.MX 8 should use xwayland only.
XWayland is the default distro for all i.MX families.

   fsl-image-validation-imx provides a gui image without QT.
   fsl-image-qt5-validation-imx provides a Qt5 image

Here are some examples:
(The example uses the imx6qsabresd MACHINE but substitute this with whatever you are using)

Building X11
------------
  DISTRO=fsl-imx-x11 MACHINE=imx6qsabresd source fsl-setup-release.sh -b build-x11
  bitbake <image>

To run the QT5 examples use the following parameters:
<QT5 example> -platform xcb -plugin evdevtouch:/dev/input/event0

Building Frame Buffer (FB)
---------------------------
  DISTRO=fsl-imx-fb MACHINE=imx6qsabresd source fsl-setup-release.sh -b build-fb
  bitbake <image>

To run the QT5 examples use the following parameters:
<QT5 Example> -platform eglfs -plugin evdevtouch:/dev/input/event0

Building XWayland
---------------------------
  DISTRO=fsl-imx-xwayland MACHINE=imx6qsabresd source fsl-setup-release.sh -b build-xwayland
  bitbake <image>

To run the QT5 examples use the following parameters:
<QT5 example> platform wayland-egl -plugin evdevtouch:/dev/input/event0 --fullscreen

Building Wayland-Weston (wayland)
---------------------------
  DISTRO=fsl-imx-wayland MACHINE=imx6qsabresd source fsl-setup-release.sh -b build-wayland
  bitbake <image>

To run the QT5 examples use the following parameters:
<QT5 example> platform wayland-egl -plugin evdevtouch:/dev/input/event0 --fullscreen

Building with Multilib support
---------------------------
Yocto Project is able to build libraries for different target optimizations, combing those in one system image,
allowing the user to run both 32-bit and 64-bit applications.
Here is an example to add multilib support (lib32).

In local.conf
- Define multilib targets
require conf/multilib.conf
MULTILIBS = "multilib:lib32"
DEFAULTTUNE_virtclass-multilib-lib32 = "armv7athf-neon"

- 32-bit libraries to be added into the image
IMAGE_INSTALL_append = "lib32-glibc lib32-libgcc lib32-libstdc++"

Enable/disable OPTEE
---------------------------
Optee feature is not enabled by default in the build. If you want to enable optee at build time, you need to add
DISTRO_FEATURES_append = " optee" to local.conf file

### To ENABLE optee, assuimg the machine supports it.
echo "DISTRO_FEATURES_append = \" optee\"" >> conf/local.conf

This updates the uboot config file, add the specific .dts files, and integrates the optee packages in rootfs.
If you want to switch back to a non-optee configuration, you can just flash a uboot without optee enabled.

Building u-boot for imx6 and imx7 legacy boards with optee disabled:

cd <build folder>
echo "UBOOT_CONFIG = \"sd-optee\"" >> conf/local.conf
MACHINE=<MACHINE> bitbake u-boot-imx -c deploy -f
cp tmp/deploy/images/<MACHINE>/u-boot-<MACHINE>.imx <folder where you keep the uboots>/u-boot-<MACHINE>'_'sd-optee.imx

Flashing boot for imx6 and imx7 legacy boards:

dd if=u-boot-<MACHINE>_sd-optee.imx of=<SDCARD> conv=notrunc seek=2 bs=512

Building boot image for imx8 with optee disabled:

To disable optee from the boot image you should remove tee.bin from eFIT image
Please refer to README and <mkimage_fit_atf.sh> files from imx-boot for more information

Flashing boot for imx8:

dd if=imx-boot-<MACHINE>-sd.bin of=<SDCARD> conv=notrunc seek=33 bs=1K

Hardware Floating Point
-----------------------
This release enables hardware floating point by default.  This feature is enabled in both the machine 
configurations and in the layer.conf. (Some machine files exist in the community meta-fsl-arm without this setting.)
DEFAULTTUNE_mx6 = "cortexa9hf-neon

Software floating point is not supported starting with the 4.1.15_1.0.0_ga release

Restricted Codecs
-----------------
These codecs have contractual restrictions that require separate distribution.

The Manufacturing Tool - MFGTool
--------------------------------
In this release MFGTool uses the community setup.  
To build MFGTool, build the following:

   bitbake fsl-image-mfgtool-initramfs

End User License Agreement
--------------------------
During the NXP Yocto Project Community BSP setup-environment process, the NXP i.MX End User License Agreement (EULA)
is displayed. To continue, users must agree to the conditions of this license. The agreement to the terms allows the
Yocto build to untar packages from the NXP mirror. Please read this license agreement carefully during the
setup process because, once accepted, all further work in the Yocto environment is tied to this accepted agreement.

Chromium
---------
Add Chromium to your Wayland or X11-based image by adding the following lines to local.conf:

# Add Chromium
IMAGE_INSTALL_append = \
    "${@bb.utils.contains('DISTRO_FEATURES', 'wayland', ' chromium-ozone-wayland libexif', \
        bb.utils.contains('DISTRO_FEATURES',     'x11', ' chromium-x11 libexif', \
                                                        '', d), d)}"
LICENSE_FLAGS_WHITELIST = \
    "${@bb.utils.contains('DISTRO_FEATURES', 'wayland', 'commercial', \
        bb.utils.contains('DISTRO_FEATURES',     'x11', 'commercial', \
                                                        '', d), d)}"

QTWebkit
--------
To start go to /usr/share/qt5/examples/webkitwidgets/browser and run browser

Qt
--
Note that Qt has both a commercial and open source license options.  Make the decision about which license
to use before starting work on custom Qt applications.  Once custom Qt applications are started with an open source
Qt license the work can not be used with a commercial Qt license.  Work with a legal representative to understand
the differences between each license.

Note Qt is not supported on i.MX 6UltraLite and i.MX 7Dual. It works on X11 backend only but is not a supported feature.

Systemd
-------
Systemd support is enabled as default but it can be disabled by commenting out the systemd settings in
imx/meta-sdk//conf/distro/include/fsl-imx-preferred-env.inc.