Installation guide

Linux Installation
Manual • Doc. No.: C.2001.21 / Rev. 3.0 •
© 2000-2007 esd gmbh
CAN-API Installation
Page 64 of 112
2. Compiling the Driver
cd ./esdcan-crd-os-arch-ver-ext
In some cases you need to edit a configuration file for the compilation:
In
config.mk
you need to set the variable
KERNELPATH
correctly. Normally the default path
should be correct. If your Linux configuration differs from the standard, correct the line
accordingly:
KERNELPATH = <your-path-to-the-kernel-source>
Note
for Linux kernel > 2.6.0: On some systems you might need to be "root" to
compile the driver.
Compilation of the driver is simply started by typing:
make
For some cards there are warnings like
COMPILING FOR xxx
. These can be ignored and will
be removed in future versions.
Now, you have a file called as described below, which is the actual driver-module in the same
directory:
esdcan-crd-os-arch-kver
Dynamic loadable driver-file with
crd
= module ID (e.g.:
crd
=
pci200
or
crd=cpci405
;
see table on page 62)
os
= host operating system (e.g.:
os
=
linux
; ...)
arch
= host architecture (e.g.:
arch
=
x86
)
kver
= target-version information ((e.g.:
kver
:
2.4.18
)
For Linux the kernel version is coded here, because the
compiled version is kernel specific!)
Example:
For a CAN-PCI/331 for 32-Bit-x86-Linux with 2.4.21-99-smp kernel the driver file
(driver version 3.6.1) is called:
esdcan-pci331-linux-x86-3.6.1-2.4.21-99-smp
Note
for Linux kernel > 2.6.0: The driver file is called
esdcan-crd.ko
and is
generated inside of the
src
- subdirectory.
Example (
for Linux kernel > 2.6.0
):
For the above mentioned CAN-PCI/331 the driver file is called:
esdcan-pci331.ko
(the file is located in
./src
subdirectory)