# Building Custom Yocto Image

**URL:** <https://mangoh.discourse.group/t/building-custom-yocto-image/1299>\
**Category:** Wiki\
**Created:** [April 4, 2018, 9:39pm UTC](https://mangoh.discourse.group/t/building-custom-yocto-image/1299 "2018-04-04T21:39:30Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![dclark75](https://avatars.discourse-cdn.com/v4/letter/d/a8b319/32.png) [@dclark75](https://mangoh.discourse.group/u/dclark75)\
**Post date:** [April 4, 2018, 9:39pm UTC](https://mangoh.discourse.group/t/building-custom-yocto-image/1299/1 "2018-04-04T21:39:30Z")

</div>

The instructions below show how to build custom yocto images for the WP76 and WP85. Note that if someone chooses to build their own yocto image then they should set the LEGATO\_KERNELROOT environment variable before building MangOH, for example:

**WP85** :  
export LEGATO\_KERNELROOT="~/yocto-2.2/build\_src/tmp/work/swi\_mdm9x15-poky-linux-gnueabi/linux-yocto/3.14.29-r0.1/linux-swi\_mdm9x15-standard-build"

**WP76** :  
export LEGATO\_KERNELROOT="~/yocto-2.2/build\_src/tmp/work/swi\_mdm9x28-poky-linux-gnueabi/linux-quic/3.18.44-r1/build"

**1. Initialize repo**

Create yocto folder:  
mkdir ~/yocto-2.2  
cd ~/yocto-2.2

**WP85** :  
repo init -u git://gerrit-legato/manifest -m lxswi/branches/master/systems/wp85xx.xml -g “default,amss”

**WP76** :  
repo init -u git://gerrit-legato/manifest -m lxswi/branches/master/systems/wp76xx.xml

**2. Synchronize repo and build yocto**

repo sync  
make image\_src

To set/unset kernel configuration options use the following commands:  
cd $LEGATO\_KERNELROOT  
VERBOSE=1 make ARCH=arm menuconfig

Note if you just want to rebuild the kernel then the following can be used in a script (e.g. here we create a script called build\_kernel.sh and place in the build\_src folder).

**WP85** :  
bitbake -c compile -f linux-yocto  
bitbake -c build -f linux-yocto  
bitbake -c build -f mdm9x15-image-minimal

**WP76** :  
bitbake -c compile -f linux-quic  
bitbake -c build -f linux-quic  
bitbake -c build -f mdm9x28-image-minimal

**3. Build and install the toolchain (optional)**

Note this step is only required for users that desire to build their own toolchain instead of downloading it from the sierrawireless web sites:

**WP85** :  
[https://source.sierrawireless.com/resources/airprime/software/wpx5xx/wpx5xx-firmware-latest-release-components/](https://source.sierrawireless.com/resources/airprime/software/wpx5xx/wpx5xx-firmware-latest-release-components/)

**WP76** :  
[https://source.sierrawireless.com/resources/airprime/software/wp76xx/wp76xx-firmware-latest-release-components/](https://source.sierrawireless.com/resources/airprime/software/wp76xx/wp76xx-firmware-latest-release-components/)

make toolchain\_src

**WP85** :  
cd ~/yocto-2.2/  
sudo ./build\_src/tmp/deploy/sdk/poky-swi-ext-glibc-x86\_64-meta-toolchain-swi-ext-armv7a-neon-toolchain-swi-ext-2.2.3.sh

**WP76** :  
cd ~/yocto-2.2/  
sudo ./build\_src/tmp/deploy/sdk/poky-swi-ext-glibc-x86\_64-meta-toolchain-swi-ext-armv7a-neon-toolchain-swi-ext-2.2.3.sh

**4. Download new yocto build to the target device**

Note before downloading switch pin 7 up for the MangOH Red and then once the downloading has started switch pin 7 back down.

**WP85** :  
cd ~/yocto-2.2/  
swiflash -m “WP85XX” -i ./build\_src/tmp/deploy/images/swi-mdm9x15/yocto-legato\_wp85.cwe  
OR  
copy yocto-legato\_wp85.cwe to a folder on Windows PC with fdt2 installed  
fdt2 yocto-legato\_wp85.cwe

**WP76** :  
cd ~/yocto-2.2/  
swiflash -m “WP76XX” -i …/yocto-wp76/build\_src/tmp/deploy/images/swi-mdm9x28/yocto\_wp76xx.4k.cwe  
OR  
copy yocto-legato\_wp85.cwe to a folder on Windows PC with fdt2 installed  
fdt2 yocto\_wp76xx.4k.cwe

---

<div class="post-metadata">

**Author:** ![deadpoolcode](https://avatars.discourse-cdn.com/v4/letter/d/8797f3/32.png) [@deadpoolcode](https://mangoh.discourse.group/u/deadpoolcode)\
**Post date:** [April 7, 2018, 12:10am UTC](https://mangoh.discourse.group/t/building-custom-yocto-image/1299/2 "2018-04-07T00:10:01Z")

</div>

currently not working, I can not get the xml:

repo init -u git://gerrit-legato/manifest -m lxswi/branches/master/systems/wp76xx.xml

fatal: unable to connect to gerrit-legato:  
gerrit-legato: Name or service not known

please advice

---

<div class="post-metadata">

**Author:** ![nick](https://sea2.discourse-cdn.com/flex016/user_avatar/mangoh.discourse.group/nick/32/1380_2.png) [@nick](https://mangoh.discourse.group/u/nick)\
**Post date:** [April 7, 2018, 12:12am UTC](https://mangoh.discourse.group/t/building-custom-yocto-image/1299/3 "2018-04-07T00:12:43Z")

</div>

I suspect those are internal git servers.

---

<div class="post-metadata">

**Author:** ![deadpoolcode](https://avatars.discourse-cdn.com/v4/letter/d/8797f3/32.png) [@deadpoolcode](https://mangoh.discourse.group/u/deadpoolcode)\
**Post date:** [April 7, 2018, 12:14am UTC](https://mangoh.discourse.group/t/building-custom-yocto-image/1299/4 "2018-04-07T00:14:51Z")

</div>

> [@dclark75](#):
>
> wp76xx.xml

thank you, if so how can I get the sources in order to build a Yocto image?

---

<div class="post-metadata">

**Author:** ![nick](https://sea2.discourse-cdn.com/flex016/user_avatar/mangoh.discourse.group/nick/32/1380_2.png) [@nick](https://mangoh.discourse.group/u/nick)\
**Post date:** [April 7, 2018, 12:37am UTC](https://mangoh.discourse.group/t/building-custom-yocto-image/1299/5 "2018-04-07T00:37:47Z")

</div>

Hey @deadpoolcode,

I just got some build hardware so I’m just starting to unravel this as well. I think everything you need can be found in here: [http://downloads.sierrawireless.com/AirPrime/WPx5xx/Release15/Legato-Dist-Source-mdm9x15-SWI9X15Y\_07.12.14.00.tar.bz2](http://downloads.sierrawireless.com/AirPrime/WPx5xx/Release15/Legato-Dist-Source-mdm9x15-SWI9X15Y_07.12.14.00.tar.bz2)

---

<div class="post-metadata">

**Author:** ![dfrey](https://sea2.discourse-cdn.com/flex016/user_avatar/mangoh.discourse.group/dfrey/32/303_2.png) [@dfrey](https://mangoh.discourse.group/u/dfrey)\
**Post date:** [April 7, 2018, 4:47pm UTC](https://mangoh.discourse.group/t/building-custom-yocto-image/1299/6 "2018-04-07T16:47:52Z")

</div>

The repo steps are wrong. @nick is correct that gerrit-legato is a server only accessible inside Sierra Wireless. For now, download the tarball for your module. @nick linked to the one for wp75/85.

---

<div class="post-metadata">

**Author:** ![nick](https://sea2.discourse-cdn.com/flex016/user_avatar/mangoh.discourse.group/nick/32/1380_2.png) [@nick](https://mangoh.discourse.group/u/nick)\
**Post date:** [April 10, 2018, 8:43pm UTC](https://mangoh.discourse.group/t/building-custom-yocto-image/1299/7 "2018-04-10T20:43:05Z")

</div>

Hey @dclark75,

I’ve recently had some success building yocto from scratch for the WP85 using the tar ball I linked above. I modified `meta-swi-extras/meta-swi-bin/files/fw-version` in attempt to release my own build (mostly for the purpose of confirming that it flashed successfully). I was also sure to commit the changes since I’ve heard the build process will re-clone repos sometimes. After flashing this custom build, I did not see the updated firmware version. I believe these this could be two things:

1. The firmware version is defined in 2 places somewhere else
2. The custom build is not flashing successfully (despite a success message from `swiflash`)

Do you guys have any debugging advice? Unfortunately we do not have access to a serial console on these units.

---

<div class="post-metadata">

**Author:** ![nick](https://sea2.discourse-cdn.com/flex016/user_avatar/mangoh.discourse.group/nick/32/1380_2.png) [@nick](https://mangoh.discourse.group/u/nick)\
**Post date:** [April 10, 2018, 9:12pm UTC](https://mangoh.discourse.group/t/building-custom-yocto-image/1299/8 "2018-04-10T21:12:27Z")

</div>

Update: I flashed release 14 (pre-built `.spk` file) and the version changed to match(`SWI9X15Y_07.12.09.00 r34123 CARMD-EV-FRMWR1 2017/04/26 23:34:19`). After that, I tried re-flashing our custom build (based on`SWI9X15Y_07.12.14.00`) and did not see the version change. This more or less confirms that our custom builds are not flashing.

---

<div class="post-metadata">

**Author:** ![Souhail](https://avatars.discourse-cdn.com/v4/letter/s/a698b9/32.png) [@Souhail](https://mangoh.discourse.group/u/Souhail)\
**Post date:** [April 11, 2018, 3:07pm UTC](https://mangoh.discourse.group/t/building-custom-yocto-image/1299/9 "2018-04-11T15:07:31Z")

</div>

The SWI9X15Y\_07.12.09.00 and SWI9X15Y\_07.12.14.00 concerns the legato version not the linux image, in order to have an .spk image with the correct legato version you should build yocto image then run the swicwe command and you should point on both the linux image and the legato image that you want to install. It is better to use AT command to check the version using microcom interface. I hope that helps you.

---

<div class="post-metadata">

**Author:** ![nick](https://sea2.discourse-cdn.com/flex016/user_avatar/mangoh.discourse.group/nick/32/1380_2.png) [@nick](https://mangoh.discourse.group/u/nick)\
**Post date:** [April 20, 2018, 6:43pm UTC](https://mangoh.discourse.group/t/building-custom-yocto-image/1299/10 "2018-04-20T18:43:35Z")

</div>

Hey @Souhail sorry for the delayed reply.

I’ve been working with custom images and I think I have a better understanding of how this all comes together. To my knowledge, `SWI9X15Y_07.12.14.00` refers to the modem firmware and not the Legato version (though certain Legato releases come bundled with certain modem firmware versions), which is not part of the Yocto image. I found this diagram very helpful in that regard:

 ![WP%20Flash%20Mapping](https://us1.discourse-cdn.com/flex016/uploads/mangoh/original/1X/7fd06b10718755e613e222096e52f6edc417ed8d.png)

I’ve been successfully flashing custom `.spk` files produced using `swicwe` (thanks again for the suggestion @Souhail).

On an unrelated note, @dclark75, would you be able to clarify a little bit on customizing the kernel? I’m a little confused as to why we run `VERBOSE=1 make ARCH=arm menuconfig` in `$LEGATO_KERNELROOT` instead of in the main kernel directory (e.g `/build-folder/yocto/kernel`) before running `make image_bin`. Additionally, I had some trouble finding the BitBake executable. I’m sure it’s in here somewhere, but I don’t have the executable in my path, so simply invoking `bitbake` doesn’t work.

Cheers!

---

<div class="post-metadata">

**Author:** ![fjanicki](https://sea2.discourse-cdn.com/flex016/user_avatar/mangoh.discourse.group/fjanicki/32/1125_2.png) [@fjanicki](https://mangoh.discourse.group/u/fjanicki)\
**Post date:** [April 23, 2018, 7:39pm UTC](https://mangoh.discourse.group/t/building-custom-yocto-image/1299/11 "2018-04-23T19:39:25Z")

</div>

Possible to get a git repository of the `meta-` modules? If we want to roll our own yocto repo using the latest yocto version? Because the tarball contains a very old version of yocto, according to here [https://wiki.yoctoproject.org/wiki/Releases](https://wiki.yoctoproject.org/wiki/Releases) (1.7.3) was released in 2014…

---

<div class="post-metadata">

**Author:** ![fjanicki](https://sea2.discourse-cdn.com/flex016/user_avatar/mangoh.discourse.group/fjanicki/32/1125_2.png) [@fjanicki](https://mangoh.discourse.group/u/fjanicki)\
**Post date:** [April 23, 2018, 7:49pm UTC](https://mangoh.discourse.group/t/building-custom-yocto-image/1299/12 "2018-04-23T19:49:59Z")

</div>

I think that to be able to access bitbake, you need to run `source oe-init-build-env` in the `/poky` directory.

---

<div class="post-metadata">

**Author:** ![nick](https://sea2.discourse-cdn.com/flex016/user_avatar/mangoh.discourse.group/nick/32/1380_2.png) [@nick](https://mangoh.discourse.group/u/nick)\
**Post date:** [April 23, 2018, 8:51pm UTC](https://mangoh.discourse.group/t/building-custom-yocto-image/1299/13 "2018-04-23T20:51:46Z")

</div>

Thanks @fjanicki, I’ll give this a try.

---

<div class="post-metadata">

**Author:** ![nick](https://sea2.discourse-cdn.com/flex016/user_avatar/mangoh.discourse.group/nick/32/1380_2.png) [@nick](https://mangoh.discourse.group/u/nick)\
**Post date:** [April 23, 2018, 8:52pm UTC](https://mangoh.discourse.group/t/building-custom-yocto-image/1299/14 "2018-04-23T20:52:49Z")

</div>

Where are you grabbing the Yocto version from? I recall seeing a newer revision somewhere in the code/build but I can’t seem to find it again.

Cheers!

---

<div class="post-metadata">

**Author:** ![fjanicki](https://sea2.discourse-cdn.com/flex016/user_avatar/mangoh.discourse.group/fjanicki/32/1125_2.png) [@fjanicki](https://mangoh.discourse.group/u/fjanicki)\
**Post date:** [April 23, 2018, 9:20pm UTC](https://mangoh.discourse.group/t/building-custom-yocto-image/1299/15 "2018-04-23T21:20:31Z")

</div>

Not sure, I just use the version bundled in the tarball provided from sierra wireless’s download section. I would much prefer to use a git repo but none is available. Problem is that the bundled version is very old and it would be nice to be able to use a newer version.

---

<div class="post-metadata">

**Author:** ![nick](https://sea2.discourse-cdn.com/flex016/user_avatar/mangoh.discourse.group/nick/32/1380_2.png) [@nick](https://mangoh.discourse.group/u/nick)\
**Post date:** [April 23, 2018, 9:38pm UTC](https://mangoh.discourse.group/t/building-custom-yocto-image/1299/16 "2018-04-23T21:38:18Z")

</div>

Yeah the tarball approach is definitely a little painful. I double checked the versions and it’s definitely Yocto `1.7.3` as you stated (not sure why I had a newer version in my head). I suspect Sierra Wireless will supply a nicer approach to managing custom images as it becomes more popular.

Cheers!

---

<div class="post-metadata">

**Author:** ![fjanicki](https://sea2.discourse-cdn.com/flex016/user_avatar/mangoh.discourse.group/fjanicki/32/1125_2.png) [@fjanicki](https://mangoh.discourse.group/u/fjanicki)\
**Post date:** [April 24, 2018, 6:13pm UTC](https://mangoh.discourse.group/t/building-custom-yocto-image/1299/17 "2018-04-24T18:13:51Z")

</div>

I found this repo but it seems outdated. Maybe we can create an unofficial git repo?

[https://github.com/meta-swi/meta-swi](https://github.com/meta-swi/meta-swi)

---

<div class="post-metadata">

**Author:** ![drewwestrick](https://sea2.discourse-cdn.com/flex016/user_avatar/mangoh.discourse.group/drewwestrick/32/270_2.png) [@drewwestrick](https://mangoh.discourse.group/u/drewwestrick)\
**Post date:** [May 29, 2018, 6:27pm UTC](https://mangoh.discourse.group/t/building-custom-yocto-image/1299/18 "2018-05-29T18:27:05Z")

</div>

I’m currently trying to build yocto from source using the WP76XX [SWI9X07Y\_02.16.02.00](http://downloads.sierrawireless.com/AirPrime/WP76xx/Release9/Legato-Dist-Source-mdm9x28-SWI9X07Y_02.16.02.00.tar.bz2) code and the steps posted above.

I’ve installed all the host build dependencies called out in [Yocto Project Quick Start](https://www.yoctoproject.org/docs/1.8/yocto-project-qs/yocto-project-qs.html).

My process is the following:

1. untar the source
2. `repo sync`
3. `make image_bin`

The build is failing and I am getting the following errors which relates to qemu-native 2.7.0-r1:

> ERROR: qemu-native-2.7.0-r1 do\_compile: oe\_runmake failed  
> ERROR: qemu-native-2.7.0-r1 do\_compile: Function failed: do\_compile (log file is located at /home/drewwestrick/SW/workspace/legato\_framework/yocto/build\_bin/tmp/work/x86\_64-linux/qemu-native/2.7.0-r1/temp/log.do\_compile.27008)  
> ERROR: Logfile of failure stored in: /home/drewwestrick/SW/workspace/legato\_framework/yocto/build\_bin/tmp/work/x86\_64-linux/qemu-native/2.7.0-r1/temp/log.do\_compile.27008  
> Log data follows:  
> | DEBUG: Executing shell function do\_compile  
> | NOTE: make -j 4 LD=ld AR=ar OBJCOPY=objcopy LDFLAGS=-L/home/drewwestrick/SW/workspace/legato\_framework/yocto/build\_bin/tmp/sysroots/x86\_64-linux/usr/lib -L/home/drewwestrick/SW/workspace/legato\_framework/yocto/build\_bin/tmp/sysroots/x86\_64-linux/lib -Wl,-rpath-link,/home/drewwestrick/SW/workspace/legato\_framework/yocto/build\_bin/tmp/sysroots/x86\_64-linux/usr/lib -Wl,-rpath-link,/home/drewwestrick/SW/workspace/legato\_framework/yocto/build\_bin/tmp/sysroots/x86\_64-linux/lib -Wl,-rpath,/home/drewwestrick/SW/workspace/legato\_framework/yocto/build\_bin/tmp/sysroots/x86\_64-linux/usr/lib -Wl,-rpath,/home/drewwestrick/SW/workspace/legato\_framework/yocto/build\_bin/tmp/sysroots/x86\_64-linux/lib -Wl,-O1 -fuse-ld=bfd  
> | ERROR: oe\_runmake failed  
> | GEN arm-softmmu/config-devices.mak.tmp  
> | GEN aarch64-softmmu/config-devices.mak.tmp  
> | GEN aarch64-linux-user/config-devices.mak.tmp  
> | GEN arm-linux-user/config-devices.mak.tmp  
> | GEN arm-linux-user/config-devices.mak  
> | GEN aarch64-linux-user/config-devices.mak  
> | GEN i386-linux-user/config-devices.mak.tmp  
> | GEN i386-softmmu/config-devices.mak.tmp  
> | GEN arm-softmmu/config-devices.mak  
> | GEN mips-linux-user/config-devices.mak.tmp  
> | GEN aarch64-softmmu/config-devices.mak  
> | GEN mips-softmmu/config-devices.mak.tmp  
> | GEN i386-linux-user/config-devices.mak  
> | GEN mips-linux-user/config-devices.mak  
> | GEN mipsel-softmmu/config-devices.mak.tmp  
> | GEN i386-softmmu/config-devices.mak  
> | GEN mipsel-linux-user/config-devices.mak.tmp  
> | GEN mips64-linux-user/config-devices.mak.tmp  
> | GEN mipsel-linux-user/config-devices.mak  
> | GEN mips64-linux-user/config-devices.mak  
> | GEN mips64-softmmu/config-devices.mak.tmp  
> | GEN ppc-linux-user/config-devices.mak.tmp  
> | GEN mipsel-softmmu/config-devices.mak  
> | GEN mips-softmmu/config-devices.mak  
> | GEN ppc-softmmu/config-devices.mak.tmp  
> | GEN x86\_64-linux-user/config-devices.mak.tmp  
> | GEN ppc-linux-user/config-devices.mak  
> | GEN x86\_64-softmmu/config-devices.mak.tmp  
> | GEN x86\_64-linux-user/config-devices.mak  
> | GEN mips64-softmmu/config-devices.mak  
> | GEN ppc-softmmu/config-devices.mak  
> | GEN x86\_64-softmmu/config-devices.mak  
> | GEN qemu-options.def  
> | GEN config-host.h  
> | GEN qmp-commands.h  
> | GEN qapi-types.h  
> | GEN qapi-visit.h  
> | GEN qapi-event.h  
> | GEN qmp-introspect.h  
> | GEN tests/test-qapi-types.h  
> | GEN tests/test-qapi-visit.h  
> | GEN tests/test-qmp-commands.h  
> | GEN tests/test-qapi-event.h  
> | GEN tests/test-qmp-introspect.h  
> | GEN config-all-devices.mak  
> | GEN trace/generated-events.h  
> | GEN trace/generated-tracers.h  
> | GEN trace/generated-tcg-tracers.h  
> | GEN trace/generated-helpers-wrappers.h  
> | GEN trace/generated-helpers.h  
> | CC tests/qemu-iotests/socket\_scm\_helper.o  
> | GEN qemu-monitor.texi  
> | GEN qemu-img-cmds.texi  
> | GEN qemu-options.texi  
> | GEN qemu-monitor-info.texi  
> | GEN qemu-tech.html  
> | GEN qemu-img.1  
> | GEN qemu-nbd.8  
> | GEN qemu-ga.8  
> | GEN qmp-commands.txt  
> | GEN qga/qapi-generated/qga-qapi-types.h  
> | GEN qga/qapi-generated/qga-qapi-visit.h  
> | GEN qga/qapi-generated/qga-qmp-commands.h  
> | GEN qga/qapi-generated/qga-qapi-types.c  
> | GEN qga/qapi-generated/qga-qapi-visit.c  
> | GEN qga/qapi-generated/qga-qmp-marshal.c  
> | GEN qmp-introspect.c  
> | GEN qapi-types.c  
> | GEN qapi-visit.c  
> | GEN qapi-event.c  
> | CC qapi/qapi-visit-core.o  
> | CC qapi/qapi-dealloc-visitor.o  
> | CC qapi/qmp-input-visitor.o  
> | CC qapi/qmp-output-visitor.o  
> | CC qapi/qmp-dispatch.o  
> | CC qapi/qmp-registry.o  
> | CC qapi/string-input-visitor.o  
> | CC qapi/string-output-visitor.o  
> | CC qapi/opts-visitor.o  
> | CC qapi/qapi-clone-visitor.o  
> | CC qapi/qmp-event.o  
> | CC qapi/qapi-util.o  
> | CC qobject/qnull.o  
> | CC qobject/qint.o  
> | CC qobject/qstring.o  
> | CC qobject/qdict.o  
> | CC qobject/qlist.o  
> | CC qobject/qfloat.o  
> | CC qobject/qbool.o  
> | CC qobject/qjson.o  
> | CC qobject/qobject.o  
> | CC qobject/json-lexer.o  
> | CC qobject/json-streamer.o  
> | CC qobject/json-parser.o  
> | GEN trace/generated-events.c  
> | CC trace/control.o  
> | CC trace/qmp.o  
> | CC util/osdep.o  
> | CC util/cutils.o  
> | CC util/unicode.o  
> | CC util/qemu-timer-common.o  
> | CC util/compatfd.o  
> | CC util/event\_notifier-posix.o  
> | CC util/mmap-alloc.o  
> | CC util/oslib-posix.o  
> | CC util/qemu-openpty.o  
> | CC util/qemu-thread-posix.o  
> | CC util/memfd.o  
> | /home/drewwestrick/SW/workspace/legato\_framework/yocto/build\_bin/tmp/work/x86\_64-linux/qemu-native/2.7.0-r1/qemu-2.7.0/util/memfd.c:40:12: error: static declaration of ‘memfd\_create’ follows non-static declaration  
> | static int memfd\_create(const char \*name, unsigned int flags)  
> | ^ ~~~~~~~~~~~  
> | In file included from /usr/include/x86\_64-linux-gnu/bits/mman-linux.h:115:0,  
> | from /usr/include/x86\_64-linux-gnu/bits/mman.h:45,  
> | from /usr/include/x86\_64-linux-gnu/sys/mman.h:41,  
> | from /home/drewwestrick/SW/workspace/legato\_framework/yocto/build\_bin/tmp/work/x86\_64-linux/qemu-native/2.7.0-r1/qemu-2.7.0/include/sysemu/os-posix.h:29,  
> | from /home/drewwestrick/SW/workspace/legato\_framework/yocto/build\_bin/tmp/work/x86\_64-linux/qemu-native/2.7.0-r1/qemu-2.7.0/include/qemu/osdep.h:104,  
> | from /home/drewwestrick/SW/workspace/legato\_framework/yocto/build\_bin/tmp/work/x86\_64-linux/qemu-native/2.7.0-r1/qemu-2.7.0/util/memfd.c:28:  
> | /usr/include/x86\_64-linux-gnu/bits/mman-shared.h:46:5: note: previous declaration of ‘memfd\_create’ was here  
> | int memfd\_create (const char \*\_\_name, unsigned int \_\_flags) \_\_THROW;  
> | ^ ~~~~~~~~~~~  
> | /home/drewwestrick/SW/workspace/legato\_framework/yocto/build\_bin/tmp/work/x86\_64-linux/qemu-native/2.7.0-r1/qemu-2.7.0/rules.mak:59: recipe for target ‘util/memfd.o’ failed  
> | make: \*\*\* [util/memfd.o] Error 1  
> | make: \*\*\* Waiting for unfinished jobs…  
> | WARNING: /home/drewwestrick/SW/workspace/legato\_framework/yocto/build\_bin/tmp/work/x86\_64-linux/qemu-native/2.7.0-r1/temp/run.do\_compile.27008:1 exit 1 from ‘exit 1’  
> | ERROR: Function failed: do\_compile (log file is located at /home/drewwestrick/SW/workspace/legato\_framework/yocto/build\_bin/tmp/work/x86\_64-linux/qemu-native/2.7.0-r1/temp/log.do\_compile.27008)  
> ERROR: Task (virtual:native:/home/drewwestrick/SW/workspace/legato\_framework/yocto/poky/meta/recipes-devtools/qemu/qemu\_2.7.0.bb:do\_compile) failed with exit code ‘1’  
> NOTE: Tasks Summary: Attempted 857 tasks of which 0 didn’t need to be rerun and 1 failed.  
> Summary: 1 task failed:  
> virtual:native:/home/drewwestrick/SW/workspace/legato\_framework/yocto/poky/meta/recipes-devtools/qemu/qemu\_2.7.0.bb:do\_compile  
> Summary: There were 9 WARNING messages shown.  
> Summary: There were 2 ERROR messages shown, returning a non-zero exit code.  
> Makefile:217: recipe for target ‘image\_bin’ failed

Build Configuration:

> Build Configuration:  
> BB\_VERSION = “1.32.0”  
> BUILD\_SYS = “x86\_64-linux”  
> NATIVELSBSTRING = “Ubuntu-18.04”  
> TARGET\_SYS = “arm-poky-linux-gnueabi”  
> MACHINE = “swi-mdm9x28”  
> DISTRO = “poky-swi-ext”  
> DISTRO\_VERSION = “2.2.3”  
> TUNE\_FEATURES = “arm armv7a vfp neon”  
> TARGET\_FPU = “softfp”  
> meta  
> meta-poky  
> meta-yocto-bsp = “HEAD:e6aadcc2a04ae4e85b1cb00c5c9ce1c0f76ee871”  
> meta-python  
> meta-networking  
> meta-oe = “HEAD:b40116cf457b88a2db14b86fda9627fb34d56ae6”  
> common  
> meta-swi-mdm9xxx  
> meta-swi-mdm9x28 = “HEAD:f646dfd3f5c04ca9a38321020cc4f3f9bdc015f5”  
> meta-swi-mdm9xxx-bin  
> meta-swi-mdm9x28-bin  
> meta-swi-mdm9x28  
> meta-swi-mdm9xxx-bin  
> meta-swi-mdm9x28-bin  
> common = “HEAD:9aca15ff07789cda916d0cd7efc4dacb87714883”

Should I try and use a more up-to-date version of qemu-native?

@dfrey @dclark75 @asyal

---

<div class="post-metadata">

**Author:** ![dfrey](https://sea2.discourse-cdn.com/flex016/user_avatar/mangoh.discourse.group/dfrey/32/303_2.png) [@dfrey](https://mangoh.discourse.group/u/dfrey)\
**Post date:** [May 29, 2018, 7:14pm UTC](https://mangoh.discourse.group/t/building-custom-yocto-image/1299/19 "2018-05-29T19:14:52Z")

</div>

Have you tried `make image_bin`. I believe `make image_src` is only possible within Sierra Wireless because it depends on proprietary source.

---

<div class="post-metadata">

**Author:** ![drewwestrick](https://sea2.discourse-cdn.com/flex016/user_avatar/mangoh.discourse.group/drewwestrick/32/270_2.png) [@drewwestrick](https://mangoh.discourse.group/u/drewwestrick)\
**Post date:** [May 29, 2018, 7:30pm UTC](https://mangoh.discourse.group/t/building-custom-yocto-image/1299/20 "2018-05-29T19:30:05Z")

</div>

Yes sorry that was a typo. `make image_src` is not even an option in the Makefile. I’m running `make image_bin`.

[Next page](https://mangoh.discourse.group/t/building-custom-yocto-image/1299.md?page=2)
