Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 270450

Summary: net-proxy/squid-3.0.13,14 fails to compile, le32 does not name a type
Product: Gentoo Linux Reporter: Patryk Rzadzinski <patryk>
Component: [OLD] ServerAssignee: Gentoo Network Proxy Developers (OBSOLETE) <net-proxy+disabled>
Status: RESOLVED FIXED    
Severity: normal CC: bas, hppa, krzysztof.kozlowski, nicolasbock, scwang, spam, toto, web
Priority: High    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Bug Depends on:    
Bug Blocks: 269096    
Attachments: Squid 3.0 patch for linux sys-kernel/linux-headers 2.6.27-r2
Squid 3.0.15 ebuild patch for linux sys-kernel/linux-headers 2.6.27-r2

Description Patryk Rzadzinski 2009-05-19 16:30:16 UTC
Hello,

I've been trying to compile squid 3.0.13 and 3.0.14-r2, however I am always getting the same error: 

cc1plus: warning: switch '-fhuge-objects' is no longer supported
depbase=`echo urn.o | sed 's|[^/]*$|.deps/&|;s|\.o$||'`;\
	x86_64-pc-linux-gnu-g++ -DHAVE_CONFIG_H -DDEFAULT_CONFIG_FILE=\"/etc/squid/squid.conf\" -I. -I../include -I. -I. -I../include -I../include -I../lib/libTrie/include   -I/usr/include/libxml2  -Wall -Wpointer-arith -Wwrite-strings -fhuge-objects -D_REENTRANT -m64 -O2 -pipe -march=nocona -mtune=nocona -MT urn.o -MD -MP -MF $depbase.Tpo -c -o urn.o urn.cc &&\
	mv -f $depbase.Tpo $depbase.Po
In file included from /usr/include/sys/capability.h:25,
                 from tools.cc:50:
