Created attachment 444592 [details] build.log app-editors/nano-2.6.3 fails to build on amd64-fbsd with the following error: winio.c: In function ‘parse_kbinput’: winio.c:513:15: error: ‘TIOCLINUX’ undeclared (first use in this function) if (ioctl(0, TIOCLINUX, &modifiers) >= 0 && (modifiers & 0x04)) { ^ winio.c:513:15: note: each undeclared identifier is reported only once for each function it appears in The following patch fixes this problem and also bug 591026: http://git.savannah.gnu.org/cgit/nano.git/commit/?id=928a24c20444a652212e544a506ed55c44efdf3b
At the tindeebox the setup of new images often fails with a similar error : x86_64-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I.. -DLOCALEDIR=\"/usr/share/locale\" -DSYSCONFDIR=\"/etc\" -D_GNU_SOURCE -I/usr/include/ncursesw -march=native -O2 -pipe -Wall -c -o winio.o winio.c winio.c: In function ‘parse_kbinput’: winio.c:515:20: error: ‘do_prev_block’ undeclared (first use in this function) return sc_seq_or(do_prev_block, 0); ^ winio.c:515:20: note: each undeclared identifier is reported only once for each function it appears in winio.c:517:20: error: ‘do_next_block’ undeclared (first use in this function) return sc_seq_or(do_next_block, 0); ^ winio.c:519:20: error: ‘do_prev_word_void’ undeclared (first use in this function) return sc_seq_or(do_prev_word_void, 0); ^ winio.c:521:20: error: ‘do_next_word_void’ undeclared (first use in this function) return sc_seq_or(do_next_word_void, 0); ^ Makefile:427: recipe for target 'winio.o' failed make[2]: *** [winio.o] Error 1 make[2]: Leaving directory '/var/tmp/portage/app-editors/nano-2.6.3/work/nano-2.6.3/src' Makefile:405: recipe for target 'all-recursive' failed
I've tested nano-2.7.0 on Gentoo/FBSD-amd64, Linux/x86_64, and Linux/MIPS N32. It solves this bug in the FreeBSD case and appears to work fine on the other two platforms. I just added it to the tree, so please test and report new bugs if any new issues crop up. I'm going to resolve this bug versus adding the patch to 2.6.3, since it looks like there isn't even a $FILESDIR for the nano branch in the repo. Unknown if it also resolves #591026, as I haven't ran into that bug on any of my platforms.