[U-Boot] [PATCH] buildman: make output dir configurable

Add an option to specify the output directory to override the default path '../'. This is useful for building in a ramdisk.
Signed-off-by: Daniel Schwierzeck daniel.schwierzeck@gmail.com Cc: Simon Glass sjg@chromium.org --- tools/buildman/buildman.py | 2 ++ tools/buildman/control.py | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/tools/buildman/buildman.py b/tools/buildman/buildman.py index 8822efe..0d95246 100755 --- a/tools/buildman/buildman.py +++ b/tools/buildman/buildman.py @@ -101,6 +101,8 @@ parser.add_option('-T', '--threads', type='int', default=None, help='Number of builder threads to use') parser.add_option('-u', '--show_unknown', action='store_true', default=False, help='Show boards with unknown build result') +parser.add_option('-o', '--output-dir', type='string', + dest='output_dir', default='..', help='Output directory')
parser.usage = """buildman -b <branch> [options]
diff --git a/tools/buildman/control.py b/tools/buildman/control.py index 8e6a08f..d2f4102 100644 --- a/tools/buildman/control.py +++ b/tools/buildman/control.py @@ -145,7 +145,7 @@ def DoBuildman(options, args): options.step = len(series.commits) - 1
# Create a new builder with the selected options - output_dir = os.path.join('..', options.branch) + output_dir = os.path.join(options.output_dir, options.branch) builder = Builder(toolchains, output_dir, options.git_dir, options.threads, options.jobs, checkout=True, show_unknown=options.show_unknown, step=options.step)

Hi Daniel,
On 28 March 2014 14:46, Daniel Schwierzeck daniel.schwierzeck@gmail.comwrote:
Add an option to specify the output directory to override the default path '../'. This is useful for building in a ramdisk.
Signed-off-by: Daniel Schwierzeck daniel.schwierzeck@gmail.com Cc: Simon Glass sjg@chromium.org
tools/buildman/buildman.py | 2 ++ tools/buildman/control.py | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/tools/buildman/buildman.py b/tools/buildman/buildman.py index 8822efe..0d95246 100755 --- a/tools/buildman/buildman.py +++ b/tools/buildman/buildman.py @@ -101,6 +101,8 @@ parser.add_option('-T', '--threads', type='int', default=None, help='Number of builder threads to use') parser.add_option('-u', '--show_unknown', action='store_true', default=False, help='Show boards with unknown build result') +parser.add_option('-o', '--output-dir', type='string',
dest='output_dir', default='..', help='Output directory')
Can you expand the help here a bit? This is the directory where all the builds happen, with a separate sub-directory for each commit. It also holds the working directory (.bm-work). So maybe 'Build output directory, also used for working space' ?
parser.usage = """buildman -b <branch> [options]
diff --git a/tools/buildman/control.py b/tools/buildman/control.py index 8e6a08f..d2f4102 100644 --- a/tools/buildman/control.py +++ b/tools/buildman/control.py @@ -145,7 +145,7 @@ def DoBuildman(options, args): options.step = len(series.commits) - 1
# Create a new builder with the selected options
- output_dir = os.path.join('..', options.branch)
- output_dir = os.path.join(options.output_dir, options.branch) builder = Builder(toolchains, output_dir, options.git_dir, options.threads, options.jobs, checkout=True, show_unknown=options.show_unknown, step=options.step)
-- 1.8.3.2
Regards, Simon

2014-04-08 21:35 GMT+02:00 Simon Glass sjg@chromium.org:
Hi Daniel,
On 28 March 2014 14:46, Daniel Schwierzeck daniel.schwierzeck@gmail.com wrote:
Add an option to specify the output directory to override the default path '../'. This is useful for building in a ramdisk.
Signed-off-by: Daniel Schwierzeck daniel.schwierzeck@gmail.com Cc: Simon Glass sjg@chromium.org
tools/buildman/buildman.py | 2 ++ tools/buildman/control.py | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/tools/buildman/buildman.py b/tools/buildman/buildman.py index 8822efe..0d95246 100755 --- a/tools/buildman/buildman.py +++ b/tools/buildman/buildman.py @@ -101,6 +101,8 @@ parser.add_option('-T', '--threads', type='int', default=None, help='Number of builder threads to use') parser.add_option('-u', '--show_unknown', action='store_true', default=False, help='Show boards with unknown build result') +parser.add_option('-o', '--output-dir', type='string',
dest='output_dir', default='..', help='Output directory')
Can you expand the help here a bit? This is the directory where all the builds happen, with a separate sub-directory for each commit. It also holds the working directory (.bm-work). So maybe 'Build output directory, also used for working space' ?
sure. How about that?
-o OUTPUT_DIR, --output-dir=OUTPUT_DIR Directory where all builds happen and buildman has its workspace (default is ../)

