View Single Post
Old 10-05-06, 11:02 AM   #1
sangu
Registered User
 
Join Date: Feb 2005
Posts: 84
Default NVIDIA kernel module doesn't be built in kernel-2.6.19rc1

http://www.kernel.org/git/?p=linux/k...d4424ff33a70ad

Quote:
Originally Posted by kernel 2.6.19rc1 changelog
commit 038b0a6d8d32db934bba6a24e74e76e4e327a94f
Author: Dave Jones <davej@redhat.com>
Date: Wed Oct 4 03:38:54 2006 -0400

Remove all inclusions of <linux/config.h>
kbuild explicitly includes this at build time.

Signed-off-by: Dave Jones <davej@redhat.com>
and nvidia kernel module doesn't be built in Fedora Rawhide kernel-2.6.18-1.2741.fc6
Code:
$rpmbuild --rebuild --target i686 --define "kversion 2.6.18-1.2741.fc6" --define "kvariants \""\" nvidia-kmod-1.0.9625-1.2.6.18_1.2689.fc6.src.rpm 
Installing nvidia-kmod-1.0.9625-1.2.6.18_1.2689.fc6.src.rpm
Building target platforms: i686
Building for target i686
Executing(%prep): /bin/sh -e /var/tmp/rpm-tmp.56368
+ umask 022
+ cd /usr/src/redhat/BUILD
+ LANG=C
+ export LANG
+ unset DISPLAY
+ bash /usr/src/redhat/SOURCES/kmodtool rpmtemplate nvidia 2.6.18-1.2741.fc6 ''
%package       -n kmod-nvidia
Summary:          nvidia kernel module(s)
Group:            System Environment/Kernel
Provides:         kernel-modules = 2.6.18-1.2741.fc6
Provides:         nvidia-kmod = %{?epoch:%{epoch}:}%{version}-%{release}
Requires:         kernel-%{_target_cpu} = 2.6.18-1.2741.fc6
Requires:         nvidia-kmod-common >= %{?epoch:%{epoch}:}%{version}
Requires(post):   /sbin/depmod
Requires(postun): /sbin/depmod
BuildRequires:    kernel-devel-%{_target_cpu} = 2.6.18-1.2741.fc6
%description   -n kmod-nvidia
This package provides the nvidia kernel modules built for the Linux
kernel 2.6.18-1.2741.fc6 for the %{_target_cpu} family of processors.
%post          -n kmod-nvidia
/sbin/depmod -aeF /boot/System.map-2.6.18-1.2741.fc6 2.6.18-1.2741.fc6 > /dev/null || :
%postun        -n kmod-nvidia
/sbin/depmod -aF /boot/System.map-2.6.18-1.2741.fc6 2.6.18-1.2741.fc6 &> /dev/null || :
%files         -n kmod-nvidia
%defattr(644,root,root,755)
/lib/modules/2.6.18-1.2741.fc6/extra/nvidia/

+ cd /usr/src/redhat/BUILD
+ rm -rf nvidia-kmod-1.0.9625
+ /bin/mkdir -p nvidia-kmod-1.0.9625
+ cd nvidia-kmod-1.0.9625
+ /usr/bin/bzip2 -dc /usr/src/redhat/SOURCES/nvidia-glx-kmod-data-1.0.9625.tar.bz2
+ tar -xf -
+ STATUS=0
+ '[' 0 -ne 0 ']'
++ /usr/bin/id -u
+ '[' 0 = 0 ']'
+ /bin/chown -Rhf root .
++ /usr/bin/id -u
+ '[' 0 = 0 ']'
+ /bin/chgrp -Rhf root .
+ /bin/chmod -Rf a+rX,u+w,g-w,o-w .
+ for kvariant in '""'
+ cp -a nvidiapkg-x86 _kmod_build_
+ exit 0
Executing(%build): /bin/sh -e /var/tmp/rpm-tmp.88214
+ umask 022
+ cd /usr/src/redhat/BUILD
+ cd nvidia-kmod-1.0.9625
+ LANG=C
+ export LANG
+ unset DISPLAY
+ for kvariant in '""'
+ ksrc=/usr/src/kernels/2.6.18-1.2741.fc6-i686
+ pushd _kmod_build_/usr/src/nv/
/usr/src/redhat/BUILD/nvidia-kmod-1.0.9625/_kmod_build_/usr/src/nv /usr/src/redhat/BUILD/nvidia-kmod-1.0.9625
+ ln -s -f Makefile.kbuild Makefile
+ make SYSSRC=/usr/src/kernels/2.6.18-1.2741.fc6-i686 module

NVIDIA: calling KBUILD...
make CC=cc  KBUILD_VERBOSE=1 -C /usr/src/kernels/2.6.18-1.2741.fc6-i686 SUBDIRS=/usr/src/redhat/BUILD/nvidia-kmod-1.0.9625/_kmod_build_/usr/src/nv modules
test -e include/linux/autoconf.h -a -e include/config/auto.conf || (           \
        echo;                                                           \
        echo "  ERROR: Kernel configuration is invalid.";               \
        echo "         include/linux/autoconf.h or include/config/auto.conf are missing.";      \
        echo "         Run 'make oldconfig && make prepare' on kernel src to fix it.";  \
        echo;                                                           \
        /bin/false)
