If you are still using package emacs-nox11: It is obsolete, it has been obsolete for years. It will break when you upgrade. Just happened to me when moving from 12.3-p3 to 12.3-p5. The reason is that is hasn't been updated in ages, and relies on obsolete internals in libxml. The fix is really easy: uninstall emacs-nox11, and instead install emacs-nox. That also gives you a much newer emacs version 27.2, while the old emacs-nox11 is stuck at version 25.