termux / termux-packages

A package build system for Termux.
https://termux.dev
Other
13.39k stars 3.08k forks source link

[Bug]: [SDK?] Compilation Errors Due to Macro Conflict with 'index' in X11/Xos.h #22115

Open IntinteDAO opened 3 weeks ago

IntinteDAO commented 3 weeks ago

Problem description

This title was suggested by ChatGPT, because I have no idea how it should sound properly.

There is a series of errors when compiling scim, but it seems to me that it does not affect the code itself directly, but the SDK (or NDK?) code. I'd love to learn something about it, solutions and so on.

https://bin.bus-hit.me/?d64d4622285ae92c#DMhaeSW94wSwFwtpSqb45NAucjnSB1fGdZMhNS9iWnDY

What steps will reproduce the bug?

https://github.com/IntinteDAO/termux-packages/tree/scim Build scim in Termux Build Environment

What is the expected behavior?

No response

System information

---
Biswa96 commented 3 weeks ago

You can workaround the issue with #undef index.

IntinteDAO commented 3 weeks ago

Ok, Works

I wonder if it's a bug in Termux and leave you have to, or if it can't be fixed and closed with workarounds in mind.