Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compile error: strlcpy/strscpy #9

Open
Damni81 opened this issue Mar 18, 2024 · 1 comment
Open

Compile error: strlcpy/strscpy #9

Damni81 opened this issue Mar 18, 2024 · 1 comment
Assignees

Comments

@Damni81
Copy link

Damni81 commented Mar 18, 2024

Distribution: Arch Linux
Kernel: 6.8.1-arch1-1

Just replacing "strlcpy" with "strscpy" works. But I know nothing about C. I leave it to you experts.

make -C /lib/modules/6.8.1-arch1-1/build M=/mnt/box/downloads/px1800kbd modules
make[1]: Entering directory '/usr/lib/modules/6.8.1-arch1-1/build'
  CC [M]  /mnt/box/downloads/px1800kbd/px1800kbd.o
/mnt/box/downloads/px1800kbd/px1800kbd.c: In function ‘init_kbd_name’:
/mnt/box/downloads/px1800kbd/px1800kbd.c:308:17: error: implicit declaration of function ‘strlcpy’; did you mean ‘strscpy’? [-Werror=implicit-function-declaration]
  308 |                 strlcpy(kbd->name, dev->manufacturer, sizeof(kbd->name));
      |                 ^~~~~~~
      |                 strscpy
cc1: some warnings being treated as errors
make[3]: *** [scripts/Makefile.build:243: /mnt/box/downloads/px1800kbd/px1800kbd.o] Error 1
make[2]: *** [/usr/lib/modules/6.8.1-arch1-1/build/Makefile:1921: /mnt/box/downloads/px1800kbd] Error 2
make[1]: *** [Makefile:240: __sub-make] Error 2
make[1]: Leaving directory '/usr/lib/modules/6.8.1-arch1-1/build'
make: *** [Makefile:33: default] Error 2

Thanks for maintaining this btw. Much appreciated!

@lolo101 lolo101 self-assigned this Mar 18, 2024
@lolo101
Copy link
Owner

lolo101 commented Mar 18, 2024

Similar error here : umlaeute/v4l2loopback#575

Looks like kernel 6.8 has deprecated strlcpy

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants