Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FEATURE] .INC to include relative directory to the source file being assembled. #651

Open
cyraid opened this issue Jan 24, 2025 · 9 comments

Comments

@cyraid
Copy link

cyraid commented Jan 24, 2025

Man, I'm keeping you busy! Sheesh eh @vhelin ? Lower priority, but, I've found that I'm including a file, but that file includes another file (that is relative to it, in the same directory). It wouldn't know what -I <dir> are being included, and doesn't wanna include the wrong common.inc for example. Could you make include a relative file with .INC? Maybe .INC RELATIVE "this_is_in_the_same_dir_as_this_file.inc"? (to not break backwards compatibility) :)

@vhelin
Copy link
Owner

vhelin commented Jan 24, 2025

Yeah, you solved my issue how to spend my free time lately. :)

But sounds good, I'll come back to this after the two previous issues have been solved...

@vhelin
Copy link
Owner

vhelin commented Jan 30, 2025

I accidentally added RELATIVE/LATESTDIR to .INCLUDE, then found a way to add RELATIVEDIR which is what you are asking for. I hope these will fix this issue :)

Image

@vhelin
Copy link
Owner

vhelin commented Jan 30, 2025

Tomorrow I'll look into adding these to .INCBIN if it makes sense. Too tired right now to figure out if it makes any sense :)

@cyraid
Copy link
Author

cyraid commented Jan 30, 2025

Wow, works great! You've been nailing all these feature upgrades like it's a hot knife through butter! I've been working with your assembler almost every day, for many hours. So I'm using it ALL the time haha .. Last night I worked so much till I was feeling ill! (I know, not good, but I need this demo created by the end of the month).

I'm creating an SNES Music Engine (so using both 65816 and SPC700) that loads a file made from Furnace Tracker that my importer creates. It is for a company that they're creating a NES/SNES Game Editor. It's been quite the wild ride as SNES has quite a lot of quirks that I've been discovering. Thank you so much for making my job easier and easier with all these upgrades. :)

The other feature I requested will help reduce a lot of code and complexity unless I have access to a 'current label' builtin function? Like get("lastlabel") or get("label.last") (so that I can use that to combine a new label) and the current ORG, get("org") ? But the .CONTENT Macro would be a lot more elegant. lol

@vhelin
Copy link
Owner

vhelin commented Jan 30, 2025

I love your energy levels and enthusiasm! :) I'm just happy to make WLA DX better for all you users.

That SNES Music Engine sounds great, I'm a big fan of SNES music!

The CONTENT feature for a .MACRO requires some planning, I don't want to do that tired and quickly as it'll be probably quite a hack or then requires a lot from the parser, need to think about it. get("label.latest") would be quite easy to implement, perhaps get("org") as well, perhaps I'll try to implement them all...

@vhelin
Copy link
Owner

vhelin commented Feb 13, 2025

Used a sleep analyzer for the 1st time yesterday night, in the morning it said I have severe sleep apnea, which explains why I'm so tired these days and have memory problems. Gotta lose weight. :) And go out more often for walks...

Anyway, I'll slowly work on this issue, next I'll see if I can add "get("org"), and then try to do that .CONTENT thing, but don't expect them to appear quickly, need to rest more...

@cyraid
Copy link
Author

cyraid commented Feb 13, 2025

@vhelin Hi friend! Nice to hear from you. I don't seem to sleep well either! Maybe I should get my sleep checked out, but I do need to lose weight too, lol ..

Your sleep is more important to me than speedy updates. Take your time, I have workarounds till then! The get("org") and get("label.latest") would be ample good for now.

Take care my friend, okay?

@vhelin
Copy link
Owner

vhelin commented Feb 28, 2025

Please let me know if there's an issue with org() or orga()!

I'll be laid off next Monday, probably for a while, until the slave drivers can find me a new project or I can find a better job. I'll hopefully have some free time before going to work again so I can try to solve my sleep apnea issues etc., and have more time and energy to spend on WLA DX among other nice things in life. :)

@cyraid
Copy link
Author

cyraid commented Feb 28, 2025

Hi @vhelin ! Nice to hear from you. A break does sound nice. :) You definitely deserve it.

I haven't tried org() yet! I didn't know you snuck that in, you silly guy lol

Most important is your health and for you to keep getting better and your sleep fixed up! I got hit with some bad infection problems myself that got me bedridden for days in a row.

I'm gonna try to pursuade the company to use your assembler and switch from asm16. Would there be any way to make it compatible just switching from that? Would you know?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants