]> git.proxmox.com Git - mirror_edk2.git/blobdiff - Tools/Source/MigrationTools/org/tianocore/migration/ModuleInfo.java
Fixed grammar in messages.
[mirror_edk2.git] / Tools / Source / MigrationTools / org / tianocore / migration / ModuleInfo.java
index e40b5f82e556d7df5164c5a38454e5e906df2318..b238551cac84ca18dc6e7af3094358c61bb515a1 100644 (file)
@@ -38,7 +38,6 @@ public class ModuleInfo {
        public String entrypoint = null;\r
        \r
        public Set<String> localmodulesources = new HashSet<String>();          //contains both .c and .h\r
        public String entrypoint = null;\r
        \r
        public Set<String> localmodulesources = new HashSet<String>();          //contains both .c and .h\r
-       public Set<String> localmoduleheaders = new HashSet<String>();\r
        public Set<String> preprocessedccodes = new HashSet<String>();\r
        \r
        public Set<String> hashfuncc = new HashSet<String>();\r
        public Set<String> preprocessedccodes = new HashSet<String>();\r
        \r
        public Set<String> hashfuncc = new HashSet<String>();\r
@@ -69,17 +68,20 @@ public class ModuleInfo {
                                if (list[i].contains(".c") || list[i].contains(".C")) {\r
                                        localmodulesources.add(list[i]);\r
                                } else if (list[i].contains(".h") || list[i].contains(".H")) {\r
                                if (list[i].contains(".c") || list[i].contains(".C")) {\r
                                        localmodulesources.add(list[i]);\r
                                } else if (list[i].contains(".h") || list[i].contains(".H")) {\r
+                                       localmodulesources.add(list[i]);        //the case that several .inf or .msa found is not concerned\r
+                               } else if (list[i].contains(".dxs")) {\r
+                                       localmodulesources.add(list[i]);\r
+                               } else if (list[i].contains(".uni")) {\r
                                        localmodulesources.add(list[i]);\r
                                        localmodulesources.add(list[i]);\r
-                                       localmoduleheaders.add(list[i]);        //the case that several .inf or .msa found is not concerned\r
                                } else if (list[i].contains(".inf")) {\r
                                } else if (list[i].contains(".inf")) {\r
-                                       if (ui.yesOrNo("Found .inf file : " + list[i] + "\nUse this file as this module's .inf ?")) {\r
+                                       if (ui.yesOrNo("Found .inf file : " + list[i] + "\nDo you want to use this file as this module's .inf?")) {\r
                                                hasInf = true;\r
                                                infname = list[i];\r
                                        } else {\r
                                                continue;\r
                                        }\r
                                } else if (list[i].contains(".msa")) {\r
                                                hasInf = true;\r
                                                infname = list[i];\r
                                        } else {\r
                                                continue;\r
                                        }\r
                                } else if (list[i].contains(".msa")) {\r
-                                       if (ui.yesOrNo("Found .msa file : " + list[i] + "\nUse this file as this module's .msa ?")) {\r
+                                       if (ui.yesOrNo("Found .msa file : " + list[i] + "\nDo you want to use this file as this module's .msa?")) {\r
                                                hasMsa = true;\r
                                                msaname = list[i];\r
                                        } else {\r
                                                hasMsa = true;\r
                                                msaname = list[i];\r
                                        } else {\r
@@ -95,7 +97,7 @@ public class ModuleInfo {
                } else if (hasMsa) {\r
                        mr.readMsa(msaname);\r
                } else {\r
                } else if (hasMsa) {\r
                        mr.readMsa(msaname);\r
                } else {\r
-                       ui.println("No Inf Nor Msa Found");\r
+                       ui.println("No INF nor MSA file found!");\r
                }\r
                \r
                CommentOutNonLocalHFile();\r
                }\r
                \r
                CommentOutNonLocalHFile();\r
@@ -104,7 +106,7 @@ public class ModuleInfo {
                new SourceFileReplacer(modulepath, this, db, ui).flush();       // some adding library actions are taken here,so it must be put before "MsaWriter"\r
                \r
                // show result\r
                new SourceFileReplacer(modulepath, this, db, ui).flush();       // some adding library actions are taken here,so it must be put before "MsaWriter"\r
                \r
                // show result\r
-               if (ui.yesOrNo("Parse Module Information Complete . See details ?")) {\r
+               if (ui.yesOrNo("Parse of the Module Information has completed. View details?")) {\r
                        ui.println("\nModule Information : ");\r
                        ui.println("Entrypoint : " + entrypoint);\r
                        show(protocol, "Protocol : ");\r
                        ui.println("\nModule Information : ");\r
                        ui.println("Entrypoint : " + entrypoint);\r
                        show(protocol, "Protocol : ");\r
@@ -127,8 +129,8 @@ public class ModuleInfo {
                \r
                ui.println("Errors Left : " + db.error);\r
                ui.println("Complete!");\r
                \r
                ui.println("Errors Left : " + db.error);\r
                ui.println("Complete!");\r
-               ui.println("Your R9 module is placed at " + modulepath + File.separator + "result");\r
-               ui.println("Your logfile is placed at " + modulepath);\r
+               ui.println("Your R9 module was placed here: " + modulepath + File.separator + "result");\r
+               ui.println("Your logfile was placed here: " + modulepath);\r
        }\r
        \r
        private void show(Set<String> hash, String show) {\r
        }\r
        \r
        private void show(Set<String> hash, String show) {\r
@@ -157,7 +159,7 @@ public class ModuleInfo {
                        while ((line = rd.readLine()) != null) {\r
                                if (line.contains("#include")) {\r
                                        mtcinclude = ptninclude.matcher(line);\r
                        while ((line = rd.readLine()) != null) {\r
                                if (line.contains("#include")) {\r
                                        mtcinclude = ptninclude.matcher(line);\r
-                                       if (mtcinclude.find() && localmoduleheaders.contains(mtcinclude.group(1))) {\r
+                                       if (mtcinclude.find() && localmodulesources.contains(mtcinclude.group(1))) {\r
                                        } else {\r
                                                line = migrationcomment + line;\r
                                        }\r
                                        } else {\r
                                                line = migrationcomment + line;\r
                                        }\r
@@ -289,4 +291,4 @@ public class ModuleInfo {
        public static void main(String[] args) throws Exception {\r
                FirstPanel.init();\r
        }\r
        public static void main(String[] args) throws Exception {\r
                FirstPanel.init();\r
        }\r
-}
\ No newline at end of file
+}\r