[svn] r7661: nemerle/trunk/misc/packages/wix: buildSetup.cmd dist.build src/Documentation.wxs src/vs-plugi...

pbludov svnadmin at nemerle.org
Tue May 8 08:03:07 CEST 2007


Log:
Nant task to build wix package source files.

Author: pbludov
Date: Tue May  8 08:03:03 2007
New Revision: 7661

Added:
   nemerle/trunk/misc/packages/wix/dist.build
Modified:
   nemerle/trunk/misc/packages/wix/buildSetup.cmd
   nemerle/trunk/misc/packages/wix/src/Documentation.wxs
   nemerle/trunk/misc/packages/wix/src/vs-plugin.wxs

Modified: nemerle/trunk/misc/packages/wix/buildSetup.cmd
==============================================================================
--- nemerle/trunk/misc/packages/wix/buildSetup.cmd	(original)
+++ nemerle/trunk/misc/packages/wix/buildSetup.cmd	Tue May  8 08:03:03 2007
@@ -54,10 +54,7 @@
 set MsiFile=%~dp0redist\Nemerle.msi
 
 
-rem Change current directory to dist/bin to help RegPkg.exe find the right dlls.
-cd "%~dp0dist\bin"
-
-"%RegPkgDir%\RegPkg.exe" /root:Software\Microsoft\VisualStudio\8.0 "/wixfile:%GeneratedFile%" /codebase "%NemerleSetupContent%\vs-plugin\Nemerle.VisualStudio.dll"
+"%RegPkgDir%\RegPkg.exe" /root:Software\Microsoft\VisualStudio\8.0 "/wixfile:%GeneratedFile%" /codebase "%NemerleSetupContent%\bin\Nemerle.VisualStudio.dll"
 if errorlevel 1 goto done
 cd "%~dp0"
 

