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

generate glob_asm.h #166

Closed
stsp opened this issue Feb 22, 2021 · 2 comments
Closed

generate glob_asm.h #166

stsp opened this issue Feb 22, 2021 · 2 comments

Comments

@stsp
Copy link
Member

stsp commented Feb 22, 2021

glob_asm.h have this comment:
/* grep "ASM " globals.h | grep "extern" | grep ";" | sed 's/extern \(.\+\) ASM \(.\+\);/__ASM(\1, \2) SEMIC/' */
So its pretty clear how it was generated initially.
But with time it gets more and more hand-editing
when new thunk types are added.
It would be good to investigate the possibility
of generating it during build.

@stsp stsp added the enhancement New feature or request label Feb 22, 2021
stsp added a commit that referenced this issue Feb 23, 2021
This allowed to adjust glob_asm.h closer to the freedos.
Also allowed to remove some __ASMADDR() hacks.
@stsp
Copy link
Member Author

stsp commented Feb 23, 2021

OK, this appears basically impossible.
One needs to get rid of glob_asmdefs.h first,
because it defines all symbols from glob_asm.h
as macros while we want to define them as symbols.
While it would be cool to get rid of one,
this will mean squashing of SymWrp into
AsmXXX classes.
One can even have some progress with
such squashing, until he hits the fact that
operator dot doesn't trigger the conversion
operator, cannot be overridden and all that.
So getting rid of glob_asmdefs.h and
consequently of glob_asm.h is currently
absolutely impossible.
Maybe with C++-23 there will be a hole
in that wall...

@stsp
Copy link
Member Author

stsp commented Feb 23, 2021

Its possible to add a new header that
will not be included in fdpp, but only in
freedos. Which means not globals.h,
as it IS included in fdpp.
So it won't be any closer to freedos
sources, no matter how hard to try.

@stsp stsp closed this as completed Feb 23, 2021
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

1 participant