difference between compiling Kernel modules for linux 2.4 with gcc 3.4 rather than 3.3

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello,

My question is about differences between gcc-3.3 and gcc-3.4 and is asked mostly because of curiosity since I've got a working solution.

We have an old x86-based product that uses RTL on Linux 2.4 and to build it we use a virtual Mandrake machine from way back. Earlier this week I got fed up with the old build system and started migrating to a more modern distro (Debian Squeeze). gcc-4.4 showed lots of warnings and in the end no object file was created. 

I downgraded to gcc-3.4 and managed to get module compiled but for some reason modinfo doesn't output anything and when installing the module in our target system we get 

                             uw.o: couldn't find the kernel version the module was compiled for

After testing switching to older version of libraries and what not to no avail I installed gcc-3.3 (the version used on the old build machine), and with after compiling with this version modinfo shows:

Filename:                                      uw.o
kernel_version:                          2.4.21
kernel_version:                          2.4.21
kernel_version:                          2.4.21
etc.

and the module works fine when installed.

What is different between the gcc-versions 3.3 and 3.4 that can cause this behavior or is there some quirky behavior of the Linux-headers?

Flags used for the project:
-D__KERNEL__ -Wall -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common \
    -pipe -mpreferred-stack-boundary=2 -march=i586 -DMODULE -fomit-frame-pointer \
    -D__RTL__ -D_LOOSE_KERNEL_NAMES -O2 \
    -I$(RTL_DIR)/linux/include \
    -I$(RTL_DIR)/include \
    -I$(RTL_DIR)/include/compat \
    -I$(RTL_DIR)/include/posix \


Best regards
/ Åke Forslund

Åke Forslund
Lasermax Roll Systems
Tel: +46 (0) 372-25639





[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux