[llvm] [llvm-objcopy] Add --change-section-address (PR #98664)
James Henderson via llvm-commits
llvm-commits at lists.llvm.org
Fri Jul 26 02:14:27 PDT 2024
================
@@ -745,6 +745,50 @@ static Error handleArgs(const CommonConfig &Config, const ELFConfig &ELFConfig,
}
}
+ if (!Config.ChangeSectionAddress.empty()) {
+ if (Obj.Type != ELF::ET_REL)
+ return createStringError(
+ object_error::invalid_file_type,
+ "cannot change section address in a non-relocatable file");
+ StringMap<AddressUpdate> SectionsToUpdateAddress;
----------------
jh7370 wrote:
Let's add a blank line before this line. I think this will help readability a little.
https://github.com/llvm/llvm-project/pull/98664
More information about the llvm-commits
mailing list