mkdir -p /usr/src/redhat/BUILD/nvidia-kmod-1.0.9625/_kmod_build_/usr/src/nv/.tmp_versions
rm -f /usr/src/redhat/BUILD/nvidia-kmod-1.0.9625/_kmod_build_/usr/src/nv/.tmp_versions/*
make -f scripts/Makefile.build obj=/usr/src/redhat/BUILD/nvidia-kmod-1.0.9625/_kmod_build_/usr/src/nv
echo \#define NV_COMPILER \"`cc -v 2>&1 | tail -n 1`\" > /usr/src/redhat/BUILD/nvidia-kmod-1.0.9625/_kmod_build_/usr/src/nv/nv_compiler.h
  cc -Wp,-MD,/usr/src/redhat/BUILD/nvidia-kmod-1.0.9625/_kmod_build_/usr/src/nv/.nv.o.d  -nostdinc -isystem /usr/lib/gcc/i386-redhat-linux/4.1.1/include -D__KERNEL__ -Iinclude  -include include/linux/autoconf.h  -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -Wstrict-prototypes -Wundef -Werror-implicit-function-declaration -Os -pipe -msoft-float -fno-builtin-sprintf -fno-builtin-log2 -fno-builtin-puts  -mpreferred-stack-boundary=2  -march=i686 -mtune=generic -mtune=generic -mregparm=3 -ffreestanding -Iinclude/asm-i386/mach-generic -Iinclude/asm-i386/mach-default -fomit-frame-pointer -fasynchronous-unwind-tables -g  -fno-stack-protector -Wdeclaration-after-statement -Wno-pointer-sign -I/usr/src/redhat/BUILD/nvidia-kmod-1.0.9625/_kmod_build_/usr/src/nv -Wall -Wimplicit -Wreturn-type -Wswitch -Wformat -Wchar-subscripts -Wparentheses -Wpointer-arith  -Wno-multichar  -Werror -O -fno-common -msoft-float -MD   -Wsign-compare -Wno-cast-qual -Wno-error -D_LOOSE_KERNEL_NAMES -D__KERNEL__ -DMODULE  -DNVRM -DNV_MAJOR_VERSION=1 -DNV_MINOR_VERSION=0 -DNV_PATCHLEVEL=9625  -UDEBUG -U_DEBUG -DNDEBUG -DNV_SIGNAL_STRUCT_RLIM -DNV_MULTIPLE_BRIDGE_AGPGART_PRESENT -DNV_PCI_GET_CLASS_PRESENT -DNV_SYSCTL_MAX_MAP_COUNT_PRESENT -DNV_PM_MESSAGE_T_PRESENT -DNV_PCI_CHOOSE_STATE_PRESENT -DNV_VM_INSERT_PAGE_PRESENT -DNV_OLD_MM_KGDB_BREAKPOINT_PRESENT -DNV_REMAP_PFN_RANGE_PRESENT -DNV_CHANGE_PAGE_ATTR_PRESENT -DNV_VMAP_4_PRESENT  -DMODULE -D"KBUILD_STR(s)=#s" -D"KBUILD_BASENAME=KBUILD_STR(nv)"  -D"KBUILD_MODNAME=KBUILD_STR(nvidia)" -c -o /usr/src/redhat/BUILD/nvidia-kmod-1.0.9625/_kmod_build_/usr/src/nv/.tmp_nv.o /usr/src/redhat/BUILD/nvidia-kmod-1.0.9625/_kmod_build_/usr/src/nv/nv.c
In file included from /usr/src/redhat/BUILD/nvidia-kmod-1.0.9625/_kmod_build_/usr/src/nv/nv.c:14:
/usr/src/redhat/BUILD/nvidia-kmod-1.0.9625/_kmod_build_/usr/src/nv/nv-linux.h:17:26: error: linux/config.h: No such file or directory
In file included from include/linux/list.h:8,
                 from include/linux/lockdep.h:12,
                 from include/linux/spinlock_types.h:12,
                 from include/linux/spinlock.h:78,
                 from include/linux/capability.h:45,
                 from include/linux/sched.h:44,
                 from include/linux/module.h:9,
                 from /usr/src/redhat/BUILD/nvidia-kmod-1.0.9625/_kmod_build_/usr/src/nv/nv-linux.h:51,
                 from /usr/src/redhat/BUILD/nvidia-kmod-1.0.9625/_kmod_build_/usr/src/nv/nv.c:14:
include/linux/prefetch.h: In function 'prefetch_range':
include/linux/prefetch.h:62: warning: pointer of type 'void *' used in arithmetic
In file included from include/linux/dmapool.h:14,
                 from include/linux/pci.h:564,
                 from /usr/src/redhat/BUILD/nvidia-kmod-1.0.9625/_kmod_build_/usr/src/nv/nv-linux.h:77,
                 from /usr/src/redhat/BUILD/nvidia-kmod-1.0.9625/_kmod_build_/usr/src/nv/nv.c:14:
include/asm/io.h: In function 'check_signature':
include/asm/io.h:245: warning: wrong type argument to increment
make[3]: *** [/usr/src/redhat/BUILD/nvidia-kmod-1.0.9625/_kmod_build_/usr/src/nv/nv.o] Error 1
make[2]: *** [_module_/usr/src/redhat/BUILD/nvidia-kmod-1.0.9625/_kmod_build_/usr/src/nv] Error 2
NVIDIA: left KBUILD.
nvidia.ko failed to build!
make[1]: *** [module] Error 1
make: *** [module] Error 2
error: Bad exit status from /var/tmp/rpm-tmp.88214 (%build)


RPM build errors:
    Bad exit status from /var/tmp/rpm-tmp.88214 (%build)
nvidia driver 1.0.9625
OS: Fedora rawhide 20061005

Last edited by sangu; 10-05-06 at 11:26 AM.
sangu is offline   Reply With Quote