Lines Matching refs:Error
10 #include "Error.h"
68 static Error validateAndSetOptions(opt::InputArgList &Args, Options &Options) {
162 return Error::success();
165 static Error setConfigToAddNewDebugSections(objcopy::ConfigManager &Config,
183 return Error::success();
186 static Error verifyOutput(const Options &Opts) {
189 return Error::success();
209 return Error::success();
259 if (Error Err = writeToOutput(
260 Config.Common.OutputFilename, [&](raw_ostream &OutFile) -> Error {
262 if (Error Err = objcopy::executeObjcopyOnBinary(Config, InputFile,
267 return Error::success();
274 static Error saveNonDebugInfo(const Options &Opts, ObjectFile &InputFile,
284 if (Error Err = writeToOutput(
285 Config.Common.OutputFilename, [&](raw_ostream &OutFile) -> Error {
286 if (Error Err =
290 return Error::success();
294 return Error::success();
297 static Error splitDebugIntoSeparateFile(const Options &Opts,
304 if (Error Err =
308 return Error::success();
313 static Error addSectionsFromLinkedData(objcopy::ConfigManager &Config,
322 if (Error Err = setConfigToAddNewDebugSections(Config, *MemFile))
330 if (Error Err = setConfigToAddNewDebugSections(Config, *MemFile))
338 if (Error Err = setConfigToAddNewDebugSections(Config, *MemFile))
346 if (Error Err = setConfigToAddNewDebugSections(Config, *MemFile))
352 return Error::success();
366 if (Error Err =
370 if (Error Err = writeToOutput(
371 Config.Common.OutputFilename, [&](raw_ostream &OutFile) -> Error {
374 if (Error Err = objcopy::executeObjcopyOnBinary(Config, InputFile,
379 return Error::success();
386 static Error saveSingleLinkedDebugInfo(const Options &Opts,
394 if (Error Err =
398 if (Error Err = writeToOutput(
399 Config.Common.OutputFilename, [&](raw_ostream &OutFile) -> Error {
404 return Error::success();
407 static Error saveLinkedDebugInfo(const Options &Opts, ObjectFile &InputFile,
416 if (Error Err =
420 if (Error Err = saveSingleLinkedDebugInfo(Opts, InputFile,
425 return Error::success();
428 static Error saveCopyOfFile(const Options &Opts, ObjectFile &InputFile) {
434 if (Error Err = writeToOutput(
435 Config.Common.OutputFilename, [&](raw_ostream &OutFile) -> Error {
440 return Error::success();
443 static Error applyCLOptions(const struct Options &Opts, ObjectFile &InputFile) {
451 if (Error Err = linkDebugInfo(InputFile, Opts, OutStream))
454 if (Error Err =
458 return Error::success();
460 if (Error Err = splitDebugIntoSeparateFile(Opts, InputFile))
463 if (Error Err = saveCopyOfFile(Opts, InputFile))
467 return Error::success();
499 if (Error Err = validateAndSetOptions(Args, Opts))
526 if (Error Err =
533 if (Error Err = PermsApplierOrErr->apply(Opts.OutputFileName))
537 if (Error Err = PermsApplierOrErr->apply(Opts.getSeparateDebugFileName()))
541 if (Error Err = verifyOutput(Opts))