Scientific Linux Forum.org



  Reply to this topicStart new topicStart Poll

> checking kernel.h kernel header... not found, amd hpl compling
semi2183
 Posted: Feb 13 2014, 01:49 PM
Quote Post


SLF Newbie


Group: Members
Posts: 2
Member No.: 2959
Joined: 13-February 14









Hi
I try to compile the linpak from amd for testing a new cluster.
For a better hardware support I change to the kernel-ml from elrepo.

But when I compile knem, I got:
CODE

[02:15 ][root@master][/work/amd-hpl/knem-0.9.8] # ./configure  --prefix=/work/amd-hpl/knem-install  --build x86_64-redhat-linux-gnu
checking build system type... x86_64-redhat-linux-gnu
checking host system type... x86_64-redhat-linux-gnu
checking target system type... x86_64-redhat-linux-gnu
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether make supports nested variables... yes
checking for style of include used by make... GNU
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking dependency style of gcc... gcc3
checking how to run the C preprocessor... gcc -E
checking for gcc... (cached) gcc
checking whether we are using the GNU C compiler... (cached) yes
checking whether gcc accepts -g... (cached) yes
checking for gcc option to accept ISO C89... (cached) none needed
checking dependency style of gcc... (cached) gcc3
checking which compiler to use for kernel modules...
checking for gcc... gcc
checking kernel.h kernel header... not found
checking autoconf.h kernel header... not found
checking kernel Makefile... not found
configure: looked for kernel headers and build system using:
configure:   kernel headers in /lib/modules/3.13.1-1.el6.elrepo.x86_64/source
configure:   kernel build in /lib/modules/3.13.1-1.el6.elrepo.x86_64/build
configure: might need --with-linux-release, --with-linux, or --with-linux-build
configure: error: could not find kernel headers and build system


The same without '--build x86_64-redhat-linux-gnu'.
It's seem that he can't find the kernel.h.
'rpm -qa kernel\* | sort' report:
CODE

kernel-2.6.32-431.1.2.el6.x86_64
kernel-devel-2.6.32-431.5.1.el6.x86_64
kernel-firmware-2.6.32-431.1.2.el6.noarch
kernel-headers-2.6.32-431.5.1.el6.x86_64
kernel-ml-3.13.1-1.el6.elrepo.x86_64
kernel-ml-devel-3.13.2-1.el6.elrepo.x86_64


Please no discussion about amd CPU's. I know the rest of the world likes intel:)

Thanks for support
Sebastian
PMEmail Poster
^
burakkucat
 Posted: Feb 13 2014, 03:14 PM
Quote Post


SLF Administrator
****

Group: Admins
Posts: 203
Member No.: 14
Joined: 10-April 11









QUOTE

kernel-ml-3.13.1-1.el6.elrepo.x86_64
kernel-ml-devel-3.13.2-1.el6.elrepo.x86_64

The first thing you should do is to ensure that the kernel-ml and kernel-ml-devel packages match. Currently you have version 3.13.1 for the former and version 3.13.2 for the latter.

The next thing to note is that the /usr/include/linux/kernel.h file is provided by the kernel-ml-headers package. Normally it is not necessary to install that package but, in this case, due to what you are attempting to build the distribution kernel-headers-2.6.32-431.5.1.el6.x86_64 package will have to be removed and replaced with the kernel-ml-headers-3.13.2-1.el6.elrepo.x86_64 package.

My suggestion --

yum --enablerepo elrepo-kernel update kernel-ml
rpm -e --nodeps kernel-headers
yum --enablerepo elrepo-kernel install kernel-ml-headers
rpm -qa kernel-ml\* | sort

--------------------
user posted image 100% Linux and, previously, Unix. Co-founder of the ELRepo Project.
PMUsers Website
^
semi2183
 Posted: Feb 13 2014, 03:52 PM
Quote Post


SLF Newbie


Group: Members
Posts: 2
Member No.: 2959
Joined: 13-February 14









Thanks a lot burakkucat
Now I see it clear. The devel packet didn't match the kernel version.
After installing the right version I got an loadable module for the kernel

Thanks again

Sebastian


PMEmail Poster
^
burakkucat
 Posted: Feb 13 2014, 04:02 PM
Quote Post


SLF Administrator
****

Group: Admins
Posts: 203
Member No.: 14
Joined: 10-April 11









That is excellent news. Thank you for reporting back with details of your success. smile.gif

So, to clarify things for posterity, it was not necessary to replace the distributed kernel-headers package as the existing /usr/include/linux/kernel.h was sufficient -- once the kernel-ml and kernel-ml-devel package versions were synchronised.

--------------------
user posted image 100% Linux and, previously, Unix. Co-founder of the ELRepo Project.
PMUsers Website
^
0 User(s) are reading this topic (0 Guests and 0 Anonymous Users)
0 Members:

Topic Options Reply to this topicStart new topicStart Poll