Modules_install missing system.map file. skipping depmod

Message ID (mailing list archive)
StateNew, archived
Headersshow
Series [v2] modules_install: warn when missing System.map file | expand

Commit Message

From: Randy Dunlap <>

If there is no System.map file for "make modules_install",
scripts/depmod.sh will silently exit with success, having done
nothing.  Since this is an unexpected situation, change it to
report a Warning for the missing file.  The behavior is not
changed except for the Warning message.

The (previous) silent success and new Warning can be reproduced
by:
$ make mrproper; make defconfig
$ make modules; make modules_install

and since System.map is produced by "make vmlinux", the steps
above omit producing the System.map file.

Reported-by: Masahiro Yamada <>
Cc: Masahiro Yamada <>
Signed-off-by: Randy Dunlap <>
---
v2: add Yamada-san's suggestions for >&2 and Skipping depmod.

 scripts/depmod.sh |    1 +
 1 file changed, 1 insertion(+)

Comments

2018-09-07 8:37 GMT+09:00 Randy Dunlap <>:
> From: Randy Dunlap <>
>
> If there is no System.map file for "make modules_install",
> scripts/depmod.sh will silently exit with success, having done
> nothing.  Since this is an unexpected situation, change it to
> report a Warning for the missing file.  The behavior is not
> changed except for the Warning message.
>
> The (previous) silent success and new Warning can be reproduced
> by:
> $ make mrproper; make defconfig
> $ make modules; make modules_install
>
> and since System.map is produced by "make vmlinux", the steps
> above omit producing the System.map file.
>
> Reported-by: Masahiro Yamada <>
> Cc: Masahiro Yamada <>
> Signed-off-by: Randy Dunlap <>
> ---
> v2: add Yamada-san's suggestions for >&2 and Skipping depmod.


Applied to linux-kbuild/fixes. Thanks!


>  scripts/depmod.sh |    1 +
>  1 file changed, 1 insertion(+)
>
> --- lnx-419-rc1.orig/scripts/depmod.sh
> +++ lnx-419-rc1/scripts/depmod.sh
> @@ -11,6 +11,7 @@ DEPMOD=$1
>  KERNELRELEASE=$2
>
>  if ! test -r System.map ; then
> +       echo "Warning: modules_install: missing 'System.map' file. Skipping depmod." >&2
>         exit 0
>  fi
>
>

Patch

--- lnx-419-rc1.orig/scripts/depmod.sh
+++ lnx-419-rc1/scripts/depmod.sh
@@ -11,6 +11,7 @@  DEPMOD=$1
 KERNELRELEASE=$2
 
 if ! test -r System.map ; then
+	echo "Warning: modules_install: missing 'System.map' file. Skipping depmod." >&2
 	exit 0
 fi
 

Hello,

I'm trying to install a kernel module.

Using

  • Raspberry Pi OS Lite (64-bit) (5.15) [/quote]
  • Raspberry Pi 4 Model B[/code]

I have done

Code: Select all

apt-get install raspberrypi-kernel-headers

But on "make modules_install" in "DEPMOD /lib/modules/5.15.32-v8+" I get:

Warning: modules_install: missing 'System.map' file. Skipping depmod

Also

Code: Select all

sudo find / -name "System.map*"

finds nothing.

Is there another way to get System.map or do I have to do a kernel rebuild?

Thanks for any help,
Martin

Need help installing a git driver

Asked by Nicole on 2020-02-02

Hello, I am trying to install this (https://github.com/jlam55555/veikk-linux-driver) driver on to my laptop and when I type in sudo make install, I get this in response.

make -C /lib/modules/5.3.0-29-generic/build M=/home/nic03/veikk-linux-driver modules_install
make[1]: Entering directory '/usr/src/linux-headers-5.3.0-29-generic'
  INSTALL /home/nic03/veikk-linux-driver/veikk.ko
At main.c:160:
- SSL error:02001002:system library:fopen:No such file or directory: ../crypto/bio/bss_file.c:72
- SSL error:2006D080:BIO routines:BIO_new_file:no such file: ../crypto/bio/bss_file.c:79
sign-file: certs/signing_key.pem: No such file or directory
  DEPMOD 5.3.0-29-generic
Warning: modules_install: missing 'System.map' file. Skipping depmod.
make[1]: Leaving directory '/usr/src/linux-headers-5.3.0-29-generic'
modprobe veikk
modprobe: FATAL: Module veikk not found in directory /lib/modules/5.3.0-29-generic
make: *** [Makefile:15: install] Error 1

The wierd thing is, is that I manually put veikk.mod into the files it claims it can't find it in, so I know for a fact it's there. It may have something to do with the missing System.map file, I'm not entirely sure. I'm using Kubuntu 19.10, any help would be much appreciated.

Can you help with this problem?

Provide an answer of your own, or ask Nicole for more information if necessary.

To post a message you must log in.