Prepare to tell apart real packages from virtual packages. Currently, the code implicitly recognises only real packages, and discards virtual packages, because of the heuristic used to recognise whether a symbol is a package: - for real package: - symbols : BR2_PACKAGE_FOO - .mk files: foo.mk - for virtual packages: - symbols : BR2_PACKAGE_HAS_FOO - .mk files: foo.mk The current heuristic is to check for each symbol if a corresponding .mk file exists, by stripping 'BR2_PACKAGE_' from the beginning of the symbol, converting the result to lowercase, and checking if a .mk file exists. So, as a side effect, it completely misses the virtual packages [*], which is pretty nice since we get a list with only real packages that the user can indeed select and see in the menuconfig. [*] Except for 'cryptodev' and 'jpeg' which are both virtual packages and normal packages. Except they are not normal packages, they are used to display a choice of the implementation to use. This case will be fixed in follow-up patches. Since we'll soon need to also output the table of virtual packages, we need to teach the _is_package() function to recognise them as well. This patch is the first step into that direction: it introduces a new function _is_real_package() that is just a wrapper to _is_package(), which gains a new parameter, being the type of packages to filter on. No behavioural change is made in this patch, it is just a preparatory patch. Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Cc: Samuel Martin <s.martin49@gmail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> |
||
---|---|---|
.. | ||
apply-patches.sh | ||
build-ext3-img | ||
check-kernel-headers.sh | ||
eclipse-register-toolchain | ||
gen-manual-lists.py | ||
graph-build-time | ||
graph-depends | ||
kconfiglib.py | ||
mkmakefile | ||
mkusers | ||
pkg-stats | ||
readme.kconfiglib | ||
scancpan | ||
setlocalversion | ||
xorg-release |
Readme ====== Kconfiglib ---------- This python module, developped by Ulf Magnusson and released under the ISC license, is fetched from: https://github.com/ulfalizer/Kconfiglib commit: 02103fba9ae32a78291af53e50ee5d4bb3f69c1e Kconfiglib license ~~~~~~~~~~~~~~~~~~ License (ISC) Copyright (c) 2011-2013, Ulf Magnusson <ulfalizer@gmail.com> Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted, provided that the above copyright notice and this permission notice appear in all copies. THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.