Skip to content

Commit 1809c8b

Browse files
authored
feat(eui-neo): add 0.6.2 (#625)
CORE_SOURCES and VULKAN_SOURCES are byte-identical to 0.6.1 (extracted and diffed from both CMakeLists.txt), so the lib's source list, deps, features and flags carry over unchanged. The release is SDL2 single-finger touch input, pixel-granular ScrollEvent::pixelX/pixelY, Markdown viewport-only builds and text-rendering memory work. The one descriptor-relevant change: upstream fixed 0.6.1's sendX11MoveResizeForWindow guard break (the SDL2 branch's definition is now hoisted OUT of the SDL_VIDEO_DRIVER_X11 guard, verified by diffing window_backend.cpp across the two tags), which collides with this index's 0.6.1 package-private stub on non-linux (redefinition, measured). Version-gating the generated header is not expressible (the xpkg parser accepts only literal strings in generated_files; a concatenated value fails with "malformed mcpp segment"), so the stub became a FUNCTION TEMPLATE: on 0.6.1 non-linux it is the only candidate; on 0.6.2 the real non-template definition wins the exact-match tie and the template goes unused. Verified with g++ mini-repros modelling each tag's exact structure (both platform shapes, plus a negative control), and by building/running every eui-neo member against 0.6.2 (sdl2/vulkan/app-main/markdown/tray/window: test result ok; the base member compiles+links 0.6.2 and only fails this machine's pre-existing runtime-closure check, which 0.6.1 fails identically -- stale subos libffi.so.7 vs the index's libffi 3.4.4). sha256 verified twice (two fresh downloads). No CN mirror yet -- plain- string GLOBAL url per SOP; members' pins raised 0.6.1 -> 0.6.2.
1 parent 6364f05 commit 1809c8b

9 files changed

Lines changed: 203 additions & 21 deletions

File tree

Lines changed: 137 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,137 @@
1+
# Design doc: bump `compat.eui-neo` to 0.6.2
2+
3+
Date: 2026-10-30
4+
5+
Follow-up to `.agents/docs/2026-10-14-bump-eui-neo-0.6.1-plan.md` and commit `725ca5d` (0.6.1).
6+
Upstream released 0.6.2; this bumps the index from 0.6.1 to 0.6.2.
7+
8+
## Source and version
9+
10+
| | |
11+
|---|---|
12+
| Upstream | `https://github.com/sudoevolve/EUI-NEO` |
13+
| Version | `0.6.2` (latest release) |
14+
| Tarball | `archive/refs/tags/v0.6.2.tar.gz` |
15+
| sha256 | `189d97aadb044de653237e12ac97d6fa92f1a65952854e3db6211d360f4d4124` (computed twice — local download and a second fresh download, stable) |
16+
| Wrap dir | `EUI-NEO-0.6.2/` — absorbed by the existing `install()` hook (`normalise_layout`) |
17+
| CN mirror | **pending** — no `mcpp-res` write access on this machine; plain-string url fallback per SOP |
18+
| License | Apache-2.0 (unchanged) |
19+
20+
## What changed upstream (0.6.1 → 0.6.2)
21+
22+
Release notes: `docs/releases/v0.6.2.md` (SDL2 single-finger touch input,
23+
pixel-granular `ScrollEvent::pixelX/pixelY`, Markdown viewport-only builds,
24+
glyph-advance caching, on-demand glyph-atlas allocation, ~8 MB text-memory
25+
win, software-renderer TODO doc).
26+
27+
- **`CORE_SOURCES` and `VULKAN_SOURCES` are byte-identical to 0.6.1**
28+
(extracted and diffed from both `CMakeLists.txt`). No new files under
29+
`core/`; the changed files are internals (`text.cpp/h`, `opengl_text.cpp`,
30+
`vulkan_text.cpp`, input headers, `render_backend.h`, `dsl_runtime.h`,
31+
runtime headers, `components/markdown.h`, `sdl2_app_main.cpp` + a new
32+
`<unordered_map>` include) and app/test/doc material. The lib's source
33+
list, deps, features and flags carry over unchanged.
34+
- `components/markdown.h` still guards its body on `EUI_HAS_MD4C` — the
35+
`markdown` feature is unchanged.
36+
- `sdl2_app_main.cpp` (the `app-main-sdl2` feature TU) gains one STL include
37+
only — no descriptor impact.
38+
- **The one descriptor-relevant change**: upstream fixed the 0.6.1
39+
`sendX11MoveResizeForWindow` breakage this index worked around in
40+
`mcpp_eui_backends.h`. In 0.6.1 the SDL2 branch's definition sat INSIDE
41+
`#if __linux__ && !__ANDROID__ && defined(SDL_VIDEO_DRIVER_X11)` while
42+
`beginWindowMove`/`beginWindowResize` called it unguarded; 0.6.2 moved the
43+
`#endif` from below the definition to above it (verified by diffing
44+
`core/window/window_backend.cpp` across the two extracted tags), so the
45+
definition is now unguarded — with the X11 specifics still inside the
46+
guard and an `#else return false` body, exactly like the GLFW branch.
47+
48+
## The shim problem this creates
49+
50+
The 0.6.1 workaround's non-linux arm is a package-private stub:
51+
52+
```cpp
53+
namespace core::window {
54+
inline bool sendX11MoveResizeForWindow(void* window, int direction) { … }
55+
}
56+
```
57+
58+
On 0.6.2 non-linux, upstream's now-unguarded real definition reaches the
59+
same TU → **redefinition** (measured: compile of the 0.6.2 member against
60+
the unmodified 0.6.1-era header fails). Version-gating the generated header
61+
from the descriptor is not expressible: the xpkg parser accepts only literal
62+
strings in `generated_files` — a concatenated Lua value fails with
63+
`malformed mcpp segment` (measured with a probe package on mcpp
64+
2026.10.1.2), so `pkginfo.version()` cannot select header content, and no
65+
per-version `mcpp` override exists in the schema.
66+
67+
**Fix: the stub became a function template.**
68+
69+
```cpp
70+
namespace core::window {
71+
template <typename W>
72+
inline bool sendX11MoveResizeForWindow(W* window, int direction) { … }
73+
}
74+
```
75+
76+
- 0.6.1 non-linux: the definition is guard-hidden, the template is the only
77+
candidate, the unguarded uses at :567/:571 resolve to it. Compiles and
78+
links (weak inline symbol).
79+
- 0.6.2 non-linux: the real non-template definition precedes the uses; the
80+
call is an exact-match tie between template (W deduces to void, `Handle`
81+
is `void*` in the SDL2 branch) and non-template — non-template wins — and
82+
the template goes unused. A template and a non-template of the same name
83+
coexist, so there is no redefinition.
84+
- linux (both tags): the linux arm still defines `SDL_VIDEO_DRIVER_X11=1`
85+
for the package's own TUs. On 0.6.1 that wakes the guard holding the real
86+
definition (non-template wins over the template — fine). On 0.6.2 it wakes
87+
the self-contained `X11ResourceApi` block (which self-includes
88+
`<SDL_syswm.h>`/`<X11/Xresource.h>` inside the guard) and the guarded
89+
branch of `sendX11MoveResizeForWindow`/`x11ContentScale`; runtime-safe
90+
under compat.sdl2 (dummy+offscreen — no SDL window is ever an X11 window,
91+
and `x11ResourceApi()` fails its `available()` check without libX11).
92+
93+
Mechanism verified with g++ -std=c++17 mini-repros that model each tag's
94+
exact structure (guard-hidden vs unguarded definition), force-including the
95+
extracted shim header:
96+
97+
- 0.6.1 shape, simulated non-linux (`-U__linux__`): compiles+links, template
98+
emitted (`nm`: weak `sendX11MoveResizeForWindow<void>`), picked at runtime.
99+
- 0.6.2 shape, simulated non-linux: compiles+links, exit code proves the
100+
real definition (returns true) won over the template (returns false).
101+
- 0.6.1 linux shape (macro woken): real in-guard definition wins, exit code
102+
proves it.
103+
- Negative control: 0.6.1 shape WITHOUT the shim fails to compile
104+
('core' undeclared), matching the original 0.6.1 failure.
105+
106+
## Version bumps
107+
108+
- `pkgs/e/compat.eui-neo.lua`: 0.6.2 entries on linux/macosx/windows,
109+
plain-string GLOBAL url (no CN mirror yet), plus the file-top version note.
110+
- Member pins `0.6.1` → `0.6.2` in all seven `tests/examples/eui-neo*`
111+
members (the pins are floors; resolution picked 0.6.1 over 0.6.2 until
112+
raised — same pattern as the 0.6.1 bump).
113+
114+
## Local verification (mcpp 2026.10.29.1, xlings 2026.10.26.1)
115+
116+
- `eui-neo-sdl2`, `eui-neo-vulkan`, `eui-neo-app-main`, `eui-neo-markdown`,
117+
`eui-neo-tray`, `eui-neo-window`: **test result ok** (each builds
118+
compat.eui-neo 0.6.2 and runs). The sdl2 member is the one that exercises
119+
the reworked shim path on linux.
120+
- `eui-neo` (base member): compat.eui-neo 0.6.2 compiles and links (27
121+
units), but the post-link runtime-closure check fails on this machine:
122+
`libffi.so.8` is not on the artifact's search path. This is pre-existing
123+
environment rot, not a 0.6.2 regression: the 0.6.1 build fails the same
124+
check here (measured before the bump), the subos library view at
125+
`~/.mcpp/registry/subos/default/lib` still carries `libffi.so.7` while the
126+
index resolves `xim:libffi@3.4.4` (which ships `.so.8`), and
127+
`xlings install/update xim:libffi` both report "already installed" without
128+
repointing the view. CI's fresh containers are authoritative for the run.
129+
- `mcpp xpkg parse` on the descriptor: OK. Lint equivalents (mirror urls,
130+
platform parity, duplicate versions) pass locally.
131+
132+
## Notes
133+
134+
- The `mcpp` segment stays version-independent; one header now serves every
135+
published tag (0.5.3 through 0.6.2).
136+
- The 0.6.1-era comment block in the descriptor was updated, not removed —
137+
the template trick only makes sense with the 0.6.1 history in view.

‎pkgs/e/compat.eui-neo.lua‎

Lines changed: 59 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,30 @@
1717
-- them as `"3rd/stb_image.h"` — except miniaudio, which audio.cpp includes
1818
-- BARE; see the 0.6.0 note below.
1919
--
20-
-- The build recipe below tracks upstream `CMakeLists.txt` (v0.6.1): CORE_SOURCES
20+
-- 0.6.2: CORE_SOURCES and VULKAN_SOURCES are byte-identical to 0.6.1, so the
21+
-- lib's source list, deps, features and flags carry over unchanged. The
22+
-- release is touch input for the SDL2 backend (single-finger pointer events,
23+
-- pixel-granular ScrollEvent::pixelX/pixelY), Markdown viewport-only builds,
24+
-- glyph-advance caching and on-demand glyph-atlas allocation, plus upstream
25+
-- regression probes. It also UN-DOES the one descriptor-relevant break of
26+
-- 0.6.1: upstream hoisted the SDL2 branch's sendX11MoveResizeForWindow
27+
-- definition OUT of the `#if … && defined(SDL_VIDEO_DRIVER_X11)` guard (the
28+
-- `#endif` moved from below the definition to above it — compare
29+
-- core/window/window_backend.cpp across the two tags), giving the non-linux
30+
-- platforms a real definition with the `#else return false` body upstream's
31+
-- GLFW branch always had. That collides with the 0.6.1 package-private stub
32+
-- in mcpp_eui_backends.h (redefinition, measured on a 0.6.2 compile), so the
33+
-- stub became a FUNCTION TEMPLATE: on 0.6.1 non-linux it is still the only
34+
-- candidate and satisfies the unguarded uses; on 0.6.2 non-linux the real
35+
-- non-template definition is preferred by overload resolution (exact-match
36+
-- tie → non-template wins) and the template goes unused; a template and a
37+
-- non-template with the same name coexist, so there is no redefinition on
38+
-- either tag. Versions cannot gate descriptor content (the xpkg parser
39+
-- accepts only literal strings in generated_files — a concatenated value
40+
-- fails with "malformed mcpp segment", measured), so one header must serve
41+
-- every published version, and the template is what makes that possible.
42+
--
43+
-- The build recipe below tracks upstream `CMakeLists.txt` (v0.6.2): CORE_SOURCES
2144
-- plus the OpenGL backend and, for the glfw window backend, `ime_bridge.c`.
2245
-- 0.5.5 grew a Shadertoy subsystem: render_backend.h and include/eui/types.h now
2346
-- include core/render/shadertoy.h unconditionally, and opengl_backend.cpp calls
@@ -250,6 +273,14 @@ package = {
250273
url = "https://github.com/sudoevolve/EUI-NEO/archive/refs/tags/v0.6.1.tar.gz",
251274
sha256 = "cd0bd6bd437177db097da146fc20f4b8b01c70d0db561a6f8e26baa26dbbbf5f",
252275
},
276+
-- 0.6.2: CORE_SOURCES/VULKAN_SOURCES byte-identical to 0.6.1; the
277+
-- mcpp_eui_backends.h stub is now a template so the header serves
278+
-- both tags (see the file-top note). No CN mirror yet — plain-
279+
-- string GLOBAL url, same as 0.6.1.
280+
["0.6.2"] = {
281+
url = "https://github.com/sudoevolve/EUI-NEO/archive/refs/tags/v0.6.2.tar.gz",
282+
sha256 = "189d97aadb044de653237e12ac97d6fa92f1a65952854e3db6211d360f4d4124",
283+
},
253284
},
254285
macosx = {
255286
["0.5.3"] = {
@@ -302,6 +333,11 @@ package = {
302333
url = "https://github.com/sudoevolve/EUI-NEO/archive/refs/tags/v0.6.1.tar.gz",
303334
sha256 = "cd0bd6bd437177db097da146fc20f4b8b01c70d0db561a6f8e26baa26dbbbf5f",
304335
},
336+
-- 0.6.2: see the linux block — plain-string GLOBAL, no CN mirror.
337+
["0.6.2"] = {
338+
url = "https://github.com/sudoevolve/EUI-NEO/archive/refs/tags/v0.6.2.tar.gz",
339+
sha256 = "189d97aadb044de653237e12ac97d6fa92f1a65952854e3db6211d360f4d4124",
340+
},
305341
},
306342
windows = {
307343
["0.5.3"] = {
@@ -354,6 +390,11 @@ package = {
354390
url = "https://github.com/sudoevolve/EUI-NEO/archive/refs/tags/v0.6.1.tar.gz",
355391
sha256 = "cd0bd6bd437177db097da146fc20f4b8b01c70d0db561a6f8e26baa26dbbbf5f",
356392
},
393+
-- 0.6.2: see the linux block — plain-string GLOBAL, no CN mirror.
394+
["0.6.2"] = {
395+
url = "https://github.com/sudoevolve/EUI-NEO/archive/refs/tags/v0.6.2.tar.gz",
396+
sha256 = "189d97aadb044de653237e12ac97d6fa92f1a65952854e3db6211d360f4d4124",
397+
},
357398
},
358399
},
359400

@@ -433,23 +474,27 @@ package = {
433474
*
434475
* Both halves must NOT become interface defines — consumers would inherit
435476
* the lie on every platform (on macOS, SDL_syswm.h would then demand X11
436-
* headers consumers do not have). */
477+
* headers consumers do not have).
478+
*
479+
* 0.6.2 note: upstream hoisted the guarded definition OUT of the macro
480+
* guard (window_backend.cpp), so on 0.6.2 this branch's stub must not be a
481+
* plain function — it would redefine the now-unguarded upstream one. It is
482+
* a FUNCTION TEMPLATE instead: on 0.6.1 (definition still guard-hidden) it
483+
* is the only candidate and satisfies the unguarded uses at :567/:571; on
484+
* 0.6.2 the real non-template definition exists before those uses and wins
485+
* the exact-match tie (non-template preferred), leaving the template
486+
* unused. A template and a non-template of the same name coexist, so one
487+
* header serves both tags. Handle is void* in the SDL2 branch
488+
* (window_types.h), so W deduces to void with an exact match.
489+
* Guarded by __cplusplus because mcpp_eui_backends.h is force-included
490+
* into the package's C TUs (tray_bridge.c, native_bridge.c) as well as
491+
* its C++ ones. */
437492
# if defined(__linux__) && !defined(__ANDROID__)
438493
# define SDL_VIDEO_DRIVER_X11 1
439494
# elif defined(__cplusplus)
440-
/* macOS / Windows: `__linux__` is false, so no macro can wake the guarded
441-
* declaration — upstream's own CI builds the SDL2 backend on Linux only and
442-
* never sees it (measured on both CI legs: use of undeclared identifier at
443-
* :567/:571). Supply the fallback upstream's GLFW branch and its release
444-
* notes both describe — "on non-X11 platforms the delegation returns false
445-
* and callers keep their programmatic fallback" — as a core::window stub.
446-
* Handle is void* in the SDL2 branch (window_types.h), so the signature
447-
* matches exactly, and the later real definition cannot exist on this branch
448-
* of the #if (it is linux-only), so there is no redefinition. Guarded by
449-
* __cplusplus because mcpp_eui_backends.h is force-included into the package's
450-
* C TUs (tray_bridge.c, native_bridge.c) as well as its C++ ones. */
451495
namespace core::window {
452-
inline bool sendX11MoveResizeForWindow(void* window, int direction) {
496+
template <typename W>
497+
inline bool sendX11MoveResizeForWindow(W* window, int direction) {
453498
(void)window;
454499
(void)direction;
455500
return false;

‎tests/examples/eui-neo-app-main/mcpp.toml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,4 +30,4 @@ name = "eui-neo-app-main-tests"
3030
version = "0.1.0"
3131

3232
[dependencies.compat]
33-
eui-neo = { version = "0.6.1", features = ["app-main"] }
33+
eui-neo = { version = "0.6.2", features = ["app-main"] }

‎tests/examples/eui-neo-markdown/mcpp.toml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,4 +7,4 @@ version = "0.1.0"
77
# what switches components/markdown.h from its fallback to the real parser.
88

99
[dependencies.compat]
10-
eui-neo = { version = "0.6.1", features = ["markdown"] }
10+
eui-neo = { version = "0.6.2", features = ["markdown"] }

‎tests/examples/eui-neo-sdl2/mcpp.toml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,4 +7,4 @@ version = "0.1.0"
77
# into a real libcurl-backed implementation. The render backend stays OpenGL,
88
# unnamed — naming a feature no longer costs you the defaults.
99
[dependencies.compat]
10-
eui-neo = { version = "0.6.1", features = ["sdl2", "network"] }
10+
eui-neo = { version = "0.6.2", features = ["sdl2", "network"] }

‎tests/examples/eui-neo-tray/mcpp.toml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,4 +25,4 @@ name = "eui-neo-tray-tests"
2525
version = "0.1.0"
2626

2727
[dependencies.compat]
28-
eui-neo = "0.6.1"
28+
eui-neo = "0.6.2"

‎tests/examples/eui-neo-vulkan/mcpp.toml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ version = "0.1.0"
66
# package resolves the exclusive choice in its own preprocessor from the
77
# MCPP_FEATURE_* flags. The window backend stays GLFW, unnamed.
88
[dependencies.compat]
9-
eui-neo = { version = "0.6.1", features = ["vulkan"] }
9+
eui-neo = { version = "0.6.2", features = ["vulkan"] }
1010

1111
[build]
1212
cxxflags = ["-DHAVE_EUI_VULKAN=1"]

‎tests/examples/eui-neo-window/mcpp.toml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,4 +34,4 @@ name = "eui-neo-window-tests"
3434
version = "0.1.0"
3535

3636
[dependencies.compat]
37-
eui-neo = "0.6.1"
37+
eui-neo = "0.6.2"

‎tests/examples/eui-neo/mcpp.toml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,4 @@ name = "eui-neo-tests"
33
version = "0.1.0"
44

55
[dependencies.compat]
6-
eui-neo = "0.6.1"
6+
eui-neo = "0.6.2"

0 commit comments

Comments
 (0)