* multiple definition of `__module_kernel_version'
@ 2000-11-08 20:09 Timur Tabi
2000-11-08 21:08 ` Keith Owens
2000-11-08 21:15 ` Timur Tabi
0 siblings, 2 replies; 4+ messages in thread
From: Timur Tabi @ 2000-11-08 20:09 UTC (permalink / raw)
To: Linux Kernel Mailing list
I'm trying to port my driver from 2.4 to 2.2. When I try to compile it, I get
several "multiple definition of `__module_kernel_version'" errors:
ver is 2.2.14-6.0
ld -r --print-map --cref -Map tdmcddk.map global.o init.o tiermap.o support.o
cccomp.o ccmp_sft.o lz77.o ccmp_s32.o gcmp_sft.o gencomp.o infoapi.o thread.o
callback.o -o tdmcddk.sys
init.o: In function `WaitStandardUnit':
/home/ttabi/src/tdimm/tdmcddk.sys/init.c:181: multiple definition of
`__module_kernel_version'
global.o(.modinfo+0x0):/home/ttabi/src/tdimm/tdmcddk.sys/global.c: first
defined here
tiermap.o: In function `FsbToDimmSlot':
/home/ttabi/src/tdimm/tdmcddk.sys/tiermap.c:10: multiple definition of
`__module_kernel_version'
global.o(.modinfo+0x0):/home/ttabi/src/tdimm/tdmcddk.sys/global.c: first
defined here
support.o: In function `IsGoodCpu':
/home/ttabi/src/tdimm/tdmcddk.sys/../support/common/cpuid.c:5: multiple
definition of `__module_kernel_version'
global.o(.modinfo+0x0):/home/ttabi/src/tdimm/tdmcddk.sys/global.c: first
defined here
cccomp.o: In function `CompressIntoCCache':
/home/ttabi/src/tdimm/tdmcddk.sys/cccomp.c:11: multiple definition of
`__module_kernel_version'
global.o(.modinfo+0x0):/home/ttabi/src/tdimm/tdmcddk.sys/global.c: first
defined here
ccmp_sft.o: In function `CompressIntoCCacheSoft':
/home/ttabi/src/tdimm/tdmcddk.sys/ccmp_sft.c:12: multiple definition of
`__module_kernel_version'
global.o(.modinfo+0x0):/home/ttabi/src/tdimm/tdmcddk.sys/global.c: first
defined here
lz77.o: In function `PackLZ77Triplette':
/home/ttabi/src/tdimm/tdmcddk.sys/lz77.c:95: multiple definition of
`__module_kernel_version'
global.o(.modinfo+0x0):/home/ttabi/src/tdimm/tdmcddk.sys/global.c: first
defined here
ccmp_s32.o: In function `CompressIntoCCacheS32':
/home/ttabi/src/tdimm/tdmcddk.sys/ccmp_s32.c:12: multiple definition of
`__module_kernel_version'
global.o(.modinfo+0x0):/home/ttabi/src/tdimm/tdmcddk.sys/global.c: first
defined here
gcmp_sft.o: In function `GenericCompressSoft':
/home/ttabi/src/tdimm/tdmcddk.sys/gcmp_sft.c:12: multiple definition of
`__module_kernel_version'
global.o(.modinfo+0x0):/home/ttabi/src/tdimm/tdmcddk.sys/global.c: first
defined here
gencomp.o: In function `GenericCompress':
/home/ttabi/src/tdimm/tdmcddk.sys/gencomp.c:11: multiple definition of
`__module_kernel_version'
global.o(.modinfo+0x0):/home/ttabi/src/tdimm/tdmcddk.sys/global.c: first
defined here
infoapi.o: In function `tdmGetDriverConfig':
/home/ttabi/src/tdimm/tdmcddk.sys/infoapi.c:12: multiple definition of
`__module_kernel_version'
global.o(.modinfo+0x0):/home/ttabi/src/tdimm/tdmcddk.sys/global.c: first
defined here
thread.o: In function `SetAnvilRestartTimer':
/home/ttabi/src/tdimm/tdmcddk.sys/thread.c:10: multiple definition of
`__module_kernel_version'
global.o(.modinfo+0x0):/home/ttabi/src/tdimm/tdmcddk.sys/global.c: first
defined here
callback.o: In function `InitializeCallbackQueue':
/home/ttabi/src/tdimm/tdmcddk.sys/callback.c:84: multiple definition of
`__module_kernel_version'
global.o(.modinfo+0x0):/home/ttabi/src/tdimm/tdmcddk.sys/global.c: first
defined here
make: *** [tdmcddk.sys] Error 1
[ttabi@one tdmcddk.sys]$
I've searched through the mailing list archives, but none of the "fixes"
suggested earlier seem to work. Why does this happen? And why doesn't it
happen with 2.4?
--
Timur Tabi - ttabi@interactivesi.com
Interactive Silicon - http://www.interactivesi.com
When replying to a mailing-list message, please direct the reply to the mailing list only. Don't send another copy to me.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: multiple definition of `__module_kernel_version'
2000-11-08 20:09 multiple definition of `__module_kernel_version' Timur Tabi
@ 2000-11-08 21:08 ` Keith Owens
2000-11-08 21:15 ` Timur Tabi
1 sibling, 0 replies; 4+ messages in thread
From: Keith Owens @ 2000-11-08 21:08 UTC (permalink / raw)
To: Timur Tabi; +Cc: Linux Kernel Mailing list
On Wed, 08 Nov 2000 14:09:43 -0600,
Timur Tabi <ttabi@interactivesi.com> wrote:
>I'm trying to port my driver from 2.4 to 2.2. When I try to compile it, I get
>several "multiple definition of `__module_kernel_version'" errors:
include/linux/module.h was changed in the 2.3 kernels to define
__module_kernel_version and __module_using_checksums as static.
Without that change you get multiple definitions of the variables when
you link multiple objects into a single module. In 2.2 you have to
#define __NO_VERSION__ before including module.h in all of the module
objects except one. Search 2.2 drivers for __NO_VERSION__ to see
examples of this.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: multiple definition of `__module_kernel_version'
2000-11-08 20:09 multiple definition of `__module_kernel_version' Timur Tabi
2000-11-08 21:08 ` Keith Owens
@ 2000-11-08 21:15 ` Timur Tabi
2000-11-08 21:30 ` Keith Owens
1 sibling, 1 reply; 4+ messages in thread
From: Timur Tabi @ 2000-11-08 21:15 UTC (permalink / raw)
To: Linux Kernel Mailing list
** Reply to message from Keith Owens <kaos@ocs.com.au> on Thu, 09 Nov 2000
08:08:31 +1100
> In 2.2 you have to
> #define __NO_VERSION__ before including module.h in all of the module
> objects except one. Search 2.2 drivers for __NO_VERSION__ to see
> examples of this.
If I do that, I get this error:
../support/schedule.h:16: parse error
and line 16 says:
#if LINUX_VERSION_CODE < KERNEL_VERSION(2,3,0)
--
Timur Tabi - ttabi@interactivesi.com
Interactive Silicon - http://www.interactivesi.com
When replying to a mailing-list message, please direct the reply to the mailing list only. Don't send another copy to me.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: multiple definition of `__module_kernel_version'
2000-11-08 21:15 ` Timur Tabi
@ 2000-11-08 21:30 ` Keith Owens
0 siblings, 0 replies; 4+ messages in thread
From: Keith Owens @ 2000-11-08 21:30 UTC (permalink / raw)
To: Timur Tabi; +Cc: Linux Kernel Mailing list
On Wed, 08 Nov 2000 15:15:59 -0600,
Timur Tabi <ttabi@interactivesi.com> wrote:
>../support/schedule.h:16: parse error
>
>and line 16 says:
>
>#if LINUX_VERSION_CODE < KERNEL_VERSION(2,3,0)
#include <linux/version.h>
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2000-11-08 21:30 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2000-11-08 20:09 multiple definition of `__module_kernel_version' Timur Tabi
2000-11-08 21:08 ` Keith Owens
2000-11-08 21:15 ` Timur Tabi
2000-11-08 21:30 ` Keith Owens
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox