Bug 257320

Summary: graphics/drm-fbsd13-kmod: Fails to build on 13.0-RELEASE: linux_kmod_gplv2.c:30: In file included from /usr/src/sys/sys/param.h:99: /usr/src/sys/sys/types.h:46:10: fatal error: 'machine/endian.h' file not found
Product: Ports & Packages Reporter: lumiwa
Component: Individual Port(s)Assignee: freebsd-x11 (Nobody) <x11>
Status: Open ---    
Severity: Affects Only Me CC: lumiwa, manu
Priority: --- Keywords: needs-qa
Version: LatestFlags: bugzilla: maintainer-feedback? (x11)
Hardware: amd64   
OS: Any   
See Also: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=233735

Description lumiwa 2021-07-21 23:22:26 UTC
I cannot build the last update of drm-fbsd13-kmod on FreeBSD-13.o-RELEASE (amd64):

ual -Wundef -Wno-pointer-sign -D__printf__=__freebsd_kprintf__ -Wmissing-include-dirs -fdiagnostics-show-option -Wno-unknown-pragmas -Wno-error-tautological-compare -Wno-error-empty-body -Wno-error-parentheses-equality -Wno-error-unused-function -Wno-error-pointer-sign -Wno-error-shift-negative-value -Wno-address-of-packed-member -Wno-format-zero-length -Wno-pointer-arith   -mno-aes -mno-avx  -std=iso9899:1999 -c /usr/ports/graphics/drm-fbsd13-kmod/work/drm-kmod-drm_v5.4.92_5/linuxkpi/gplv2/src/linux_irq.c -o linux_irq.o
--- linux_kmod_gplv2.o ---
In file included from /usr/ports/graphics/drm-fbsd13-kmod/work/drm-kmod-drm_v5.4.92_5/linuxkpi/gplv2/src/linux_kmod_gplv2.c:30:
In file included from /usr/src/sys/sys/param.h:99:
/usr/src/sys/sys/types.h:46:10: fatal error: 'machine/endian.h' file not found
#include <machine/endian.h>
         ^~~~~~~~~~~~~~~~~~
1 error generated.
*** [linux_kmod_gplv2.o] Error code 1

make[3]: stopped in /usr/ports/graphics/drm-fbsd13-kmod/work/drm-kmod-drm_v5.4.92_5/linuxkpi
--- linux_interval_tree.o ---
In file included from /usr/ports/graphics/drm-fbsd13-kmod/work/drm-kmod-drm_v5.4.92_5/linuxkpi/gplv2/src/linux_interval_tree.c:1:
In file included from /usr/ports/graphics/drm-fbsd13-kmod/work/drm-kmod-drm_v5.4.92_5/linuxkpi/gplv2/include/linux/interval_tree.h:5:
In file included from /usr/ports/graphics/drm-fbsd13-kmod/work/drm-kmod-drm_v5.4.92_5/linuxkpi/gplv2/include/linux/rbtree.h:36:
In file included from /usr/src/sys/sys/param.h:99:
/usr/src/sys/sys/types.h:46:10: fatal error: 'machine/endian.h' file not found
#include <machine/endian.h>
         ^~~~~~~~~~~~~~~~~~
--- linux_anon_inodefs.o ---
In file included from /usr/ports/graphics/drm-fbsd13-kmod/work/drm-kmod-drm_v5.4.92_5/linuxkpi/gplv2/src/linux_anon_inodefs.c:5:
In file included from /usr/src/sys/sys/param.h:99:
/usr/src/sys/sys/types.h:46:10: fatal error: 'machine/endian.h' file not found
#include <machine/endian.h>
         ^~~~~~~~~~~~~~~~~~
--- linux_anon_inodes.o ---
In file included from /usr/ports/graphics/drm-fbsd13-kmod/work/drm-kmod-drm_v5.4.92_5/linuxkpi/gplv2/src/linux_anon_inodes.c:2:
In file included from /usr/src/sys/sys/param.h:99:
/usr/src/sys/sys/types.h:46:10: fatal error: 'machine/endian.h' file not found
#include <machine/endian.h>
         ^~~~~~~~~~~~~~~~~~
--- linux_i2c.o ---
In file included from /usr/ports/graphics/drm-fbsd13-kmod/work/drm-kmod-drm_v5.4.92_5/linuxkpi/gplv2/src/linux_i2c.c:31:
/usr/src/sys/sys/types.h:46:10: fatal error: 'machine/endian.h' file not found
#include <machine/endian.h>
         ^~~~~~~~~~~~~~~~~~
--- linux_compat.o ---
In file included from /usr/ports/graphics/drm-fbsd13-kmod/work/drm-kmod-drm_v5.4.92_5/linuxkpi/gplv2/src/linux_compat.c:1:
In file included from /usr/src/sys/sys/param.h:99:
/usr/src/sys/sys/types.h:46:10: fatal error: 'machine/endian.h' file not found
#include <machine/endian.h>
         ^~~~~~~~~~~~~~~~~~
