make distclean.make clean.I expected Vim to build normally, and for make clean to be sufficient.
This problem started sometime within the last couple of days. Because it takes two separate build attempts to verify the presence of the issue, I don't have time to bisect right now.
My guess is that some piece of detritus is wrongly being left behind by make clean, but is correctly swept away by make distclean.
9.0.0084
OS: Ubuntu 20.04
terminal: kitty
$TERM: xterm-kitty
shell: bash
gcc -L/lib/x86_64-linux-gnu -L/usr/local/lib -Wl,--as-needed -o vim objects/alloc.o objects/arabic.o objects/arglist.o objects/autocmd.o objects/beval.o objects/buffer.o objects/change.o objects/blob.o objects/blowfish.o objects/cindent.o objects/clientserver.o objects/clipboard.o objects/cmdexpand.o objects/cmdhist.o objects/crypt.o objects/crypt_zip.o objects/debugger.o objects/dict.o objects/diff.o objects/digraph.o objects/drawline.o objects/drawscreen.o objects/edit.o objects/eval.o objects/evalbuffer.o objects/evalfunc.o objects/evalvars.o objects/evalwindow.o objects/ex_cmds.o objects/ex_cmds2.o objects/ex_docmd.o objects/ex_eval.o objects/ex_getln.o objects/fileio.o objects/filepath.o objects/findfile.o objects/float.o objects/fold.o objects/getchar.o objects/gui_xim.o objects/hardcopy.o objects/hashtab.o objects/help.o objects/highlight.o objects/if_cscope.o objects/if_xcmdsrv.o objects/indent.o objects/insexpand.o objects/list.o objects/locale.o objects/map.o objects/mark.o objects/match.o objects/mbyte.o objects/memline.o objects/menu.o objects/misc1.o objects/misc2.o objects/mouse.o objects/move.o objects/normal.o objects/ops.o objects/option.o objects/optionstr.o objects/os_unix.o objects/pathdef.o objects/popupmenu.o objects/popupwin.o objects/profiler.o objects/pty.o objects/quickfix.o objects/regexp.o objects/register.o objects/screen.o objects/scriptfile.o objects/search.o objects/session.o objects/sha256.o objects/sign.o objects/sound.o objects/spell.o objects/spellfile.o objects/spellsuggest.o objects/strings.o objects/syntax.o objects/tag.o objects/term.o objects/terminal.o objects/testing.o objects/textformat.o objects/textobject.o objects/textprop.o objects/time.o objects/typval.o objects/ui.o objects/undo.o objects/usercmd.o objects/userfunc.o objects/version.o objects/vim9cmds.o objects/vim9compile.o objects/vim9execute.o objects/vim9expr.o objects/vim9instr.o objects/vim9script.o objects/vim9type.o objects/viminfo.o objects/window.o objects/bufwrite.o objects/gui.o objects/gui_gtk.o objects/gui_gtk_x11.o objects/gui_gtk_f.o objects/gui_beval.o objects/gui_gtk_gresources.o objects/vterm_encoding.o objects/vterm_keyboard.o objects/vterm_mouse.o objects/vterm_parser.o objects/vterm_pen.o objects/vterm_screen.o objects/vterm_state.o objects/vterm_unicode.o objects/vterm_vterm.o objects/job.o objects/channel.o objects/xdiffi.o objects/xemit.o objects/xprepare.o objects/xutils.o objects/xhistogram.o objects/xpatience.o objects/charset.o objects/json.o objects/main.o objects/memfile.o objects/message.o -lgtk-x11-2.0 -lgdk-x11-2.0 -lpangocairo-1.0 -latk-1.0 -lcairo -lgdk_pixbuf-2.0 -lgio-2.0 -lpangoft2-1.0 -lpango-1.0 -lgobject-2.0 -lglib-2.0 -lharfbuzz -lfontconfig -lfreetype -lSM -lICE -lXpm -lXt -lX11 -lXdmcp -lSM -lICE -lm -ltinfo -lselinux -ldl /usr/bin/ld: objects/os_unix.o: in function `stop_timeout': /opt/bld/vim/src/os_unix.c:8278: undefined reference to `timer_settime' /usr/bin/ld: objects/os_unix.o: in function `start_timeout': /opt/bld/vim/src/os_unix.c:8318: undefined reference to `timer_create' /usr/bin/ld: /opt/bld/vim/src/os_unix.c:8331: undefined reference to `timer_settime' /usr/bin/ld: objects/os_unix.o: in function `delete_timer': /opt/bld/vim/src/os_unix.c:8346: undefined reference to `timer_delete' collect2: error: ld returned 1 exit status link.sh: Linking failed make[1]: *** [Makefile:2112: vim] Error 1
—
Reply to this email directly, view it on GitHub.
You are receiving this because you are subscribed to this thread.![]()
I cannot reproduce this. When lining works, does the link command have "-lrt" ?
Any differences between the two link commands?
What changed not so long ago is cross-compiling support related to timers. I don't see why that would be a problem for you (while nobody else complains so far). You could sync back to 9.0.0064 to see if it works, then to 9.0.0065 to see if it fails.
—
Reply to this email directly, view it on GitHub.
You are receiving this because you are subscribed to this thread.![]()
Hi,
I have the same error while compiling a Debian package from the git master branch. I can confirm that reverting 509695c makes the compilation succeed.
—
Reply to this email directly, view it on GitHub.
You are receiving this because you are subscribed to this thread.![]()
When lining works, does the link command have "-lrt" ?
When linking works, "-lrt" is present. When linking does not work, "-lrt" is absent, and that is the sole difference between the linking commands. This is 9.0.0084.
9.0.0064 is fine and I can't reproduce. I'll try 9.0.0065.
—
Reply to this email directly, view it on GitHub.
You are receiving this because you are subscribed to this thread.![]()
9.0.0065 is bad, 9.0.0064 is not.
—
Reply to this email directly, view it on GitHub.
You are receiving this because you are subscribed to this thread.![]()
OK, so the missing "-lrt" in $LIBS is the problem. However, normally this is set in src/auto/config.mk and it does not change when doing "make clean". My copy has this line:
LIBS = -lm -ltinfo -lselinux -lcanberra -lsodium -lrt -lgpm
If you override $LIBS then it would fail before and after "make clean". I can't guess what the problem is.
—
Reply to this email directly, view it on GitHub.
You are receiving this because you are subscribed to this thread.![]()
If it helps, I always use ./configure -C when building.
Also, here are the flags I use:
--with-x
--enable-gui=gtk2
--x-includes=/usr/include/x86_64-linux-gnu
--x-libraries=/lib/x86_64-linux-gnu
--disable-netbeans
--disable-nls
--with-compiledby=me
--prefix=$HOME/sw
—
Reply to this email directly, view it on GitHub.
You are receiving this because you are subscribed to this thread.![]()
FYI, 9.0.98 does not solve this problem.
—
Reply to this email directly, view it on GitHub.
You are receiving this because you are subscribed to this thread.![]()
From the other thread:
Can you check the LIBS line in src/auto/config.mk ? It probably should
include "-lrt". If not, then try adding it (and run "make", not
"configure").
That worked.
—
Reply to this email directly, view it on GitHub.
You are receiving this because you are subscribed to this thread.![]()
—
Reply to this email directly, view it on GitHub.
You are receiving this because you are subscribed to this thread.![]()
Strange. So when running configure/make after "make distclean" then LIBS includes "-lrt", but after "make clean" it does not?
That's right. Triple checked.
And can you see where the "LIBS" line is changed?
I'm not sure what you're asking, but I'll describe how the LIBS line changed through the process, starting from a clean git clone.
configure -C [args] and make steps, LIBS contains -lrt.make clean. I see that LIBS still contains -lrt.configure -C [args] again, but DO NOT make: I see that LIBS has lost the -lrt.At this point if I try to make, linking will fail. But a make distclean will temporarily cure things since it cleans up config.mk into some kind of stub.
—
Reply to this email directly, view it on GitHub.
You are receiving this because you are subscribed to this thread.![]()
—
Reply to this email directly, view it on GitHub.
You are receiving this because you are subscribed to this thread.![]()
Closed #10799 as completed via efffa53.
—
Reply to this email directly, view it on GitHub.
You are receiving this because you are subscribed to this thread.![]()