[LLD] Add support for the -stack_size option to Darwin ld.

llvm-svn: 237841
diff --git a/lld/lib/ReaderWriter/MachO/MachONormalizedFileBinaryWriter.cpp b/lld/lib/ReaderWriter/MachO/MachONormalizedFileBinaryWriter.cpp
index 5d85189..820959f 100644
--- a/lld/lib/ReaderWriter/MachO/MachONormalizedFileBinaryWriter.cpp
+++ b/lld/lib/ReaderWriter/MachO/MachONormalizedFileBinaryWriter.cpp
@@ -829,7 +829,7 @@
       ep->cmd       = LC_MAIN;
       ep->cmdsize   = sizeof(entry_point_command);
       ep->entryoff  = _file.entryAddress - _seg1addr;
-      ep->stacksize = 0;
+      ep->stacksize = _file.stackSize;
       if (_swap)
         swapStruct(*ep);
       lc += sizeof(entry_point_command);