Fix compilation and JIT support on NetBSD:

1. Disable hugepages (not supported).
2. Force W^X (required).
3. When allocating JIT memory, PROT_EXEC must be reserved
   in order to set the pages executable later.
This commit is contained in:
tevador
2020-06-28 16:16:20 +02:00
parent 7741eb1e97
commit 708a4e50c5
6 changed files with 21 additions and 11 deletions
+4
View File
@@ -35,3 +35,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#else
#include "jit_compiler_fallback.hpp"
#endif
#if defined(__OpenBSD__) || defined(__NetBSD__)
#define RANDOMX_FORCE_SECURE
#endif