hyprwm / xdg-desktop-portal-hyprland

xdg-desktop-portal backend for Hyprland
BSD 3-Clause "New" or "Revised" License
273 stars 47 forks source link

Build hyprland on Guix: undefined reference to drmGetDeviceFromDevId #60

Closed dcunited001 closed 1 year ago

dcunited001 commented 1 year ago

hey i'm trying to build hyprland in Guix (i'm using the flake.nix files as examples) I'm running into the following errors when linking xdg-desktop-portal-hyprland

ld: xdg-desktop-portal-hyprland.p/src_screencast_wlr_screencast.c.o: in function `linux_dmabuf_feedback_handle_main_device':
/tmp/guix-build-xdg-desktop-portal-hyprland-0.3.1.drv-0/build/../xdg-desktop-portal-hyprland-0.3.1/src/screencast/wlr_screencast.c:847: undefined reference to `drmGetDeviceFromDevId'
ld: xdg-desktop-portal-hyprland.p/src_screencast_wlr_screencast.c.o: in function `linux_dmabuf_feedback_tranche_target_devices':
/tmp/guix-build-xdg-desktop-portal-hyprland-0.3.1.drv-0/build/../xdg-desktop-portal-hyprland-0.3.1/src/screencast/wlr_screencast.c:895: undefined reference to `drmGetDeviceFromDevId'
collect2: error: ld returned 1 exit status
ninja: build stopped: subcommand failed.
error: in phase 'build': uncaught exception:
%exception #<&invoke-error program: "ninja" arguments: ("-j" "32") exit-status: 1 term-signal: #f stop-signal: #f> 

here's my build log:

https://pastebin.com/2qM304u0

and the packages I defined:

https://pastebin.com/HBvMjDKn

The pastebins are dated for about a week, so i added the build log as an attachment. I can pull stuff out of the pastebins and add them to the issue if necessary. I tried asking on the discord and elsewhere about the question, but didn't get much of a response. i think the issue here surrounds the drmGetDeviceFromDevId reference not being found.

i'm building my own hyprland-protocols and i dont think the build is doing anything with the submodule in this repository.

build.log

vaxerski commented 1 year ago

It's clearly an issue with guix, whatever it is. It builds just fine under nix (CI) and arch. Does xdpw build?

lambdanil commented 1 year ago

Hi, would you happen to have the definitions still available?

I'm looking to package Hyprland for Guix myself and this could save me a lot of effort + I could help debug your issues.

vasiliyl commented 1 year ago

Hi! You can find hyprland packages for guix here - https://github.com/rakino/Rosenthal/blob/trunk/rosenthal/packages/wm.scm

lambdanil commented 1 year ago

Hi! You can find hyprland packages for guix here - https://github.com/rakino/Rosenthal/blob/trunk/rosenthal/packages/wm.scm

Thank you!

dcunited001 commented 1 year ago

hey, sorry @CuBeRJAN @vasiliyl i've been a bit busy. i was just dipping into hyprland to explore it a bit to see if it would fit before i settled on sway. my laptop's been off & on for the past few weeks.

I'm glad to see that someone's packaged it. i'm excited about the Lua in Pipewire anyways, so it seems like hyprland might vibe with that. i just don't know whether I have time for it.

@vaxerski whatever it was, it's not necessarily an issue with Guix. i don't really know what I'm doing, but i'm not trying to write the definitive package for it.