license.bbclass: use do_package_prepend only for target recipes

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>