patchelf
libelfin
patchelf | libelfin | |
---|---|---|
12 | 1 | |
3,248 | 284 | |
2.2% | - | |
3.6 | 0.0 | |
22 days ago | over 1 year ago | |
C | C++ | |
GNU General Public License v3.0 only | MIT License |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
patchelf
-
Debian pauses /usr merge file moves
I mean, we don't have to hack the elf loader if we just rewrite every elf binary using patchelf: https://github.com/NixOS/patchelf
The parent commenter is already suggesting "just run a regex", so it seems like a trivial extension to their simple solution to "just run patchelf on every binary on your system"
-
How does Nix make sure binaries can access their runtime dependencies?
Patching paths in text files typically used substituteInPlace (including in cowsay). For dynamic libraries, patchelf is typically used.
-
"Discord installation is corrupt" on Ubuntu Linux.
Install patchelf.
-
Invalid or corrupted package (PGP signature)
Thank you! I followed the instruction here, but it looks like I didn't actually install it, because my pacman -Q patchelf did not find anything. Maybe I was missing a dependency. Also, it was late so I didn't pay attention to warnings at the time.
-
Rpath, or why lld doesn’t work on NixOS
How does an article on NixOS talk about the `rpath` issue without also mentioning the `patchelf` utility that NixOS developers created to solve this issue? It's a small tool that lets you modify ELF executables and binaries. It's also the recommended way for NixOS users to modify binaries to work properly.
https://github.com/NixOS/patchelf
-
cxfreeze error when compiling py to exe
So install it? https://github.com/NixOS/patchelf
- PatchELF: Simple utility for modifying existing ELF executables and libraries
-
Scala project (FIRRTL) failing to build on NixOS
NixOS doesn't have stable paths to shared libraries like macOS or other linux distributions (and this is the core feature) and always need to patch elf for current paths ( https://github.com/NixOS/patchelf ).
libelfin
-
PatchELF: Simple utility for modifying existing ELF executables and libraries
I built a (research) library a few years ago to rewrite ELF binaries; our research projects ran into a lot of limitations with doing incremental patches to a binary (ELF has a lot of redundant representations of the same data). For us, parsing the binary into a normalized representation, modifying that, and re-serializing worked — we could make more intrusive changes to the binary, and (almost? I don’t recall anything breaking) everything in the Debian repos still ran after the binaries has been rewritten.
I expect the library is now woefully out of date, and documentation is mostly in the form of conference talk slides:
https://github.com/jbangert/mithril
there’s also https://github.com/aclements/libelfin (parsing only, supports dwarf); https://github.com/bx/elf-bf-tools (Turing machine inside elf relocations) and of course the “olg guard” of ELF reversing tools ERESI/elfsh (website seems down; GitHub mirror on https://github.com/thorkill/eresi).
What are some alternatives?
nixops - NixOps is a tool for deploying to NixOS machines in a network or cloud.
elf-bf-tools
vscode-remote-release - Visual Studio Code Remote Development: Open any folder in WSL, in a Docker container, or on a remote machine using SSH and take advantage of VS Code's full feature set.
lorri - Your project's nix-env
mithril - In Soviet Russia, Mithril forges ELF.
serverless-application-model - The AWS Serverless Application Model (AWS SAM) transform is a AWS CloudFormation macro that transforms SAM templates into CloudFormation templates.
eresi - The ERESI Reverse Engineering Software Interface
nixpkgs - Nix Packages collection & NixOS
pdf-tools - Emacs support library for PDF files.
aws-sam-cli - CLI tool to build, test, debug, and deploy Serverless applications using AWS SAM