From: | Aaron Optimizer Digulla |
Date: | 4 Aug 2000 at 13:29:26 |
Subject: | AMIOPEN: ixemulng library, tools and global variables |
(Already posted a week ago but got no answer)
Oh well, I just tried to make ixemulng work and I ran into a couple
of problems which are not mentioned in the SDK docs:
- How do I access a global variable of the thread ? After a bit of
browsing and disassembling of /lib/perror.00, I came up with this
code to set errno from within a function in ixemulng:
#define seterrno(x) \
Is this code correct ? What other variables can be accessed via
gp ? Or is there a better interface to access gp from C ?
- Then, I found out that we're going to need own globals, too.
How can a tool add global variables to the threads which use the
tool ? I suggest to expand the mathtest.c example :-)
- If I want to test the tool without installing it, what must I
use in the cmdline for vpcc ? Currently, I'm using
vpcc {-Dprefix=}$sys.cwd -T -o $sys.cwd/exec exec.c
but how do I adjust the path in the header files (... __attribute__
(("qcall ixemulng/exec"));) ? I could use the define prefix in them
but when I install those files, everyone who includes them would
have to define it as well :-(
Are there any plans to pride us with a tool-search-path in the
near future ? These absolute paths in the tools suck :-(
- Why doesn't this work:
echo vpcc {-Dprefix=}$sys.cwd -T -o ${sys.cwd}/file file.c
When I try this, I get "shell: echo: try 'help echo' for documentation".
Not very useful :-(
- rm -f should never return with an error. Right now, I cannot
use "rm -f *.o" if there is no file matching .o (or better: I have
to write "-rm -f *.o" in the makefile so it doesn't abort). This is
a small incompatibility to unix which should be simple to fix (never
return with an error because of file not found when -f is given).
Subscribe/Unsubscribe: open-request@amiga.com
Amiga FAQ: http://www.amiga.com/faq.html