From 093d5f5ab10d04d928f10a042d27ad6025ccacde Mon Sep 17 00:00:00 2001 From: Eike Ziller Date: Thu, 12 Nov 2020 16:08:06 +0100 Subject: Build in release mode on GitHub Add option to build scripts to override build type, so it can be freely chosen. Build in release mode on GitHub - RelWithDebInfo was too big. Amends b1640074e3630fff8d510c0f96efdfcfeedb93a1 Change-Id: Ibba6e60d4e9b2eee24e789bfd28bddffb1e782f6 Reviewed-by: Cristian Adam Reviewed-by: Tim Jenssen --- scripts/build_plugin.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'scripts/build_plugin.py') diff --git a/scripts/build_plugin.py b/scripts/build_plugin.py index f8d920dca6..a8d40424a9 100755 --- a/scripts/build_plugin.py +++ b/scripts/build_plugin.py @@ -57,7 +57,8 @@ def get_arguments(): action='store_true', default=False) parser.add_argument('--deploy', help='Installs the "Dependencies" component of the plugin.', action='store_true', default=False) - parser.add_argument('--debug', help='Enable debug builds', action='store_true', default=False) + parser.add_argument('--build-type', help='Build type to pass to CMake (defaults to RelWithDebInfo)', + default='RelWithDebInfo') return parser.parse_args() def build(args, paths): @@ -67,10 +68,9 @@ def build(args, paths): os.makedirs(paths.result) prefix_paths = [os.path.abspath(fp) for fp in args.prefix_paths] + [paths.qt_creator, paths.qt] prefix_paths = [common.to_posix_path(fp) for fp in prefix_paths] - build_type = 'Debug' if args.debug else 'RelWithDebInfo' cmake_args = ['cmake', '-DCMAKE_PREFIX_PATH=' + ';'.join(prefix_paths), - '-DCMAKE_BUILD_TYPE=' + build_type, + '-DCMAKE_BUILD_TYPE=' + args.build_type, '-DCMAKE_INSTALL_PREFIX=' + common.to_posix_path(paths.install), '-G', 'Ninja'] -- cgit v1.2.1