mirror of
https://github.com/ctm/executor.git
synced 2024-06-05 23:29:33 +00:00
50 lines
1.1 KiB
Cheetah
50 lines
1.1 KiB
Cheetah
#include "rsys/everything.h"
|
|
|
|
/* for `EXIT_SUCCESS' */
|
|
#include <stdlib.h>
|
|
|
|
static const char *
|
|
map_type_name (const char *in_type)
|
|
{
|
|
static const struct
|
|
{
|
|
char *in_type, *out_type;
|
|
}
|
|
mapping_table[] =
|
|
{
|
|
{ "Str15", "StringPtr" },
|
|
{ "Str31", "StringPtr" },
|
|
{ "Str32", "StringPtr" },
|
|
{ "Str63", "StringPtr" },
|
|
{ "Str255", "StringPtr" },
|
|
{ "Pattern", "Byte *" },
|
|
{ "Bits16", "INTEGER *" },
|
|
};
|
|
int i;
|
|
|
|
for (i = 0; i < NELEM (mapping_table); i ++)
|
|
if (! strcmp (mapping_table[i].in_type, in_type))
|
|
return mapping_table[i].out_type;
|
|
|
|
return in_type;
|
|
}
|
|
|
|
#include "p_q_defines.h"
|
|
|
|
int
|
|
main (int argc, char *argv[])
|
|
{
|
|
printf ("#if !defined(_STUBIFY_H_)\n"
|
|
"#define _STUBIFY_H_\n"
|
|
"\n"
|
|
"#include \"rsys/ctopflags.h\"\n"
|
|
"#include \"rsys/ptocflags.h\"\n"
|
|
"#include \"rsys/trapglue.h\"\n"
|
|
"\n"
|
|
"extern long CToPascalCall (void *, unsigned long, ...);\n"
|
|
"extern toolstuff_t toolstuff[NTOOLENTRIES];\n\n");
|
|
@genstubify_body@
|
|
printf ("#endif /* !defined(_STUBIFY_H_) */\n");
|
|
return EXIT_SUCCESS;
|
|
}
|