/* */
/* */
/* */
-/* (C) 1998-2011, Ullrich von Bassewitz */
+/* (C) 1998-2012, Ullrich von Bassewitz */
/* Roemerstrasse 52 */
/* D-70794 Filderstadt */
/* EMail: uz@cc65.org */
/* ar65 */
#include "error.h"
+#include "library.h"
#include "objdata.h"
#include "exports.h"
while (1) {
if (strcmp (L->Name, Name) == 0) {
/* Duplicate entry */
- Warning ("External symbol `%s' in module `%s' is duplicated in "
- "module `%s'",
- Name, L->Name, Module->Name);
+ Warning ("External symbol `%s' in module `%s', library `%s' "
+ "is duplicated in module `%s'",
+ Name, L->Name, LibName, Module->Name);
}
if (L->Next == 0) {
break;
/* */
/* */
/* */
-/* (C) 1998-2011, Ullrich von Bassewitz */
+/* (C) 1998-2012, Ullrich von Bassewitz */
/* Roemerstrasse 52 */
/* D-70794 Filderstadt */
/* EMail: uz@cc65.org */
/*****************************************************************************/
+
+/* Name of the library file */
+const char* LibName = 0;
/* File descriptor for the library file */
FILE* NewLib = 0;
static FILE* Lib = 0;
-static const char* LibName = 0;
/* The library header */
-static LibHeader Header = {
+static LibHeader Header = {
LIB_MAGIC,
LIB_VERSION,
0,
}
Header.Flags = Read16 (Lib);
Header.IndexOffs = Read32 (Lib);
-}
+}
}
if (NewLib && fclose (NewLib) != 0) {
Error ("Problem closing temporary library file: %s", strerror (errno));
- }
+ }
}
/* */
/* */
/* */
-/* (C) 1998 Ullrich von Bassewitz */
-/* Wacholderweg 14 */
-/* D-70597 Stuttgart */
-/* EMail: uz@musoftware.de */
+/* (C) 1998-2012, Ullrich von Bassewitz */
+/* Roemerstrasse 52 */
+/* D-70794 Filderstadt */
+/* EMail: uz@cc65.org */
/* */
/* */
/* This software is provided 'as-is', without any expressed or implied */
+/* Name of the library file */
+extern const char* LibName;
+
/* File descriptor for the new library file */
extern FILE* NewLib;
void LibCopyFrom (unsigned long Pos, unsigned long Bytes, FILE* F);
/* Copy data from the library file into another file */
-void LibClose (void);
+void LibClose (void);
/* Write remaining data, close both files and copy the temp file to the old
* filename
*/
/* */
/* */
/* */
-/* (C) 1998-2011, Ullrich von Bassewitz */
+/* (C) 1998-2012, Ullrich von Bassewitz */
/* Roemerstrasse 52 */
/* D-70794 Filderstadt */
/* EMail: uz@cc65.org */
-/* */
-/* */
+/* */
+/* */
/* This software is provided 'as-is', without any expressed or implied */
/* warranty. In no event will the authors be held liable for any damages */
/* arising from the use of this software. */
case 'V':
fprintf (stderr,
- "ar65 V%s - (C) Copyright 1998-2011 Ullrich von Bassewitz\n",
+ "ar65 V%s - (C) Copyright 1998-2012 Ullrich von Bassewitz\n",
GetVersionAsString ());
break;
/* */
/* */
/* */
-/* (C) 1998-2011, Ullrich von Bassewitz */
+/* (C) 1998-2012, Ullrich von Bassewitz */
/* Roemerstrasse 52 */
/* D-70794 Filderstadt */
/* EMail: uz@cc65.org */
/* ar65 */
#include "error.h"
+#include "library.h"
#include "objdata.h"
void ClearObjData (ObjData* O)
/* Remove any data stored in O */
{
- unsigned I;
+ unsigned I;
xfree (O->Name);
O->Name = 0;
for (I = 0; I < CollCount (&O->Strings); ++I) {
}
/* Not found! */
- Warning ("Module `%s' not found in library", Module);
+ Warning ("Module `%s' not found in library `%s'", Module, LibName);
}
* and the external one.
*/
if (difftime ((time_t)O->MTime, StatBuf.st_mtime) > 0.0) {
- Warning ("Replacing module `%s' by older version", O->Name);
+ Warning ("Replacing module `%s' by older version in library `%s'",
+ O->Name, LibName);
}
/* Free data */
/* Bail out if the module does not exist */
if (O == 0) {
- Error ("Module `%s' not found in library", Module);
+ Error ("Module `%s' not found in library `%s'", Module, LibName);
}
/* Open the output file */