Skip to content
Advertisement

How to compile OpenJDK with OpenJ9 on Linux without a NUMA error?

Hello Stackoverflowers!
I am trying to build the OpenJDK with OpenJ9 on Linux, but when I run the configure script, I get the error:

configure: error: Could not find numa! 

Normally it should have just created the config and let me build, because I don’t have multiple CPUs.

I have already googled the error message and looked trough and followed the documentation on the projects Github(https://github.com/ibmruntimes/openj9-openjdk-jdk17/blob/openj9/doc/building.md and https://github.com/eclipse-openj9/openj9/blob/master/doc/build-instructions/Build_Instructions_V17.md).

Here is the command I used:

bash configure --with-boot-jdk=/home/USER/bootjdk16

Here is the complete output if needed:

configure: Configuration created at Sun Nov 21 14:08:05 CET 2021.
checking for basename... /usr/bin/basename
checking for dirname... /usr/bin/dirname
checking for file... /usr/bin/file
checking for ldd... /usr/bin/ldd
checking for bash... /usr/bin/bash
checking for cat... /usr/bin/cat
checking for chmod... /usr/bin/chmod
checking for cp... /usr/bin/cp
checking for cut... /usr/bin/cut
checking for date... /usr/bin/date
checking for gdiff... [not found]
checking for diff... /usr/bin/diff
checking for echo... echo [builtin]
checking for expr... /usr/bin/expr
checking for find... /usr/bin/find
checking for gunzip... /usr/bin/gunzip
checking for pigz... [not found]
checking for gzip... /usr/bin/gzip
checking for head... /usr/bin/head
checking for ln... /usr/bin/ln
checking for ls... /usr/bin/ls
checking for gmkdir... [not found]
checking for mkdir... /usr/bin/mkdir
checking for mktemp... /usr/bin/mktemp
checking for mv... /usr/bin/mv
checking for gawk... /usr/bin/gawk
checking for printf... printf [builtin]
checking for rm... /usr/bin/rm
checking for rmdir... /usr/bin/rmdir
checking for sh... /usr/bin/sh
checking for sort... /usr/bin/sort
checking for tail... /usr/bin/tail
checking for gtar... [not found]
checking for tar... /usr/bin/tar
checking for tee... /usr/bin/tee
checking for touch... /usr/bin/touch
checking for tr... /usr/bin/tr
checking for uname... /usr/bin/uname
checking for wc... /usr/bin/wc
checking for xargs... /usr/bin/xargs
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for fgrep... /usr/bin/grep -F
checking for a sed that does not truncate output... /usr/bin/sed
checking for df... /usr/bin/df
checking for nice... /usr/bin/nice
checking for greadlink... [not found]
checking for readlink... /usr/bin/readlink
checking for cygpath... [not found]
checking for wslpath... [not found]
checking for lsb_release... [not found]
checking for cmd.exe... [not found]
checking for cmp... /usr/bin/cmp
checking for uniq... /usr/bin/uniq
checking build system type... x86_64-unknown-linux-gnu
checking host system type... x86_64-unknown-linux-gnu
checking target system type... x86_64-unknown-linux-gnu
checking openjdk-build os-cpu... linux-x86_64
checking openjdk-build C library... gnu
checking openjdk-target os-cpu... linux-x86_64
checking openjdk-target C library... gnu
checking compilation type... native
checking for top-level directory... /home/USER/openj9-openjdk-jdk17
checking if custom source is suppressed (openjdk-only)... disabled, default
checking for --enable-debug... disabled, default
checking which debug level to use... release
checking which variants of the JVM to build... server
checking for m4... /usr/bin/m4
checking for cmake... /usr/bin/cmake
checking for CRIU support... no (default)
checking for cuda... no (default)
checking for ddr... yes (default for xa64)
checking if demos should be included in jdk image... no
checking checking for numa... no
configure: error: Could not find numa! 
configure exiting with result code 1

Thank you in advance!

Answer

It looks like I didn’t install the package “numactl” for some reason.

Just double check if you have those packages installed with (On Archbased)

sudo pacman -Q  numactl

(On Debainbased)

sudo dpkg -l numactl-devel

Credit: Stephen C

Advertisement