Even more Mac build fixes.

The stack one is a punt until I've got an actual machine to test on.

Change-Id: Ibb2132511f4c9f50f1f21651ca9ba7d5bed67e09
diff --git a/src/reference_table.cc b/src/reference_table.cc
index 2281eac..e56f5ec 100644
--- a/src/reference_table.cc
+++ b/src/reference_table.cc
@@ -118,7 +118,7 @@
   }
 
   size_t total = identical + equiv + 1;
-  std::string msg(StringPrintf("%5d of %s", total, className.c_str()));
+  std::string msg(StringPrintf("%5zd of %s", total, className.c_str()));
   if (identical + equiv != 0) {
     StringAppendF(&msg, " (%d unique instances)", equiv + 1);
   }
diff --git a/src/stack.h b/src/stack.h
index 868b157..3a0903f 100644
--- a/src/stack.h
+++ b/src/stack.h
@@ -61,7 +61,7 @@
   uint32_t GetVReg(const DexFile::CodeItem* code_item, uint32_t core_spills, uint32_t fp_spills,
                     size_t frame_size, int vreg) const;
 
-  uintptr_t GetVReg(Method* m, int vreg) const;
+  uint32_t GetVReg(Method* m, int vreg) const;
   void SetVReg(Method* method, int vreg, uint32_t new_value);
 
   Method** GetSP() const {
diff --git a/src/thread.cc b/src/thread.cc
index a0179d8..c850429 100644
--- a/src/thread.cc
+++ b/src/thread.cc
@@ -341,6 +341,9 @@
 }
 
 void Thread::InitStackHwm() {
+#if defined(__APPLE__)
+  UNIMPLEMENTED(FATAL) << "try pthread_get_stacksize_np and pthread_get_stackaddr_np";
+#else
   pthread_attr_t attributes;
   CHECK_PTHREAD_CALL(pthread_getattr_np, (pthread_self(), &attributes), __FUNCTION__);
 
@@ -361,6 +364,7 @@
   CHECK_GT(&stack_variable, (void*) stack_end_);
 
   CHECK_PTHREAD_CALL(pthread_attr_destroy, (&attributes), __FUNCTION__);
+#endif
 }
 
 void Thread::Dump(std::ostream& os, bool dump_pending_exception) const {