thopiekar / rcraid-dkms

AMD RAIDXpert driver as DKMS package
Other
126 stars 27 forks source link

stdarg.h: No such file or directory #45

Open FatildaIV opened 2 years ago

FatildaIV commented 2 years ago

Hello,

I'm encountering some issues building DKMS modules on Linux 5.16:

Sat Jan 15 10:56:16 CET 2022
make -C /lib/modules/5.16.0-AMD/build M=/var/lib/dkms/rcraid/17.2.1/build
make[1]: Entering directory '/usr/lib/modules/5.16.0-AMD/build'
ln -sf `basename /var/lib/dkms/rcraid/17.2.1/build/rcblob.x86_64.o .o` /var/lib/dkms/rcraid/17.2.1/build/rcblob.x86_64.o
  CC [M]  /var/lib/dkms/rcraid/17.2.1/build/rc_init.o
  CC [M]  /var/lib/dkms/rcraid/17.2.1/build/rc_msg.o
  CC [M]  /var/lib/dkms/rcraid/17.2.1/build/rc_mem_ops.o
  CC [M]  /var/lib/dkms/rcraid/17.2.1/build/rc_event.o
  CC [M]  /var/lib/dkms/rcraid/17.2.1/build/rc_config.o
  CC [M]  /var/lib/dkms/rcraid/17.2.1/build/vers.o
In file included from /var/lib/dkms/rcraid/17.2.1/build/rc_config.c:27:
/var/lib/dkms/rcraid/17.2.1/build/rc_msg_platform.h:30:10: fatal error: stdarg.h: No such file or directory
   30 | #include <stdarg.h>
      |          ^~~~~~~~~~
compilation terminated.
make[2]: *** [scripts/Makefile.build:287: /var/lib/dkms/rcraid/17.2.1/build/rc_config.o] Error 1
make[2]: *** Waiting for unfinished jobs....
In file included from /var/lib/dkms/rcraid/17.2.1/build/rc.h:97,
                 from /var/lib/dkms/rcraid/17.2.1/build/rc_mem_ops.c:43:
/var/lib/dkms/rcraid/17.2.1/build/rc_msg_platform.h:30:10: fatal error: stdarg.h: No such file or directory
   30 | #include <stdarg.h>
      |          ^~~~~~~~~~
compilation terminated.
In file included from /var/lib/dkms/rcraid/17.2.1/build/rc.h:97,
                 from /var/lib/dkms/rcraid/17.2.1/build/rc_event.c:25:
/var/lib/dkms/rcraid/17.2.1/build/rc_msg_platform.h:30:10: fatal error: stdarg.h: No such file or directory
   30 | #include <stdarg.h>
      |          ^~~~~~~~~~
compilation terminated.
In file included from /var/lib/dkms/rcraid/17.2.1/build/rc.h:97,
                 from /var/lib/dkms/rcraid/17.2.1/build/rc_init.c:38:
/var/lib/dkms/rcraid/17.2.1/build/rc_msg_platform.h:30:10: fatal error: stdarg.h: No such file or directory
   30 | #include <stdarg.h>
      |          ^~~~~~~~~~
In file included from /var/lib/dkms/rcraid/17.2.1/build/rc.h:97,
                 from /var/lib/dkms/rcraid/17.2.1/build/rc_msg.c:22:
/var/lib/dkms/rcraid/17.2.1/build/rc_msg_platform.h:30:10: fatal error: stdarg.h: No such file or directory
   30 | #include <stdarg.h>
      |          ^~~~~~~~~~
compilation terminated.
compilation terminated.
make[2]: *** [scripts/Makefile.build:287: /var/lib/dkms/rcraid/17.2.1/build/rc_mem_ops.o] Error 1
make[2]: *** [scripts/Makefile.build:287: /var/lib/dkms/rcraid/17.2.1/build/rc_event.o] Error 1
make[2]: *** [scripts/Makefile.build:287: /var/lib/dkms/rcraid/17.2.1/build/rc_init.o] Error 1
make[2]: *** [scripts/Makefile.build:287: /var/lib/dkms/rcraid/17.2.1/build/rc_msg.o] Error 1
make[1]: *** [Makefile:1846: /var/lib/dkms/rcraid/17.2.1/build] Error 2
make[1]: Leaving directory '/usr/lib/modules/5.16.0-AMD/build'
make: *** [Makefile:68: module] Error 2

Installed kernels:

linux-amd 5.16.v.0-2
linux-amd-headers 5.16.v.0-2
linux-atm 2.5.2-7
linux-firmware 20211216.f682ecb-1
linux-headers 5.16.arch1-1
linux-lts 5.15.14-1
linux-lts-headers 5.15.14-1

Using arch build directory, DKMS built on LTS kernel successfully.

Thanks for your help

MarkLTZ commented 2 years ago

@FatildaIV can you please check if you have the same issue also after having applied the following patch?

https://github.com/thopiekar/rcraid-dkms/pull/44

Marwis2 commented 2 years ago

Here is my suggestion for kernel 5.16 (Use on your own risk) rcraid_kernel_5-16.txt

MarkLTZ commented 2 years ago

