[PATCH] D109840: Add MachO signature verification test

Nuri Amari via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Sep 15 14:17:07 PDT 2021


nuriamari added inline comments.


================
Comment at: lld/test/MachO/Inputs/code-signature-check.py:1
+#! /usr/bin/env python3
+
----------------
oontvoo wrote:
> Any chance this could be omitted for portability?  (since you've already invoked the script with `%python` below)?
> (also is python3 a must?) 
I'll remove the shebang, but the script does require at least python3.5 for the [[ https://docs.python.org/3/library/typing.html | typing module ]].


================
Comment at: lld/test/MachO/adhoc-codesign-hash.s:16-33
+# ARM64-MACOS: - cmd:             LC_CODE_SIGNATURE
+# ARM64-MACOS-NEXT: cmdsize:         16
+# ARM64-MACOS-NEXT: dataoff:         16400
+# ARM64-MACOS-NEXT: datasize:        304
+
+# ARM64-IOS: - cmd:             LC_CODE_SIGNATURE
+# ARM64-IOS-NEXT: cmdsize:         16
----------------
int3 wrote:
> oontvoo wrote:
> > Perhaps consider using variables here to avoid duplication? (also easier for future updates?)
> > 
> > (suggested diff is in-complete -- only included one eg)
> nit: try to vertically align where possible (same for lines below)
I haven't been able to get what you are suggesting working. Are `FileCheck` capture variables usable within a run command? 


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D109840/new/

https://reviews.llvm.org/D109840



More information about the llvm-commits mailing list