Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 223695 - net-wireless/madwifi-ng-0.9.4 emerge error on Kernel 2.6.24: error: /ath_hal/ah_os.c: linux/config.h: No such file..
Summary: net-wireless/madwifi-ng-0.9.4 emerge error on Kernel 2.6.24: error: /ath_hal/...
Status: VERIFIED INVALID
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: AMD64 Linux
: High normal (vote)
Assignee: Steev Klimaszewski (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 205116
  Show dependency tree
 
Reported: 2008-05-26 14:06 UTC by Christian Bayer
Modified: 2008-06-09 08:13 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Christian Bayer 2008-05-26 14:06:34 UTC
Compiling the source of net-wireless/madwifi-ng-0.9.4 fails with Linux 2.6.24-r8 because of missing includes:

 * Preparing ath_hal module
make -C /usr/src/linux M=/tmp/net-wireless/madwifi-ng-0.9.4/work/madwifi-0.9.4/ath_hal modules
make[1]: Entering directory `/usr/src/linux-2.6.24-gentoo-r8'
x86_64-pc-linux-gnu-gcc -march=nocona -O4 -pipe -z combreloc -fprefetch-loop-arrays -funroll-loops -frerun-cse-after-loop -frerun-loop-opt -falign-functions=4 -mmmx -msse -mfpmath=sse  -include /tmp/net-wireless/madwifi-ng-0.9.4/work/madwifi-0.9.4/ath_hal/../include/compat.h -I/tmp/net-wireless/madwifi-ng-0.9.4/work/madwifi-0.9.4/ath_hal/../include -I/tmp/net-wireless/madwifi-ng-0.9.4/work/madwifi-0.9.4/ath_hal/../ath_hal -I/tmp/net-wireless/madwifi-ng-0.9.4/work/madwifi-0.9.4/ath_hal/../hal -Werror -DAH_BYTE_ORDER=AH_LITTLE_ENDIAN -DAH_WORDSIZE=64 -mcmodel=kernel -mno-red-zone -fomit-frame-pointer -DATH_SUPERG_FF=1 -DATH_SUPERG_DYNTURBO=1 -DATH_TURBO_SCAN=1 -DATH_SUPERG_XR=1 -DOPT_AH_H=\"/tmp/net-wireless/madwifi-ng-0.9.4/work/madwifi-0.9.4/ath_hal/../hal/public/x86_64-elf.opt_ah.h\"  -c -o /tmp/net-wireless/madwifi-ng-0.9.4/work/madwifi-0.9.4/ath_hal/ah_os.o /tmp/net-wireless/madwifi-ng-0.9.4/work/madwifi-0.9.4/ath_hal/ah_os.c
  HOSTCC  /tmp/net-wireless/madwifi-ng-0.9.4/work/madwifi-0.9.4/ath_hal/uudecode.o
/tmp/net-wireless/madwifi-ng-0.9.4/work/madwifi-0.9.4/ath_hal/ah_os.c:48:26: error: linux/config.h: No such file or directory
/tmp/net-wireless/madwifi-ng-0.9.4/work/madwifi-0.9.4/ath_hal/ah_os.c:51:26: error: linux/module.h: No such file or directory
/tmp/net-wireless/madwifi-ng-0.9.4/work/madwifi-0.9.4/ath_hal/ah_os.c:52:24: error: linux/init.h: No such file or directory
/tmp/net-wireless/madwifi-ng-0.9.4/work/madwifi-0.9.4/ath_hal/ah_os.c:55:24: error: linux/slab.h: No such file or directory
/tmp/net-wireless/madwifi-ng-0.9.4/work/madwifi-0.9.4/ath_hal/ah_os.c:56:25: error: linux/delay.h: No such file or directory

These includes are not in /usr/include/linux. As I suspect, these are in /usr/src/linux/include, but adding this directory to the includes causes redefinition errors and incuding-this-is-not-allowed-from-userspace errors/warnings. It does not seem right, though.

Compiling madwifi-ng-0.9.3.3 does not work either. Because of the newly created architectures x86_32 and x86_64, I had to apply this patch before emerging got to the same point as above:


diff -ur madwifi-0.9.3.3.orig/ath_hal/ah_target.inc madwifi-0.9.3.3/ath_hal/ah_target.inc
--- madwifi-0.9.3.3.orig/ath_hal/ah_target.inc 2006-11-18 00:34:30.000000000 +0100
+++ madwifi-0.9.3.3/ath_hal/ah_target.inc 2008-01-25 20:34:35.000000000 +0100
@@ -37,5 +37,7 @@
 TARGET-$(CONFIG_CPU_SA110) = xscale-$(ENDIAN)-elf
 TARGET-$(CONFIG_CPU_SA1100) = xscale-$(ENDIAN)-elf
 TARGET-$(CONFIG_CPU_XSCALE) = xscale-$(ENDIAN)-elf
+TARGET-$(CONFIG_X86_64) = x86_64-elf
+TARGET-$(CONFIG_X86_32) = i386-elf

 TARGET = $(if $(TARGET-y),$(TARGET-y),$(ARCH)-elf)

diff -ur madwifi-0.9.3.3.orig/scripts/get_arch.mk madwifi-0.9.3.3/scripts/get_arch.mk
--- madwifi-0.9.3.3.orig/scripts/get_arch.mk 2006-11-15 08:24:13.000000000 +0100
+++ madwifi-0.9.3.3/scripts/get_arch.mk 2008-01-25 20:32:23.000000000 +0100
@@ -9,7 +9,7 @@
 ARCH-$(CONFIG_CRIS) = cris
 ARCH-$(CONFIG_FRV) = frv
 ARCH-$(CONFIG_H8300) = h8300
-ARCH-$(CONFIG_X86) = i386
+ARCH-$(CONFIG_X86) = x86
 ARCH-$(CONFIG_IA64) = ia64
 ARCH-$(CONFIG_M32R) = m32r
 ARCH-$(CONFIG_M68K) = m68k
@@ -29,7 +29,7 @@
 ARCH-$(CONFIG_SPARC64) = sparc64
 ARCH-$(CONFIG_UML) = um
 ARCH-$(CONFIG_V850) = v850
-ARCH-$(CONFIG_X86_64) = x86_64
+ARCH-$(CONFIG_X86_64) = x86
 ARCH-$(CONFIG_XTENSA) = xtensa
 ifeq (,$(ARCH-y))

But just as stated above, emerging fails again with the same error, complaining about missing config.h etc.

Today's svn snapshot of madwifi-ng compiled fine with the old kernel 2.6.23-r8, as did madwifi-ng-0.9.3.3. Both refuse building with kernel 2.6.24.

I suspect updating sys-kernel/linux-headers could help, but this should usually be done only when re-emerging libc, thatswhy I wanted to ask for help before.

Thanks in advance, Christian Bayer

Reproducible: Always

Steps to Reproduce:
1. emerge madwifi-ng
2.
3.
Comment 1 Jeroen Roovers (RETIRED) gentoo-dev 2008-05-26 17:01:34 UTC
emerge --info, please.
Comment 2 Christian Bayer 2008-05-26 20:42:40 UTC
Portage 2.1.4.4 (default-linux/amd64/2007.0, gcc-4.1.2, glibc-2.6.1-r0, 2.6.23-gentoo-r8-h3lios x86_64)
=================================================================
System uname: 2.6.23-gentoo-r8-h3lios x86_64 Intel(R) Core(TM)2 CPU 4400 @ 2.00GHz
Timestamp of tree: Sat, 24 May 2008 13:45:01 +0000
distcc 2.18.3 x86_64-pc-linux-gnu (protocols 1 and 2) (default port 3632) [disabled]
ccache version 2.4 [disabled]
app-shells/bash:     3.2_p33
dev-java/java-config: 1.3.7, 2.1.6
dev-lang/python:     2.4.4-r13, 2.5.2-r4
dev-python/pycrypto: 2.0.1-r6
dev-util/ccache:     2.4-r7
sys-apps/baselayout: 1.12.11.1
sys-apps/sandbox:    1.2.18.1-r2
sys-devel/autoconf:  2.13, 2.61-r1
sys-devel/automake:  1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10.1
sys-devel/binutils:  2.18-r1
sys-devel/gcc-config: 1.4.0-r4
sys-devel/libtool:   1.5.26
virtual/os-headers:  2.6.23-r3
ACCEPT_KEYWORDS="amd64"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=nocona -O4 -pipe -z combreloc -fprefetch-loop-arrays -funroll-loops -frerun-cse-after-loop -frerun-loop-opt -falign-functions=4 -mmmx -msse -mfpmath=sse"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/share/config"
CONFIG_PROTECT_MASK="/etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/revdep-rebuild /etc/terminfo /etc/texmf/web2c /etc/udev/rules.d"
CXXFLAGS="-march=nocona -O4 -pipe -z combreloc -fprefetch-loop-arrays -funroll-loops -frerun-cse-after-loop -frerun-loop-opt -falign-functions=4 -mmmx -msse -mfpmath=sse"
DISTDIR="/usr/portage/distfiles"
FEATURES="distlocks metadata-transfer sandbox sfperms strict unmerge-orphans userfetch"
GENTOO_MIRRORS=" http://distfiles.gentoo.org http://www.ibiblio.org/pub/Linux/distributions/gentoo"
LANG="de_DE.UTF-8"
LINGUAS="de"
MAKEOPTS="-j3"
PKGDIR="/usr/portage/packages"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/portage/local/layman/hamsoftware"
SYNC="rsync://rsync.europe.gentoo.org/gentoo-portage"
USE="X a52 acl alsa amd64 avi bash-completion berkdb cairo cli cracklib crypt cups dbus divx4linux dri dvdread encode fame fortran gdbm gpm gtk hal iconv ipv6 isdnlog kde lm_sensors midi mjpeg mmx mpeg mudflap ncurses nls nptl nptlonly ogg opengl openmp pam pcre perl pppd python qt3 quicktime readline reflection samba session slang spl sse sse2 ssl subtitles tcpd tiff unicode vorbis xcomposite xinerama xorg xvid zlib" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" ELIBC="glibc" INPUT_DEVICES="keyboard mouse" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="de" USERLAND="GNU" VIDEO_CARDS="mga mach64 r128 radeon nv vesa fglrx apm v4l fbdev"
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LC_ALL, LDFLAGS, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Comment 3 Peter Volkov (RETIRED) gentoo-dev 2008-06-05 08:50:26 UTC
As I see net-wireless/madwifi-ng-0.9.3.3 will never work with 2.6.24 and we are about to stabilize net-wireless/madwifi-ng-0.9.4. 

kernel modules should use /usr/src/linux/include as they are part of kernel, so I suppose to fix your build issue with net-wireless/madwifi-ng-0.9.4 you should use "eselect kernel list/set" to set kernel symlink correctly, after that configure kernel correctly and only after that you should rebuild modules. If the problem persist attach full build log and reopen this bug report. Thank you.
Comment 4 Christian Bayer 2008-06-05 15:22:26 UTC
Using select kernel set did not help. Building net-wireless/madwifi-ng-0.9.4 still fails with the same error on kernel 2.6.24-r8 with correctly set /usr/src/linux. As long as eselect kernel set does nothing more than setting a correct symlink this does not surprise.
But something other surprises: Compiling on freshly downloaded linux-2.6.25-r4 works!
I tried again with kernel 2.6.24 after a "make mrproper", but this didn't help either.
I can live with a working madwifi in 2.6.25, but I will have to test it a little.
Comment 5 Peter Volkov (RETIRED) gentoo-dev 2008-06-06 09:59:59 UTC
Try to emerge -C =gentoo-sources-2.6.24-r8 && rm -rf /usr/src/linux-2.6.24-gentoo-r8 and after that emerge =gentoo-sources-2.6.24-r8 again. I've tried but failed to reproduce your problem here with =gentoo-sources-2.6.24-r8.
Comment 6 Christian Bayer 2008-06-09 08:13:47 UTC
Ok. My fault. Killing the kernel tree and emerging it again made madwifi build. Thanks a lot for the help.