Bug 166086 - sys-kernel/gentoo-sources-2.6.20 doesn't compile
Bug#: 166086 Product:  Gentoo Linux Version: unspecified Platform: AMD64
OS/Version: Linux Status: RESOLVED Severity: normal Priority: P2
Resolution: FIXED Assigned To: kernel@gentoo.org Reported By: pacho@condmat1.ciencias.uniovi.es
Component: Applications
URL:  http://forums.gentoo.org/viewtopic-t-537880-highlight-.html
Summary: sys-kernel/gentoo-sources-2.6.20 doesn't compile
Keywords:  
Status Whiteboard: 
Opened: 2007-02-09 14:58 0000
Description:   Opened: 2007-02-09 14:58 0000
I get the following errors:
  CC [M]  drivers/char/speakup/speakup_keyhelp.o
  CC [M]  drivers/char/speakup/speakup.o
drivers/char/speakup/speakup.c: In function 'say_line':
drivers/char/speakup/speakup.c:900: warning: format '%d' expects type 'int',
but argument 3 has type 'long int'
drivers/char/speakup/speakup.c:900: warning: format '%d' expects type 'int',
but argument 3 has type 'long int'
drivers/char/speakup/speakup.c: At top level:
drivers/char/speakup/speakup.c:2031: error: expected identifier or '(' before
'{' token
make[3]: *** [drivers/char/speakup/speakup.o] Error 1
make[2]: *** [drivers/char/speakup] Error 2
make[1]: *** [drivers/char] Error 2
make: *** [drivers] Error 2

My emerge --info:
Portage 2.1.1-r2 (default-linux/amd64/2006.1, gcc-4.1.1, glibc-2.4-r4,
2.6.19-gentoo-r5 x86_64)
=================================================================
System uname: 2.6.19-gentoo-r5 x86_64 AMD Athlon(tm) 64 Processor 3200+
Gentoo Base System release 1.12.8
Last Sync: Fri, 09 Feb 2007 08:50:01 +0000
ccache version 2.4 [enabled]
app-admin/eselect-compiler: [Not Present]
dev-java/java-config: 1.3.7, 2.0.31
dev-lang/python:     2.4.3-r4
dev-python/pycrypto: 2.0.1-r5
dev-util/ccache:     2.4-r6
dev-util/confcache:  [Not Present]
sys-apps/sandbox:    1.2.17
sys-devel/autoconf:  2.13, 2.61
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10
sys-devel/binutils:  2.16.1-r3
sys-devel/gcc-config: 1.3.14
sys-devel/libtool:   1.5.22
virtual/os-headers:  2.6.19.2-r2
ACCEPT_KEYWORDS="amd64"
AUTOCLEAN="yes"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=k8 -O2 -pipe -msse3"
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/X11/xkb /usr/share/config"
CONFIG_PROTECT_MASK="/etc/env.d /etc/env.d/java/ /etc/gconf
/etc/java-config/vms/ /etc/revdep-rebuild /etc/splash /etc/terminfo
/etc/texmf/web2c"
CXXFLAGS="-march=k8 -O2 -pipe -msse3"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoconfig ccache distlocks metadata-transfer parallel-fetch sandbox
sfperms strict"
GENTOO_MIRRORS="http://ftp.club-internet.fr/pub/mirrors/gentoo"
LANG="es_ES.UTF-8"
LC_ALL="es_ES.UTF-8"
LINGUAS="es en_US"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress
--force --whole-file --delete --delete-after --stats --timeout=180
--exclude='/distfiles' --exclude='/local' --exclude='/packages'"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/portage/local/layman/sunrise
/usr/portage/local/layman/armagetron /usr/local/portage"
SYNC="rsync://rsync.europe.gentoo.org/gentoo-portage"
USE="X a52 aac aalib acpi alsa alsa_cards_ali5451 alsa_cards_als4000
alsa_cards_atiixp alsa_cards_atiixp-modem alsa_cards_bt87x alsa_cards_ca0106
alsa_cards_cmipci alsa_cards_emu10k1x alsa_cards_ens1370 alsa_cards_ens1371
alsa_cards_es1938 alsa_cards_es1968 alsa_cards_fm801 alsa_cards_hda-intel
alsa_cards_intel8x0 alsa_cards_intel8x0m alsa_cards_maestro3 alsa_cards_trident
alsa_cards_usb-audio alsa_cards_via82xx alsa_cards_via82xx-modem
alsa_cards_ymfpci alsa_pcm_plugins_adpcm alsa_pcm_plugins_alaw
alsa_pcm_plugins_asym alsa_pcm_plugins_copy alsa_pcm_plugins_dmix
alsa_pcm_plugins_dshare alsa_pcm_plugins_dsnoop alsa_pcm_plugins_empty
alsa_pcm_plugins_extplug alsa_pcm_plugins_file alsa_pcm_plugins_hooks
alsa_pcm_plugins_iec958 alsa_pcm_plugins_ioplug alsa_pcm_plugins_ladspa
alsa_pcm_plugins_lfloat alsa_pcm_plugins_linear alsa_pcm_plugins_meter
alsa_pcm_plugins_mulaw alsa_pcm_plugins_multi alsa_pcm_plugins_null
alsa_pcm_plugins_plug alsa_pcm_plugins_rate alsa_pcm_plugins_route
alsa_pcm_plugins_share alsa_pcm_plugins_shm alsa_pcm_plugins_softvol amd64
apache2 arts asf audiofile bash-completion beagle bitmap-fonts bzip2 bzlib
cairo caps cdb cdda cddb cdparanoia cdr cli cpdflib cracklib cross crypt cscope
cups curl dbus dga divx4linux dlloader dri dts dvb dvb_cards_usb-dib0700 dvd
dvdr dvdread elibc_glibc encode erandom escreen esd evo evolution exif fam
fbcon flac foomaticdb fortran ftp galago gb gcj ggi gif gimp gimpprint glitz
glut glx gnome gnome-print gphoto2 gpm gstreamer gtk gtk2 gtkhtml hal iconv idn
imagemagick imlib input_devices_keyboard input_devices_mouse isdnlog ithreads
jabber jack java jpeg kde kdeenablefinal kdehiddenvisibility kernel_linux latex
lcd_devices_bayrad lcd_devices_cfontz lcd_devices_cfontz633 lcd_devices_glk
lcd_devices_hd44780 lcd_devices_lb216 lcd_devices_lcdm001 lcd_devices_mtxorb
lcd_devices_ncurses lcd_devices_text lcms libg++ libnotify linguas_en_US
linguas_es logrotate mad madwifi midi mikmod mime mng mono motif mp3 mpeg mpi
mplayer musepack musicbrainz nas nautilus ncurses nethack network nls nocardbus
nptl nptlonly nvidia ogg oggvorbis openal opengl oss pam pcre pdf perl pic
plotutils png posix ppds pppd python qt3 qt4 quicktime readline reflection rtc
ruby scanner sdl seamonkey session slang slp sockets spell spl ssl svg sysvipc
tcltk tcpd tetex theora threads tiff timidity tk totem trayicon truetype
truetype-fonts type1-fonts udev unicode usb userland_GNU v4l v4l2 vcd
video_cards_fbdev video_cards_nv video_cards_nvidia video_cards_vesa
video_cards_vga videos vim vorbis wma wmf xcomposite xine xml xml2 xorg xpm xv
xvid zlib"
Unset:  CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LDFLAGS,
PORTAGE_RSYNC_EXTRA_OPTS


