As the title states, you cannot build ncurses with crossdev's mingw-w64 toolchain without --enable-term-driver passed to the ./configure script. You will end up with the following errors: ../obj_s/lib_kernel.o:lib_kernel.c:(.text+0xe3): undefined reference to `_nc_mingw_tcflush' ../obj_s/lib_kernel.o:lib_kernel.c:(.text+0x12a): undefined reference to `_nc_mingw_tcflush' ../obj_s/lib_ttyflags.o:lib_ttyflags.c:(.text+0x5f): undefined reference to `_nc_mingw_tcgetattr' ../obj_s/lib_ttyflags.o:lib_ttyflags.c:(.text+0x118): undefined reference to `_nc_mingw_tcsetattr' collect2: error: ld returned 1 exit status make[1]: *** [Makefile:850: ../lib/libncurses6.dll] Error 1 This bug is mostly for documentation purposes, as my pull request for it (https://github.com/gentoo/gentoo/pull/5734) will address this issue and also fix bug https://bugs.gentoo.org/631468
The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=fc3a9c5ebff98664ab50c9a8ff4e136bea9bd0db commit fc3a9c5ebff98664ab50c9a8ff4e136bea9bd0db Author: Marty E. Plummer <hanetzer@protonmail.com> AuthorDate: 2017-09-20 09:09:33 +0000 Commit: Lars Wendler <polynomial-c@gentoo.org> CommitDate: 2018-03-28 07:46:50 +0000 sys-libs/ncurses: fix mingw-w64 build and runtime *.dll.a files are required for linking on mingw-w64 targets, only delete normal static libraries. --enable-term-driver is required on mingw-w64, otherwise you get a host of undefined reference to `_nc_*' errors, and possibly other windows platforms/runtimes/toolchains. Bug: https://bugs.gentoo.org/631468 Bug: https://bugs.gentoo.org/639670 Package-Manager: Portage-2.3.10, Repoman-2.3.3 Signed-off-by: Marty E. Plummer <hanetzer@protonmail.com> Closes: https://github.com/gentoo/gentoo/pull/5734 sys-libs/ncurses/ncurses-6.0-r2.ebuild | 8 +++++++- sys-libs/ncurses/ncurses-6.1-r2.ebuild | 8 +++++++- 2 files changed, 14 insertions(+), 2 deletions(-)}
The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f8a9083ee799487181327c3d51f44bbdea1e2bfd commit f8a9083ee799487181327c3d51f44bbdea1e2bfd Author: Michael Haubenwallner <haubi@gentoo.org> AuthorDate: 2019-07-31 11:19:47 +0000 Commit: Michael Haubenwallner <haubi@gentoo.org> CommitDate: 2019-07-31 11:34:05 +0000 profiles/prefix/windows: p.use.mask tinfo for ncurses On KERNEL=Winnt, ncurses requires the term-driver option (#639670), which conflicts with the termlib option (use.forced by #487844). Bug: https://bugs.gentoo.org/639670 Bug: https://bugs.gentoo.org/487844 Signed-off-by: Michael Haubenwallner <haubi@gentoo.org> profiles/prefix/windows/package.use.mask | 6 ++++++ 1 file changed, 6 insertions(+)