Skip to content

Getting error "ioctl and TIOCGWINSZ are not declared in the scope" in Solaris 10 during compilation #3643

@SowndharyaKs

Description

@SowndharyaKs

On Solaris 10 x86 and sparc, below error is seen while building poco 1.11.3. ioctl function is not defined in sys/ioctl.h in Solaris 10. “TIOCGWINSZ” is also not declared in the header files included in 4066c4d.

Error:
src/Application.cpp: In static member function 'static Poco::Util::Application::WindowSize Poco::Util::Application::windowSize()':
src/Application.cpp:338:17: error: aggregate 'Poco::Util::Application::windowSize()::winsize winsz' has incomplete type and cannot be defined
struct winsize winsz;
^

src/Application.cpp:339:18: error: 'TIOCGWINSZ' was not declared in this scope
if (ioctl(0, TIOCGWINSZ , &winsz) != -1)
^
src/Application.cpp:339:37: error: 'ioctl' was not declared in this scope
if (ioctl(0, TIOCGWINSZ , &winsz) != -1)
^
GCC version: 5.5.0 (using c++11)

Config.txt

Compiling using below options:
./configure --config=<< using attached config >> --prefix=<< install-dir >>
--omit=Encodings,Net,NetSSL_OpenSSL,Data,Data/SQLite,Data/ODBC,Data/MySQL,Zip,PageCompiler,PageCompiler/File2Page,JWT,CppParser,PDF,MongoDB,Redis --include-path=<< openssl-include-path >> --library-path=<< openssl-lib-path >>

Can you please help with this issue?

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions