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

Unbreak build on FreeBSD #324

Merged
merged 3 commits into from Dec 26, 2020
Merged

Unbreak build on FreeBSD #324

merged 3 commits into from Dec 26, 2020

Conversation

jbeich
Copy link
Contributor

@jbeich jbeich commented Dec 21, 2020

Depends on emersion/basu#32

Runtime seems to work fine but I haven't tested much:

  • notify-send -> shows popup
  • makoctl dismiss -> clears popup

event-loop.c:58:24: error: use of undeclared identifier 'CLOCK_MONOTONIC'
                .fd = timerfd_create(CLOCK_MONOTONIC, TFD_CLOEXEC),
                                     ^
event-loop.c:58:41: error: use of undeclared identifier 'O_CLOEXEC'
                .fd = timerfd_create(CLOCK_MONOTONIC, TFD_CLOEXEC),
                                                      ^
/usr/local/include/libepoll-shim/sys/timerfd.h:12:21: note: expanded from macro 'TFD_CLOEXEC'
 #define TFD_CLOEXEC O_CLOEXEC
                     ^
event-loop.c:140:16: error: use of undeclared identifier 'CLOCK_MONOTONIC'
        clock_gettime(CLOCK_MONOTONIC, &timer->at);
                      ^
meson.build Outdated Show resolved Hide resolved
meson.build Outdated Show resolved Hide resolved
event-loop uses timerfd/signalfd which are Linux-only but BSDs have a
shim via kqueue. On FreeBSD libwayland uses epoll-shim by default, so
the build fails at linking instead of compilation stage.

ld: error: undefined symbol: timerfd_create
>>> referenced by event-loop.c:58 (../event-loop.c:58)
>>>               mako.p/event-loop.c.o:(init_event_loop)

ld: error: undefined symbol: epoll_shim_close
>>> referenced by event-loop.c:70 (../event-loop.c:70)
>>>               mako.p/event-loop.c.o:(finish_event_loop)

ld: error: undefined symbol: timerfd_settime
>>> referenced by event-loop.c:120 (../event-loop.c:120)
>>>               mako.p/event-loop.c.o:(update_event_loop_timer)

ld: error: undefined symbol: epoll_shim_read
>>> referenced by event-loop.c:166 (../event-loop.c:166)
>>>               mako.p/event-loop.c.o:(handle_event_loop_timer)

ld: error: undefined symbol: signalfd
>>> referenced by event-loop.c:28 (../event-loop.c:28)
>>>               mako.p/event-loop.c.o:(init_signalfd)
Unlike Alpine it tests system basu package.
@jbeich jbeich marked this pull request as ready for review December 26, 2020 17:36
Copy link
Owner

@emersion emersion left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@emersion emersion merged commit 17b0296 into emersion:master Dec 26, 2020
@jbeich
Copy link
Contributor Author

jbeich commented Dec 26, 2020

Now that basu is tested on FreeBSD would it make sense to switch Alpine to -Dsd-bus-provider=libelogind?

@emersion
Copy link
Owner

Indeed, would be better to get full coverage for all providers!

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

Successfully merging this pull request may close these issues.

None yet

3 participants