net-tools: split into binary packages
PATCH 1/1 net-tools: split into binary packages
Support per binary package to not bloat the system with unneeded tools.
Signed-off-by Sinan Kaya <[email protected]>
--- .../net-tools/net-tools_1.60-26.bb | 27 +++++++++++++++++++ 1 file changed, 27 insertions(+)
meta/recipes-extended/net-tools/net-tools_1.60-26.bb +27 -0
@@ -129,4 +129,31 @@ python __anonymous() { } ALTERNATIVE_PRIORITY = "100" +python __anonymous () { + packages = [] + for prog in d.getVar('base_sbindir_progs').split(): + pkg = "net-tools-%s" % prog.replace("_", "-") + packages.append(pkg) + if not d.getVar("FILES_%s" % pkg): + d.setVar("FILES_%s" % pkg, "${base_sbindir}/%s*" % prog) + for prog in d.getVar('base_bindir_progs').split(): + pkg = "net-tools-%s" % prog.replace("_", "-") + packages.append(pkg) + if not d.getVar("FILES_%s" % pkg): + d.setVar("FILES_%s" % pkg, "${base_bindir}/%s*" % prog) + pkg = "net-tools-man" + packages.append(pkg) + if not d.getVar("FILES_%s" % pkg): + d.setVar("FILES_%s" % pkg, "${mandir}/*") + d.setVar("NETTOOLS_PACKAGES", " ".join(packages)) +} +# "net-tools" is a metapackage which pulls in all net-tools binaries +PACKAGES += "${PN}" +PACKAGES = "${PN}-dbg ${NETTOOLS_PACKAGES}" +PROVIDES += "${PN}" +PROVIDES = "${PN}-dbg ${NETTOOLS_PACKAGES}" +FILES_${PN} = "" +ALLOW_EMPTY_${PN} = "1" +RRECOMMENDS_${PN} += "${NETTOOLS_PACKAGES}" + BBCLASSEXTEND = "native nativesdk"
Signature · 1 line
2.17.1