Added: nemerle/trunk/misc/packages/wix/dist.build
==============================================================================
--- (empty file)
+++ nemerle/trunk/misc/packages/wix/dist.build	Tue May  8 08:03:03 2007
@@ -0,0 +1,117 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<project name="ItemTemplates" default="build" xmlns="http://nant.sf.net/release/0.85-rc3/nant.xsd">
+  <description>
+    Copyright (c) 2003-2007 The University of Wroclaw.
+    All rights reserved.
+
+    Redistribution and use in source and binary forms, with or without
+    modification, are permitted provided that the following conditions
+    are met:
+       1. Redistributions of source code must retain the above copyright
+          notice, this list of conditions and the following disclaimer.
+       2. Redistributions in binary form must reproduce the above copyright
+          notice, this list of conditions and the following disclaimer in the
+          documentation and/or other materials provided with the distribution.
+       3. The name of the University may not be used to endorse or promote
+          products derived from this software without specific prior
+          written permission.
+
+    THIS SOFTWARE IS PROVIDED BY THE UNIVERSITY ``AS IS'' AND ANY EXPRESS OR
+    IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+    OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN
+    NO EVENT SHALL THE UNIVERSITY BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+    SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
+    TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
+    PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
+    LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+    NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+    SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+    
+    You must not remove this notice, or any other, from this software.
+
+    dist.build - Builds Nemerle package source.
+  </description>
+
+  <property name="dir.top" value="${path::get-full-path('../../../')}" overwrite="false" />
+  <property name="nemerle.include" value="${path::combine(dir.top, 'Nemerle.include')}" overwrite="false" />
+
+  <fail message="Please run `nant configure' in the ${dir.top} folder first." if="${not file::exists(nemerle.include)}"/>
+  <include buildfile="${nemerle.include}" failonerror="true" />
+
+  <fail if="${not property::exists('dir.vs-plugin')}">
+<![CDATA[
+
+Visual studio integration path not set. Build can not continue.
+Please create or edit file `${nemerle.include}.user' and specify `dir.vs-plugin' property.
+
+    For example:
+
+<?xml version="1.0" encoding="utf-8" ?>
+<project name="Nemerle build properties" xmlns="http://nant.sf.net/release/0.85-rc3/nant.xsd">
+  <property name="dir.vs-plugin"  value="foobar/Nemerle/vs-plugin/trunk" />
+  <!--                                   ^^^^^^^^^^^^^^ Set actual path here
+   -->
+</project>
+]]></fail>
+
+
+  
+  <!-- Real begin -->
+
+  <target name="build"           description="Build dist" depends="build.bin build.docs build.vs-plugin"/>
+  
+  <target name="build.bin"       description="Build binaries">
+    <copy todir="dist/bin" flatten="true">
+      <fileset basedir="${dir.top}">
+        <include name="${path::combine('bin', configuration)}/*" />
+        <include name="tools/msbuild-task/Nemerle.MSBuild.targets" />
+        <include name="${path::combine('tools/nemerlish/bin', configuration)}/*" />
+        <include name="${path::combine('tools/nant-task/bin', configuration)}/*" />
+      </fileset>
+    </copy>
+  </target>
+
+  <target name="build.docs"      description="Build documentation">
+    <mkdir dir="dist/docs" />
+    <exec program="wget" workingdir="dist/docs" verbose="true">
+      <arg value="http://nemerle.org/static/Grokking_Nemerle.html" />
+      <arg value="http://nemerle.org/static/Macros.html" />
+      <arg value="http://nemerle.org/static/Tutorials_and_examples.html" />
+    </exec>
+  </target>            
+
+  <target name="build.vs-plugin" description="Build item templates">
+    <!-- CodeSnippets -->
+    <copy todir="dist/vs-plugin/CodeSnippets">
+      <fileset basedir="${path::combine(dir.vs-plugin, 'Nemerle.VsIntegration/CodeSnippets')}">
+        <include name="**/*" />
+      </fileset>
+    </copy>
+
+    <!-- Templates -->
+    <mkdir dir="dist/vs-plugin/ItemTemplates" />
+    <foreach item="Folder" in="${path::combine(dir.vs-plugin, 'Nemerle.VsIntegration/Templates/ProjectItems')}" property="foldername">
+      <zip zipfile="dist/vs-plugin/ItemTemplates/${path::get-file-name(foldername)}.zip" unless="${path::get-file-name(foldername) == '.svn'}">
+        <fileset basedir="${foldername}">
+          <include name="**/*" />
+        </fileset>
+      </zip>
+    </foreach>
+    <mkdir dir="dist/vs-plugin/ProjectTemplates" />
+    <foreach item="Folder" in="${path::combine(dir.vs-plugin, 'Nemerle.VsIntegration/Templates/Projects')}" property="foldername">
+      <zip zipfile="dist/vs-plugin/ProjectTemplates/${path::get-file-name(foldername)}.zip" unless="${path::get-file-name(foldername) == '.svn'}">
+        <fileset basedir="${foldername}">
+          <include name="**/*" />
+        </fileset>
+      </zip>
+    </foreach>
+
+    <!-- Binaries -->
+    <copy todir="dist/bin">
+      <fileset basedir="${path::combine(dir.vs-plugin, path::combine('bin', configuration))}">
+        <include name="Nemerle.Compiler.Utils.*" />
+        <include name="Nemerle.VisualStudio.*" />
+      </fileset>
+    </copy>
+  </target>
+</project>

Modified: nemerle/trunk/misc/packages/wix/src/Documentation.wxs
==============================================================================
--- nemerle/trunk/misc/packages/wix/src/Documentation.wxs	(original)
+++ nemerle/trunk/misc/packages/wix/src/Documentation.wxs	Tue May  8 08:03:03 2007
@@ -41,30 +41,18 @@
 
       <!-- Nemerle guides (docs folder). -->
       <ComponentRef Id="Comp_Docs" />
-      <ComponentRef Id="Comp_Styles" />
 
     </ComponentGroup>
 
     <DirectoryRef Id="Dir_Docs">
 
       <Component Id="Comp_Docs" DiskId="1" Guid="61300733-2A09-466a-A849-C17C3B7A9B15">
-        <File Id="Courses.html"                Name="Courses.html"                Source="dist\docs\Courses.html" KeyPath="yes" />
-        <File Id="Grokking_Nemerle.html"       Name="Grokking_Nemerle.html"       Source="dist\docs\Grokking_Nemerle.html" />
+
+        <File Id="Grokking_Nemerle.html"       Name="Grokking_Nemerle.html"       Source="dist\docs\Grokking_Nemerle.html" KeyPath="yes" />
         <File Id="Macros.html"                 Name="Macros.html"                 Source="dist\docs\Macros.html" />
