提交 a2e4f74c authored 作者: Thomas Mueller's avatar Thomas Mueller

--no commit message

--no commit message
上级 bee262fa
......@@ -31,7 +31,7 @@ call build -quiet spellcheck javadocImpl jarClient
echo %time:~0,8% JDK 1.4
call java14 >nul 2>nul
call build -quiet compile
call build -quiet clean compile
call build -quiet installer mavenDeployCentral
rem call build -quiet compile benchmark
......
......@@ -116,7 +116,7 @@ Section "All"
SetOutPath "$INSTDIR\src"
File /r /x CVS /x .cvsignore /x .svn ..\..\src\*.*
SetOutPath "$INSTDIR\bin"
File /x CVS /x .cvsignore ..\..\bin\h2.*
File /x CVS /x .cvsignore ..\..\bin\h2*
SetOutPath "$INSTDIR\docs"
File /r /x CVS /x .cvsignore ..\..\docs\*.*
SetOutPath "$INSTDIR\service"
......@@ -139,7 +139,7 @@ Section "All"
!insertmacro MUI_STARTMENU_WRITE_BEGIN Application
SetOutPath "$INSTDIR\bin"
CreateDirectory "$SMPROGRAMS\$STARTMENU_FOLDER"
CreateShortCut "$SMPROGRAMS\$STARTMENU_FOLDER\H2 Console.lnk" "javaw" "-cp $\"$INSTDIR\bin\h2.jar;%H2DRIVERS%;%CLASSPATH%$\" org.h2.tools.Console" "$INSTDIR\src\installer\favicon.ico" 0 SW_SHOWMINIMIZED "" "Start the Console"
CreateShortCut "$SMPROGRAMS\$STARTMENU_FOLDER\H2 Console.lnk" "cmd" "/c h2w.bat" "$INSTDIR\src\installer\favicon.ico" 0 SW_SHOWMINIMIZED "" "Start the Console"
CreateShortCut "$SMPROGRAMS\$STARTMENU_FOLDER\H2 Console (Command Line).lnk" "cmd" "/c h2.bat" "$INSTDIR\src\installer\favicon.ico" 0 SW_SHOWMINIMIZED "" "Start the Console from command line (using h2.bat)"
CreateShortCut "$SMPROGRAMS\$STARTMENU_FOLDER\H2 Documentation.lnk" "$INSTDIR\docs\index.html"
; CreateShortCut "$SMPROGRAMS\$STARTMENU_FOLDER\Uninstall.lnk" "$INSTDIR\Uninstall.exe"
......
@start javaw -cp "h2.jar;%H2DRIVERS%;%CLASSPATH%" org.h2.tools.Console %*
@if errorlevel 1 pause
\ No newline at end of file
......@@ -126,17 +126,18 @@ public class Build extends BuildBase {
files.addAll(getFiles("src/tools"));
javac(new String[] { "-d", "temp", "-sourcepath", "src/test" + File.pathSeparator + "src/tools",
"-classpath", classpath }, files);
files = getFiles("src/installer").keep("*.bat");
files.addAll(getFiles("src/installer").keep("*.sh"));
copy("bin", files, "src/installer");
files = getFiles("src/test").
exclude("*.java").
exclude("*/package.html");
copy("temp", files, "src/test");
}
}
private void filter(String source, String target, String old, String replacement) {
String text = new String(readFile(new File(source)));
text = replaceAll(text, old, replacement);
writeFile(new File(target), text.getBytes());
}
/**
* Create the documentation from the documentation sources. API Javadocs are
......@@ -191,6 +192,7 @@ public class Build extends BuildBase {
* Create the h2.zip file and the Windows installer.
*/
public void installer() {
delete(getFiles("bin").keep("*.jar"));
jar();
docs();
exec("soffice", new String[]{"-invisible", "macro:///Standard.Module1.H2Pdf"});
......@@ -225,6 +227,9 @@ public class Build extends BuildBase {
exclude("*.sh").
exclude("*.txt");
jar("bin/h2" + getJarSuffix(), files, "temp");
filter("src/installer/h2.sh", "bin/h2.sh", "h2.jar", "h2" + getJarSuffix());
filter("src/installer/h2.bat", "bin/h2.bat", "h2.jar", "h2" + getJarSuffix());
filter("src/installer/h2w.bat", "bin/h2w.bat", "h2.jar", "h2" + getJarSuffix());
}
/**
......
......@@ -725,6 +725,18 @@ public class BuildBase {
delete(new File(dir));
}
/**
* Delete all files in the list.
*
* @param files the name of the files to delete
*/
protected void delete(FileList files) {
for (int i = 0; i < files.size(); i++) {
File f = (File) files.get(i);
delete(f);
}
}
private void delete(File file) {
if (file.exists()) {
if (file.isDirectory()) {
......
......@@ -562,4 +562,4 @@ monitoring razuna asset drag pekar devx dmitry fragments onmouseup nav
onmousedown olap valign army blitz backgammon knife abbreviate berger dhuse
strictly greg germany abbreviates frontends cleversafe payload cloneable
scripting jaks reconnected serverlist safes somewhere anzo war contacts helpful
implies looping cataloguing mapper frees
implies looping cataloguing mapper frees javaw
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论