Compile error with 2.1.7-2.6.14.3-200511261227

Discuss usability issues, general maintenance, and general support issues for a grsecurity-enabled system.

Compile error with 2.1.7-2.6.14.3-200511261227

Postby linuxuser » Sat Nov 26, 2005 7:52 pm

Same config with 2.6.13-2 worked fine.

CC arch/i386/mm/fault.o
arch/i386/mm/fault.c:354:1: directives may not be used inside a macro argument
arch/i386/mm/fault.c:352:49: unterminated argument list invoking macro "likely"
arch/i386/mm/fault.c: In function `do_page_fault':
arch/i386/mm/fault.c:358: `likely' undeclared (first use in this function)
arch/i386/mm/fault.c:358: (Each undeclared identifier is reported only once
arch/i386/mm/fault.c:358: for each function it appears in.)
arch/i386/mm/fault.c:358: parse error before ')' token
arch/i386/mm/fault.c:260: warning: unused variable `vma'
arch/i386/mm/fault.c:262: warning: unused variable `write'
arch/i386/mm/fault.c:266: warning: unused variable `pte_mask'
arch/i386/mm/fault.c:318: label `not_pax_fault' used but not defined
arch/i386/mm/fault.c:312: label `bad_area_nopax' used but not defined
arch/i386/mm/fault.c:304: label `bad_area_nosemaphore' used but not defined
arch/i386/mm/fault.c:299: label `vmalloc_fault' used but not defined
arch/i386/mm/fault.c: At top level:
arch/i386/mm/fault.c:367: warning: type defaults to `int' in declaration of `pte_mask'
arch/i386/mm/fault.c:367: `error_code' undeclared here (not in a function)
arch/i386/mm/fault.c:367: warning: data definition has no type or storage class
arch/i386/mm/fault.c:372: parse error before "volatile"
arch/i386/mm/fault.c:395: warning: type defaults to `int' in declaration of `kunmap_atomic'
arch/i386/mm/fault.c:395: warning: parameter names (without types) in function declaration
arch/i386/mm/fault.c:395: conflicting types for `kunmap_atomic'
include/asm/highmem.h:72: previous declaration of `kunmap_atomic'
arch/i386/mm/fault.c:395: warning: data definition has no type or storage class
arch/i386/mm/fault.c:396: parse error before "do"
arch/i386/mm/fault.c:421: parse error before '&' token
arch/i386/mm/fault.c:421: warning: type defaults to `int' in declaration of `down_read'
arch/i386/mm/fault.c:421: warning: function declaration isn't a prototype
arch/i386/mm/fault.c:421: conflicting types for `down_read'
include/linux/rwsem.h:42: previous declaration of `down_read'
arch/i386/mm/fault.c:421: warning: data definition has no type or storage class
arch/i386/mm/fault.c:424: warning: type defaults to `int' in declaration of `vma'
arch/i386/mm/fault.c:424: `mm' undeclared here (not in a function)
arch/i386/mm/fault.c:424: `address' undeclared here (not in a function)
arch/i386/mm/fault.c:424: warning: initialization makes integer from pointer without a cast
arch/i386/mm/fault.c:424: initializer element is not constant
arch/i386/mm/fault.c:424: warning: data definition has no type or storage class
arch/i386/mm/fault.c:425: parse error before "if"
arch/i386/mm/fault.c:449: warning: type defaults to `int' in declaration of `write'
arch/i386/mm/fault.c:449: warning: data definition has no type or storage class
arch/i386/mm/fault.c:450: parse error before "switch"
arch/i386/mm/fault.c:498: parse error before '&' token
arch/i386/mm/fault.c:498: warning: type defaults to `int' in declaration of `up_read'
arch/i386/mm/fault.c:498: warning: function declaration isn't a prototype
arch/i386/mm/fault.c:498: conflicting types for `up_read'
include/linux/rwsem.h:88: previous declaration of `up_read'
arch/i386/mm/fault.c:498: warning: data definition has no type or storage class
arch/i386/mm/fault.c:516: parse error before numeric constant
arch/i386/mm/fault.c:516: warning: type defaults to `int' in declaration of `do_exit'
arch/i386/mm/fault.c:516: warning: function declaration isn't a prototype
arch/i386/mm/fault.c:516: conflicting types for `do_exit'
include/linux/kernel.h:93: previous declaration of `do_exit'
arch/i386/mm/fault.c:516: warning: data definition has no type or storage class
arch/i386/mm/fault.c:531: parse error before '(' token
arch/i386/mm/fault.c:532: parse error before numeric constant
arch/i386/mm/fault.c:532: warning: type defaults to `int' in declaration of `do_exit'
arch/i386/mm/fault.c:532: warning: function declaration isn't a prototype
arch/i386/mm/fault.c:532: warning: data definition has no type or storage class
arch/i386/mm/fault.c:553: parse error before numeric constant
arch/i386/mm/fault.c:553: warning: type defaults to `int' in declaration of `force_sig_info_fault'
arch/i386/mm/fault.c:553: warning: function declaration isn't a prototype
arch/i386/mm/fault.c:553: conflicting types for `force_sig_info_fault'
arch/i386/mm/fault.c:208: previous declaration of `force_sig_info_fault'
arch/i386/mm/fault.c:553: warning: data definition has no type or storage class
arch/i386/mm/fault.c:591: parse error before numeric constant
arch/i386/mm/fault.c:591: warning: type defaults to `int' in declaration of `bust_spinlocks'
arch/i386/mm/fault.c:591: warning: function declaration isn't a prototype
arch/i386/mm/fault.c:591: conflicting types for `bust_spinlocks'
arch/i386/mm/fault.c:41: previous declaration of `bust_spinlocks'
arch/i386/mm/fault.c:591: warning: data definition has no type or storage class
arch/i386/mm/fault.c:622: parse error before string constant
arch/i386/mm/fault.c:622: warning: type defaults to `int' in declaration of `printk'
arch/i386/mm/fault.c:622: warning: function declaration isn't a prototype
arch/i386/mm/fault.c:622: warning: data definition has no type or storage class
arch/i386/mm/fault.c:623: parse error before string constant
arch/i386/mm/fault.c:623: warning: type defaults to `int' in declaration of `printk'
arch/i386/mm/fault.c:623: warning: function declaration isn't a prototype
arch/i386/mm/fault.c:623: warning: data definition has no type or storage class
arch/i386/mm/fault.c:624: parse error before string constant
arch/i386/mm/fault.c:624: warning: type defaults to `int' in declaration of `printk'
arch/i386/mm/fault.c:624: warning: function declaration isn't a prototype
arch/i386/mm/fault.c:624: warning: data definition has no type or storage class
arch/i386/mm/fault.c:632: warning: type defaults to `int' in declaration of `pgd'
arch/i386/mm/fault.c:632: conflicting types for `pgd'
arch/i386/mm/fault.c:627: previous declaration of `pgd'
arch/i386/mm/fault.c:632: `index' undeclared here (not in a function)
arch/i386/mm/fault.c:632: braced-group within expression allowed only inside a function
arch/i386/mm/fault.c:632: parse error before ')' token
arch/i386/mm/fault.c:633: parse error before string constant
arch/i386/mm/fault.c:633: warning: type defaults to `int' in declaration of `printk'
arch/i386/mm/fault.c:633: warning: function declaration isn't a prototype
arch/i386/mm/fault.c:633: parse error before "unsigned"
arch/i386/mm/fault.c:636: warning: type defaults to `int' in declaration of `pmd'
arch/i386/mm/fault.c:636: conflicting types for `pmd'
arch/i386/mm/fault.c:629: previous declaration of `pmd'
arch/i386/mm/fault.c:636: `address' undeclared here (not in a function)
arch/i386/mm/fault.c:636: warning: data definition has no type or storage class
arch/i386/mm/fault.c:637: parse error before string constant
arch/i386/mm/fault.c:637: warning: type defaults to `int' in declaration of `printk'
arch/i386/mm/fault.c:637: warning: function declaration isn't a prototype
arch/i386/mm/fault.c:637: parse error before "unsigned"
arch/i386/mm/fault.c:655: parse error before string constant
arch/i386/mm/fault.c:655: warning: type defaults to `int' in declaration of `die'
arch/i386/mm/fault.c:655: warning: function declaration isn't a prototype
arch/i386/mm/fault.c:655: conflicting types for `die'
arch/i386/mm/fault.c:34: previous declaration of `die'
arch/i386/mm/fault.c:655: warning: data definition has no type or storage class
arch/i386/mm/fault.c:656: parse error before numeric constant
arch/i386/mm/fault.c:656: warning: type defaults to `int' in declaration of `bust_spinlocks'
arch/i386/mm/fault.c:656: warning: function declaration isn't a prototype
arch/i386/mm/fault.c:656: warning: data definition has no type or storage class
arch/i386/mm/fault.c:657: parse error before numeric constant
arch/i386/mm/fault.c:657: warning: type defaults to `int' in declaration of `do_exit'
arch/i386/mm/fault.c:657: warning: function declaration isn't a prototype
arch/i386/mm/fault.c:657: warning: data definition has no type or storage class
arch/i386/mm/fault.c:663: parse error before ':' token
arch/i386/mm/fault.c:667: parse error before '&' token
arch/i386/mm/fault.c:667: warning: type defaults to `int' in declaration of `down_read'
arch/i386/mm/fault.c:667: warning: function declaration isn't a prototype
arch/i386/mm/fault.c:667: warning: data definition has no type or storage class
arch/i386/mm/fault.c:670: parse error before string constant
arch/i386/mm/fault.c:670: warning: type defaults to `int' in declaration of `printk'
arch/i386/mm/fault.c:670: warning: function declaration isn't a prototype
arch/i386/mm/fault.c:670: warning: data definition has no type or storage class
arch/i386/mm/fault.c:689: parse error before numeric constant
arch/i386/mm/fault.c:703: conflicting types for `pgd'
arch/i386/mm/fault.c:632: previous declaration of `pgd'
arch/i386/mm/fault.c:705: conflicting types for `pmd'
arch/i386/mm/fault.c:636: previous declaration of `pmd'
arch/i386/mm/fault.c:708: warning: type defaults to `int' in declaration of `pgd_paddr'
arch/i386/mm/fault.c:708: conflicting types for `pgd_paddr'
arch/i386/mm/fault.c:702: previous declaration of `pgd_paddr'
arch/i386/mm/fault.c:708: braced-group within expression allowed only inside a function
arch/i386/mm/fault.c:708: warning: type defaults to `int' in declaration of `__dummy'
arch/i386/mm/fault.c:708: warning: data definition has no type or storage class
arch/i386/mm/fault.c:708: parse error before '}' token
arch/i386/mm/fault.c:709: warning: type defaults to `int' in declaration of `pgd'
arch/i386/mm/fault.c:709: conflicting types for `pgd'
arch/i386/mm/fault.c:703: previous declaration of `pgd'
arch/i386/mm/fault.c:709: `index' undeclared here (not in a function)
arch/i386/mm/fault.c:709: warning: data definition has no type or storage class
arch/i386/mm/fault.c:710: warning: type defaults to `int' in declaration of `pgd_k'
arch/i386/mm/fault.c:710: conflicting types for `pgd_k'
arch/i386/mm/fault.c:703: previous declaration of `pgd_k'
arch/i386/mm/fault.c:710: `index' undeclared here (not in a function)
arch/i386/mm/fault.c:710: warning: data definition has no type or storage class
arch/i386/mm/fault.c:712: parse error before "if"
arch/i386/mm/fault.c:721: warning: type defaults to `int' in declaration of `pud'
arch/i386/mm/fault.c:721: conflicting types for `pud'
arch/i386/mm/fault.c:704: previous declaration of `pud'
arch/i386/mm/fault.c:721: `address' undeclared here (not in a function)
arch/i386/mm/fault.c:721: warning: passing arg 1 of `pud_offset' makes pointer from integer without a cast
arch/i386/mm/fault.c:721: warning: data definition has no type or storage class
arch/i386/mm/fault.c:722: warning: type defaults to `int' in declaration of `pud_k'
arch/i386/mm/fault.c:722: conflicting types for `pud_k'
arch/i386/mm/fault.c:704: previous declaration of `pud_k'
arch/i386/mm/fault.c:722: `address' undeclared here (not in a function)
arch/i386/mm/fault.c:722: warning: passing arg 1 of `pud_offset' makes pointer from integer without a cast
arch/i386/mm/fault.c:722: warning: data definition has no type or storage class
arch/i386/mm/fault.c:723: parse error before "if"
arch/i386/mm/fault.c:726: warning: type defaults to `int' in declaration of `pmd'
arch/i386/mm/fault.c:726: conflicting types for `pmd'
arch/i386/mm/fault.c:705: previous declaration of `pmd'
arch/i386/mm/fault.c:726: `address' undeclared here (not in a function)
arch/i386/mm/fault.c:726: warning: passing arg 1 of `pmd_offset' makes pointer from integer without a cast
arch/i386/mm/fault.c:726: warning: data definition has no type or storage class
arch/i386/mm/fault.c:727: warning: type defaults to `int' in declaration of `pmd_k'
arch/i386/mm/fault.c:727: conflicting types for `pmd_k'
arch/i386/mm/fault.c:705: previous declaration of `pmd_k'
arch/i386/mm/fault.c:727: `address' undeclared here (not in a function)
arch/i386/mm/fault.c:727: warning: passing arg 1 of `pmd_offset' makes pointer from integer without a cast
arch/i386/mm/fault.c:727: warning: data definition has no type or storage class
arch/i386/mm/fault.c:728: parse error before "if"
arch/i386/mm/fault.c:730: parse error before '=' token
arch/i386/mm/fault.c:732: warning: type defaults to `int' in declaration of `pte_k'
arch/i386/mm/fault.c:732: conflicting types for `pte_k'
arch/i386/mm/fault.c:706: previous declaration of `pte_k'
arch/i386/mm/fault.c:732: invalid type argument of `unary *'
arch/i386/mm/fault.c:732: `address' undeclared here (not in a function)
arch/i386/mm/fault.c:732: warning: data definition has no type or storage class
arch/i386/mm/fault.c:733: parse error before "if"
arch/i386/mm/fault.c:553: warning: `force_sig_info_fault' defined but not used
make[1]: *** [arch/i386/mm/fault.o] Error 1
make: *** [arch/i386/mm] Error 2


#
# PaX
#
CONFIG_PAX=y

#
# PaX Control
#
# CONFIG_PAX_SOFTMODE is not set
CONFIG_PAX_EI_PAX=y
CONFIG_PAX_PT_PAX_FLAGS=y
CONFIG_PAX_NO_ACL_FLAGS=y
# CONFIG_PAX_HAVE_ACL_FLAGS is not set
# CONFIG_PAX_HOOK_ACL_FLAGS is not set

#
# Non-executable pages
#
CONFIG_PAX_NOEXEC=y
CONFIG_PAX_PAGEEXEC=y
CONFIG_PAX_SEGMEXEC=y
# CONFIG_PAX_DEFAULT_PAGEEXEC is not set
CONFIG_PAX_DEFAULT_SEGMEXEC=y
# CONFIG_PAX_EMUTRAMP is not set
CONFIG_PAX_MPROTECT=y
# CONFIG_PAX_NOELFRELOCS is not set
# CONFIG_PAX_KERNEXEC is not set

#
# Address Space Layout Randomization
#
CONFIG_PAX_ASLR=y
CONFIG_PAX_RANDKSTACK=y
CONFIG_PAX_RANDUSTACK=y
CONFIG_PAX_RANDMMAP=y
CONFIG_PAX_NOVSYSCALL=y

#
# Grsecurity
#
CONFIG_GRKERNSEC=y
# CONFIG_GRKERNSEC_LOW is not set
# CONFIG_GRKERNSEC_MEDIUM is not set
# CONFIG_GRKERNSEC_HIGH is not set
CONFIG_GRKERNSEC_CUSTOM=y

#
# Address Space Protection
#
CONFIG_GRKERNSEC_KMEM=y
CONFIG_GRKERNSEC_IO=y
CONFIG_GRKERNSEC_PROC_MEMMAP=y
# CONFIG_GRKERNSEC_BRUTE is not set
CONFIG_GRKERNSEC_HIDESYM=y

#
# Role Based Access Control Options
#
CONFIG_GRKERNSEC_ACL_HIDEKERN=y
CONFIG_GRKERNSEC_ACL_MAXTRIES=3
CONFIG_GRKERNSEC_ACL_TIMEOUT=30

#
# Filesystem Protections
#
CONFIG_GRKERNSEC_PROC=y
CONFIG_GRKERNSEC_PROC_USER=y
CONFIG_GRKERNSEC_PROC_ADD=y
CONFIG_GRKERNSEC_LINK=y
CONFIG_GRKERNSEC_FIFO=y
CONFIG_GRKERNSEC_CHROOT=y
CONFIG_GRKERNSEC_CHROOT_MOUNT=y
CONFIG_GRKERNSEC_CHROOT_DOUBLE=y
CONFIG_GRKERNSEC_CHROOT_PIVOT=y
CONFIG_GRKERNSEC_CHROOT_CHDIR=y
CONFIG_GRKERNSEC_CHROOT_CHMOD=y
CONFIG_GRKERNSEC_CHROOT_FCHDIR=y
CONFIG_GRKERNSEC_CHROOT_MKNOD=y
CONFIG_GRKERNSEC_CHROOT_SHMAT=y
CONFIG_GRKERNSEC_CHROOT_UNIX=y
CONFIG_GRKERNSEC_CHROOT_FINDTASK=y
CONFIG_GRKERNSEC_CHROOT_NICE=y
CONFIG_GRKERNSEC_CHROOT_SYSCTL=y
CONFIG_GRKERNSEC_CHROOT_CAPS=y

#
# Kernel Auditing
#
# CONFIG_GRKERNSEC_AUDIT_GROUP is not set
# CONFIG_GRKERNSEC_EXECLOG is not set
# CONFIG_GRKERNSEC_RESLOG is not set
# CONFIG_GRKERNSEC_CHROOT_EXECLOG is not set
# CONFIG_GRKERNSEC_AUDIT_CHDIR is not set
CONFIG_GRKERNSEC_AUDIT_MOUNT=y
# CONFIG_GRKERNSEC_AUDIT_IPC is not set
# CONFIG_GRKERNSEC_SIGNAL is not set
CONFIG_GRKERNSEC_FORKFAIL=y
CONFIG_GRKERNSEC_TIME=y
CONFIG_GRKERNSEC_PROC_IPADDR=y
# CONFIG_GRKERNSEC_AUDIT_TEXTREL is not set

#
# Executable Protections
#
CONFIG_GRKERNSEC_EXECVE=y
# CONFIG_GRKERNSEC_SHM is not set
CONFIG_GRKERNSEC_DMESG=y
CONFIG_GRKERNSEC_RANDPID=y
CONFIG_GRKERNSEC_TPE=y
CONFIG_GRKERNSEC_TPE_ALL=y
# CONFIG_GRKERNSEC_TPE_INVERT is not set
CONFIG_GRKERNSEC_TPE_GID=1005

#
# Network Protections
#
CONFIG_GRKERNSEC_RANDNET=y
CONFIG_GRKERNSEC_RANDSRC=y
CONFIG_GRKERNSEC_SOCKET=y
CONFIG_GRKERNSEC_SOCKET_ALL=y
CONFIG_GRKERNSEC_SOCKET_ALL_GID=1004
CONFIG_GRKERNSEC_SOCKET_CLIENT=y
CONFIG_GRKERNSEC_SOCKET_CLIENT_GID=1003
CONFIG_GRKERNSEC_SOCKET_SERVER=y
CONFIG_GRKERNSEC_SOCKET_SERVER_GID=1002

#
# Sysctl support
#
# CONFIG_GRKERNSEC_SYSCTL is not set

#
# Logging Options
#
CONFIG_GRKERNSEC_FLOODTIME=10
CONFIG_GRKERNSEC_FLOODBURST=4
CONFIG_KEYS=y
# CONFIG_KEYS_DEBUG_PROC_KEYS is not set
CONFIG_SECURITY=y
CONFIG_SECURITY_NETWORK=y
CONFIG_SECURITY_CAPABILITIES=y
# CONFIG_SECURITY_ROOTPLUG is not set
CONFIG_SECURITY_SECLVL=m
# CONFIG_SECURITY_SELINUX is not set
[/quote]
linuxuser
 
Posts: 16
Joined: Wed May 11, 2005 4:59 pm

Postby spender » Sun Nov 27, 2005 12:38 pm

Can you mail me your complete config? I'm unable to reproduce this problem.

-Brad
spender
 
Posts: 2185
Joined: Wed Feb 20, 2002 8:00 pm

Config e-mailed

Postby linuxuser » Sun Nov 27, 2005 5:39 pm

Sent the full config to your e-mail. Thanks for looking into this. It may simply be that I'm doing something unusual in my config, in which case, I can probably change it. :-)
linuxuser
 
Posts: 16
Joined: Wed May 11, 2005 4:59 pm

Postby spender » Sun Nov 27, 2005 7:55 pm

I just successfully compiled a kernel with your configuration. Can you check to make sure your kernel source and patch haven't been corrupted?

-Brad
spender
 
Posts: 2185
Joined: Wed Feb 20, 2002 8:00 pm

Archives and patches check out

Postby linuxuser » Sun Nov 27, 2005 9:00 pm

The archives look good. Perhaps this a problem with older redhat distributions? I'm building this on a rh9 box.

$ gpg grsecurity-2.1.7-2.6.14.3-200511261227.patch.gz.sign
gpg: Signature made Sat 26 Nov 2005 12:33:58 PM EST using DSA key ID 4245D46A
gpg: Good signature from "Bradley Spengler (spender) <spender@grsecurity.net>"
gpg: aka "Bradley Spengler (spender) <spender@grsecurity.net>"
gpg: checking the trustdb
gpg: no ultimately trusted keys found
gpg: WARNING: This key is not certified with a trusted signature!
gpg: There is no indication that the signature belongs to the owner.
Primary key fingerprint: 9F74 393D 7E7F FF3C 6500 E778 9879 B649 4245 D46A
$ gpg linux-2.6.14.3.tar.bz2.sign
gpg: Signature made Thu 24 Nov 2005 05:53:27 PM EST using DSA key ID 517D0F0E
gpg: Good signature from "Linux Kernel Archives Verification Key <ftpadmin@kernel.org>"
gpg: aka "Linux Kernel Archives Verification Key <ftpadmin@kernel.org>"
gpg: WARNING: This key is not certified with a trusted signature!
gpg: There is no indication that the signature belongs to the owner.
Primary key fingerprint: C75D C40A 11D7 AF88 9981 ED5B C86B A06A 517D 0F0E
linuxuser
 
Posts: 16
Joined: Wed May 11, 2005 4:59 pm

Gonna clean up the build environment

Postby linuxuser » Sun Nov 27, 2005 9:02 pm

Gonna try cleaning up the build environment, maybe there is some cruff laying around that is throwing off the build.
linuxuser
 
Posts: 16
Joined: Wed May 11, 2005 4:59 pm

Quick notes

Postby linuxuser » Sun Nov 27, 2005 9:29 pm

The problem only seems to be with the paging based non-executable PAX option, when compiled on a rh9 box with gcc 3.2.2. All the other PAX options compile, and with the 2.6.13 patch, they compiled as well.

My best guess is that the gcc 3.2.2 compiler doesn't like something with the new patch. Maybe something as subtle as a syntax issue with newer compilers that the older 3.2.2 compiler doesn't like. I'll see if I can find out what exactly is causing it.
linuxuser
 
Posts: 16
Joined: Wed May 11, 2005 4:59 pm

Found it

Postby linuxuser » Sun Nov 27, 2005 9:36 pm

For some reason, gcc 3.2.2 doesn't like this:

Starting on line 354 of arch/i386/mm/fault.c:

#ifdef CONFIG_SMP
&& cpu_isset(smp_processor_id(), mm->context.cpu_user_cs_mask)
#endif


It looks like gvv 3.2.2 doesn't like the format. Without it, its compiling just fine, well, with one minor warning: ;-)

arch/i386/mm/fault.c: In function `do_page_fault':
arch/i386/mm/fault.c:627: warning: unused variable `pte'

This box isn't SMP, so I'm not concerned about pull this out. So I think this is just a gcc syntax issue.
linuxuser
 
Posts: 16
Joined: Wed May 11, 2005 4:59 pm

Re: Found it

Postby PaX Team » Mon Nov 28, 2005 7:44 am

linuxuser wrote:So I think this is just a gcc syntax issue.
indeed, it's a nesting of ifdef inside define, to fix it, change that whole construct to:
Code: Select all
#ifdef CONFIG_SMP
        if (likely(address > get_limit(regs->xcs) && cpu_isset(smp_processor_id(), mm->context.cpu_user_cs_mask)))
#else
        if (likely(address > get_limit(regs->xcs)))
#endif
PaX Team
 
Posts: 2310
Joined: Mon Mar 18, 2002 4:35 pm

Postby spender » Tue Nov 29, 2005 7:00 pm

It's fixed in the latest patch on the website. I didn't catch it earlier because my gcc was accepting it as valid.

-Brad
spender
 
Posts: 2185
Joined: Wed Feb 20, 2002 8:00 pm

Postby dr-who » Mon Sep 25, 2006 9:29 am

i have the same problem with kernel 2.6.18
gcc version 3.4.6

----
CC arch/i386/mm/fault.o
arch/i386/mm/fault.c: In function `do_page_fault':
arch/i386/mm/fault.c:596: error: label `do_sigbus' used but not defined
arch/i386/mm/fault.c:598: error: label `out_of_memory' used but not defined
arch/i386/mm/fault.c: At top level:
arch/i386/mm/fault.c:743: error: syntax error before "if"
arch/i386/mm/fault.c:750: warning: type defaults to `int' in declaration of `pgd'
arch/i386/mm/fault.c:750: error: conflicting types for 'pgd'
arch/i386/mm/fault.c:745: error: previous declaration of 'pgd' was here
arch/i386/mm/fault.c:750: error: `index' undeclared here (not in a function)
arch/i386/mm/fault.c:750: error: braced-group within expression allowed only inside a function
arch/i386/mm/fault.c:750: error: syntax error before ')' token
arch/i386/mm/fault.c:751: error: syntax error before string constant
arch/i386/mm/fault.c:751: warning: type defaults to `int' in declaration of `printk'
arch/i386/mm/fault.c:751: warning: function declaration isn't a prototype
arch/i386/mm/fault.c:751: error: conflicting types for 'printk'
arch/i386/mm/fault.c:751: note: a parameter list with an ellipsis can't match an empty parameter name list declaration
include/linux/kernel.h:145: error: previous declaration of 'printk' was here
arch/i386/mm/fault.c:751: error: conflicting types for 'printk'
arch/i386/mm/fault.c:751: note: a parameter list with an ellipsis can't match an empty parameter name list declaration
include/linux/kernel.h:145: error: previous declaration of 'printk' was here
arch/i386/mm/fault.c:751: error: syntax error before "unsigned"
arch/i386/mm/fault.c:754: warning: type defaults to `int' in declaration of `pmd'
arch/i386/mm/fault.c:754: error: conflicting types for 'pmd'
arch/i386/mm/fault.c:747: error: previous declaration of 'pmd' was here
arch/i386/mm/fault.c:754: error: `address' undeclared here (not in a function)
arch/i386/mm/fault.c:754: warning: initialization makes integer from pointer without a cast
arch/i386/mm/fault.c:754: error: initializer element is not constant
arch/i386/mm/fault.c:754: warning: data definition has no type or storage class
arch/i386/mm/fault.c:755: error: syntax error before string constant
arch/i386/mm/fault.c:755: warning: type defaults to `int' in declaration of `printk'
arch/i386/mm/fault.c:755: warning: function declaration isn't a prototype
arch/i386/mm/fault.c:755: error: syntax error before "unsigned"
arch/i386/mm/fault.c:765: error: syntax error before string constant
arch/i386/mm/fault.c:765: warning: type defaults to `int' in declaration of `printk'
arch/i386/mm/fault.c:765: warning: function declaration isn't a prototype
arch/i386/mm/fault.c:765: error: syntax error before "unsigned"
arch/i386/mm/fault.c:773: error: syntax error before string constant
arch/i386/mm/fault.c:773: warning: type defaults to `int' in declaration of `die'
arch/i386/mm/fault.c:773: warning: function declaration isn't a prototype
arch/i386/mm/fault.c:773: error: conflicting types for 'die'
arch/i386/mm/fault.c:34: error: previous declaration of 'die' was here
arch/i386/mm/fault.c:773: error: conflicting types for 'die'
arch/i386/mm/fault.c:34: error: previous declaration of 'die' was here
arch/i386/mm/fault.c:773: warning: data definition has no type or storage class
arch/i386/mm/fault.c:774: error: syntax error before numeric constant
arch/i386/mm/fault.c:774: warning: type defaults to `int' in declaration of `bust_spinlocks'
arch/i386/mm/fault.c:774: warning: function declaration isn't a prototype
arch/i386/mm/fault.c:774: error: conflicting types for 'bust_spinlocks'
arch/i386/mm/fault.c:75: error: previous definition of 'bust_spinlocks' was here
arch/i386/mm/fault.c:774: warning: data definition has no type or storage class
arch/i386/mm/fault.c:775: error: syntax error before numeric constant
arch/i386/mm/fault.c:775: warning: type defaults to `int' in declaration of `do_exit'
arch/i386/mm/fault.c:775: warning: function declaration isn't a prototype
arch/i386/mm/fault.c:775: error: conflicting types for 'do_exit'
include/linux/kernel.h:103: error: previous declaration of 'do_exit' was here
arch/i386/mm/fault.c:775: error: conflicting types for 'do_exit'
include/linux/kernel.h:103: error: previous declaration of 'do_exit' was here
arch/i386/mm/fault.c:775: warning: data definition has no type or storage class
arch/i386/mm/fault.c:781: error: syntax error before ':' token
arch/i386/mm/fault.c:785: error: syntax error before '&' token
arch/i386/mm/fault.c:785: warning: type defaults to `int' in declaration of `down_read'
arch/i386/mm/fault.c:785: warning: function declaration isn't a prototype
arch/i386/mm/fault.c:785: error: conflicting types for 'down_read'
include/linux/rwsem.h:30: error: previous declaration of 'down_read' was here
arch/i386/mm/fault.c:785: error: conflicting types for 'down_read'
include/linux/rwsem.h:30: error: previous declaration of 'down_read' was here
arch/i386/mm/fault.c:785: warning: data definition has no type or storage class
arch/i386/mm/fault.c:788: error: syntax error before string constant
arch/i386/mm/fault.c:788: warning: type defaults to `int' in declaration of `printk'
arch/i386/mm/fault.c:788: warning: function declaration isn't a prototype
arch/i386/mm/fault.c:788: warning: data definition has no type or storage class
arch/i386/mm/fault.c:807: error: syntax error before numeric constant
{standard input}: Assembler messages:
{standard input}:356: Error: symbol `pgd' is already defined
{standard input}:362: Error: symbol `pmd' is already defined
make[1]: *** [arch/i386/mm/fault.o] Error 1
make: *** [arch/i386/mm] Error 2
dr-who
 
Posts: 4
Joined: Mon Sep 25, 2006 9:27 am

Postby spender » Tue Sep 26, 2006 5:04 pm

Fixed in the latest patch.

-Brad
spender
 
Posts: 2185
Joined: Wed Feb 20, 2002 8:00 pm


Return to grsecurity support