Lines Matching refs:Config
60 static void removeSections(const CommonConfig &Config, Object &Obj) {
64 if (!Config.ToRemove.empty()) {
65 RemovePred = [&Config](const Section &Sec) {
66 return Config.ToRemove.matches(Sec.Name);
70 if (Config.StripDebug) {
76 if (Config.StripAll) {
83 if (Config.OnlyKeepDebug) {
84 RemovePred = [&Config](const Section &Sec) {
87 return Config.ToRemove.matches(Sec.Name) || !isDebugSection(Sec);
91 if (!Config.OnlySection.empty()) {
92 RemovePred = [&Config](const Section &Sec) {
95 return !Config.OnlySection.matches(Sec.Name);
99 if (!Config.KeepSection.empty()) {
100 RemovePred = [&Config, RemovePred](const Section &Sec) {
102 if (Config.KeepSection.matches(Sec.Name))
112 static Error handleArgs(const CommonConfig &Config, Object &Obj) {
114 for (StringRef Flag : Config.DumpSection) {
122 removeSections(Config, Obj);
124 for (const NewSectionInfo &NewSection : Config.AddSection) {
144 Error executeObjcopyOnBinary(const CommonConfig &Config, const WasmConfig &,
149 return createFileError(Config.InputFilename, ObjOrErr.takeError());
152 if (Error E = handleArgs(Config, *Obj))
156 return createFileError(Config.OutputFilename, std::move(E));