Jan Bredenbeek wrote: >> Jan Bredenbeek wrote: >> > QMAC can do conditional assembly outside macros using the GENIF and >> ENDGEN >> > keywords. Check the updates textfile for details. >> >> Ah, I only checked the manual, how foolish of me ;-) Great, thanks, I >> will check that out. > > I discovered it only a week or two ago ;-).
I actually knew this many many years ago, the DISA source code for example makes use of it. But I have forgotten sooo many things and when I checked the manual it explicitely said it couldn't do it. So I thought I was mistaken ;) I knew EasyPtr makes heavy use of conditional assembly, too, but that uses a different assembler, I even forgot which but after an extensive search it seems to be the C1 assembler. On the plus side, while looking for the assember I found the source for the QTYP spell device, I didn't even know I had those. > I've always found this a major omission in the otherwise great GST > assembler. > It's a bit awkward to use though as QMAC doesn't let you define symbols via > the command line. I had to create two _ASM files, one for the ROM version > and one for the RAM version with a variable set to 1 or 0 (using EQU or > SETNUM) and then INCLUDE the target _ASM file from there. Ah, clever. Bit akward but good solution, that also solves the problem of re-assembling the file when switching the version. This way there are two files to begin with and in QMake I can just add a dependency on the shared file so everything get gets reassembled if that changes. Thanks! Marcel _______________________________________________ QL-Users Mailing List