Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HAVE_NCURSESW_CURSES_H flag set without having the include file #886

Closed
maki-chan opened this issue Jun 18, 2019 · 10 comments
Closed

HAVE_NCURSESW_CURSES_H flag set without having the include file #886

maki-chan opened this issue Jun 18, 2019 · 10 comments

Comments

@maki-chan
Copy link

Due to this commit I am not able to compile rtorrent anymore: 9cce5a0

The problem is, that with Arch Linux, there is no <ncursesw/curses.h> file, but the HAVE_NCURSESW_CURSES_H flag gets set and thus I get a compilation error that the file ncursesw/curses.h cannot be found.

@chros73
Copy link
Contributor

chros73 commented Jun 18, 2019

It was a pull request that was merged after 0.9.7 release. You can try to contact @ss23 about this.
So the 0.9.7 release should compile fine.

@ss23
Copy link
Contributor

ss23 commented Jun 18, 2019

I'm not super familiar with autotools, but HAVE_NCURSESW_CURSES_H will only be set if pkgconfig finds it: PKG_CHECK_MODULES([CURSES],[ncursesw],[...]. Is there a reason it would be found on your system, but not exist? Do you know if the problem is across multiple arch installs, or just yours?

@nouman8
Copy link

nouman8 commented Jun 20, 2019

having same issue on Arch Linux as well..can't compile rtorrent master branch.

@maki-chan
Copy link
Author

@ss23 Arch Linux has an include file called /usr/include/cursesw.h. I don't know if that's the path in Arch Linux for ncursesw support, but it seems to be the case. The package itself can be found here: https://www.archlinux.org/packages/core/x86_64/ncurses/

@ghost
Copy link

ghost commented Jun 20, 2019

Also experiencing this, can't compile rtorrent.

Also on Arch.

./../display/attributes.h:44:10: fatal error: ncursesw/curses.h: No such file or directory
 #include <ncursesw/curses.h>
          ^~~~~~~~~~~~~~~~~~~
compilation terminated.

These files exist on my system:

/usr/include/curses.h
/usr/include/ncurses.h

ss23 added a commit to ss23/rtorrent that referenced this issue Jun 27, 2019
This is a fix for rakshasa#886, a bug that causes Arch Linux to fail
compilation.
@ss23
Copy link
Contributor

ss23 commented Jun 27, 2019

I don't have an Arch Linux system to test on, but it looks like some weirdness to do with how they package ncurses: https://git.archlinux.org/svntogit/packages.git/tree/trunk/PKGBUILD?h=packages/ncurses#n36

I've pushed an attempted fix for this that just checks for ncurses before ncursesw, which may fix it. Could someone try applying https://github.com/ss23/rtorrent/commit/a808d67b1fe28c74a4f6e3b44000fd51f864f11e.patch (or checking out the branch) and seeing if that helps?

@chros73
Copy link
Contributor

chros73 commented Jun 27, 2019

I don't have an Arch Linux system to test on

You can install it in a VM if it's not trouble.

@rakshasa
Copy link
Owner

Should be fixed.

@nouman8
Copy link

nouman8 commented Jul 13, 2019

just tried, still not compiling on Archlinux.

@rakshasa
Copy link
Owner

It seems ax_with_curses.m4 was too old, and the newest version had various issues, so some custom autoconf magic was committed due to broken pkgconfig files in most distros.

Reverted to using only ax_with_curses.m4, and upgraded it from 13 to 16, which is the latest one that seems to work properly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants