[yocto] running task only for native but not target?

Paul Eggleton paul.eggleton at linux.intel.com
Fri Mar 13 02:01:48 PDT 2015


Hi Yannick,

On Thursday 12 March 2015 19:05:13 Koehler, Yannick wrote:
> I have a package that produce a binary that I need for native, and an C
> header file that I need for target.
> 
> I put the following do_install function to install appropriately the bin or
> header according to the class:
> 
> 	do_install_append_class-target () {
> 	        install -d ${D}${includedir}
> 	        install -m 0755 ${S}/ifrpc.h ${D}${includedir}
> 	}
> 
> 	do_install_append_class-native() {
> 	        install -d ${D}${bindir}
> 	        install -m 0755 ${S}/ifrpcgen ${D}${bindir}
> 	}
> 
> but is there a way for me to disable do_patch/do_configure/do_compile only
> when building for the target?  I have tried the following without success:
> 
> 	do_configure_class-target[noexec] = "1"
> 	do_patch_class-target[noexec] = "1"
> 	do_compile_class-target[noexec] = "1"
> 
> It appears the OVERRIDES do not apply here, any hint on how I can achieve
> this?

Probably the easiest way would be to just null out the tasks just for the 
target class i.e.

do_configure_class-target () {
   :
}

Cheers,
Paul

-- 

Paul Eggleton
Intel Open Source Technology Centre



More information about the yocto mailing list