Expose architecture defines during Project XML parsing#2044
Expose architecture defines during Project XML parsing#2044Tutez64 wants to merge 1 commit intoopenfl:developfrom
Conversation
|
I would prefer to avoid exposing the |
|
I agree, the goal is to expose the target architecture information.
rather than If that approach sounds good, I can update the PR accordingly. |
|
That does sound better, however, just to let you know because I saw the steamwrap or that you linked. Lime follows a layout in the ndll folder which should allow copying to be handled automatically for every platform, without the include.xml having to do it manually. I would recommend relying on that rather than handling each case individually, that might also avoid the need for these flags. Lime's ndll is handled like this for example. |
|
I tested this approach locally. I placed In the final output, Lime still copied So from what I could reproduce, the standard ndll layout seems to handle selecting the correct ndll, but not automatically packaging additional runtime libraries beside it. If there is a specific extension or code path that demonstrates the intended behavior, I’d be happy to follow that pattern instead. |
Summary
This updates Lime to expose resolved architecture defines earlier, during Project XML parsing.
HXProjectnow sets architecture-related defines such as:HXCPP_M32HXCPP_M64HXCPP_ARM643264x86_32x86_64arm64based on the requested target flags, or the default native architecture when applicable.
Why
Some extensions need to select platform-specific runtime assets from
include.xml, but architecture information was only becoming available later during the build phase.This made conditions like
if="HXCPP_M32"unusable ininclude.xml, even though the final build target was already known.Result
Extensions can now use normal XML conditions to choose the correct architecture-specific assets during project parsing, without requiring post-build scripts or other workarounds.