/usr/include/linux/capability.h:73: error: '__le32' does not name a type
/usr/include/linux/capability.h:75: error: '__le32' does not name a type
/usr/include/linux/capability.h:76: error: '__le32' does not name a type
cc1plus: warning: switch '-fhuge-objects' is no longer supported
make[3]: *** [tools.o] Error 1
make[3]: *** Waiting for unfinished jobs....
make[3]: Leaving directory `/var/tmp/portage/net-proxy/squid-3.0.14-r2/work/squid-3.0.STABLE14/src'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/var/tmp/portage/net-proxy/squid-3.0.14-r2/work/squid-3.0.STABLE14/src'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/var/tmp/portage/net-proxy/squid-3.0.14-r2/work/squid-3.0.STABLE14/src'
make: *** [all-recursive] Error 1
 * 
 * ERROR: net-proxy/squid-3.0.14-r2 failed.
 * Call stack:
 *               ebuild.sh, line   48:  Called src_compile
 *             environment, line 3560:  Called _eapi2_src_compile
 *               ebuild.sh, line  625:  Called die
 * The specific snippet of code:
 *   		emake || die "emake failed"
 *  The die message:
 *   emake failed
 * 
 * If you need support, post the topmost build error, and the call stack if relevant.
 * A complete build log is located at '/var/tmp/portage/net-proxy/squid-3.0.14-r2/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/net-proxy/squid-3.0.14-r2/temp/environment'.
 * 

>>> Failed to emerge net-proxy/squid-3.0.14-r2, Log file: (...)

What I tried to do without getting this solved:
1. new kernel, 2.6.29-r4
2. new linux headers, reinstall old linux headers

Here's my emerge --info:

Portage 2.1.6.11 (default/linux/amd64/2008.0, gcc-4.3.3, glibc-2.8_p20080602-r1, 2.6.29-gentoo-r4 x86_64)
=================================================================
System uname: Linux-2.6.29-gentoo-r4-x86_64-Intel-R-_Xeon-R-_CPU_X3320_@_2.50GHz-with-glibc2.2.5
Timestamp of tree: Tue, 19 May 2009 08:00:01 +0000
app-shells/bash:     3.2_p39
dev-lang/python:     2.5.4-r2
sys-apps/baselayout: 1.12.11.1
sys-apps/sandbox:    1.6-r2
sys-devel/autoconf:  2.63
sys-devel/automake:  1.10.2
sys-devel/binutils:  2.18-r3
sys-devel/gcc-config: 1.4.1
sys-devel/libtool:   1.5.26
virtual/os-headers:  2.6.29
ACCEPT_KEYWORDS="amd64"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2 -pipe -march=nocona -mtune=nocona"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/gconf /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo /etc/udev/rules.d"
CXXFLAGS="-O2 -pipe -march=nocona -mtune=nocona"
DISTDIR="/usr/portage/distfiles"
FEATURES="distlocks fixpackages parallel-fetch protect-owned sandbox sfperms strict unmerge-orphans userfetch"
GENTOO_MIRRORS="http://gentoo.po.opole.pl http://gentoo.mirror.pw.edu.pl/ http://ftp.vectranet.pl/gentoo/"
LDFLAGS="-Wl,-O1"
MAKEOPTS="-j5"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
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"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="acl amd64 berkdb bzip2 caps cli cracklib crypt cups dri gdbm gmp gnutls iconv isdnlog ithreads libffi logrotate md5sum midi mmx mudflap multilib ncurses nls nptl nptlonly ntp openmp openntpd pam pcre perl pppd python readline reflection ruby session spl sqlite sse sse2 ssl ssse3 sysfs tcpd threads unicode urandom x509 xinetd xorg zlib zsh" 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 mmap_emul 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 evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" USERLAND="GNU" VIDEO_CARDS="fbdev glint i810 intel mach64 mga neomagic nv r128 radeon savage sis tdfx trident vesa vga via vmware voodoo"
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, FFLAGS, INSTALL_MASK, LANG, LC_ALL, LINGUAS, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, PORTDIR_OVERLAY


Reproducible: Always

Steps to Reproduce:
1.emerge squid
2.
3.
Comment 1 scwang 2009-05-20 06:58:00 UTC
> In file included from /usr/include/sys/capability.h:25,
>                  from tools.cc:50:
> /usr/include/linux/capability.h:73: error: '__le32' does not name a type
> /usr/include/linux/capability.h:75: error: '__le32' does not name a type
> /usr/include/linux/capability.h:76: error: '__le32' does not name a type
> cc1plus: warning: switch '-fhuge-objects' is no longer supported
> make[3]: *** [tools.o] Error 1

I encountered the same problem. After checking files tools.cc, /usr/include/linux/capability.h, /usr/include/linux/types.h, I find the problem is the result of an 'ugly glue' in tools.cc file. That is in file tools.cc as following:

/* Ugly glue to get around linux header madness colliding with glibc */
#define _LINUX_TYPES_H
#define _LINUX_FS_H
typedef uint32_t __u32;
#include <sys/capability.h>

My solution is to comment out this "Ugly glue" as following:

//#define _LINUX_TYPES_H
#define _LINUX_FS_H
//typedef uint32_t __u32;

Then you can compile it! Hope it help you.
Comment 2 Krzysztof Kozlowski 2009-05-21 09:47:37 UTC
Created attachment 192017 [details, diff]
Squid 3.0 patch for linux sys-kernel/linux-headers 2.6.27-r2

After upgrading sys-kernel/linux-headers to 2.6.27-r2 - the same problem (I have tried squid 3.0.13, 3.0.14, 3.0.15). Scwang's patch works well for me (Squid 3.0.15, linux-headers 2.6.27-r2, x86, GCC 4.3.2-r3, Glibc 2.8_p20080602-r1).
Comment 3 Krzysztof Kozlowski 2009-05-21 09:48:23 UTC
Created attachment 192018 [details, diff]
Squid 3.0.15 ebuild patch for linux sys-kernel/linux-headers 2.6.27-r2

Squid 3.0.15 ebuild patch
Comment 4 Jeroen Roovers (RETIRED) gentoo-dev 2009-05-21 20:17:26 UTC
Confirmed.
Comment 5 Justin Lecher (RETIRED) gentoo-dev 2009-05-26 14:58:16 UTC
*** Bug 271311 has been marked as a duplicate of this bug. ***
Comment 6 Alex Glazunov 2009-06-08 06:41:20 UTC
Confirm this bug for squid 3.0.15
Comment 7 Lars Wendler (Polynomial-C) (RETIRED) gentoo-dev 2009-06-14 00:48:46 UTC
*** Bug 273713 has been marked as a duplicate of this bug. ***
Comment 8 Alin Năstac (RETIRED) gentoo-dev 2009-06-16 19:35:36 UTC
Fixed in versions 3.0.15, 3.0.16 and 3.1.0.7_beta. Thanks!