Skip to content

Compilation error in CodeBlock #27799

Closed
Closed
@Vasyan2006

Description

Describe the bug
Compilation error in CodeBlock

To Reproduce
Steps to reproduce the behavior:

  1. Download source code.
  2. Start CodeBlock
  3. Open CataclysmWin.cbp.
  4. Press "Build and run" button.

Screenshots
Actual error message:

||=== Build: Release in Cataclysm (compiler: GNU GCC Compiler) ===|
C:\Games\_debug\master\src\posix_time.cpp||In function 'int nanosleep(const timespec*, timespec*)':|
C:\Games\_debug\master\src\posix_time.cpp|14|error: 'errno' was not declared in this scope|
C:\Games\_debug\master\src\posix_time.cpp|14|error: 'EINVAL' was not declared in this scope|
||=== Build finished: 2 error(s), 0 warning(s) (0 minute(s), 10 second(s)) ===|

Versions and configuration(please complete the following information):

  • OS: Windows 10
  • Game Version: Todays code at 8:24 AM GMT
  • Graphics version: Terminal

UPD: It was created by #27785
UPD2: This error disappears after adding previously removed #include <cerrno> in posix_time.h
UPD3: Travis has the same error in all PRs:

src/posix_time.cpp: In function 'int nanosleep(const timespec*, timespec*)':
src/posix_time.cpp:14:9: error: 'errno' was not declared in this scope
         errno = EINVAL;
         ^
src/posix_time.cpp:14:17: error: 'EINVAL' was not declared in this scope
         errno = EINVAL;
                 ^

Metadata

Assignees

No one assigned

    Labels

    <Bug>This needs to be fixedCode: BuildIssues regarding different builds and build environments

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions