jonhoo / volley

Volley is a benchmarking tool for measuring the performance of server networking stacks.
MIT License
123 stars 12 forks source link

Makefile failure on mac #17

Open cep21 opened 9 years ago

cep21 commented 9 years ago

Hi,

I would like to develop clients in other languages, but only have access to a mac. The makefile fails on mac, mostly around the use of stdatomic.h, bsd/stdlib.h, and clock_gettime. I'm not a C/C++ expert but if someone could make the makefile work on Mac it would help in developing other language benchmarks, even if the published benchmark numbers don't happen on mac.

jonhoo commented 9 years ago

Are you compiling with clang or with gcc? Are you using the versions that shipped with XCode, or are they installed with homebrew?

I think clock_gettime is the biggest issue. OSX includes arc4random in stdlib.h, so bsd/stdlib.h can simply be put under an #ifndef __MACH__ (though ideally it should also not be included in BSD either). stdatomic.h should work out of the box with homebrew's clang as far as I can tell. Judging from this blog post it shouldn't be too tricky to emulate clock_gettime -- feel free to give it a shot.