summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVladimir Prus <vladimir.prus@gmail.com>2016-10-28 11:30:41 +0300
committerRene Rivera <grafikrobot@gmail.com>2016-11-03 12:54:59 -0500
commit235330995e2be4d47bc3da346ea34e927e6950a9 (patch)
tree19bcf5096490feff87cc9ba87eb986a3b625b163
parentdf4be667f0b27aca90e91e4333d42a70e60063d8 (diff)
downloadboost-235330995e2be4d47bc3da346ea34e927e6950a9.tar.gz
Support additional tagging of binaries by Python version.
-rw-r--r--Jamroot5
-rw-r--r--boostcpp.jam13
2 files changed, 18 insertions, 0 deletions
diff --git a/Jamroot b/Jamroot
index 4a73899267..e669186821 100644
--- a/Jamroot
+++ b/Jamroot
@@ -182,6 +182,11 @@ rule tag ( name : type ? : property-set )
return [ boostcpp.tag $(name) : $(type) : $(property-set) ] ;
}
+rule python-tag ( name : type ? : property-set )
+{
+ return [ boostcpp.python-tag $(name) : $(type) : $(property-set) ] ;
+}
+
rule handle-static-runtime ( properties * )
{
# Using static runtime with shared libraries is impossible on Linux, and
diff --git a/boostcpp.jam b/boostcpp.jam
index f45d12ef2f..38113c46c6 100644
--- a/boostcpp.jam
+++ b/boostcpp.jam
@@ -163,6 +163,19 @@ rule tag ( name : type ? : property-set )
}
}
+# Specialized tag function to use for libraries linking to Python.
+# Appends value of --python-buildid if provided.
+rule python-tag ( name : type ? : property-set )
+{
+ local result = $(name) ;
+ if $(type) in STATIC_LIB SHARED_LIB IMPORT_LIB && $(PYTHON_ID)
+ {
+ result = $(result)-$(PYTHON_ID) ;
+ }
+
+ # forward to the boost tagging rule
+ return [ tag $(result) : $(type) : $(property-set) ] ;
+}
################################################################################
#