build_haiku_image: Distinguish between system (activated) and unactivated packages.
Previously, all packages on the image, both activated and unactivated, were in $systemPackages, so if a package actually in /system/packages had a dependency in the Installer optional package area, the dependency checking would see no problem but the generated image would be broken. Now, packages going into /system/packages are treated separately from those going elsewhere, and error checks added so the above condition will not occur. (I ran into this while working on the build-package upgrade in the following commits.)
This commit is contained in:
+21
-7
@@ -887,13 +887,20 @@ rule AddPackagesAndRepositoryVariablesToContainerScript script : container
|
||||
: $(HAIKU_UPDATE_ALL_PACKAGES) ;
|
||||
|
||||
# Add variable "systemPackages" with the packages copied/updated.
|
||||
local allPackages = [ on $(container) return $(HAIKU_PACKAGES_IN_IMAGE) ] ;
|
||||
local systemPackages = [ on $(container) return $(HAIKU_SYSTEM_PACKAGES_IN_IMAGE) ] ;
|
||||
if $(updateOnly) && ! [ IncludeAllTargetsInContainer $(container) ] {
|
||||
allPackages = [ FilterContainerUpdateTargets $(allPackages)
|
||||
systemPackages = [ FilterContainerUpdateTargets $(systemPackages)
|
||||
: [ on $(container) return $(HAIKU_INCLUDE_IN_CONTAINER_VAR) ] ] ;
|
||||
}
|
||||
AddTargetVariableToScript $(script) : $(systemPackages) : systemPackages ;
|
||||
|
||||
AddTargetVariableToScript $(script) : $(allPackages) : systemPackages ;
|
||||
# Add variable "otherPackages" with the packages copied/updated.
|
||||
local otherPackages = [ on $(container) return $(HAIKU_OTHER_PACKAGES_IN_IMAGE) ] ;
|
||||
if $(updateOnly) && ! [ IncludeAllTargetsInContainer $(container) ] {
|
||||
otherPackages = [ FilterContainerUpdateTargets $(otherPackages)
|
||||
: [ on $(container) return $(HAIKU_INCLUDE_IN_CONTAINER_VAR) ] ] ;
|
||||
}
|
||||
AddTargetVariableToScript $(script) : $(otherPackages) : otherPackages ;
|
||||
|
||||
# Generate the repository package lists and add variables for the
|
||||
# repositories.
|
||||
@@ -1036,9 +1043,16 @@ rule AddPackageFilesToHaikuImage location : packages : flags
|
||||
# info
|
||||
|
||||
packages = [ FFilterByBuildFeatures $(packages) ] ;
|
||||
HAIKU_PACKAGES_IN_IMAGE on $(HAIKU_IMAGE_CONTAINER_NAME)
|
||||
= [ on $(HAIKU_IMAGE_CONTAINER_NAME) return $(HAIKU_PACKAGES_IN_IMAGE) ]
|
||||
$(packages) ;
|
||||
|
||||
if $(location[1]) = system && $(location[2]) = packages && ! $(location[3]) {
|
||||
HAIKU_SYSTEM_PACKAGES_IN_IMAGE on $(HAIKU_IMAGE_CONTAINER_NAME)
|
||||
= [ on $(HAIKU_IMAGE_CONTAINER_NAME) return $(HAIKU_SYSTEM_PACKAGES_IN_IMAGE) ]
|
||||
$(packages) ;
|
||||
} else {
|
||||
HAIKU_OTHER_PACKAGES_IN_IMAGE on $(HAIKU_IMAGE_CONTAINER_NAME)
|
||||
= [ on $(HAIKU_IMAGE_CONTAINER_NAME) return $(HAIKU_OTHER_PACKAGES_IN_IMAGE) ]
|
||||
$(packages) ;
|
||||
}
|
||||
|
||||
if nameFromMetaInfo in $(flags) {
|
||||
AddFilesToHaikuImage $(location) : $(packages)
|
||||
@@ -1570,7 +1584,7 @@ rule BuildCDBootImage image : bootfloppy : bootefi : extrafiles
|
||||
Depends $(image) : $(bootefi) ;
|
||||
Depends $(image) : $(extrafiles) ;
|
||||
BOOTIMG on $(image) = $(bootfloppy) ;
|
||||
|
||||
|
||||
if $(HAIKU_NIGHTLY_BUILD) = 1 {
|
||||
VOLID on $(image) = haiku-nightly-$(TARGET_ARCH) ;
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user