Hi Daniel,
On 8 April 2014 12:52, Daniel Schwierzeck daniel.schwierzeck@gmail.comwrote:
2014-04-08 21:35 GMT+02:00 Simon Glass sjg@chromium.org:
Hi Daniel,
On 28 March 2014 14:46, Daniel Schwierzeck <daniel.schwierzeck@gmail.com
wrote:
Add an option to specify the output directory to override the default path '../'. This is useful for building in a ramdisk.
Signed-off-by: Daniel Schwierzeck daniel.schwierzeck@gmail.com Cc: Simon Glass sjg@chromium.org
tools/buildman/buildman.py | 2 ++ tools/buildman/control.py | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/tools/buildman/buildman.py b/tools/buildman/buildman.py index 8822efe..0d95246 100755 --- a/tools/buildman/buildman.py +++ b/tools/buildman/buildman.py @@ -101,6 +101,8 @@ parser.add_option('-T', '--threads', type='int', default=None, help='Number of builder threads to use') parser.add_option('-u', '--show_unknown', action='store_true', default=False, help='Show boards with unknown build result') +parser.add_option('-o', '--output-dir', type='string',
dest='output_dir', default='..', help='Output directory')
Can you expand the help here a bit? This is the directory where all the builds happen, with a separate sub-directory for each commit. It also
holds
the working directory (.bm-work). So maybe 'Build output directory, also used for working space' ?
sure. How about that?
-o OUTPUT_DIR, --output-dir=OUTPUT_DIR Directory where all builds happen and buildman has its workspace (default is ../)
SGTM
- Simon

Add an option to specify the output directory to override the default path '../'. This is useful for building in a ramdisk.
Signed-off-by: Daniel Schwierzeck daniel.schwierzeck@gmail.com Cc: Simon Glass sjg@chromium.org --- Changes for v2: - improved help message --- tools/buildman/buildman.py | 3 +++ tools/buildman/control.py | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-)
diff --git a/tools/buildman/buildman.py b/tools/buildman/buildman.py index 8822efe..73a5483 100755 --- a/tools/buildman/buildman.py +++ b/tools/buildman/buildman.py @@ -101,6 +101,9 @@ parser.add_option('-T', '--threads', type='int', default=None, help='Number of builder threads to use') parser.add_option('-u', '--show_unknown', action='store_true', default=False, help='Show boards with unknown build result') +parser.add_option('-o', '--output-dir', type='string', + dest='output_dir', default='..', + help='Directory where all builds happen and buildman has its workspace (default is ../)')
parser.usage = """buildman -b <branch> [options]
diff --git a/tools/buildman/control.py b/tools/buildman/control.py index 8e6a08f..d2f4102 100644 --- a/tools/buildman/control.py +++ b/tools/buildman/control.py @@ -145,7 +145,7 @@ def DoBuildman(options, args): options.step = len(series.commits) - 1
# Create a new builder with the selected options - output_dir = os.path.join('..', options.branch) + output_dir = os.path.join(options.output_dir, options.branch) builder = Builder(toolchains, output_dir, options.git_dir, options.threads, options.jobs, checkout=True, show_unknown=options.show_unknown, step=options.step)

On 17 April 2014 13:13, Daniel Schwierzeck daniel.schwierzeck@gmail.com wrote:
Add an option to specify the output directory to override the default path '../'. This is useful for building in a ramdisk.
Signed-off-by: Daniel Schwierzeck daniel.schwierzeck@gmail.com Cc: Simon Glass sjg@chromium.org
Thanks.
Acked-by: Simon Glass sjg@chromium.org

On Thu, Apr 17, 2014 at 09:13:11PM +0200, Daniel Schwierzeck wrote:
Add an option to specify the output directory to override the default path '../'. This is useful for building in a ramdisk.
Signed-off-by: Daniel Schwierzeck daniel.schwierzeck@gmail.com Cc: Simon Glass sjg@chromium.org Acked-by: Simon Glass sjg@chromium.org
Applied to u-boot/master, thanks!
participants (3)
-
Daniel Schwierzeck
-
Simon Glass
-
Tom Rini