mirror of
https://review.haiku-os.org/haiku
synced 2024-11-23 15:28:58 +01:00
Introduced rules UserBuildConfigRulePostBuildTargets,
UserBuildConfigRulePreImage, and UserBuildConfigRulePostImage which will be invoked at different points in the build system execution. They can be overridden in UserBuildConfig, thus allowing for executing user code at those points. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28765 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
parent
4a3ec9b6a4
commit
30ed37c845
5
Jamrules
5
Jamrules
@ -45,6 +45,11 @@ include [ FDirName $(HAIKU_BUILD_RULES_DIR) PackageRules ] ;
|
||||
include [ FDirName $(HAIKU_BUILD_RULES_DIR) TestsRules ] ;
|
||||
include [ FDirName $(HAIKU_BUILD_RULES_DIR) BuildSetup ] ;
|
||||
|
||||
# Declare no-op user-overridable build rules.
|
||||
rule UserBuildConfigRulePostBuildTargets { }
|
||||
rule UserBuildConfigRulePreImage { }
|
||||
rule UserBuildConfigRulePostImage { }
|
||||
|
||||
# Include UserBuildConfig.
|
||||
{
|
||||
local userBuildConfig
|
||||
|
@ -606,6 +606,9 @@ if $(HAIKU_IMAGE_HOST_NAME) {
|
||||
#pragma mark - Build The Image
|
||||
|
||||
|
||||
# Execute pre-image user config rules.
|
||||
UserBuildConfigRulePreImage ;
|
||||
|
||||
# Set image name and directory defaults and locate the image.
|
||||
HAIKU_IMAGE_NAME ?= $(HAIKU_DEFAULT_IMAGE_NAME) ;
|
||||
HAIKU_IMAGE_DIR ?= $(HAIKU_DEFAULT_IMAGE_DIR) ;
|
||||
@ -716,3 +719,6 @@ MakeLocate $(HAIKU_VMWARE_IMAGE) : $(HAIKU_IMAGE_DIR) ;
|
||||
_BuildHaikuImage $(HAIKU_VMWARE_IMAGE) : true : true ;
|
||||
NotFile haiku-vmware-image ;
|
||||
Depends haiku-vmware-image : $(HAIKU_VMWARE_IMAGE) ;
|
||||
|
||||
# Execute post-image user config rules.
|
||||
UserBuildConfigRulePostImage ;
|
||||
|
@ -12,14 +12,6 @@
|
||||
Exit You must NOT copy UserBuildConfig.ReadMe directly but use parts of it! ;
|
||||
|
||||
|
||||
# Adding timezone and keymap settings
|
||||
AddSymlinkToHaikuImage home config settings
|
||||
: /boot/beos/etc/timezones/Europe/Paris : timezone ;
|
||||
|
||||
AddFilesToHaikuImage home config settings : <keymap>US-International
|
||||
: Key_map ;
|
||||
|
||||
|
||||
# Adjusting Build Variables
|
||||
|
||||
# The following variables can be configured per subdirectory (or subtree) or
|
||||
@ -99,6 +91,11 @@ AddFilesToHaikuImage beos bin : crashing_app ;
|
||||
# Make a symlink to home/config/bin/crash.
|
||||
AddSymlinkToHaikuImage home config bin : /beos/bin/crashing_app : crash ;
|
||||
|
||||
# Add timezone and keymap settings.
|
||||
AddSymlinkToHaikuImage home config settings
|
||||
: /boot/beos/etc/timezones/Europe/Paris : timezone ;
|
||||
AddFilesToHaikuImage home config settings : <keymap>US-International : Key_map ;
|
||||
|
||||
# Adds the source directories src/kits/storage and src/tests/servers/debug
|
||||
# (recursively) to the image (as /boot/home/HaikuSources/src/kits/storage
|
||||
# and /boot/home/HaikuSources/src/tests/servers/debug respectively).
|
||||
@ -284,3 +281,24 @@ DeferredSubInclude HAIKU_TOP src tests add-ons kernel file_systems
|
||||
# usual). Omitting this parameter or specifying "global" will cause the given
|
||||
# name to be used recursively.
|
||||
DeferredSubInclude HAIKU_TOP src 3rdparty myproject : Jamfile.haiku : local ;
|
||||
|
||||
# The following rules can be overriden to do things at different points of
|
||||
# the build system execution by jam (note: we're talking about execution of
|
||||
# Jamfiles, not the build actions they define):
|
||||
#
|
||||
# UserBuildConfigRulePostBuildTargets:
|
||||
# Executed after the complete Jamfile tree has been processed. I.e. all build
|
||||
# targets are known and located at this point.
|
||||
# UserBuildConfigRulePreImage:
|
||||
# Executed after the contents of the Haiku image has been defined, but before
|
||||
# the scripts generating the images are defined.
|
||||
# UserBuildConfigRulePostImage:
|
||||
# Executed after the Haiku image build target has been fully defined.
|
||||
#
|
||||
# E.g. making use of the fact that all targets have already been located when
|
||||
# UserBuildConfigRulePostBuildTargets is called, we can print the directory
|
||||
# where the StyledEdit executable will be generated.
|
||||
rule UserBuildConfigRulePostBuildTargets
|
||||
{
|
||||
Echo "StyledEdit will appear here:" [ on StyledEdit return $(LOCATE) ] ;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user