summaryrefslogtreecommitdiff
path: root/talerbuildconfig.py
diff options
context:
space:
mode:
authorng0 <ng0@n0.is>2019-12-14 13:43:13 +0000
committerng0 <ng0@n0.is>2019-12-14 13:43:13 +0000
commit6d8322d57cb8f9ded3528b456a47d93b37be00e2 (patch)
tree67c7c4c34ffe31ef690516b78ae21ba7de740eee /talerbuildconfig.py
parentd725a0cd1b4aa3ff54452a702b8c19db3f3c3393 (diff)
downloadbuild-common-6d8322d57cb8f9ded3528b456a47d93b37be00e2.tar.gz
build-common-6d8322d57cb8f9ded3528b456a47d93b37be00e2.tar.bz2
build-common-6d8322d57cb8f9ded3528b456a47d93b37be00e2.zip
add '--variant' to set installation directory.
possibly a bad naming choice, but it enables varying directories for stage vs www.
Diffstat (limited to 'talerbuildconfig.py')
-rw-r--r--talerbuildconfig.py11
1 files changed, 11 insertions, 0 deletions
diff --git a/talerbuildconfig.py b/talerbuildconfig.py
index da063b9..b444513 100644
--- a/talerbuildconfig.py
+++ b/talerbuildconfig.py
@@ -77,6 +77,10 @@ class BuildConfig:
"""If enabled, process the --prefix argument."""
self.prefix_enabled = True
+ def enable_variant(self):
+ """If enable, process the --variant argument."""
+ self.variant_enabled = False
+
def enable_configmk(self):
"""If enabled, output the config.mk makefile fragment."""
self.configmk_enabled = True
@@ -90,6 +94,13 @@ class BuildConfig:
default="/usr/local",
help="Directory prefix for installation",
)
+ if self.variant_enabled:
+ parser.add_argument(
+ "--variant",
+ type=str,
+ default="",
+ help="Directory for installation",
+ )
for tool in self.tools:
tool.args(parser)
args = self.args = parser.parse_args()