diff --git a/staticx/archive.py b/staticx/archive.py index 47ed72c..3a3c29c 100644 --- a/staticx/archive.py +++ b/staticx/archive.py @@ -57,7 +57,10 @@ def _prepare(self, path): if self.strip: logging.info("Stripping binary {}".format(dst)) - strip_elf(dst) + try: + strip_elf(dst) + except ToolError as e: + pass return dst diff --git a/staticx/elf.py b/staticx/elf.py index 81b7ff4..1ed7b54 100644 --- a/staticx/elf.py +++ b/staticx/elf.py @@ -58,7 +58,11 @@ def run(self, *args): stderr_ignore = [ b'working around a Linux kernel bug by creating a hole', ]) -tool_strip = ExternTool('strip', 'binutils') +tool_strip = ExternTool('strip', 'binutils', + stderr_ignore = [ + 'Not enough room for program headers, try linking with -N', + '[.note.ABI-tag]: Bad value', + ]) def get_shobj_deps(path): output = tool_ldd.run(path)