From 46760580031d8ba37098ed1fa1c9c6e3fc8e706e Mon Sep 17 00:00:00 2001 From: Matt Madia Date: Wed, 23 Jun 2010 21:27:45 +0000 Subject: [PATCH] Record the installed optional packages to common/data/InstalledPackages. This will be utilized by installoptionalpackage, to determine which packages are already installed in the system and thus should not prevent the installation of other packages. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@37239 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- build/jam/HaikuImage | 4 ++++ build/jam/ImageRules | 16 ++++++++++++++++ 2 files changed, 20 insertions(+) diff --git a/build/jam/HaikuImage b/build/jam/HaikuImage index 08b19aa185..f7b921cf67 100644 --- a/build/jam/HaikuImage +++ b/build/jam/HaikuImage @@ -317,6 +317,10 @@ AddFilesToHaikuImage system bin : installoptionalpackage ; SEARCH on install-wifi-firmwares.sh = [ FDirName $(HAIKU_TOP) data bin ] ; AddFilesToHaikuImage system bin : install-wifi-firmwares.sh ; +# Record the installed optional packages. To be used by installoptionalpackage. +AddDirectoryToHaikuImage common data optional-packages ; +AddInstalledPackagesFileToHaikuImage ; + AddSymlinkToHaikuImage system bin : bash : sh ; AddSymlinkToHaikuImage system bin : trash : untrash ; diff --git a/build/jam/ImageRules b/build/jam/ImageRules index e762725fac..592d3da2ac 100644 --- a/build/jam/ImageRules +++ b/build/jam/ImageRules @@ -926,6 +926,22 @@ rule AddExpanderRuleToHaikuImage mimetype : extension : list : extract : $(entry) ; } +rule AddInstalledPackagesFileToHaikuImage +{ + #AddInstalledPackagesFileToHaikuImage + local file = InstalledPackages ; + + Always $(file) ; + MakeLocate $(file) : $(HAIKU_COMMON_PLATFORM_OBJECT_DIR) ; + BuildHaikuImageInstalledPackagesFile $(file) ; + AddFilesToHaikuImage common data : $(file) ; +} + +actions BuildHaikuImageInstalledPackagesFile +{ + echo -e "$(HAIKU_ADDED_OPTIONAL_PACKAGES)" | tr '\ ' '\n' > $(1) +} + rule AddOptionalPackageDescriptionToHaikuImage file : searchPath { if $(searchPath) {