add nonstop, uc and ucf to build, plus scripts include-recipes.sh and show-package.sh
This commit is contained in:
parent
dc4f61cc8e
commit
6258becc3c
|
@ -13,6 +13,9 @@ PREFIX_BINARY?=1
|
||||||
REPO_BINARY?=0
|
REPO_BINARY?=0
|
||||||
## Name of the configuration to include in the image name e.g. desktop or server
|
## Name of the configuration to include in the image name e.g. desktop or server
|
||||||
CONFIG_NAME?=desktop
|
CONFIG_NAME?=desktop
|
||||||
|
## Ignore errors when building the repo, attempt to build every package
|
||||||
|
## REPO_NONSTOP?=--nonstop
|
||||||
|
REPO_NONSTOP?=
|
||||||
## Select filesystem config
|
## Select filesystem config
|
||||||
ifeq ($(BOARD),)
|
ifeq ($(BOARD),)
|
||||||
FILESYSTEM_CONFIG?=config/$(ARCH)/$(CONFIG_NAME).toml
|
FILESYSTEM_CONFIG?=config/$(ARCH)/$(CONFIG_NAME).toml
|
||||||
|
|
10
mk/repo.mk
10
mk/repo.mk
|
@ -16,7 +16,7 @@ else
|
||||||
export PATH="$(PREFIX_PATH):$$PATH" && \
|
export PATH="$(PREFIX_PATH):$$PATH" && \
|
||||||
PACKAGES="$$($(INSTALLER) --list-packages -c $(FILESYSTEM_CONFIG))" && \
|
PACKAGES="$$($(INSTALLER) --list-packages -c $(FILESYSTEM_CONFIG))" && \
|
||||||
cd cookbook && \
|
cd cookbook && \
|
||||||
./repo.sh "$${PACKAGES}"
|
./repo.sh $(REPO_NONSTOP) "$${PACKAGES}"
|
||||||
mkdir -p $(BUILD)
|
mkdir -p $(BUILD)
|
||||||
# make sure fetch.tag is newer than the things repo modifies
|
# make sure fetch.tag is newer than the things repo modifies
|
||||||
touch $<
|
touch $<
|
||||||
|
@ -72,3 +72,11 @@ cr.%: $(FSTOOLS_TAG) FORCE
|
||||||
ucr.%: $(FSTOOLS_TAG) FORCE
|
ucr.%: $(FSTOOLS_TAG) FORCE
|
||||||
$(MAKE) u.$*
|
$(MAKE) u.$*
|
||||||
$(MAKE) cr.$*
|
$(MAKE) cr.$*
|
||||||
|
|
||||||
|
uc.%: $(FSTOOLS_TAG) FORCE
|
||||||
|
$(MAKE) u.$*
|
||||||
|
$(MAKE) c.$*
|
||||||
|
|
||||||
|
ucf.%: (FSTOOLS_TAG) FORCE
|
||||||
|
$(MAKE) uc.$*
|
||||||
|
$(MAKE) f.$*
|
||||||
|
|
23
scripts/include-recipes.sh
Executable file
23
scripts/include-recipes.sh
Executable file
|
@ -0,0 +1,23 @@
|
||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
# Given a string, find recipe.toml files containing that string.
|
||||||
|
# Create a list that can be copy/pasted into a filesystem config.
|
||||||
|
|
||||||
|
if [ -z "$*" ]
|
||||||
|
then
|
||||||
|
echo "Find matching recipes, and format for inclusion in config"
|
||||||
|
echo "Usage: $0 \"pattern\""
|
||||||
|
echo "Must be run from 'redox' directory"
|
||||||
|
echo "e.g. $0 \"TODO.*error\""
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
cookbook_recipes="cookbook/recipes"
|
||||||
|
recipe_paths=$(grep -rl "$*" "$cookbook_recipes" --include recipe.toml)
|
||||||
|
|
||||||
|
for recipe_path in $recipe_paths
|
||||||
|
do
|
||||||
|
recipe_dir="$(dirname $recipe_path)"
|
||||||
|
recipe_name="$(basename $recipe_dir)"
|
||||||
|
echo "$recipe_name = {} # " $(grep "$*" $recipe_path)
|
||||||
|
done
|
26
scripts/show-package.sh
Executable file
26
scripts/show-package.sh
Executable file
|
@ -0,0 +1,26 @@
|
||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
# Show the contents of the stage and sysroot folders in some recipe
|
||||||
|
|
||||||
|
if [ -z "$*" ]
|
||||||
|
then
|
||||||
|
echo "Show the contents of the stage and sysroot folders in recipe(s)"
|
||||||
|
echo "Usage: $0 recipe1 ..."
|
||||||
|
echo "Must be run from the 'redox' directory"
|
||||||
|
echo "e.g. $0 kernel"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
find_recipe="target/release/find_recipe"
|
||||||
|
if [ ! -x "cookbook/$find_recipe" ]
|
||||||
|
then
|
||||||
|
echo "$find_recipe not found."
|
||||||
|
echo "Please run 'make fstools' and try again."
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
for recipe in $*
|
||||||
|
do
|
||||||
|
recipe_dir="$(cd cookbook; "$find_recipe" "$recipe")"
|
||||||
|
ls -1 "cookbook/$recipe_dir/target"/*/{stage,sysroot}
|
||||||
|
done
|
Loading…
Reference in a new issue