2003-02-11 15:52:04

by Martin J. Bligh

[permalink] [raw]
Subject: [Bug 337] New: build breakage for module versioning support

http://bugme.osdl.org/show_bug.cgi?id=337

Summary: build breakage for module versioning support
Kernel Version: 2.5.60, 2.5.60-bk1
Status: NEW
Severity: normal
Owner: [email protected]
Submitter: [email protected]


Exact Kernel version: 2.5.60, 2.5.60-bk1
Distribution: Gentoo 1.4rc2
Hardware Environment: Abit KG7-RAID, AMD Athlon TBird 1.4, 512MB DDR,
Geforce 3 Software Environment: gcc 3.2.1, glibc 2.3.1, ld 2.13.90.0.16
Problem Description:

Enabling module versioning support causes build breakage.

gcc -Wp,-MD,arch/i386/kernel/.time.o.d -D__KERNEL__ -Iinclude -Wall
-Wstrict-prototypes -Wno-trigraphs -O2 -fno-strict-aliasing -fno-common
-pipe -mpreferred-stack-boundary=2 -march=athlon
-Iinclude/asm-i386/mach-default -nostdinc -iwithprefix include
-DKBUILD_BASENAME=time -DKBUILD_MODNAME=time -c -o
arch/i386/kernel/.tmp_time.o arch/i386/kernel/time.c
ld:arch/i386/kernel/.tmp_time.ver:1: parse error
make[1]: *** [arch/i386/kernel/time.o] Error 1
make: *** [arch/i386/kernel] Error 2


Steps to reproduce:

CONFIG_MODVERSIONS=y

Loadable module support --->
[*] Module versioning support (EXPERIMENTAL)



2003-02-11 16:02:51

by Kai Germaschewski

[permalink] [raw]
Subject: Re: [Bug 337] New: build breakage for module versioning support

On Tue, 11 Feb 2003, Martin J. Bligh wrote:

> http://bugme.osdl.org/show_bug.cgi?id=337
>
> Summary: build breakage for module versioning support
> Kernel Version: 2.5.60, 2.5.60-bk1
> Status: NEW
> Severity: normal
> Owner: [email protected]
> Submitter: [email protected]
>
>
> Problem Description:
>
> Enabling module versioning support causes build breakage.
>
> gcc -Wp,-MD,arch/i386/kernel/.time.o.d -D__KERNEL__ -Iinclude -Wall
> -Wstrict-prototypes -Wno-trigraphs -O2 -fno-strict-aliasing -fno-common
> -pipe -mpreferred-stack-boundary=2 -march=athlon
> -Iinclude/asm-i386/mach-default -nostdinc -iwithprefix include
> -DKBUILD_BASENAME=time -DKBUILD_MODNAME=time -c -o
> arch/i386/kernel/.tmp_time.o arch/i386/kernel/time.c
> ld:arch/i386/kernel/.tmp_time.ver:1: parse error
> make[1]: *** [arch/i386/kernel/time.o] Error 1
> make: *** [arch/i386/kernel] Error 2

That's caused by a sed incompatibility.
Fix already posted on l-k: (I'll submit it to Linus)

===== scripts/Makefile.build 1.27 vs edited =====
--- 1.27/scripts/Makefile.build Sat Feb 8 14:30:33 2003
+++ edited/scripts/Makefile.build Mon Feb 10 15:25:44 2003
@@ -94,7 +94,7 @@
else \
$(CPP) -D__GENKSYMS__ $(c_flags) $< \
| $(GENKSYMS) -k $(VERSION).$(PATCHLEVEL).$(SUBLEVEL) \
- | sed -n 's/\#define __ver_\(\w*\)\W*\(\w*\)/__crc_\1 = 0x\2 ;/gp' \
+ | sed -n 's/\#define __ver_\([^ ]*\)[ ]*\([^ ]*\)/__crc_\1 = 0x\2 ;/gp' \
> $(@D)/.tmp_$(@F:.o=.ver); \
\
$(LD) $(LDFLAGS) -r -o $@ $(@D)/.tmp_$(@F) \