• R/O
  • SSH
  • HTTPS

oricsdk: Commit


Commit MetaInfo

Revision1549 (tree)
Time2020-12-24 03:29:07
Authordbug

Log Message

Link65 0.67
- Error messages now indicate that they came from the Linker, because a generic "Error, can't load xxxx" was not very informative

Change Summary

Incremental Difference

--- public/pc/tools/osdk/main/Osdk/_final_/documentation/doc_linker.htm (revision 1548)
+++ public/pc/tools/osdk/main/Osdk/_final_/documentation/doc_linker.htm (revision 1549)
@@ -73,6 +73,9 @@
7373 <p>Here is the list of all releases with a short description of things that changed:
7474 </p>
7575
76+<p id=dateentry>Version 0.67</p>
77+- Error messages now indicate that they came from the Linker, because a generic "Error, can't load xxxx" was not very informative
78+
7679 <p id=dateentry>Version 0.66</p>
7780 - The new macro file generate lines that contain multiple instructions, the linker stopped at the first encountered instruction, this new version correctly parses that
7881
--- public/pc/tools/osdk/main/header/includes/infos.h (revision 1548)
+++ public/pc/tools/osdk/main/header/includes/infos.h (revision 1549)
@@ -5,8 +5,11 @@
55 0.2 - 2014/05/11
66 - The address can now be specified with either $ or 0x as an hexadecimal prefix
77
8+1.0 - 2020/12/12
9+- Added the flag -b to specify if the converted file should expose 00 (BASIC) or 80 (Binary) in the header
10+
811 */
912
10-#define TOOL_VERSION_MAJOR 0
11-#define TOOL_VERSION_MINOR 2
13+#define TOOL_VERSION_MAJOR 1
14+#define TOOL_VERSION_MINOR 0
1215
--- public/pc/tools/osdk/main/link65/includes/infos.h (revision 1548)
+++ public/pc/tools/osdk/main/link65/includes/infos.h (revision 1549)
@@ -42,9 +42,12 @@
4242 0.66 - 2019/04/06
4343 - The new macro file generate lines that contain multiple instructions, the linker stopped at the first encountered instruction, this new version correctly parses that
4444
45+0.67 - 2020/12/18
46+- Error messages now indicate that they came from the Linker, because a generic "Error, can't load xxxx" was not very informative
47+
4548 */
4649
4750
4851
4952 #define TOOL_VERSION_MAJOR 0
50-#define TOOL_VERSION_MINOR 66
53+#define TOOL_VERSION_MINOR 67
--- public/pc/tools/osdk/main/link65/sources/Link65.cpp (revision 1548)
+++ public/pc/tools/osdk/main/link65/sources/Link65.cpp (revision 1549)
@@ -551,35 +551,12 @@
551551
552552
553553
554-void outall()
555-{
556-#ifndef _POSIX_VERSION
557- flushall();
558-#endif
559- fcloseall();
560-}
561-
562-//
563-// Simple function that prints error message/calls outall.
564-// Simplifies the look of the main program
565-//
566-void linkerror(const char *msg)
567-{
568- printf(msg);
569- outall();
570-}
571-
572-
573-
574-
575554 bool ParseFile(const std::string& filename)
576555 {
577556 std::vector<std::string> cTextData;
578557 if (!LoadText(filename.c_str(),cTextData))
579558 {
580- printf("\nCannot open %s \n",filename.c_str());
581- outall();
582- exit(1);
559+ ShowError("\nCannot open %s \n",filename.c_str());
583560 }
584561
585562 if (gFlagVerbose)
@@ -695,8 +672,7 @@
695672 std::vector<std::string> cTextData;
696673 if (!LoadText(ndxstr.c_str(),cTextData))
697674 {
698- printf("Cannot open Index file : %s \n",ndxstr.c_str());
699- exit(1);
675+ ShowError("Cannot open Index file : %s \n",ndxstr.c_str());
700676 }
701677
702678 if (gFlagVerbose)
@@ -727,9 +703,7 @@
727703 {
728704 if (cLabelEntry.file_name==gLibraryReferencesList[i].file_name)
729705 {
730- printf("Duplicate file %s in lib index\n",cLabelEntry.file_name.c_str());
731- outall();
732- exit(1);
706+ ShowError("Duplicate file %s in lib index\n",cLabelEntry.file_name.c_str());
733707 }
734708 }
735709 }
@@ -738,8 +712,7 @@
738712 // Found a label. Check if already used, if not put it in table
739713 if (cLabelEntry.file_name.size()<2)
740714 {
741- linkerror("Error with file line indicator\n");
742- exit(1);
715+ ShowError("Error with file line indicator\n");
743716 }
744717
745718 cLabelEntry.label_name=cCurrentLine;
@@ -749,9 +722,7 @@
749722 {
750723 if (cLabelEntry.label_name==gLibraryReferencesList[i].label_name)
751724 {
752- printf("Duplicate label %s in lib index file\n",cLabelEntry.label_name.c_str());
753- outall();
754- exit(1);
725+ ShowError("Duplicate label %s in lib index file\n",cLabelEntry.label_name.c_str());
755726 }
756727 }
757728
@@ -1050,8 +1021,7 @@
10501021 printf("%s\n",cLabelName.c_str());
10511022 ++cIt;
10521023 }
1053- outall();
1054- return(0);
1024+ return 0;
10551025 }
10561026 else
10571027 {
@@ -1070,8 +1040,7 @@
10701040
10711041 if (state == 1)
10721042 {
1073- linkerror("Errors durink link.\n");
1074- exit(1);
1043+ ShowError("Errors durink link.\n");
10751044 }
10761045
10771046
@@ -1079,8 +1048,7 @@
10791048 FILE *gofile=fopen(output_file_name.c_str(),"wb");
10801049 if (!gofile)
10811050 {
1082- linkerror("Cannot open output file for writing\n");
1083- exit(1);
1051+ ShowError("Cannot open output file for writing\n");
10841052 }
10851053
10861054 //
@@ -1121,9 +1089,7 @@
11211089 std::vector<std::string> cTextData;
11221090 if (!LoadText(gInputFileList[k].m_cFileName.c_str(),cTextData))
11231091 {
1124- printf("\nCannot open %s \n",gInputFileList[k].m_cFileName.c_str());
1125- outall();
1126- exit(1);
1092+ ShowError("\nCannot open %s \n",gInputFileList[k].m_cFileName.c_str());
11271093 }
11281094
11291095 std::vector<std::string>::const_iterator cItText=cTextData.begin();
@@ -1143,9 +1109,7 @@
11431109 ++cItText;
11441110 }
11451111 }
1146-
1147- outall();
1148- return(0);
1112+ return 0;
11491113 }
11501114
11511115
Show on old repository browser