# Pastebin Be0choRC #!/bin/bash class="setuptools3-base" echo "Finding recipes which inherit $class..." raw_recipes=$(bitbake-layers show-recipes --recipes-only -i $class -b | awk '!/Load|NOTE|===|Parsing/ { print $1}') #echo "$raw_recipes" recipes=$(echo -n $raw_recipes | tr '\n' ' ') #fetch_recipes=$(bitbake-layers show-recipes --recipes-only -i $class -b | awk '!/Load|NOTE|===|Parsing/ { print "-c fetch " $1}' | tr '\n' ' ') #echo "$fetch_recipes" #echo "Fetching recipes: $recipes" #bitbake ${fetch_recipes} # toml get --toml-path $(find $(bitbake-getvar S -r python3-cryptography --value) -name pyproject.toml) build-system.build-backend # toml get --toml-path $(find $(bitbake-getvar S -r python3-jsonschema --value) -maxdepth 1 -name pyproject.toml) build-system.build-backend recipes_pyprojecttoml="" recipes_setuppy="" recipes_setupcfg="" recipes_buildsystem="" #recipes="python3-cryptography python3-jsonschema" for recipe in $recipes do bitbake --no-setscene -c unpack $recipe source=$(bitbake-getvar S -r ${recipe} --value) echo "source: $source" toml=$(find $source -name pyproject.toml | xargs) if [ ! -z "$toml" ]; then recipes_pyprojecttoml="$recipes_pyprojecttoml $recipe" echo "pyproject.toml: $toml" fi setuppy=$(find $source -name setup.py | xargs) if [ ! -z "$setuppy" ]; then recipes_setuppy="$recipes_setuppy $recipe" echo "setup.py: $setuppy" fi setupcfg=$(find $source -name setup.cfg -print -quit) if [ ! -z "$setucfg" ]; then echo "setup.cfg: $setupcfg" recipes_setupcfg="$recipes_setupcfg $recipe" fi if [ ! -z "$toml" ]; then backend=$(toml get --toml-path ${toml} build-system.build-backend) echo "recipe: $recipe" echo "backend: $backend" recipes_buildsystem="$recipes_buildsystem ${recipe}:${backend}" fi done echo $recipes_pyprojecttoml echo $recipes_buildsystem