Leaf and mkapp and legato system .api files

I would like to use the mkapp tool to reduce the app development time overhead of running mksys

I’m using leaf with mksys this is working fine to build a working system

But when I try to

(lsh:currentWp76) john@john-VirtualBox-ST:~/WP76$ mkapp ./apps/wan/wan.adef
** ERROR:
/home/john/WP76/apps/wan/wanComponent/Component.cdef:6:8: error: Can't find dependent .api file: 'le_mdc.api'.

Component.cdef is like this

requires:
{
    api:
    {
        le_data.api
		le_cfg.api
        modemServices/le_mdc.api
        modemServices/le_mrc.api
        modemServices/le_sim.api
     
    }
}

I did try hacking around like this (below) which looks like it works - but is there a better way?

$ mkapp -s components -t wp76xx -i ./leaf-data/current/wp76-legato/interfaces/modemServices ./apps/wan/wan.adef

[22/22] Packaging app

Any ideas?

@johnofleek,

First for all, the best way to work and use the legato framework is to switch to the source mode with $ leaf getsrc legato (in your workspace). Otherwise, the -I option can be used when the compilator can’t find the interfaces needed, so, it’s not bad to use -i option.