HEMTT icon indicating copy to clipboard operation
HEMTT copied to clipboard

Bad PBOPREFIX makes sqfc compilation fail

Open rekterakathom opened this issue 1 year ago • 6 comments

Tools (complete and add to the following information):

  • HEMTT: 1.12.3 stable
  • Operating System: Windows 10 22H2

Description: ASC does not compile any files

Steps to reproduce:

  1. Checkout this PR
  2. Run 'hemtt build' or 'hemtt release'

Expected behavior: SQF scripts get compiled and included in the built addon.

Logs: asc.log latest.log

Additional context: SQF files get validated properly but not compiled: 2024-06-17T13:48:31.069102Z INFO ThreadId(01) Validated 497 sqf files ... 2024-06-17T13:48:33.152117Z DEBUG ThreadId(01) asc didn't process overthrow_mainaddons/overthrow_main/functions/cleanup/fn_cleanupEmptyGroup.sqf

rekterakathom avatar Jun 17 '24 14:06 rekterakathom

some possible things to check prefix = "OT" but pboPrefix is just overthrow_main

(temp)\asc\output\overthrow_main\missions\fugitive.sqfc exists but the error is DEBUG asc didn't process overthrow_mainaddons/overthrow_main/missions/fugitive.sqf not sure why it's mangling overthrow_mainaddons

PabstMirror avatar Jun 17 '24 15:06 PabstMirror

Yeah the ASC module is definitely not liking that pbo prefix.

You could use --expsqfc to use HEMTT's SQFC compiler instead of ASC, it should work fine but still needs further evaluation.

BrettMayson avatar Jun 17 '24 16:06 BrettMayson

some possible things to check prefix = "OT" but pboPrefix is just overthrow_main

(temp)\asc\output\overthrow_main\missions\fugitive.sqfc exists but the error is DEBUG asc didn't process overthrow_mainaddons/overthrow_main/missions/fugitive.sqf not sure why it's mangling overthrow_mainaddons

Thanks for the heads up. Fixing the pboPrefix makes the compilation work, so I suppose the issue is that an incorrect pboPrefix makes the sqfc compilation fail, but HEMTT never warns about an incorrect pboPrefix. I think that would be a great feature to implement, if it's not too much hassle.

Yeah the ASC module is definitely not liking that pbo prefix.

You could use --expsqfc to use HEMTT's SQFC compiler instead of ASC, it should work fine but still needs further evaluation.

--expsqfc seems to indeed compile it even with the bad pboPrefix, but the PBO will be bloated with .sqfast files, even with a fixed pboPrefix

rekterakathom avatar Jun 17 '24 21:06 rekterakathom

ASC compilation seems to work correctly only when the pboprefix of an addon ends with addons\addonname. So for example, if the addon files are in directory Overthrow/addons/overthrow_main, the pboprefix must end with addons\overthrow_main.

HEMTT is possibly copying the whole addons directory somewhere to be processed by ASC but then expecting to find it later in a directory ending with pboprefix.

Tuupertunut avatar Jun 17 '24 23:06 Tuupertunut

Ah yeah --expsqfc still has debug files for testing, they'll be gone in the next version.

There's nothing inherently wrong about your pboprefix, just yeah the ASC module in HEMTT is having a problem with it. HEMTT doesn't warn or anything because it is supposed to be fine as is, all the other modules are working with it, it should match the hemtt project file though

BrettMayson avatar Jun 18 '24 05:06 BrettMayson

it should match the hemtt project file though

The project.toml has a prefix for the whole mod, but pboprefix is different per addon. In which way should they match?

Tuupertunut avatar Jun 20 '24 12:06 Tuupertunut

Closing since HEMTT no longer includes ASC

BrettMayson avatar Nov 10 '24 08:11 BrettMayson