# Build BLE sample for mangoH yellow vsc

**URL:** <https://forum.legato.io/t/build-ble-sample-for-mangoh-yellow-vsc/5876>\
**Category:** Uncategorized\
**Created:** [July 7, 2021, 5:14am UTC](https://forum.legato.io/t/build-ble-sample-for-mangoh-yellow-vsc/5876 "2021-07-07T05:14:45Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![ilan](https://avatars.discourse-cdn.com/v4/letter/i/ecae2f/32.png) [@ilan](https://forum.legato.io/u/ilan)\
**Post date:** [July 7, 2021, 5:14am UTC](https://forum.legato.io/t/build-ble-sample-for-mangoh-yellow-vsc/5876/1 "2021-07-07T05:14:45Z")

</div>

Hello

I am trying to build some BLE example

in order to do so I need to add BLE component to the cdef file

the problem is that build does not find the BLE libraries

this is my define file:

sources:  
{  
bluetoothSensorTagComponent.c  
}

cflags:  
{  
-std=c99

```
// pkg-config --cflags glib-2.0 gio-2.0 gio-unix-2.0
-pthread
-I${LEGATO_SYSROOT}/usr/include/glib-2.0
-I${LEGATO_SYSROOT}/usr/lib/glib-2.0/include
-I${LEGATO_SYSROOT}/usr/include/gio-unix-2.0

```

}

// Bind resources from the target module into your application.  
requires:  
{  
// IPC APIs used by this component.  
api:  
{

```
}

// File paths local to your target module.
file:
{
}

// Directories on your target module to make accessible to the app.
dir:
{
}

// Linux filesystem device paths.
device:
{
}

// Shared libraries pre-installed on the module.
lib:
{
    gio-2.0
    gobject-2.0
    glib-2.0
}
component:
{
    bluezDBus
    json
}

```

}

this is the error I get:

> Executing task: mksys ${LEGATO\_DEF\_FILE} -s components -t ${LEGATO\_TARGET} -w ${LEGATO\_OBJECT\_DIR} -o ${LEGATO\_OUTPUT\_DIR} -d ${LEGATO\_DEBUG\_DIR} && update ${LEGATO\_UPDATE\_FILE} \<

[1/1] Regenerating build script  
FAILED: /home/administrator/myWorkspace/\_build\_mySystem/wp77xx/build.ninja  
mksys --dont-run-ninja “/home/administrator/myWorkspace/mySystem.sdef” “-s” “components” “-t” “wp77xx” “-w” “./\_build\_mySystem/wp77xx” “-o” “.” “-d” “.debug”  
\*\* ERROR:  
/home/administrator/myWorkspace/components/bluetoothSensorTagComponent/Component.cdef:35:8: error: \* Couldn’t find file ‘io.api.’  
ninja: error: rebuilding ‘/home/administrator/myWorkspace/\_build\_mySystem/wp77xx/build.ninja’: subcommand failed  
The terminal process “bash ‘-c’, ‘mksys ${LEGATO\_DEF\_FILE} -s components -t ${LEGATO\_TARGET} -w ${LEGATO\_OBJECT\_DIR} -o ${LEGATO\_OUTPUT\_DIR} -d ${LEGATO\_DEBUG\_DIR} && update ${LEGATO\_UPDATE\_FILE}’” terminated with exit code: 1.

Terminal will be reused by tasks, press any key to close it.

> Executing task: mksys ${LEGATO\_DEF\_FILE} -s components -t ${LEGATO\_TARGET} -w ${LEGATO\_OBJECT\_DIR} -o ${LEGATO\_OUTPUT\_DIR} -d ${LEGATO\_DEBUG\_DIR} && update ${LEGATO\_UPDATE\_FILE} \<

[1/1] Regenerating build script  
FAILED: /home/administrator/myWorkspace/\_build\_mySystem/wp77xx/build.ninja  
mksys --dont-run-ninja “/home/administrator/myWorkspace/mySystem.sdef” “-s” “components” “-t” “wp77xx” “-w” “./\_build\_mySystem/wp77xx” “-o” “.” “-d” “.debug”  
\*\* ERROR:  
/home/administrator/myWorkspace/components/bluetoothSensorTagComponent/Component.cdef:62:8: error: Couldn’t find component ‘bluezDBus’.  
ninja: error: rebuilding ‘/home/administrator/myWorkspace/\_build\_mySystem/wp77xx/build.ninja’: subcommand failed  
The terminal process “bash ‘-c’, ‘mksys ${LEGATO\_DEF\_FILE} -s components -t ${LEGATO\_TARGET} -w ${LEGATO\_OBJECT\_DIR} -o ${LEGATO\_OUTPUT\_DIR} -d ${LEGATO\_DEBUG\_DIR} && update ${LEGATO\_UPDATE\_FILE}’” terminated with exit code: 1.

Terminal will be reused by tasks, press any key to close it.

---

<div class="post-metadata">

**Author:** ![jyijyi](https://sea1.discourse-cdn.com/flex019/user_avatar/forum.legato.io/jyijyi/32/822_2.png) [@jyijyi](https://forum.legato.io/u/jyijyi)\
**Post date:** [July 7, 2021, 5:23am UTC](https://forum.legato.io/t/build-ble-sample-for-mangoh-yellow-vsc/5876/2 "2021-07-07T05:23:53Z")

</div>

Suggest you build the whole mangoh yellow layer  
The bluezDBus component is here:

> **[mangOH/components/bluezDBus at master · mangOH/mangOH](https://github.com/mangOH/mangOH/tree/master/components/bluezDBus)**
>
> master/components/bluezDBus

For the problem that io.api is not found, you can see here:

> **[Couldn't find file 'io.api'](https://forum.mangoh.io/t/couldnt-find-file-io-api/4495)**
>
> hello, Trying out sample app RedSensorToCloud on MangoH red for wp7608 with SDK for WP76 (Release 13.3 + Legato 20.04.0) while mkapp following error popping up myWorkspace/apps/RedSensorToCloud/components/avPublisher/Component.cdef:6:17: error:...
