tccrun: another incompatible change to the tcc_relocate API

We are now compatible with the 0.9,25 version though.  A special
value for the second (ptr) argument is used to get the simple
behavior as with the 0.9.24 version.
This commit is contained in:
grischka
2012-09-01 11:33:34 +02:00
parent 56e23984b9
commit ca38792df1
3 changed files with 15 additions and 6 deletions

View File

@ -58,7 +58,7 @@ int main(int argc, char **argv)
tcc_add_symbol(s, "add", add);
/* relocate the code */
if (tcc_relocate(s) < 0)
if (tcc_relocate(s, TCC_RELOCATE_AUTO) < 0)
return 1;
/* get entry symbol */