Bug #1234
closed'fd_set' type not declared
100%
Description
When compiling with CrystaX 10.3.1, I got the following error that didn't exist with 10.2 (didn't try with 10.3.0):
In file included from jni/cryptopp/network.cpp:5:0: jni/cryptopp/wait.h:184:2: error: 'fd_set' does not name a type fd_set m_readfds, m_writefds;
I've tried with armeabi, x86, and mips ABIs. I suspect the same applied for others.
Files
Updated by Dmitry M. almost 9 years ago
- Status changed from Open to Waiting for feedback
- Assignee set to Dmitry M.
According to "POSIX":http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/sys_select.h.html, @fd_set@ is defined in @sys/select.h@. It works in CrystaX NDK 10.3.1.
However, such things can happen when switching from previous CrystaX NDK version to the latest one, since we're working on providing complete POSIX implementation and change public headers occasionally to make it working. Is it regression or not, depends on point of view. Strictly speaking, this is not regression, since we confirm POSIX requirements; however, I'd like to make CrystaX NDK to fit not only requirements, but typical use cases too. In other words, if your code compiles fine without explicit inclusion of @sys/select.h@ on GNU/Linux and/or OS X (the most widely used POSIX-conforming modern operating systems), I'd like to fix it in CrystaX NDK and make other headers implicitly include @sys/select.h@ too; if not, then I'd prefer not touch CrystaX NDK headers, and would suggest you fix it in your code by including @sys/select.h@.
Please provide more details - what exactly was included in jni/cryptopp/network.cpp and, specifically, in jni/cryptopp/wait.h. The preprocessed jni/cryptopp/network.cpp would be even better.
Updated by Alex A. almost 9 years ago
- File include.txt include.txt added
I've attached compilation result with -H
option.
I can also confirm that including sys/select.h
solves the problem. In fact, the upstream of the project I'm compiling (cryptopp) has included the fix, but they did that in android specific way, suggesting that only Android is such strong with POSIX-compliance:
#if defined(__ANDROID__) #include #endif
The older code is compiling fine on all other platforms (Linux, Freebsd, OSX, etc.) and was compiled successfully with previous versions of CrystaX (definitely with 10.2.1).
Updated by Dmitry M. almost 9 years ago
- Category set to libcrystax
- Status changed from Waiting for feedback to In Progress
- Priority changed from Normal to High
- Target version set to 11.0.0
Updated by Dmitry M. almost 9 years ago
- Status changed from In Progress to Completed
- % Done changed from 0 to 100
"Done":https://github.com/crystax/android-platform-ndk/commit/3bc93d1bba2510ce0114c764f828f52b7209b2fd. Will be available in NDK starting from build #798 (https://dl.crystax.net/builds/).