Skip to content

Instantly share code, notes, and snippets.

@LinusU
Last active August 29, 2015 14:04
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save LinusU/a1771562fec0201c54cd to your computer and use it in GitHub Desktop.
Save LinusU/a1771562fec0201c54cd to your computer and use it in GitHub Desktop.
Diff to get mongodb to compile on newer OS X 10.10
diff --git a/src/third_party/s2/util/endian/endian.h b/src/third_party/s2/util/endian/endian.h
index 9def73f..9de7ab0 100755
--- a/src/third_party/s2/util/endian/endian.h
+++ b/src/third_party/s2/util/endian/endian.h
@@ -178,14 +178,5 @@ class LittleEndian {
};
-// This one is safe to take as it's an extension
-#define htonll(x) ghtonll(x)
-
-// ntoh* and hton* are the same thing for any size and bytesex,
-// since the function is an involution, i.e., its own inverse.
-#define gntohl(x) ghtonl(x)
-#define gntohs(x) ghtons(x)
-#define gntohll(x) ghtonll(x)
-#define ntohll(x) htonll(x)
#endif // UTIL_ENDIAN_ENDIAN_H_
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment