pmbootstrap/pmb/build
Minecrell 0e27713512
pmb.parse._apkbuild: Extend APKBUILD parser to work for subpackages (!1866)
At the moment we have a simple subpkgdesc() function that can only
parse "pkgdesc" from subpackages, without support for any variables.
But we have a quite nice variable parser now that can be extended
to work for subpackages.

Simply put this works by:
  - Finding the lines that belong to the subpackage function
  - Stripping indentation (tab)
  - Parsing relevant attributes similar to the apkbuild() function

The "subpackages" in the parsed APKBUILD are replaced by a dict
of subpkgname: {"pkgdesc": "...", "depends": "..."} which are
parsed from the subpackage function (if found).
This makes it possible to get the "depends" of a subpackage.
2020-02-19 14:56:57 +03:00
..
__init__.py Change copyright to 2020 2020-01-06 02:43:00 +01:00
_package.py pmb.parse._apkbuild: Extend APKBUILD parser to work for subpackages (!1866) 2020-02-19 14:56:57 +03:00
autodetect.py Change copyright to 2020 2020-01-06 02:43:00 +01:00
checksum.py Change copyright to 2020 2020-01-06 02:43:00 +01:00
envkernel.py Change copyright to 2020 2020-01-06 02:43:00 +01:00
init.py Change copyright to 2020 2020-01-06 02:43:00 +01:00
menuconfig.py Change copyright to 2020 2020-01-06 02:43:00 +01:00
newapkbuild.py Change copyright to 2020 2020-01-06 02:43:00 +01:00
other.py Change copyright to 2020 2020-01-06 02:43:00 +01:00