Native: Multiple fixes#3479
Conversation
|
cc: @nguerrera, @sokket |
There was a problem hiding this comment.
Out of curiosity, why is this needed?
There was a problem hiding this comment.
This is for the check #ifdef BSD:
sys/param.h is available in all POSIX and BSD macro is only defined in BSD-backed OSes. (ref: http://sourceforge.net/p/predef/wiki/OperatingSystems/, https://technet.microsoft.com/en-us/library/bb463220.aspx)
|
Thanks, @jasonwilliams200OK. I had two comments, but the rest looks good. |
There was a problem hiding this comment.
Just found a third issue: Are we even using locate_llvm_exec or llvm_prefix anymore?
There was a problem hiding this comment.
Nice catch! I thought it is used to check llvm existence and early exit. Fixed by 9e22f86.
Clang on FreeBSD caught this as an error.
* It builds without llvm-* dependencies. * Minor conditions and comment fixes.
|
Thanks for the review @nguerrera. I have fixed the issues and re-pushed. Regarding the |
|
Nevermind the assert since it was already missing. (Aside: Note that sizeof() check isn't sufficient since it doesn't account for possible difference in signedness between int32_t and id_t.) I'm going to make another change to make potentially narrowing conversions like that go through a helper that also avoids having to cmake configure every occurrence like this. It'll also help clean up some things in the crypto shim. This LGTM once it gets through a successful CI. |
067ea11d9cf2d8id_tis not the type[get/set]priorityfunctions are expecting:id_t who): http://man7.org/linux/man-pages/man2/getpriority.2.htmlint who): https://www.freebsd.org/cgi/man.cgi?query=getpriority&sektion=2 (this applies to other BSDs as well, such as DragonFly and NetBSD, except for OpenBSD, hence I've used#if !defined(BSD) ..cmake_prototype_definitionto detect the correct prototype).207d186e348434src/Native/gen-buildsys-clang.sh.