Skip to content

Add ability to read package = recipe from filesystem config

Ron Williams requested to merge rw_van/installer:rw_van_230307 into master

Adds a command line option --cooking, which enables the new functionality when combined with --cookbook.

During cooking, if all of the following conditions apply:

  • the package config in the filesystem config is package = "recipe" or package = "recipe_no_fetch"
  • the combination of options is --list-packages --cooking --cookbook= then only those packages are listed for the cookbook system to build, the other packages specified package = {} are skipped.

During install to directory, if these conditions apply:

  • the combination of options is --cooking --cookbook=
  • the package is specified as package = {} then the package is taken from the remote repo. Otherwise, it is taken from the repo built by cookbook system.

Until the makefiles are changed, these changes will have no effect. To try the changes before then, set REPO_BINARY=1, and in `mk/config.mk, edit the following:

ifeq ($(REPO_BINARY),0)
INSTALLER+=--cookbook=cookbook
REPO_TAG=$(BUILD)/repo.tag
# add these three lines
else
INSTALLER+=--cookbook=cookbook --cooking
REPO_TAG=$(BUILD)/repo.tag
endif

Support for the "recipe_no_fetch" spec not fully implemented. It will eventually allow the cookbook system to skip the fetch of source when the user is actively developing that package, instead of requiring the [source] section of the recipe to be commented out. If you would prefer not to implement that feature, let me know and I will take it out.

Merge request reports