--- linux_genalloc.o ---
In file included from /usr/ports/graphics/drm-fbsd13-kmod/work/drm-kmod-drm_v5.4.92_5/linuxkpi/gplv2/src/linux_genalloc.c:31:
In file included from /usr/src/sys/compat/linuxkpi/common/include/linux/slab.h:34:
In file included from /usr/src/sys/sys/param.h:99:
/usr/src/sys/sys/types.h:46:10: fatal error: 'machine/endian.h' file not found
#include <machine/endian.h>
         ^~~~~~~~~~~~~~~~~~
--- linux_irq.o ---
In file included from /usr/ports/graphics/drm-fbsd13-kmod/work/drm-kmod-drm_v5.4.92_5/linuxkpi/gplv2/src/linux_irq.c:1:
In file included from /usr/src/sys/compat/linuxkpi/common/include/linux/interrupt.h:34:
In file included from /usr/ports/graphics/drm-fbsd13-kmod/work/drm-kmod-drm_v5.4.92_5/linuxkpi/gplv2/include/linux/device.h:4:
In file included from /usr/src/sys/compat/linuxkpi/common/include/linux/device.h:34:
In file included from /usr/src/sys/compat/linuxkpi/common/include/linux/err.h:34:
/usr/src/sys/sys/types.h:46:10: fatal error: 'machine/endian.h' file not found
#include <machine/endian.h>
         ^~~~~~~~~~~~~~~~~~
--- linux_interval_tree.o ---
1 error generated.
*** [linux_interval_tree.o] Error code 1

make[3]: stopped in /usr/ports/graphics/drm-fbsd13-kmod/work/drm-kmod-drm_v5.4.92_5/linuxkpi
--- linux_anon_inodes.o ---
1 error generated.
*** [linux_anon_inodes.o] Error code 1

make[3]: stopped in /usr/ports/graphics/drm-fbsd13-kmod/work/drm-kmod-drm_v5.4.92_5/linuxkpi
--- linux_genalloc.o ---
1 error generated.
*** [linux_genalloc.o] Error code 1

make[3]: stopped in /usr/ports/graphics/drm-fbsd13-kmod/work/drm-kmod-drm_v5.4.92_5/linuxkpi
--- linux_anon_inodefs.o ---
1 error generated.
*** [linux_anon_inodefs.o] Error code 1

make[3]: stopped in /usr/ports/graphics/drm-fbsd13-kmod/work/drm-kmod-drm_v5.4.92_5/linuxkpi
--- linux_irq.o ---
1 error generated.
--- linux_i2c.o ---
1 error generated.
--- linux_irq.o ---
*** [linux_irq.o] Error code 1

make[3]: stopped in /usr/ports/graphics/drm-fbsd13-kmod/work/drm-kmod-drm_v5.4.92_5/linuxkpi
--- linux_i2c.o ---
*** [linux_i2c.o] Error code 1

make[3]: stopped in /usr/ports/graphics/drm-fbsd13-kmod/work/drm-kmod-drm_v5.4.92_5/linuxkpi
--- linux_compat.o ---
1 error generated.
*** [linux_compat.o] Error code 1

make[3]: stopped in /usr/ports/graphics/drm-fbsd13-kmod/work/drm-kmod-drm_v5.4.92_5/linuxkpi
8 errors

make[3]: stopped in /usr/ports/graphics/drm-fbsd13-kmod/work/drm-kmod-drm_v5.4.92_5/linuxkpi

make[2]: stopped in /usr/ports/graphics/drm-fbsd13-kmod/work/drm-kmod-drm_v5.4.92_5
===> Compilation failed unexpectedly.
Try to set MAKE_JOBS_UNSAFE=yes and rebuild before reporting the failure to
the maintainer.
*** Error code 1

Stop.
make[1]: stopped in /usr/ports/graphics/drm-fbsd13-kmod
*** Error code 1

Stop.
make: stopped in /usr/ports/graphics/drm-fbsd13-kmod

Thank you.
Comment 1 Kubilay Kocak freebsd_committer freebsd_triage 2021-07-22 02:15:16 UTC
^Triage: Possible dupe of bug 233735?
Comment 2 Emmanuel Vadot freebsd_committer 2021-07-23 07:30:27 UTC
No it's likely that the includes aren't present.
Do you have /usr/include/machine/endian.h ?
Comment 3 lumiwa 2021-07-23 22:31:15 UTC
Yes, I have - size 87
Comment 4 lumiwa 2021-07-23 22:33:56 UTC
And in /usr/include/machine I have 87 files and directory pc where are bios.h and display.h