File tree Expand file tree Collapse file tree 1 file changed +18
-2
lines changed
utils/cmpcodesize/cmpcodesize Expand file tree Collapse file tree 1 file changed +18
-2
lines changed Original file line number Diff line number Diff line change @@ -107,6 +107,18 @@ def main():
107
107
'other programs.' ,
108
108
action = 'store_true' ,
109
109
default = False )
110
+ parser .add_argument ('-o' , '--old-build-directory' ,
111
+ help = 'The directory containing the baseline objects ' +
112
+ 'against which to compare sizes.' ,
113
+ action = 'store' ,
114
+ dest = 'old_build_dir' ,
115
+ default = None )
116
+ parser .add_argument ('-n' , '--new-build-directory' ,
117
+ help = 'The directory containing the new objects whose' +
118
+ 'sizes are to be compared against the baseline.' ,
119
+ action = 'store' ,
120
+ dest = 'new_build_dir' ,
121
+ default = None )
110
122
111
123
# Positional arguments.
112
124
# These can be specified in means beyond what argparse supports,
@@ -145,8 +157,12 @@ def main():
145
157
else :
146
158
old_file_args = parsed_arguments .files
147
159
148
- old_build_dir = os .environ .get ("SWIFT_OLD_BUILDDIR" )
149
- new_build_dir = os .environ .get ("SWIFT_NEW_BUILDDIR" )
160
+ old_build_dir = parsed_arguments .old_build_dir
161
+ if not old_build_dir :
162
+ old_build_dir = os .environ .get ("SWIFT_OLD_BUILDDIR" )
163
+ new_build_dir = parsed_arguments .new_build_dir
164
+ if not new_build_dir :
165
+ new_build_dir = os .environ .get ("SWIFT_NEW_BUILDDIR" )
150
166
151
167
if not parsed_arguments .files :
152
168
assert old_build_dir and new_build_dir , \
You can’t perform that action at this time.
0 commit comments