... CC input/drivers/udev_input.c CC input/drivers_joypad/udev_joypad.c CC input/drivers_hid/libusb_hid.c input/drivers/udev_input.c:54:10:CC input/drivers_joypad/hid_joypad.c fatal error: 'linux/kd.h' file not found #include <linux/kd.h> ^~~~~~~~~~~~ CC input/connect/joypad_connection.c CC input/connect/connect_ps2adapter.c 1 error generated. gmake[2]: *** [Makefile:207: obj-unix/release/input/drivers/udev_input.o] Error 1 gmake[2]: *** Waiting for unfinished jobs.... ... WAYLAND_BUILD_DEPENDS= ${LOCALBASE}/include/linux/input.h:devel/evdev-proto \ ${LOCALBASE}/include/linux/kd.h:graphics/svgalib but I unset WAYLAND and set UDEV.
I install graphics/svgalib by hands, but get next error: ... CC libretro-common/rthreads/tpool.c CC tasks/task_decompress.c LD retroarch ld: error: undefined symbol: rarch_key_map_linux >>> referenced by udev_input.c >>> obj-unix/release/input/drivers/udev_input.o:(udev_input_init) c++: error: linker command failed with exit code 1 (use -v to see invocation) gmake[2]: *** [Makefile:202: retroarch] Error 1 gmake[2]: Leaving directory '/tmp/ports/usr/ports/games/retroarch/work/RetroArch-1.8.5' ...
By default cores dir is: /usr/local/lib/libretro but all cores installed to /usr/local/libexec/libretro can it be fixed too?
> rarch_key_map_linux That is ifdef'd to linux||HAVE_WAYLAND too. I guess I'll just set UDEV_IMPLIES=WAYLAND in the next update. > By default cores dir is: /usr/local/lib/libretro but all cores installed to /usr/local/libexec/libretro PREFIX/lib/libretro is the modern directory — upstream emulator ports (emulators/mgba, emulators/mesen and emulators/ppsspp) already install their cores there! Looks like the games/libretro* core ports that were just committed are installing to the wrong directory. Daniel please fix :)
Greg, please, I'm not ready to wayland :) Just add UDEV_BUILD_DEPENDS= ${LOCALBASE}/include/linux/kd.h:graphics/svgalib and probably some simple regexp patch to fix rarch_key_map_linux.
(In reply to Greg V from comment #3) Fixed, I'll send a bug report asap.
Created attachment 214406 [details] patch With this build and work ok. No wayland required.
(In reply to rozhuk.im from comment #6) Greg: are you ok with this patch?
Does it build with UDEV off?
(In reply to Greg V from comment #8) No input/input_keymaps.c:50:10: fatal error: 'linux/kd.h' file not found #include <linux/kd.h> ^~~~~~~~~~~~ Looks like should fix this. BUILD_DEPENDS+= ${LOCALBASE}/include/linux/kd.h:graphics/svgalib
^Triage: What is the conditionality of this build fix? Is the default build/connfiguration (options, etc) affected? Note also: Build fixes are: Approved by: portmgr (blanket: build fix) MFH: <branch|no> <reason> (if quarterly is affected)
(In reply to Kubilay Kocak from comment #10) No, the default configuration is fine. This is about when WAYLAND is off.
Created attachment 219378 [details] games.retroarch.patch Slightly improved version of PR's patch. Changes are: 1. linux/input.h is installed unconditionally. 2. dummy linux/kd.h is created unconditionally too, so svgalib is not needed anymore. That should make port buildable with any combination of WAYLAND and UDEV options.
polkit sucks in rust and llvm90 through spidermonkey78 dependence. WTF?????
(In reply to Vladimir Kondratyev from comment #12) > 1. linux/input.h is installed unconditionally. good catch! > 2. dummy linux/kd.h is created unconditionally too, so svgalib is not needed anymore. If no staff from linux/kd.h used then probably better comment/remove in source files? > polkit sucks in rust and llvm90 through spidermonkey78 dependence. WTF????? Yes, rust is crap! https://gitlab.freedesktop.org/polkit/polkit/-/merge_requests/35
Created attachment 219406 [details] games.retroarch.patch > If no staff from linux/kd.h used then probably better comment/remove in source files? Here you are. > Yes, rust is crap! > https://gitlab.freedesktop.org/polkit/polkit/-/merge_requests/35 I don't think that the rust is guilty. It looks like the wrong embedded interpreter library was chosen by polkit authors at the day 0.
with latest update: In file included from deps/switchres/custom_video.cpp:18: ./deps/switchres/custom_video.h:99:7: warning: private field 'm_device_name' is not used [-Wunused-private-field] char m_device_name[32]; ^ ./deps/switchres/custom_video.h:100:7: warning: private field 'm_device_key' is not used [-Wunused-private-field] char m_device_key[128]; ^ ./deps/switchres/custom_video.h:103:6: warning: private field 'm_custom_method' is not used [-Wunused-private-field] int m_custom_method; ^ 3 warnings generated. deps/switchres/edid.cpp:165:20: warning: implicit conversion from 'int' to 'char' changes value from 229 to -27 [-Wconstant-conversion] edid->b[66] = 485 & 0xff; ~ ~~~~^~~~~~ 1 warning generated. LD retroarch ld: error: undefined symbol: rarch_key_map_linux >>> referenced by udev_input.c >>> obj-unix/release/input/drivers/udev_input.o:(udev_input_init) >>> referenced by udev_input.c >>> obj-unix/release/input/drivers/udev_input.o:(udev_input_init) c++: error: linker command failed with exit code 1 (use -v to see invocation)
Created attachment 231472 [details] files/patch-input_input__keymaps.c (In reply to Ivan Rozhuk from comment #16) This is because you're building without the WAYLAND option. Try this as /usr/ports/games/retroarch/files/patch-input_input__keymaps.c
(In reply to Greg V from comment #17) It work, thanks!
^Triage: note that maintainer actually has given feedback.