* bug 4403 fixed - isinf was defined (when not provided by the system) with a return
+* bug 4407 fixed - help file scilab_xx_XX_help.jar have another scilab_xx_XX_help.jar embedded
+ and not valid.
+
* bug 4433 fixed - problem using optim. On some examples, the optim function makes scilab hangs.
* bug 4461 fixed - redefines prompt not displayed in a diary.
/**
* Get the list of the files in a directory
* @param directory the directory where files have to be searched
- * @return teh list of the files found
+ * @return the list of the files found
*/
- private static ArrayList<File> buildFileList(File directory) {
+ private static ArrayList<File> buildFileList(File directory, String language) {
+ String baseNameJar = Helpers.getBaseName(language) + ".jar";
ArrayList<File> listFile = new ArrayList<File>();
-
+
File [] files = directory.listFiles();
for (int i = 0; i < files.length; i++) {
-
if (files[i].isDirectory()) {
- listFile.addAll(buildFileList(files[i]));
+ listFile.addAll(buildFileList(files[i], language));
} else {
+ /* bug 4407 */
+ /* we do not add scilab_xx_XX_help.jar file to the list */
+ if (files[i].compareTo(new File(baseNameJar)) != 0) {
listFile.add(files[i]);
+ }
}
}
-
return listFile;
}
final int compressionLevel = 5;
/* Stored into SCI/modules/helptools/jar */
String fileName = outputDirectory + "/" + baseName + ".jar";
+
+ /* bug 4407 */
+ /* we do list of files before to create scilab_xx_XX_help.jar */
+ ArrayList<File> fileList = BuildJavaHelp.buildFileList(new File(outputDirectory), language);
try {
}
jarFile.setLevel(compressionLevel);
- ArrayList<File> fileList = BuildJavaHelp.buildFileList(new File(outputDirectory));
+
File []allFiles = fileList.toArray(new File [fileList.size()]);
for (int i = 0; i < allFiles.length; i++) {
try {
--- /dev/null
+// =============================================================================
+// Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
+// Copyright (C) 2009 - DIGITEO - Allan CORNET
+//
+// This file is distributed under the same license as the Scilab package.
+// =============================================================================
+
+// <-- INTERACTIVE TEST -->
+
+// <-- Non-regression test for bug 4407 -->
+//
+// <-- Bugzilla URL -->
+// http://bugzilla.scilab.org/show_bug.cgi?id=4407
+//
+// <-- Short Description -->
+// help file scilab_xx_XX_help.jar have another scilab_xx_XX_help.jar embedded
+
+
+// build java help
+
+xmltojar()
+
+// check that scilab_xx_XX_help.jar do not have another scilab_xx_XX_help.jar embedded
\ No newline at end of file