From 4e2caf1e383a8e90d874b1c086343703f91475d9 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Mon, 6 Mar 2023 10:03:41 +0200 Subject: Add --debian-build-option to pass additional options to dpkg-buildpackage --- bpkg/pkg-bindist.cli | 7 +++++++ bpkg/system-package-manager-debian.cxx | 5 +++++ 2 files changed, 12 insertions(+) diff --git a/bpkg/pkg-bindist.cli b/bpkg/pkg-bindist.cli index abf578b..aa66796 100644 --- a/bpkg/pkg-bindist.cli +++ b/bpkg/pkg-bindist.cli @@ -77,6 +77,13 @@ namespace bpkg options, if any, are used as configured." } + strings --debian-build-option + { + "", + "Additional option to pass to the \cb{dpkg-buildpackage} program. Repeat + this option to specify multiple build options." + } + string --debian-build-meta { "", diff --git a/bpkg/system-package-manager-debian.cxx b/bpkg/system-package-manager-debian.cxx index 92a32f9..3fb93c3 100644 --- a/bpkg/system-package-manager-debian.cxx +++ b/bpkg/system-package-manager-debian.cxx @@ -3145,6 +3145,11 @@ namespace bpkg args.push_back ((jobs_arg = "--jobs=" + to_string (n)).c_str ()); } + // Pass any additional options specified by the user. + // + for (const string& o: ops_->debian_build_option ()) + args.push_back (o.c_str ()); + args.push_back (nullptr); if (ops_->debian_prepare_only ()) -- cgit v1.1