2

I'm running Ubuntu 20.04.4 under WSL2 on Windows 11. I've cloned https://github.com/vim/vim.git in the environment. (The latest commit is tagged as v9.0.0260.) When I go to the directory and do this ...

./configure
sudo make

... the latter command reports:

/usr/bin/ld: objects/os_unix.o: in function `stop_timeout':
/home/me/git/vim/src/os_unix.c:8281: undefined reference to `timer_settime'
/usr/bin/ld: objects/os_unix.o: in function `start_timeout':
/home/me/git/vim/src/os_unix.c:8321: undefined reference to `timer_create'
/usr/bin/ld: /home/me/git/vim/src/os_unix.c:8334: undefined reference to `timer_settime'
/usr/bin/ld: objects/os_unix.o: in function `delete_timer':
/home/me/git/vim/src/os_unix.c:8349: undefined reference to `timer_delete'

A bit of searching shows that the problem might be related to the need for a -lrt flag somewhere in the build, to include the timer library. But I'm at a loss as to what changes the makefiles would need. The ./configure command doesn't tell me that I'm missing anything. Is there something I can do about it?

3
  • See github.com/vim/vim/issues/10831
    – Matt
    Commented Aug 25, 2022 at 5:11
  • @Matt: That was what I needed. I did "make distclean" followed by "./configure", etc., and the build worked. If you write up an answer, I'll accept it and give it a +1. Thanks!
    – Denizen
    Commented Aug 25, 2022 at 13:38
  • Giving answer for your own question is welcomed on this site, so you can write it in all detail yourself.
    – Matt
    Commented Aug 25, 2022 at 15:06

1 Answer 1

2

At github.com/vim/vim/issues/10831 is this comment:

"Generally, after syncing to head, make distclean might be needed, because the configure checks may need to run again for changes in configure or build environment."

I ran: make distclean, after which the usual sequence of build instructions worked.

Thanks to @Matt for the insight.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.