-        <File Id="Quick_Guide.html"            Name="Quick_Guide.html"            Source="dist\docs\Quick_Guide.html" />
         <File Id="Tutorials_and_examples.html" Name="Tutorials_and_examples.html" Source="dist\docs\Tutorials_and_examples.html" />
-        <File Id="intro.pdf"                   Name="intro.pdf"                   Source="dist\docs\intro.pdf" />
-        <File Id="metaprogramming.pdf"         Name="metaprogramming.pdf"         Source="dist\docs\metaprogramming.pdf" />
-      </Component>
 
-      <Directory Id="styles" Name="styles">
-        <Component Id="Comp_Styles" DiskId="1" Guid="3C13A268-5AA0-4e11-81B1-77C17B2A1AA4">
-          <File Id="logo.png"        Name="logo.png"         Source="dist\docs\styles\logo.png" />
-          <File Id="nemerleicon.png" Name="nemerle-icon.png" Source="dist\docs\styles\nemerle-icon.png" />
-          <File Id="prettyprint.js"  Name="prettyprint.js"   Source="dist\docs\styles\prettyprint.js" />
-          <File Id="style.css"       Name="style.css"        Source="dist\docs\styles\style.css" />
         </Component>
-      </Directory>
 
     </DirectoryRef>
 

Modified: nemerle/trunk/misc/packages/wix/src/vs-plugin.wxs
==============================================================================
--- nemerle/trunk/misc/packages/wix/src/vs-plugin.wxs	(original)
+++ nemerle/trunk/misc/packages/wix/src/vs-plugin.wxs	Tue May  8 08:03:03 2007
@@ -49,15 +49,15 @@
     <DirectoryRef Id="INSTALLDIR">
     <!--<DirectoryRef Id="VSINTEGRATIONDIR">-->
       <Component Id="ComponentPath" DiskId="1" Guid="86C2D7DF-AA48-4f24-9EC0-FBC54B9D0395">
-        <File Id="File_Nemerle.Compiler.Utils.dll" Name="Nemerle.Compiler.Utils.dll" Source="dist\vs-plugin\" >
+        <File Id="File_Nemerle.Compiler.Utils.dll" Name="Nemerle.Compiler.Utils.dll" Source="dist\bin\" >
            <netfx:NativeImage Id="Image_Nemerle.Compiler.Utils.dll" Dependencies="no" />
         </File>
-        <File Id="File_Nemerle.Compiler.Utils.xml" Name="Nemerle.Compiler.Utils.xml" Source="dist\vs-plugin\" />
-        <File Id="File_Nemerle.VisualStudio.dll" Name="Nemerle.VisualStudio.dll"     Source="dist\vs-plugin\" >
+        <File Id="File_Nemerle.Compiler.Utils.xml" Name="Nemerle.Compiler.Utils.xml" Source="dist\bin\" />
+        <File Id="File_Nemerle.VisualStudio.dll" Name="Nemerle.VisualStudio.dll"     Source="dist\bin\" >
            <netfx:NativeImage Id="Image_Nemerle.VisualStudio.dll" Dependencies="no" />
         </File>
-        <File Id="File_Nemerle.VisualStudio.xml" Name="Nemerle.VisualStudio.xml"     Source="dist\vs-plugin\" />
-        <File Id="File_Nemerle.VisualStudio.dll.config" Name="Nemerle.VisualStudio.dll.config"     Source="dist\vs-plugin\" />
+        <File Id="File_Nemerle.VisualStudio.xml" Name="Nemerle.VisualStudio.xml"     Source="dist\bin\" />
+        <File Id="File_Nemerle.VisualStudio.dll.config" Name="Nemerle.VisualStudio.dll.config"     Source="dist\bin\" />
 
         <!-- Remove mapping for .n files added by Simple VS Integration -->
         <RemoveRegistryKey Action="removeOnInstall" Root="HKCU" Key="Software\Microsoft\VisualStudio\8.0\FileExtensionMapping\n" /> 



More information about the svn mailing list