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

AIX 32bit build fails: 'error: size of unnamed array is negative' #111687

Closed
ayappanec opened this issue Nov 3, 2023 · 1 comment
Closed

AIX 32bit build fails: 'error: size of unnamed array is negative' #111687

ayappanec opened this issue Nov 3, 2023 · 1 comment
Labels
build The build process and cross-build type-bug An unexpected behavior, bug, or error

Comments

@ayappanec
Copy link
Contributor

ayappanec commented Nov 3, 2023

Bug report

Bug description:

AIX 32bit build fails after #111641

./Modules/timemodule.c: In function 'check_ticks_per_second':
./Modules/timemodule.c:78:36: warning: comparison is always false due to limited range of data type [-Wtype-limits]
78 | if (tps >= 0 && (_PyTime_t)tps > _PyTime_MAX / SEC_TO_NS) {
| ^
In file included from ./Include/Python.h:42,
from ./Modules/timemodule.c:3:
./Modules/timemodule.c: In function 'time_clockid_converter':
./Include/pymacro.h:62:18: error: size of unnamed array is negative
62 | (sizeof(char [1 - 2*!(cond)]) - 1)
| ^
./Include/pymacro.h:65:15: note: in expansion of macro 'Py_BUILD_ASSERT_EXPR'
65 | (void)Py_BUILD_ASSERT_EXPR(cond);
| ^~~~~~~~~~~~~~~~~~~~
./Modules/timemodule.c:252:5: note: in expansion of macro 'Py_BUILD_ASSERT'
252 | Py_BUILD_ASSERT(sizeof(clk_id) == sizeof(*p));
| ^~~~~~~~~~~~~~~
gmake: *** [Makefile:3239: Modules/timemodule.o] Error 1
gmake: *** Waiting for unfinished jobs....

There are no problems with AIX 64bit build.

CPython versions tested on:

CPython main branch

Operating systems tested on:

Other

Linked PRs

@ayappanec ayappanec added the type-bug An unexpected behavior, bug, or error label Nov 3, 2023
@AlexWaygood AlexWaygood added the build The build process and cross-build label Nov 3, 2023
ayappanec added a commit to ayappanec/cpython that referenced this issue Nov 3, 2023
@ayappanec
Copy link
Contributor Author

closed via #112170

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
build The build process and cross-build type-bug An unexpected behavior, bug, or error
Projects
None yet
Development

No branches or pull requests

2 participants