Here is my suggestion for kernel 5.16 (Use on your own risk) rcraid_kernel_5-16.txt

Thanks. BTW, what distro of Linux has kernel 5.16? Ubuntu 21.10?

Marwis2 commented 2 years ago

Don't know, I always compile latest available kernel on my Gentoo box.

MarkLTZ commented 2 years ago

Don't know, I always compile latest available kernel on my Gentoo box.

got it :) https://ubuntuhandbook.org/index.php/2022/01/install-linux-kernel-516-ubuntu/

furioness commented 1 year ago

Fixed here too https://github.com/thopiekar/rcraid-dkms/pull/47

swishkin commented 1 year ago

The problem I'm running into seems nearly identical to what's described in this thread, but is (presumably) occurring on code patched for 5.17/5.18. Here's my output for makepkg -si

==> Making package: rcraid-dkms 17.2.1-2 (Mon 06 Feb 2023 12:38:28 AM UTC)
==> Checking runtime dependencies...
==> Checking buildtime dependencies...
==> Retrieving sources...
  -> Found dkms.conf
==> Validating source files with md5sums...
    dkms.conf ... Passed
==> Extracting sources...
==> Starting prepare()...
==> Removing existing $pkgdir/ directory...
==> Starting build()...
make -C /lib/modules/6.1.8-artix1-1/build M=/home/swishkin/rcraid-dkms/arch/src
make[1]: Entering directory '/usr/lib/modules/6.1.8-artix1-1/build'
ln -sf `basename /home/swishkin/rcraid-dkms/arch/src/rcblob.x86_64.o .o` /home/swishkin/rcraid-dkms/arch/src/rcblob.x86_64.o
  CC [M]  /home/swishkin/rcraid-dkms/arch/src/rc_init.o
  CC [M]  /home/swishkin/rcraid-dkms/arch/src/rc_msg.o
  CC [M]  /home/swishkin/rcraid-dkms/arch/src/rc_mem_ops.o
make[2]: /bin/hostname: No such file or directory
  CC [M]  /home/swishkin/rcraid-dkms/arch/src/rc_event.o
  CC [M]  /home/swishkin/rcraid-dkms/arch/src/rc_config.o
/home/swishkin/rcraid-dkms/arch/src/rc_config.c:11:10: fatal error: linux/genhd.h: No such file or directory
   11 | #include <linux/genhd.h>
      |          ^~~~~~~~~~~~~~~
compilation terminated.
make[2]: *** [scripts/Makefile.build:250: /home/swishkin/rcraid-dkms/arch/src/rc_config.o] Error 1
make[2]: *** Waiting for unfinished jobs....
In file included from /home/swishkin/rcraid-dkms/arch/src/rc.h:97,
                 from /home/swishkin/rcraid-dkms/arch/src/rc_init.c:38:
/home/swishkin/rcraid-dkms/arch/src/rc_msg_platform.h:30:10: fatal error: stdarg.h: No such file or directory
   30 | #include <stdarg.h>
      |          ^~~~~~~~~~
compilation terminated.
make[2]: *** [scripts/Makefile.build:250: /home/swishkin/rcraid-dkms/arch/src/rc_init.o] Error 1
In file included from /home/swishkin/rcraid-dkms/arch/src/rc.h:97,
                 from /home/swishkin/rcraid-dkms/arch/src/rc_msg.c:22:
/home/swishkin/rcraid-dkms/arch/src/rc_msg_platform.h:30:10: fatal error: stdarg.h: No such file or directory
   30 | #include <stdarg.h>
      |          ^~~~~~~~~~
compilation terminated.
In file included from /home/swishkin/rcraid-dkms/arch/src/rc.h:97,
                 from /home/swishkin/rcraid-dkms/arch/src/rc_event.c:25:
/home/swishkin/rcraid-dkms/arch/src/rc_msg_platform.h:30:10: fatal error: stdarg.h: No such file or directory
   30 | #include <stdarg.h>
      |          ^~~~~~~~~~
compilation terminated.
In file included from /home/swishkin/rcraid-dkms/arch/src/rc.h:97,
                 from /home/swishkin/rcraid-dkms/arch/src/rc_mem_ops.c:43:
/home/swishkin/rcraid-dkms/arch/src/rc_msg_platform.h:30:10: fatal error: stdarg.h: No such file or directory
   30 | #include <stdarg.h>
      |          ^~~~~~~~~~
compilation terminated.
make[2]: *** [scripts/Makefile.build:250: /home/swishkin/rcraid-dkms/arch/src/rc_msg.o] Error 1
make[2]: *** [scripts/Makefile.build:250: /home/swishkin/rcraid-dkms/arch/src/rc_event.o] Error 1
make[2]: *** [scripts/Makefile.build:250: /home/swishkin/rcraid-dkms/arch/src/rc_mem_ops.o] Error 1
make[1]: *** [Makefile:1992: /home/swishkin/rcraid-dkms/arch/src] Error 2
make[1]: Leaving directory '/usr/lib/modules/6.1.8-artix1-1/build'
make: *** [Makefile:68: module] Error 2
==> ERROR: A failure occurred in build().
    Aborting...

Running Artix Linux, kernel 6.1.8-artix1-1; am I doing something wrong?