Fixed a bug: If all output data was discarded (by using file = "" in the

linker config), CheckExports was never called, which in turn meant that
the list of all exports was never built. This caused a crash later when
the linker tried to generate a map file. The solution is to separate the
creation of the exports list and the check for unresolved imports.


git-svn-id: svn://svn.cc65.org/cc65/trunk@3360 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
cuz
2005-01-09 13:16:51 +00:00
parent a456e503e4
commit 9cd0b7705c
5 changed files with 29 additions and 13 deletions

View File

@@ -6,7 +6,7 @@
/* */
/* */
/* */
/* (C) 1999-2003 Ullrich von Bassewitz */
/* (C) 1999-2005 Ullrich von Bassewitz */
/* R<>merstra<72>e 52 */
/* D-70794 Filderstadt */
/* EMail: uz@cc65.org */
@@ -1356,7 +1356,7 @@ void O65WriteTarget (O65Desc* D, File* F)
* if we get an unresolved symbol.
*/
D->Undef = 0; /* Reset the counter */
CheckExports (O65Unresolved, D);
CheckUnresolvedImports (O65Unresolved, D);
if (D->Undef > 0) {
/* We had unresolved symbols, cannot create output file */
Error ("%u unresolved external(s) found - cannot create output file", D->Undef);