Reproducible: Always

------- Comment #1 From Daniel Drake 2007-02-09 15:09:24 0000 -------
Please attach kernel .config

------- Comment #2 From Pacho Ramos 2007-02-09 15:41:23 0000 -------
Created an attachment (id=109648) [details]
config

------- Comment #3 From Pacho Ramos 2007-02-18 12:29:33 0000 -------
Seems that more people has the same problem, disable console speech is not the
properly fix for this bug :-(

Thanks a lot

------- Comment #4 From Phillip Hardy 2007-02-19 22:16:40 0000 -------
(In reply to comment #3)
> Seems that more people has the same problem, disable console speech is not the
> properly fix for this bug :-(
> 
> Thanks a lot
> 

Same problem here AMD64 also.
listed Temp fix works. 

------- Comment #5 From Daniel Drake 2007-02-24 18:13:06 0000 -------
Can't reproduce here. In /usr/src/linux/drivers/char/speakup.c, find these
lines at  the top:

#include <linux/selection.h>
#include <asm/uaccess.h> /* copy_from|to|user( ) and others */
#include <linux/unistd.h>

Add another line under that which says:

#include <linux/console_struct.h>

Does that help?

------- Comment #6 From Pacho Ramos 2007-02-24 19:11:44 0000 -------
The problem persists (In reply to comment #5)
> Can't reproduce here. In /usr/src/linux/drivers/char/speakup.c, find these
> lines at  the top:
> 
> #include <linux/selection.h>
> #include <asm/uaccess.h> /* copy_from|to|user( ) and others */
> #include <linux/unistd.h>
> 
> Add another line under that which says:
> 
> #include <linux/console_struct.h>
> 
> Does that help?
> 

The problem persists. I am on amd64 arch

Thanks

------- Comment #7 From Pacho Ramos 2007-03-04 14:21:42 0000 -------
The problem doesn't affect to vanilla-sources and ck-sources, I think that the
problem is caused by 4400_speakup-20070204.patch provided in
genpatches-2.6.20-1.extras.tar.bz2

Thanks

------- Comment #8 From Pacho Ramos 2007-03-04 14:26:53 0000 -------
Created an attachment (id=112063) [details]
4400_speakup-20070204.patch

I attach the problematic patch

------- Comment #9 From Daniel Drake 2007-03-04 17:03:12 0000 -------
Indeed, that was already known. Problem is that I can't reproduce it -- have
specifically tested on 4 systems.

------- Comment #10 From Pacho Ramos 2007-03-04 17:18:42 0000 -------
(In reply to comment #9)
> Indeed, that was already known. Problem is that I can't reproduce it -- have
> specifically tested on 4 systems.
> 

I am really surprised :-O

I have run:
emerge -C sys-kernel/gentoo-sources-2.6.20
cd /usr/src
rm -rf linux-2.6.20-gentoo
emerge gentoo-sources

And the problem persists :-/

------- Comment #11 From Pacho Ramos 2007-03-04 17:51:48 0000 -------
It works regenerating the config, this is the diff:

< CONFIG_SPEAKUP=m
---
> CONFIG_SPEAKUP=y

Seems that CONFIG_SPEAKUP cannot be compiled as a module, if I compile it into
the kernel, it works. Is this the normal behavior? :-|

Thanks a lot

------- Comment #12 From Michiel de Bruijne 2007-03-05 07:25:54 0000 -------
(In reply to comment #9)
> Indeed, that was already known. Problem is that I can't reproduce it -- have
> specifically tested on 4 systems.
> 

FWIW; I was unable to reproduce the problem on any i386 (kernel architecture
not actually an i386), but on every x86_x64 I have tested I was able to
reproduce this problem.

------- Comment #13 From Daniel Drake 2007-03-06 18:31:47 0000 -------
Thanks for the hint, I can reproduce this with the modular build

------- Comment #14 From Daniel Drake 2007-03-10 04:46:32 0000 -------
This was fixed in gentoo-sources-2.6.20-r1