Change in osmo-dev[master]: add --docker-cmd argument

osmith gerrit-no-reply at
Fri Aug 13 07:30:41 UTC 2021

osmith has submitted this change. ( )

Change subject: add --docker-cmd argument
...................................................................... add --docker-cmd argument

To be used by to run the actual build inside docker.
runs the programs built by osmo-dev inside docker with the exact
configs that we use on, but so far it builds the
component outside of docker. But building inside docker is necessary to
avoid incompatibilities between the host system and the docker
containers (e.g. different glibc).

Change-Id: Ibd20f0e0e2a5105085066a9f04b5868c68691024
1 file changed, 9 insertions(+), 4 deletions(-)

  osmith: Verified
  neels: Looks good to me, approved

diff --git a/ b/
index ad42978..81d41e7 100755
--- a/
+++ b/
@@ -107,6 +107,9 @@
   default=True, action='store_false',
   help='''do not 'make check', just 'make' to build.''')
+    help='''prefix configure/make/make install calls with this command (used by''')
 args = parser.parse_args()
 class listdict(dict):
@@ -189,19 +192,19 @@
 	-chmod -R ug+w {build_proj}
 	-rm -rf {build_proj}
 	mkdir -p {build_proj}
-	cd {build_proj}; {build_to_src}/configure {configure_opts}
+	cd {build_proj}; {docker_cmd}{build_to_src}/configure {configure_opts}
 	touch $@
 .make.{proj}.build: .make.{proj}.configure $({proj}_files)
 	@echo -e "\n\n\n===== $@\n"
-	$(MAKE) -C {build_proj} -j {jobs} {check}
+	{docker_cmd}$(MAKE) -C {build_proj} -j {jobs} {check}
 	touch $@
 .make.{proj}.install: .make.{proj}.build
 	@echo -e "\n\n\n===== $@\n"
-	{sudo_make_install}$(MAKE) -C {build_proj} install
+	{docker_cmd}{sudo_make_install}$(MAKE) -C {build_proj} install
 	touch $@
@@ -235,6 +238,7 @@
     no_ldconfig='#' if no_ldconfig else '',
     sudo_ldconfig='' if ldconfig_without_sudo else 'sudo ',
     check='check' if make_check else '',
+    docker_cmd=f'{args.docker_cmd} ' if args.docker_cmd else '',
@@ -283,7 +287,7 @@
 		-o {makefile} \
 		-s {src_dir} \
 		-b {build_dir} \
-		-u "{url}"{push_url}{sudo_make_install}{no_ldconfig}{ldconfig_without_sudo}{make_check}
+		-u "{url}"{push_url}{sudo_make_install}{no_ldconfig}{ldconfig_without_sudo}{make_check}{docker_cmd}
     script=os.path.relpath(sys.argv[0], make_dir),
@@ -299,6 +303,7 @@
     no_ldconfig=' \\\n\t\t-L' if args.no_ldconfig else '',
     ldconfig_without_sudo=' \\\n\t\t--ldconfig-without-sudo' if args.ldconfig_without_sudo else '',
     make_check='' if args.make_check else " \\\n\t\t--no-make-check",
+    docker_cmd=f' \\\n\t\t--docker-cmd "{args.docker_cmd}"' if args.docker_cmd else ''
   # convenience target: clone all repositories first

To view, visit
To unsubscribe, or for help writing mail filters, visit

Gerrit-Project: osmo-dev
Gerrit-Branch: master
Gerrit-Change-Id: Ibd20f0e0e2a5105085066a9f04b5868c68691024
Gerrit-Change-Number: 25189
Gerrit-PatchSet: 2
Gerrit-Owner: osmith <osmith at>
Gerrit-Reviewer: neels <nhofmeyr at>
Gerrit-Reviewer: osmith <osmith at>
Gerrit-MessageType: merged
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the gerrit-log mailing list