134 |
program text). HDR's standard fields are already correct, except that |
program text). HDR's standard fields are already correct, except that |
135 |
this adjustment to the `a_text' field has not yet been made; |
this adjustment to the `a_text' field has not yet been made; |
136 |
thus, the amount of offset can depend on the data in the file. |
thus, the amount of offset can depend on the data in the file. |
137 |
|
|
138 |
* A_TEXT_SEEK(HDR) |
* A_TEXT_SEEK(HDR) |
139 |
|
|
140 |
If defined, this macro specifies the number of bytes to seek into the |
If defined, this macro specifies the number of bytes to seek into the |
399 |
{ |
{ |
400 |
close (new); |
close (new); |
401 |
/* unlink (new_name); /* Failed, unlink new a.out */ |
/* unlink (new_name); /* Failed, unlink new a.out */ |
402 |
return -1; |
return -1; |
403 |
} |
} |
404 |
|
|
405 |
close (new); |
close (new); |
992 |
char c; |
char c; |
993 |
int mcount_address, mcount_offset, count; |
int mcount_address, mcount_offset, count; |
994 |
extern char *_execname; |
extern char *_execname; |
995 |
|
|
996 |
|
|
997 |
/* The use of _execname is incompatible with RISCiX 1.1 */ |
/* The use of _execname is incompatible with RISCiX 1.1 */ |
998 |
sprintf (command, "nm %s | fgrep mcount", _execname); |
sprintf (command, "nm %s | fgrep mcount", _execname); |
1012 |
{ |
{ |
1013 |
sprintf (errbuf, "Failed to execute the command '%s'\n", command); |
sprintf (errbuf, "Failed to execute the command '%s'\n", command); |
1014 |
PERROR (errbuf); |
PERROR (errbuf); |
1015 |
} |
} |
1016 |
|
|
1017 |
sscanf(address_text, "%x", &mcount_address); |
sscanf(address_text, "%x", &mcount_address); |
1018 |
ptr = (char *) unexec_text_start; |
ptr = (char *) unexec_text_start; |