aboutsummaryrefslogtreecommitdiff
path: root/lib/std/macho.zig
diff options
context:
space:
mode:
authorJakub Konka <kubkon@jakubkonka.com>2020-11-12 21:29:25 +0100
committerJakub Konka <kubkon@jakubkonka.com>2020-11-26 11:50:09 +0100
commit1bec531cf234f04818e22b7b792b18a88c5faf88 (patch)
tree88230e4f49a5238c644f7c46c5c895547c898b6b /lib/std/macho.zig
parent72310db1da792aae05edffe96082d97bb04cf7e5 (diff)
downloadzig-1bec531cf234f04818e22b7b792b18a88c5faf88.tar.gz
zig-1bec531cf234f04818e22b7b792b18a88c5faf88.zip
stage2 MachO: add source version load cmd
Diffstat (limited to 'lib/std/macho.zig')
-rw-r--r--lib/std/macho.zig13
1 files changed, 13 insertions, 0 deletions
diff --git a/lib/std/macho.zig b/lib/std/macho.zig
index 2dcc4b4b37..a4a8bbdd10 100644
--- a/lib/std/macho.zig
+++ b/lib/std/macho.zig
@@ -722,6 +722,19 @@ pub const version_min_command = extern struct {
sdk: u32,
};
+/// The source_version_command is an optional load command containing
+/// the version of the sources used to build the binary.
+pub const source_version_command = extern struct {
+ /// LC_SOURCE_VERSION
+ cmd: u32,
+
+ /// sizeof(source_version_command)
+ cmdsize: u32,
+
+ /// A.B.C.D.E packed as a24.b10.c10.d10.e10
+ version: u64,
+};
+
/// After MacOS X 10.1 when a new load command is added that is required to be
/// understood by the dynamic linker for the image to execute properly the
/// LC_REQ_DYLD bit will be or'ed into the load command constant. If the dynamic