From: Marko Grönroos Date: Mon, 11 Jan 2010 14:16:33 +0000 (+0000) Subject: Updated build scripts to build only one platform-independent package (#3811). Updated... X-Git-Tag: 6.7.0.beta1~2082 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=59d31a7a5b96d9d7dfb6c9e56cf92c3864031b12;p=vaadin-framework.git Updated build scripts to build only one platform-independent package (#3811). Updated sample widgetset build script for GWT 2.0 (#3972). Also removed obsolete Mac DMG target. svn changeset:10679/svn branch:6.3 --- diff --git a/WebContent/VAADIN/readme.txt b/WebContent/VAADIN/readme.txt index 926bc01a9e..672862a35c 100644 --- a/WebContent/VAADIN/readme.txt +++ b/WebContent/VAADIN/readme.txt @@ -29,8 +29,7 @@ Vaadin Development When developing the Vaadin Library itself, change to "build" directory and run "ant widgetsets" to compile all widgetsets or "ant widgetset-default", "ant-widgetset-reserver", or "ant widgetset-colorpicker" to compile individual -widgetsets. You must have GWT installed under build/gwt, under the proper -platform directory. +widgetsets. You must have GWT installed under build/gwt. See http://dev.vaadin.com/wiki/DevDocs/StartingDevelopment for instructions for installing GWT and compiling widgetsets for Vaadin development. diff --git a/build/bin/package-diff.py b/build/bin/package-diff.py index de479ca8b4..1f898e62bc 100755 --- a/build/bin/package-diff.py +++ b/build/bin/package-diff.py @@ -1,6 +1,6 @@ #!/usr/bin/python -import sys,os +import sys,os,re from sets import Set ################################################################################ @@ -45,6 +45,29 @@ def listfiles(archive): return cleanedfiles +# For Zip archives in Vaadin 6.3.0 +def listZipFiles(archive): + pin = os.popen("unzip -l -qq %s | cut -c 29- | sort" % (archive), "r") + files = map(lambda x: x.strip(), pin.readlines()) + pin.close() + + cleanedfiles = [] + for file in files: + # Remove archive file name from the file names + slashpos = file.find("/") + if slashpos != -1: + cleanedname = file[slashpos+1:] + else: + cleanedname = file + + # Purge GWT compilation files. + if cleanedname.find(".cache.html") != -1: + continue + + cleanedfiles.append(cleanedname) + + return cleanedfiles + ################################################################################ # Difference of two lists of files ################################################################################ @@ -59,9 +82,9 @@ def diffFiles(a, b): ################################################################################ # Lists files inside a Zip file (a JAR) ################################################################################ -def listZipFiles(zipfile): - # Read the zip content listing - pin = os.popen("unzip -ql %s" % zipfile, "r") +def listJarFiles(jarfile): + # Read the jar content listing + pin = os.popen("unzip -ql %s" % jarfile, "r") lines = map(lambda x: x[:-1], pin.readlines()) pin.close() @@ -77,15 +100,26 @@ def listZipFiles(zipfile): ################################################################################ # Lists files inside a Vaadin Jar inside a Tar ################################################################################ +# For Vaadin 6.2 Tar def listTarVaadinJarFiles(tarfile, vaadinversion): jarfile = "vaadin-linux-%s/WebContent/vaadin-%s.jar" % (vaadinversion, vaadinversion) extractedjar = "/tmp/vaadinjar-tmp-%d.jar" % (os.getpid()) tarcmd = "tar zOxf %s %s > %s " % (tarfile, jarfile, extractedjar) command (tarcmd) - files = listZipFiles(extractedjar) + files = listJarFiles(extractedjar) command ("rm %s" % (extractedjar)) return files +# For Vaadin 6.3 Zip +def listZipVaadinJarFiles(zipfile, vaadinversion): + jarfile = "vaadin-%s/WebContent/vaadin-%s.jar" % (vaadinversion, vaadinversion) + extractedjar = "/tmp/vaadinjar-tmp-%d.jar" % (os.getpid()) + tarcmd = "unzip -p %s %s > %s " % (zipfile, jarfile, extractedjar) + command (tarcmd) + files = listJarFiles(extractedjar) + command ("rm %s" % (extractedjar)) + return files + ################################################################################ # ################################################################################ @@ -99,6 +133,8 @@ pin.close() latestversion = latestdata[0].strip() latestpath = latestdata[1].strip() latestURL = downloadsite + "/" + latestpath + "/" + +# TODO: Remove "linux" after 6.3.0 is released. linuxfilename = "vaadin-linux-%s.tar.gz" % (latestversion) linuxpackage = latestURL + linuxfilename locallinuxpackage = "/tmp/%s" % (linuxfilename) @@ -123,8 +159,8 @@ latestfiles = listfiles(locallinuxpackage) # List files in built version. builtversion = sys.argv[1] -builtpackage = "build/result/vaadin-linux-%s.tar.gz" % (builtversion) -builtfiles = listfiles(builtpackage) +builtpackage = "build/result/vaadin-%s.zip" % (builtversion) +builtfiles = listZipFiles(builtpackage) # Report differences @@ -145,7 +181,7 @@ for item in removed: print "\n--------------------------------------------------------------------------------\nVaadin JAR differences" latestJarFiles = listTarVaadinJarFiles(locallinuxpackage, latestversion) -builtJarFiles = listTarVaadinJarFiles(builtpackage, builtversion) +builtJarFiles = listZipVaadinJarFiles(builtpackage, builtversion) # New files newfiles = diffFiles(builtJarFiles, latestJarFiles) diff --git a/build/build.xml b/build/build.xml index a6b7e65ecf..58654a1d73 100644 --- a/build/build.xml +++ b/build/build.xml @@ -9,7 +9,7 @@ When creating release use only "package-*" targets: package-all - * creates four release packages for three three platforms (below) + * creates the release package, a war, and a Liferay war package-windows * vaadin-windows-.zip @@ -30,31 +30,19 @@ - - - - - - - - - - - - - + - + - + - + @@ -77,19 +65,14 @@ - Creating package for Mac platform. - - + - @@ -142,10 +125,6 @@ - - - - @@ -179,7 +158,7 @@ - We are on ${platform} platform (${os.name} ${os.version}), using gwt version ${gwt-version}. + We are using gwt version ${gwt-version}. @@ -233,18 +212,16 @@ - - - Creating package for ${package-platform} platform. + - - - + + + - + @@ -252,82 +229,17 @@ - - - - - Creating package for ${package-platform} platform. - - - - - - - - - - - - - - - - - + - - - Creating package for ${package-platform} platform. - - - - - - - - - - - - - - - - - - - Creating package for ${package-platform} platform. - - - - - - - - - - - - - - - - - - Building WAR - - - + @@ -367,77 +279,9 @@ ##teamcity[publishArtifacts '${result-path}/${product-file}-${version.full}-liferay.zip'] - - - - - - - - - - - - - Creating Mac disk image (dmg) - - hdiutil create -format UDRW -volname ${product-file}-${version.full} -srcfolder ${result-path}/${product-file}-${package-platform}-${version.full} ${result-path}/disk-image.dmg - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Adding platform specific files for ${package-platform} + @@ -455,9 +299,6 @@ - - - @@ -468,11 +309,6 @@ - - - - - @@ -487,12 +323,11 @@ - + - + - @@ -502,18 +337,12 @@ - - - - - - @@ -542,80 +371,20 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + @@ -1023,7 +792,7 @@ - We are on ${platform} platform, using ${lib-gwt-dev}. + We are using ${lib-gwt-dev}. Widget sets output dir: ${widgetsets-output-dir} @@ -1240,7 +1009,7 @@ - + @@ -1285,14 +1054,13 @@ Installing ${output-dir}/WebContent/${lib-jar-name} to ${nightly.publish} Hopefully you have permissions for the copy operation with SSH. - - + - + @@ -1338,7 +1106,6 @@ - Version: ${version.full} @@ -1348,11 +1115,11 @@ - + - - + + @@ -1360,9 +1127,9 @@ - + - + diff --git a/build/package/build-widgetset.xml b/build/package/build-widgetset.xml index 27a371b3a3..7fd7bd073d 100644 --- a/build/package/build-widgetset.xml +++ b/build/package/build-widgetset.xml @@ -23,17 +23,14 @@ See configure target to adjust this buildfile. 1. use WebContent under your project's root directory 2. WebContent/WEB-INF/lib/vaadin-@version@.jar exists 3. WebContent/WEB-INF/src contains your project source files - 4. gwt directory contains extracted GWT distribution for your platform (windows, linux or mac) + 4. gwt directory contains extracted GWT distribution --> - - - - + @@ -86,9 +83,8 @@ See configure target to adjust this buildfile. - Configured for ${gwt-platform} platform. Requirements for classpath: - ${gwt-location}/gwt-dev-${gwt-platform}.jar + ${gwt-location}/gwt-dev.jar ${gwt-location}/gwt-user.jar ${toolkit-jar-location} ${src-location} @@ -97,7 +93,7 @@ See configure target to adjust this buildfile. - + @@ -109,7 +105,7 @@ See configure target to adjust this buildfile. - + diff --git a/build/package/eclipse-Vaadin Hosted Mode Browser-launch b/build/package/eclipse-Vaadin Hosted Mode Browser-launch index 0578393797..9f3820fad2 100644 --- a/build/package/eclipse-Vaadin Hosted Mode Browser-launch +++ b/build/package/eclipse-Vaadin Hosted Mode Browser-launch @@ -2,7 +2,7 @@ - + diff --git a/build/package/linux-readme.txt b/build/package/linux-readme.txt deleted file mode 100644 index 7ac0f10f15..0000000000 --- a/build/package/linux-readme.txt +++ /dev/null @@ -1,68 +0,0 @@ -============================================================================== -Vaadin Readme -============================================================================== - -------------- -How to Start? -------------- - -Open a shell window, change to the installation directory, and execute "sh start.sh". It -will start a web application at port 8888 on the local host and opens a web browser window -to display the start page of Vaadin Content Browser. - -The installation directory is a web application as itself and is directly importable to -Eclipse IDE by selecting "File / Import / Existing Projects into Workspace" from Eclipse -main menu. See the manual for detailed instructions. - ---------------------------------- -What's Inside the Vaadin Package? ---------------------------------- - -You should start exploring Vaadin through the provided Content Browser web -application within this package; see 'How to Start?' above. - -The WebContent directory contains the content available through the Content Browser: the -Vaadin Library, demos, documentation, and other useful information to get started -with Vaadin. - -Below is a list of most important locations and files: - -Start Vaadin -- start exploring Vaadin by double-clicking this icon - -COPYING -- license file - -WebContent/vaadin-.jar -- Vaadin Library containing Java source and compiled files - -WebContent/doc/manual.pdf -- Vaadin Reference Manual in PDF format - -WebContent/doc/manual/index.html -- Vaadin Reference Manual in HTML format - -WebContent/doc/api/index.html -- Vaadin API Documentation as JavaDoc reference - -WebContent/WEB-INF/src -- Content Browser source code, compiled into WebContent/WEB-INF/classes - -WebContent/doc/example-source -- example source code in HTML format - -WebContent/demo -- files required by the demos - -Vaadin Hosted Mode Browser.launch -Vaadin Development Server.launch -- launch configurations for Eclipse workspace - -WebContent/doc/example-source/build-widgetset.xml -- example on how to build GWT widget sets for Vaadin application - -WebContent/VAADIN -- widget sets and themes - -gwt -- Google Web Toolkit is required for building new widget sets diff --git a/build/package/mac-DS_Store b/build/package/mac-DS_Store deleted file mode 100644 index b2de4bf44f..0000000000 Binary files a/build/package/mac-DS_Store and /dev/null differ diff --git a/build/package/mac-Start IT Mill Toolkit.zip b/build/package/mac-Start IT Mill Toolkit.zip deleted file mode 100644 index 23df10e3a1..0000000000 Binary files a/build/package/mac-Start IT Mill Toolkit.zip and /dev/null differ diff --git a/build/package/mac-Start-icon_script.zip b/build/package/mac-Start-icon_script.zip deleted file mode 100644 index 9de5a208d4..0000000000 Binary files a/build/package/mac-Start-icon_script.zip and /dev/null differ diff --git a/build/package/mac-VolumeIcon.icns b/build/package/mac-VolumeIcon.icns deleted file mode 100644 index a11c092378..0000000000 Binary files a/build/package/mac-VolumeIcon.icns and /dev/null differ diff --git a/build/package/readme.txt b/build/package/readme.txt new file mode 100644 index 0000000000..d8c3d8ca77 --- /dev/null +++ b/build/package/readme.txt @@ -0,0 +1,79 @@ +============================================================================== +Vaadin @version@ Readme +============================================================================== + +------------- +How to Start? +------------- + +In Windows: + Just double-click start.bat icon. It will start a web application at + port 8888 on the local host and opens a web browser window to display + the start page of Vaadin Content Browser. + +In Linux: + Open a shell window, change to the installation directory, and execute + "sh start.sh". It will start a web application at port 8888 on the local + host and opens a web browser window to display the start page of Vaadin + Content Browser. + +In Mac: + Start Terminal.app and run the start.sh script in the installation + directory. It will start a web application at port 8888 on the local + host and opens a web browser window to display the start page of Vaadin + Content Browser. + +The installation directory is a web application as itself and can be directly +imported to the Eclipse IDE by selecting +"File / Import / Existing Projects into Workspace" from Eclipse main menu. +See the manual for detailed instructions. + +--------------------------------- +What's Inside the Vaadin Package? +--------------------------------- + +You should start exploring Vaadin through the provided Content Browser web +application within this package; see 'How to Start?' above. + +The WebContent directory contains the content available through the Content +Browser: the Vaadin Library, demos, documentation, and other useful +information to get started with Vaadin. + +Below is a list of most important locations and files: + +Start Vaadin +- start exploring Vaadin by double-clicking this icon + +COPYING +- license file + +WebContent/vaadin-@version@.jar +- Vaadin Library containing Java source and compiled files + +WebContent/doc/book-of-vaadin.pdf +- Book of Vaadin in PDF format + +WebContent/doc/api/index.html +- Vaadin API Documentation as JavaDoc reference + +WebContent/WEB-INF/src +- Content Browser source code, compiled into WebContent/WEB-INF/classes + +WebContent/doc/example-source +- example source code in HTML format + +WebContent/demo +- files required by the demos + +Vaadin Hosted Mode Browser.launch +Vaadin Development Server.launch +- launch configurations for Eclipse workspace + +WebContent/doc/example-source/build-widgetset.xml +- example on how to build GWT widget sets for Vaadin application + +WebContent/VAADIN +- widget sets and themes + +gwt +- Google Web Toolkit is required for building new widget sets