Solved ld-elf.so.1: /usr/local/bin/emacs: Undefined symbol "fflush_unlocked@FBSD_1.6"

I've just installed emacs on two systems, both running 12.2-RELEASE and one it works fine, but on the other I get this error:-
Code:
ld-elf.so.1: /usr/local/bin/emacs: Undefined symbol "fflush_unlocked@FBSD_1.6"

I've run pkg update on both but can't get rid of this error.

I came across a post, Thread 76581reporting a similar error but didn't see a solution.

After deleting the pkg, i installed emacs-nox, but got the same error when running the program.

Anyone come across the problem recently?
 
Make sure your system is completely up to date. And by completely, I also mean the latest patch version.

How did you update? Via source or freebsd-update(8)?
 
Patch level should never be an issue, but it is an incomplete upgrade. I only upgrade from source, but having seen many reports of problems with symbols / symbol versions on 12.2, I decided to try to reproduce on a VM, and couldn't, see PR 254290.

Most likely IMHO is "user error" (not following the upgrade procedure with freebsd-update(8) correctly)…
 
Well it looks like it may well have been due to "user error" ... <blush> I had run freebsd-update install because I was at 12.2-RELEASE p4, but when I ran it again some more programs were updated which must have cleared the above error as I can now run emacs, and this did not require a reboot.

Thanks for the help.
 
You have to run freebsd-update install at least twice. The first time only the kernel gets updated, the second run will update the userland. With a major version upgrade you have to run it three times even. The third will remove any old libraries and other things.
 
Back
Top