summaryrefslogtreecommitdiffstats
path: root/bitbake
diff options
context:
space:
mode:
authorEd Bartosh <ed.bartosh@linux.intel.com>2016-04-25 11:16:27 +0300
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-05-06 10:12:16 +0100
commit3437266a081f6a44f40a2cc158cbd4a29a02fb35 (patch)
tree726e9b545c7268d2c474f40aedaf2ccae4af7ec9 /bitbake
parent24f5c32b805bdc58202bf4ce239fee3b3b1de365 (diff)
downloadpoky-3437266a081f6a44f40a2cc158cbd4a29a02fb35.tar.gz
bitbake: bitbake: main: fix bad-witespace pylint warnings
Fixed pylint warnings: No space allowed around keyword argument assignment No space allowed after bracket No space allowed before bracket (Bitbake rev: c39770239f7b61217501782b9c5e9d3211355d42) Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake')
-rwxr-xr-xbitbake/lib/bb/main.py138
1 files changed, 69 insertions, 69 deletions
diff --git a/bitbake/lib/bb/main.py b/bitbake/lib/bb/main.py
index b843b7dd70..c1f14be285 100755
--- a/bitbake/lib/bb/main.py
+++ b/bitbake/lib/bb/main.py
@@ -100,7 +100,7 @@ def import_extension_module(pkg, modulename, checkattr):
100 # Dynamically load the UI based on the ui name. Although we 100 # Dynamically load the UI based on the ui name. Although we
101 # suggest a fixed set this allows you to have flexibility in which 101 # suggest a fixed set this allows you to have flexibility in which
102 # ones are available. 102 # ones are available.
103 module = __import__(pkg.__name__, fromlist = [modulename]) 103 module = __import__(pkg.__name__, fromlist=[modulename])
104 return getattr(module, modulename) 104 return getattr(module, modulename)
105 except AttributeError: 105 except AttributeError:
106 raise BBMainException('FATAL: Unable to import extension module "%s" from %s. Valid extension modules: %s' % (modulename, pkg.__name__, present_options(list_extension_modules(pkg, checkattr)))) 106 raise BBMainException('FATAL: Unable to import extension module "%s" from %s. Valid extension modules: %s' % (modulename, pkg.__name__, present_options(list_extension_modules(pkg, checkattr))))
@@ -129,111 +129,111 @@ class BitBakeConfigParameters(cookerdata.ConfigParameters):
129 129
130 def parseCommandLine(self, argv=sys.argv): 130 def parseCommandLine(self, argv=sys.argv):
131 parser = optparse.OptionParser( 131 parser = optparse.OptionParser(
132 formatter = BitbakeHelpFormatter(), 132 formatter=BitbakeHelpFormatter(),
133 version = "BitBake Build Tool Core version %s" % bb.__version__, 133 version="BitBake Build Tool Core version %s" % bb.__version__,
134 usage = """%prog [options] [recipename/target recipe:do_task ...] 134 usage="""%prog [options] [recipename/target recipe:do_task ...]
135 135
136 Executes the specified task (default is 'build') for a given set of target recipes (.bb files). 136 Executes the specified task (default is 'build') for a given set of target recipes (.bb files).
137 It is assumed there is a conf/bblayers.conf available in cwd or in BBPATH which 137 It is assumed there is a conf/bblayers.conf available in cwd or in BBPATH which
138 will provide the layer, BBFILES and other configuration information.""") 138 will provide the layer, BBFILES and other configuration information.""")
139 139
140 parser.add_option("-b", "--buildfile", help = "Execute tasks from a specific .bb recipe directly. WARNING: Does not handle any dependencies from other recipes.", 140 parser.add_option("-b", "--buildfile", help="Execute tasks from a specific .bb recipe directly. WARNING: Does not handle any dependencies from other recipes.",
141 action = "store", dest = "buildfile", default = None) 141 action="store", dest="buildfile", default=None)
142 142
143 parser.add_option("-k", "--continue", help = "Continue as much as possible after an error. While the target that failed and anything depending on it cannot be built, as much as possible will be built before stopping.", 143 parser.add_option("-k", "--continue", help="Continue as much as possible after an error. While the target that failed and anything depending on it cannot be built, as much as possible will be built before stopping.",
144 action = "store_false", dest = "abort", default = True) 144 action="store_false", dest="abort", default=True)
145 145
146 parser.add_option("-a", "--tryaltconfigs", help = "Continue with builds by trying to use alternative providers where possible.", 146 parser.add_option("-a", "--tryaltconfigs", help="Continue with builds by trying to use alternative providers where possible.",
147 action = "store_true", dest = "tryaltconfigs", default = False) 147 action="store_true", dest="tryaltconfigs", default=False)
148 148
149 parser.add_option("-f", "--force", help = "Force the specified targets/task to run (invalidating any existing stamp file).", 149 parser.add_option("-f", "--force", help="Force the specified targets/task to run (invalidating any existing stamp file).",
150 action = "store_true", dest = "force", default = False) 150 action="store_true", dest="force", default=False)
151 151
152 parser.add_option("-c", "--cmd", help = "Specify the task to execute. The exact options available depend on the metadata. Some examples might be 'compile' or 'populate_sysroot' or 'listtasks' may give a list of the tasks available.", 152 parser.add_option("-c", "--cmd", help="Specify the task to execute. The exact options available depend on the metadata. Some examples might be 'compile' or 'populate_sysroot' or 'listtasks' may give a list of the tasks available.",
153 action = "store", dest = "cmd") 153 action="store", dest="cmd")
154 154
155 parser.add_option("-C", "--clear-stamp", help = "Invalidate the stamp for the specified task such as 'compile' and then run the default task for the specified target(s).", 155 parser.add_option("-C", "--clear-stamp", help="Invalidate the stamp for the specified task such as 'compile' and then run the default task for the specified target(s).",
156 action = "store", dest = "invalidate_stamp") 156 action="store", dest="invalidate_stamp")
157 157
158 parser.add_option("-r", "--read", help = "Read the specified file before bitbake.conf.", 158 parser.add_option("-r", "--read", help="Read the specified file before bitbake.conf.",
159 action = "append", dest = "prefile", default = []) 159 action="append", dest="prefile", default=[])
160 160
161 parser.add_option("-R", "--postread", help = "Read the specified file after bitbake.conf.", 161 parser.add_option("-R", "--postread", help="Read the specified file after bitbake.conf.",
162 action = "append", dest = "postfile", default = []) 162 action="append", dest="postfile", default=[])
163 163
164 parser.add_option("-v", "--verbose", help = "Output more log message data to the terminal.", 164 parser.add_option("-v", "--verbose", help="Output more log message data to the terminal.",
165 action = "store_true", dest = "verbose", default = False) 165 action="store_true", dest="verbose", default=False)
166 166
167 parser.add_option("-D", "--debug", help = "Increase the debug level. You can specify this more than once.", 167 parser.add_option("-D", "--debug", help="Increase the debug level. You can specify this more than once.",
168 action = "count", dest="debug", default = 0) 168 action="count", dest="debug", default=0)
169 169
170 parser.add_option("-n", "--dry-run", help = "Don't execute, just go through the motions.", 170 parser.add_option("-n", "--dry-run", help="Don't execute, just go through the motions.",
171 action = "store_true", dest = "dry_run", default = False) 171 action="store_true", dest="dry_run", default=False)
172 172
173 parser.add_option("-S", "--dump-signatures", help = "Dump out the signature construction information, with no task execution. The SIGNATURE_HANDLER parameter is passed to the handler. Two common values are none and printdiff but the handler may define more/less. none means only dump the signature, printdiff means compare the dumped signature with the cached one.", 173 parser.add_option("-S", "--dump-signatures", help="Dump out the signature construction information, with no task execution. The SIGNATURE_HANDLER parameter is passed to the handler. Two common values are none and printdiff but the handler may define more/less. none means only dump the signature, printdiff means compare the dumped signature with the cached one.",
174 action = "append", dest = "dump_signatures", default = [], metavar="SIGNATURE_HANDLER") 174 action="append", dest="dump_signatures", default=[], metavar="SIGNATURE_HANDLER")
175 175
176 parser.add_option("-p", "--parse-only", help = "Quit after parsing the BB recipes.", 176 parser.add_option("-p", "--parse-only", help="Quit after parsing the BB recipes.",
177 action = "store_true", dest = "parse_only", default = False) 177 action="store_true", dest="parse_only", default=False)
178 178
179 parser.add_option("-s", "--show-versions", help = "Show current and preferred versions of all recipes.", 179 parser.add_option("-s", "--show-versions", help="Show current and preferred versions of all recipes.",
180 action = "store_true", dest = "show_versions", default = False) 180 action="store_true", dest="show_versions", default=False)
181 181
182 parser.add_option("-e", "--environment", help = "Show the global or per-recipe environment complete with information about where variables were set/changed.", 182 parser.add_option("-e", "--environment", help="Show the global or per-recipe environment complete with information about where variables were set/changed.",
183 action = "store_true", dest = "show_environment", default = False) 183 action="store_true", dest="show_environment", default=False)
184 184
185 parser.add_option("-g", "--graphviz", help = "Save dependency tree information for the specified targets in the dot syntax.", 185 parser.add_option("-g", "--graphviz", help="Save dependency tree information for the specified targets in the dot syntax.",
186 action = "store_true", dest = "dot_graph", default = False) 186 action="store_true", dest="dot_graph", default=False)
187 187
188 parser.add_option("-I", "--ignore-deps", help = """Assume these dependencies don't exist and are already provided (equivalent to ASSUME_PROVIDED). Useful to make dependency graphs more appealing""", 188 parser.add_option("-I", "--ignore-deps", help="""Assume these dependencies don't exist and are already provided (equivalent to ASSUME_PROVIDED). Useful to make dependency graphs more appealing""",
189 action = "append", dest = "extra_assume_provided", default = []) 189 action="append", dest="extra_assume_provided", default=[])
190 190
191 parser.add_option("-l", "--log-domains", help = """Show debug logging for the specified logging domains""", 191 parser.add_option("-l", "--log-domains", help="""Show debug logging for the specified logging domains""",
192 action = "append", dest = "debug_domains", default = []) 192 action="append", dest="debug_domains", default=[])
193 193
194 parser.add_option("-P", "--profile", help = "Profile the command and save reports.", 194 parser.add_option("-P", "--profile", help="Profile the command and save reports.",
195 action = "store_true", dest = "profile", default = False) 195 action="store_true", dest="profile", default=False)
196 196
197 # @CHOICES@ is substituted out by BitbakeHelpFormatter above 197 # @CHOICES@ is substituted out by BitbakeHelpFormatter above
198 parser.add_option("-u", "--ui", help = "The user interface to use (@CHOICES@ - default %default).", 198 parser.add_option("-u", "--ui", help="The user interface to use (@CHOICES@ - default %default).",
199 action="store", dest="ui", default=os.environ.get('BITBAKE_UI', 'knotty')) 199 action="store", dest="ui", default=os.environ.get('BITBAKE_UI', 'knotty'))
200 200
201 # @CHOICES@ is substituted out by BitbakeHelpFormatter above 201 # @CHOICES@ is substituted out by BitbakeHelpFormatter above
202 parser.add_option("-t", "--servertype", help = "Choose which server type to use (@CHOICES@ - default %default).", 202 parser.add_option("-t", "--servertype", help="Choose which server type to use (@CHOICES@ - default %default).",
203 action = "store", dest = "servertype", default = ["process", "xmlrpc"]["BBSERVER" in os.environ]) 203 action="store", dest="servertype", default=["process", "xmlrpc"]["BBSERVER" in os.environ])
204 204
205 parser.add_option("", "--token", help = "Specify the connection token to be used when connecting to a remote server.", 205 parser.add_option("", "--token", help="Specify the connection token to be used when connecting to a remote server.",
206 action = "store", dest = "xmlrpctoken", default = os.environ.get("BBTOKEN")) 206 action="store", dest="xmlrpctoken", default=os.environ.get("BBTOKEN"))
207 207
208 parser.add_option("", "--revisions-changed", help = "Set the exit code depending on whether upstream floating revisions have changed or not.", 208 parser.add_option("", "--revisions-changed", help="Set the exit code depending on whether upstream floating revisions have changed or not.",
209 action = "store_true", dest = "revisions_changed", default = False) 209 action="store_true", dest="revisions_changed", default=False)
210 210
211 parser.add_option("", "--server-only", help = "Run bitbake without a UI, only starting a server (cooker) process.", 211 parser.add_option("", "--server-only", help="Run bitbake without a UI, only starting a server (cooker) process.",
212 action = "store_true", dest = "server_only", default = False) 212 action="store_true", dest="server_only", default=False)
213 213
214 parser.add_option("-B", "--bind", help = "The name/address for the bitbake server to bind to.", 214 parser.add_option("-B", "--bind", help="The name/address for the bitbake server to bind to.",
215 action = "store", dest = "bind", default = False) 215 action="store", dest="bind", default=False)
216 216
217 parser.add_option("", "--no-setscene", help = "Do not run any setscene tasks. sstate will be ignored and everything needed, built.", 217 parser.add_option("", "--no-setscene", help="Do not run any setscene tasks. sstate will be ignored and everything needed, built.",
218 action = "store_true", dest = "nosetscene", default = False) 218 action="store_true", dest="nosetscene", default=False)
219 219
220 parser.add_option("", "--setscene-only", help = "Only run setscene tasks, don't run any real tasks.", 220 parser.add_option("", "--setscene-only", help="Only run setscene tasks, don't run any real tasks.",
221 action = "store_true", dest = "setsceneonly", default = False) 221 action="store_true", dest="setsceneonly", default=False)
222 222
223 parser.add_option("", "--remote-server", help = "Connect to the specified server.", 223 parser.add_option("", "--remote-server", help="Connect to the specified server.",
224 action = "store", dest = "remote_server", default = os.environ.get("BBSERVER")) 224 action="store", dest="remote_server", default=os.environ.get("BBSERVER"))
225 225
226 parser.add_option("-m", "--kill-server", help = "Terminate the remote server.", 226 parser.add_option("-m", "--kill-server", help="Terminate the remote server.",
227 action = "store_true", dest = "kill_server", default = False) 227 action="store_true", dest="kill_server", default=False)
228 228
229 parser.add_option("", "--observe-only", help = "Connect to a server as an observing-only client.", 229 parser.add_option("", "--observe-only", help="Connect to a server as an observing-only client.",
230 action = "store_true", dest = "observe_only", default = False) 230 action="store_true", dest="observe_only", default=False)
231 231
232 parser.add_option("", "--status-only", help = "Check the status of the remote bitbake server.", 232 parser.add_option("", "--status-only", help="Check the status of the remote bitbake server.",
233 action = "store_true", dest = "status_only", default = False) 233 action="store_true", dest="status_only", default=False)
234 234
235 parser.add_option("-w", "--write-log", help = "Writes the event log of the build to a bitbake event json file. Use '' (empty string) to assign the name automatically.", 235 parser.add_option("-w", "--write-log", help="Writes the event log of the build to a bitbake event json file. Use '' (empty string) to assign the name automatically.",
236 action = "store", dest = "writeeventlog", default = os.environ.get("BBEVENTLOG")) 236 action="store", dest="writeeventlog", default=os.environ.get("BBEVENTLOG"))
237 237
238 options, targets = parser.parse_args(argv) 238 options, targets = parser.parse_args(argv)
239 239
@@ -280,7 +280,7 @@ def start_server(servermodule, configParams, configuration, features):
280 if configParams.bind: 280 if configParams.bind:
281 (host, port) = configParams.bind.split(':') 281 (host, port) = configParams.bind.split(':')
282 server.initServer((host, int(port)), single_use) 282 server.initServer((host, int(port)), single_use)
283 configuration.interface = [ server.serverImpl.host, server.serverImpl.port ] 283 configuration.interface = [server.serverImpl.host, server.serverImpl.port]
284 else: 284 else:
285 server.initServer(single_use=single_use) 285 server.initServer(single_use=single_use)
286 configuration.interface = [] 286 configuration.interface = []
@@ -342,7 +342,7 @@ def bitbake_main(configParams, configuration):
342 if configParams.remote_server: 342 if configParams.remote_server:
343 raise BBMainException("FATAL: The '--server-only' option conflicts with %s.\n" % 343 raise BBMainException("FATAL: The '--server-only' option conflicts with %s.\n" %
344 ("the BBSERVER environment variable" if "BBSERVER" in os.environ \ 344 ("the BBSERVER environment variable" if "BBSERVER" in os.environ \
345 else "the '--remote-server' option" )) 345 else "the '--remote-server' option"))
346 346
347 if configParams.bind and configParams.servertype != "xmlrpc": 347 if configParams.bind and configParams.servertype != "xmlrpc":
348 raise BBMainException("FATAL: If '-B' or '--bind' is defined, we must " 348 raise BBMainException("FATAL: If '-B' or '--bind' is defined, we must "