diff --git a/.gitignore b/.gitignore index 6c7cafff..942751b0 100644 --- a/.gitignore +++ b/.gitignore @@ -10,4 +10,4 @@ compile.bat *.resources *~ *.userprefs -.vs +.vs \ No newline at end of file diff --git a/NullBuild.txt b/NullBuild.txt deleted file mode 100644 index 58d4e512..00000000 --- a/NullBuild.txt +++ /dev/null @@ -1,12 +0,0 @@ - - - - - - - - - - - - diff --git a/README.md b/README.md index c0044fb2..b9ffcfcf 100644 --- a/README.md +++ b/README.md @@ -14,7 +14,7 @@ Developers: # License **Radegast Metaverse Client**
-*Copyright © 2009-2011, Radegast Development Team*
+*Copyright © 2009-2016, Radegast Development Team*
*All rights reserved.* Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: @@ -73,3 +73,7 @@ http://commandline.codeplex.com/
Uses code snippets from CSAT Library (MIT License)
Copyright © 2011 mjt
http://code.google.com/p/csat/
+ +Uses SmartIrc4net (LGPL)
+Copyright © 2003-2005 Mirco Bauer
+http://www.meebey.net/projects/smartirc4net/
diff --git a/Radegast/prebuild.exe b/Radegast/prebuild.exe deleted file mode 100755 index f5ec5db4..00000000 Binary files a/Radegast/prebuild.exe and /dev/null differ diff --git a/build/README.txt b/build/README.txt new file mode 100644 index 00000000..6f58b2ce --- /dev/null +++ b/build/README.txt @@ -0,0 +1 @@ +You can find the most current version of premake5 at https://premake.github.io/download.html \ No newline at end of file diff --git a/build/linux/premake5 b/build/linux/premake5 new file mode 100755 index 00000000..59bca8a8 Binary files /dev/null and b/build/linux/premake5 differ diff --git a/build/linux/version.txt b/build/linux/version.txt new file mode 100644 index 00000000..5bea2231 --- /dev/null +++ b/build/linux/version.txt @@ -0,0 +1 @@ +build-7-linux-travis_ci-2016-07-24 diff --git a/build/macosx/premake5 b/build/macosx/premake5 new file mode 100755 index 00000000..1ce41a0e Binary files /dev/null and b/build/macosx/premake5 differ diff --git a/build/macosx/version.txt b/build/macosx/version.txt new file mode 100644 index 00000000..5cb89dad --- /dev/null +++ b/build/macosx/version.txt @@ -0,0 +1 @@ +build-7-osx-travis_ci-2016-07-24 diff --git a/build/windows/premake5.exe b/build/windows/premake5.exe new file mode 100755 index 00000000..28bccbcb Binary files /dev/null and b/build/windows/premake5.exe differ diff --git a/plugins/Radegast.Plugin.IRC/Radegast.Plugin.IRC.csproj b/plugins/Radegast.Plugin.IRC/Radegast.Plugin.IRC.csproj deleted file mode 100644 index b1756211..00000000 --- a/plugins/Radegast.Plugin.IRC/Radegast.Plugin.IRC.csproj +++ /dev/null @@ -1,130 +0,0 @@ - - - - Debug - AnyCPU - 9.0.30729 - 2.0 - {6D4DFA78-7DA5-4B5F-BE42-67EF949478FC} - Library - Properties - Radegast.Plugin.IRC - Radegast.Plugin.IRC - v4.0 - 512 - - - - - 3.5 - publish\ - true - Disk - false - Foreground - 7 - Days - false - false - true - 0 - 1.0.0.%2a - false - false - true - - - - true - ..\..\bin\ - TRACE;DEBUG;SMARTHREADPOOL_REF;VISUAL_STUDIO - full - x86 - prompt - - - ..\..\bin\ - TRACE;SMARTHREADPOOL_REF;VISUAL_STUDIO - true - pdbonly - x86 - prompt - - - - False - assemblies\Meebey.SmartIrc4net.dll - - - - 3.5 - - - - - 3.5 - - - 3.5 - - - - - - - - - UserControl - - - RelayConsole.cs - - - - - - - - RelayConsole.cs - - - - - {F048B0F0-2A65-4588-A292-9C812FC8F354} - OpenMetaverse.StructuredData - - - {5F087E42-6E20-4F87-BE86-AEBED154FDEB} - OpenMetaverseTypes - - - {1545F87D-D8F6-4CD9-BB01-772389BFBC63} - OpenMetaverse - - - {E6CB0CED-4066-41D3-93BF-F922FEE235F9} - Radegast - - - - - False - .NET Framework 3.5 SP1 Client Profile - false - - - False - .NET Framework 3.5 SP1 - true - - - - - - \ No newline at end of file diff --git a/plugins/Radegast.Plugin.Speech/RadSpeechMac/Assemblies/Monobjc.Cocoa.dll b/plugins/Radegast.Plugin.Speech/RadSpeechMac/assemblies/Monobjc.Cocoa.dll similarity index 100% rename from plugins/Radegast.Plugin.Speech/RadSpeechMac/Assemblies/Monobjc.Cocoa.dll rename to plugins/Radegast.Plugin.Speech/RadSpeechMac/assemblies/Monobjc.Cocoa.dll diff --git a/plugins/Radegast.Plugin.Speech/RadSpeechMac/Assemblies/Monobjc.dll b/plugins/Radegast.Plugin.Speech/RadSpeechMac/assemblies/Monobjc.dll similarity index 100% rename from plugins/Radegast.Plugin.Speech/RadSpeechMac/Assemblies/Monobjc.dll rename to plugins/Radegast.Plugin.Speech/RadSpeechMac/assemblies/Monobjc.dll diff --git a/prebuild.xml b/prebuild.xml deleted file mode 100644 index 8cd67a7c..00000000 --- a/prebuild.xml +++ /dev/null @@ -1,496 +0,0 @@ - - - - - - TRACE;DEBUG;SMARTHREADPOOL_REF - false - false - true - 3 - false - 1591,1574,0419,0618,0414,0169 - bin - true - true - false - x86 - - - - - TRACE;SMARTHREADPOOL_REF - true - false - true - 3 - false - 1591,1574,0419,0618,0414,0169 - bin - true - false - false - x86 - - - - - - - - - ../bin/ - x86 - - - - - ../bin/ - x86 - - - - ../bin/ - - - - - - - - - - - - ../bin/ - x86 - - - - - ../bin/ - x86 - - - - ../bin/ - - - - - - - - - - - - ../bin/ - x86 - - - - - ../bin/ - x86 - - - - ../bin/ - - - - - - - - - - - - - - - - - - - - ../bin/ - x86 - - - - - ../bin/ - x86 - - - - ../bin/ - - - - - - - - - - - - - - - - - - ../bin/ - x86 - - - - - 1591,1574,0419,0618,0414,0169 - ../bin/ - x86 - - - - ../bin/ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ../../bin/ - x86 - - - - - 1591,1574,0419,0618,0414,0169 - ../../bin/ - x86 - - - - ../../bin/ - - - - - - - - - - - - - - - - - - - - - - - - - - - - ../../bin/ - x86 - - - - - 1591,1574,0419,0618,0414,0169 - ../../bin/ - x86 - - - - ../../bin/ - - - - - - - - - - - - - - - - - - - - - - - ../../bin/ - x86 - - - - - 1591,1574,0419,0618,0414,0169 - ../../bin/ - x86 - - - - ../../bin/ - - - - - - - - - - - - - - - - - - - - - - - - ../../../bin/ - x86 - - - - - ../../../bin/ - x86 - - - - ../../../bin/ - - - - - - - - - - - - - - - - - - - - - - - - - ../../../bin/ - x86 - - - - - ../../../bin/ - x86 - - - - ../../../bin/ - - \ - - - - - - - - - - - - - - - - - - - ../../../bin/ - x86 - - - - - ../../../bin/ - x86 - - - - ../../../bin/ - - - - - - - - - - - - - - - - - - - - - - - - ../../../bin/ - x86 - - - - - ../../../bin/ - x86 - - - - ../../../bin/ - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/premake5.lua b/premake5.lua new file mode 100644 index 00000000..bcc18492 --- /dev/null +++ b/premake5.lua @@ -0,0 +1,451 @@ +solution "Radegast" + configurations { "Debug", "Release" } + platforms { "x86" } + dotnetframework "4.5" + language "C#" + warnings "Extra" + disablewarnings {"1591", "1574", "0419", "0618", "0414", "0169"} + buildoptions { "/checked-", "/nostdlib-"} + targetdir "bin" + implibdir "bin" + + configuration "Debug" + defines { "TRACE", "DEBUG", "SMARTHREADPOOL_REF" } + flags { "Symbols" } + optimize "Off" + clr "Unsafe" + + configuration "Release" + defines { "TRACE", "SMARTHREADPOOL_REF" } + optimize "Full" + clr "Unsafe" + + configuration "**.config" + buildaction "Copy" + configuration "**.so" + buildaction "Copy" + configuration "**.xml" + buildaction "Copy" + configuration "**.txt" + buildaction "Copy" + configuration "**.png" + buildaction "Copy" + configuration "**.wav" + buildaction "Copy" + + project "OpenMetaverseTypes" + kind("SharedLib") + location(path.join("libopenmetaverse", "OpenMetaverseTypes")) + namespace("OpenMetaverse") + files { + path.join("%{prj.location}", "**.cs") + } + excludes { + path.join("%{prj.location}", "obj", "**") + } + links { + "System", + "System.Core", + "System.Xml", + } + + project "OpenMetaverse.StructuredData" + kind("SharedLib") + location(path.join("libopenmetaverse", "OpenMetaverse.StructuredData")) + namespace("OpenMetaverse.StructuredData") + files { + path.join("%{prj.location}", "**.cs") + } + excludes { + path.join("%{prj.location}", "obj", "**") + } + dependson { + "OpenMetaverseTypes", + } + links { + "System", + "System.Xml", + "OpenMetaverseTypes", + } + + project "OpenMetaverse" + kind("SharedLib") + location(path.join("libopenmetaverse", "OpenMetaverse")) + namespace("OpenMetaverse") + files { + path.join("%{prj.location}", "**.cs") + } + excludes { + path.join("%{prj.location}", "obj", "**") + } + dependson { + "OpenMetaverseTypes", + "OpenMetaverse.StructuredData", + } + links { + "System", + "System.Core", + "System.Xml", + "System.Data", + "System.Drawing", + "OpenMetaverseTypes", + "OpenMetaverse.StructuredData", + path.join("libopenmetaverse", "bin", "log4net"), + path.join("libopenmetaverse", "bin", "SmartThreadPool"), + path.join("libopenmetaverse", "bin", "XMLRPC"), + path.join("libopenmetaverse", "bin", "zlib.net"), + } + + project "OpenMetaverse.Rendering.Meshmerizer" + kind("SharedLib") + location(path.join("libopenmetaverse", "OpenMetaverse.Rendering.Meshmerizer")) + namespace("OpenMetaverse.Rendering") + files { + path.join("%{prj.location}", "**.cs") + } + excludes { + path.join("%{prj.location}", "obj", "**") + } + dependson { + "OpenMetaverse", + "OpenMetaverseTypes", + } + links { + "System", + "System.Xml", + "System.Data", + "System.Drawing", + "OpenMetaverse", + "OpenMetaverseTypes", + path.join("libopenmetaverse", "bin", "PrimMesher"), + } + + project "Radegast" + kind("WindowedApp") + location("Radegast") + icon(path.join("%{prj.location}", "radegast.ico")) + files { + path.join("%{prj.location}", "Properties", "**.cs"), + path.join("%{prj.location}", "**.cs"), + path.join("%{prj.location}", "**.resx"), + path.join("%{prj.location}", "openjpeg-dotnet*"), + path.join("%{prj.location}", "*.config"), + path.join("%{prj.location}", "*.so"), + path.join("%{prj.location}", "*.dylib"), + path.join("%{prj.location}", "fmodex.*"), + path.join("%{prj.location}", "*.xml"), + path.join("%{prj.location}", "*.txt"), + path.join("%{prj.location}", "*.png"), + path.join("%{prj.location}", "radegast.nsi"), + path.join("%{prj.location}", "openmetaverse_data", "**"), + path.join("%{prj.location}", "character", "**"), + path.join("%{prj.location}", "shader_data", "**") + } + excludes { + path.join("%{prj.location}", "AssemblyInfo.cs"), + path.join("%{prj.location}", "openmetaverse_data", ".svn", "**"), + path.join("%{prj.location}", "obj", "**") + } + dependson { + "OpenMetaverse", + "OpenMetaverseTypes", + "OpenMetaverse.StructuredData", + "OpenMetaverse.Rendering.Meshmerizer" + } + links { + "System", + "System.Core", + "System.Data", + "System.Drawing", + "System.Web", + "System.Web.Extensions", + "System.Windows.Forms", + "System.Xml", + "OpenMetaverse", + "OpenMetaverseTypes", + "OpenMetaverse.StructuredData", + "OpenMetaverse.Rendering.Meshmerizer", + path.join("%{prj.location}", "assemblies", "fmodex-dotnet"), + path.join("%{prj.location}", "assemblies", "OpenTK"), + path.join("%{prj.location}", "assemblies", "OpenTK.GLControl"), + path.join("%{prj.location}", "assemblies", "Tools"), + path.join("%{prj.location}", "assemblies", "log4net"), + path.join("%{prj.location}", "assemblies", "CommandLine"), + path.join("%{prj.location}", "assemblies", "XMLRPC"), + } + configuration "**/**.dylib" + buildaction "Copy" + configuration "**/fmodex.*" + buildaction "Copy" + configuration "**/openjpeg-dotnet*" + buildaction "Copy" + configuration "**/radegast.nsi" + buildaction "Copy" + configuration "**/openmetaverse_data/**" + buildaction "Copy" + configuration "**/character/**" + buildaction "Copy" + configuration "**/shader_data/**" + buildaction "Copy" + + project "Radegast.Plugin.Alice" + kind("SharedLib") + location(path.join("plugins", "Radegast.Plugin.Alice")) + files { + path.join("%{prj.location}", "**.cs"), + path.join("%{prj.location}", "Properties", "**.cs"), + path.join("%{prj.location}", "aiml", "**"), + path.join("%{prj.location}", "aiml_config", "**") + } + excludes { + path.join("%{prj.location}", "AssemblyInfo.cs"), + path.join("%{prj.location}", "obj", "**") + } + dependson { + "Radegast", + "OpenMetaverse", + "OpenMetaverseTypes", + "OpenMetaverse.StructuredData", + "Radegast.Plugin.Speech" + } + links { + "System", + "System.Core", + "System.Xml", + "System.Data", + "System.Drawing", + "System.Xml.Linq", + "System.Windows.Forms", + "OpenMetaverse", + "OpenMetaverseTypes", + "OpenMetaverse.StructuredData", + "Radegast.exe", + path.join("%{prj.location}", "assemblies", "AIMLbot"), + } + configuration "**/aiml/**" + buildaction "Copy" + configuration "**/aiml_config/**" + buildaction "Copy" + + project "Radegast.Plugin.SimpleBuilder" + kind("SharedLib") + location(path.join("plugins", "Radegast.Plugin.SimpleBuilder")) + files { + path.join("%{prj.location}", "**.cs"), + path.join("%{prj.location}", "Properties", "**.cs") + } + excludes { + path.join("%{prj.location}", "AssemblyInfo.cs"), + path.join("%{prj.location}", "obj", "**") + } + dependson{ + "Radegast", + "OpenMetaverse", + "OpenMetaverseTypes", + "OpenMetaverse.StructuredData" + } + links { + "System", + "System.Core", + "System.Xml", + "System.Data", + "System.Drawing", + "System.Windows.Forms", + "OpenMetaverse", + "OpenMetaverseTypes", + "OpenMetaverse.StructuredData", + "Radegast", + } + + project "Radegast.Plugin.IRC" + kind("SharedLib") + location(path.join("plugins", "Radegast.Plugin.IRC")) + files { + path.join("%{prj.location}", "**.cs"), + path.join("%{prj.location}", "Properties", "**.cs") + } + excludes { + path.join("%{prj.location}", "AssemblyInfo.cs"), + path.join("%{prj.location}", "obj", "**") + } + dependson{ + "Radegast", + "OpenMetaverse", + "OpenMetaverseTypes", + "OpenMetaverse.StructuredData" + } + links { + "System", + "System.Core", + "System.Xml", + "System.Data", + "System.Drawing", + "System.Windows.Forms", + "System.Xml.Linq", + "System.Data.DataSetExtensions", + "OpenMetaverse", + "OpenMetaverseTypes", + "OpenMetaverse.StructuredData", + "Radegast", + path.join("%{prj.location}", "assemblies", "Meebey.SmartIrc4net") + } + +--[[ + project "Radegast.Plugin.EVOVend" + kind("SharedLib") + location(path.join("plugins", "Radegast.Plugin.EVOVend")) + files { + path.join("%{prj.location}", "**.cs"), + path.join("%{prj.location}", "Properties", "**.cs") + } + excludes { + path.join("%{prj.location}", "AssemblyInfo.cs"), + path.join("%{prj.location}", "obj", "**") + } + dependson{ + "Radegast", + "OpenMetaverse", + "OpenMetaverseTypes", + "OpenMetaverse.StructuredData" + } + links { + "System", + "System.Core", + "System.Xml", + "System.Data", + "System.Drawing", + "System.Windows.Forms", + "OpenMetaverse", + "OpenMetaverseTypes", + "OpenMetaverse.StructuredData", + "Radegast", + } +--]] + + project "Radegast.Plugin.Speech" + kind("SharedLib") + location(path.join("plugins", "Radegast.Plugin.Speech", "RadSpeech")) + files { + path.join("%{prj.location}", "**.cs"), + path.join("%{prj.location}", "**.wav"), + path.join("%{prj.location}", "**.resx"), + } + excludes { + path.join("%{prj.location}", "obj", "**") + } + dependson{ + "Radegast", + "OpenMetaverse", + "OpenMetaverseTypes", + "OpenMetaverse.StructuredData" + } + links { + "System", + "System.Core", + "System.Drawing", + "System.Windows.Forms", + "System.Xml.Linq", + "System.Data.DataSetExtensions", + "System.Data", + "System.Xml", + "OpenMetaverse", + "OpenMetaverseTypes", + "OpenMetaverse.StructuredData", + "Radegast.exe", + "fmodex-dotnet.dll", + } + + project "RadSpeechLin" + kind("SharedLib") + location(path.join("plugins", "Radegast.Plugin.Speech", "RadSpeechLin")) + files { + path.join("%{prj.location}", "**.cs"), + } + excludes { + path.join("%{prj.location}", "obj", "**") + } + dependson { + "Radegast", + "OpenMetaverse", + "OpenMetaverseTypes", + "OpenMetaverse.StructuredData", + "Radegast.Plugin.Speech" + } + links { + "System", + "System.Core", + "System.Xml.Linq", + "System.Data.DataSetExtensions", + "System.Data", + "System.Xml", + "OpenMetaverse", + "OpenMetaverseTypes", + "OpenMetaverse.StructuredData", + "Radegast.exe", + "Radegast.Plugin.Speech", + } + + if os.is("windows") then + project "RadSpeechWin" + kind("SharedLib") + location(path.join("plugins", "Radegast.Plugin.Speech", "RadSpeechWin")) + files { + path.join("%{prj.location}", "**.cs"), + } + excludes { + path.join("%{prj.location}", "obj", "**") + } + dependson { + "Radegast", + "OpenMetaverse", + "OpenMetaverseTypes", + "OpenMetaverse.StructuredData", + "Radegast.Plugin.Speech" + } + links { + "System", + "System.Core", + "System.Speech", + "System.Xml.Linq", + "System.Data.DataSetExtensions", + "System.Data", + "System.Xml", + "OpenMetaverse", + "OpenMetaverseTypes", + "OpenMetaverse.StructuredData", + "Radegast.exe", + "Radegast.Plugin.Speech", + } + end + + project "RadSpeechMac" + kind("SharedLib") + location(path.join("plugins", "Radegast.Plugin.Speech", "RadSpeechMac")) + files { + path.join("%{prj.location}", "**.cs"), + } + excludes { + path.join("%{prj.location}", "obj", "**") + } + dependson { + "Radegast", + "OpenMetaverse", + "OpenMetaverseTypes", + "OpenMetaverse.StructuredData", + "Radegast.Plugin.Speech" + } + links { + "System", + "System.Core", + "System.Xml.Linq", + "System.Data.DataSetExtensions", + "System.Data", + "System.Xml", + "OpenMetaverse", + "OpenMetaverseTypes", + "OpenMetaverse.StructuredData", + "Radegast.exe", + "Radegast.Plugin.Speech", + path.join("%{prj.location}", "assemblies", "Monobjc.Cocoa"), + path.join("%{prj.location}", "assemblies", "Monobjc"), + } diff --git a/runprebuild-nant.sh b/runprebuild-nant.sh deleted file mode 100755 index bb5447de..00000000 --- a/runprebuild-nant.sh +++ /dev/null @@ -1,28 +0,0 @@ -#!/bin/bash - -cd `dirname "$0"` -mkdir bin 2>/dev/null -cp Radegast/assemblies/* bin -cp plugins/Radegast.Plugin.Alice/assemblies/*.dll bin - -mono Radegast/prebuild.exe /target nant - -cp -f NullBuild.txt plugins/Radegast.Plugin.Speech/RadSpeechWin/RadSpeechWin.dll.build -cp -f NullBuild.txt plugins/Radegast.Plugin.Speech/RadSpeechMac/RadSpeechMac.dll.build -cp -f NullBuild.txt plugins/Radegast.Plugin.Demo/Radegast.Plugin.Demo.dll.build - -if [ x$1 == xnant ]; then - nant -buildfile:Radegast.build - RES=$? - echo Build Exit Code: $RES - - if [ x$RES != x0 ]; then - exit $RES - fi - - if [ x$2 == xdist ]; then - tar czvf radegast-latest.tgz bin - fi - - exit $RES -fi diff --git a/runprebuild.sh b/runprebuild.sh index e7c0df27..99af8f1e 100755 --- a/runprebuild.sh +++ b/runprebuild.sh @@ -3,7 +3,11 @@ cd `dirname "$0"` mkdir bin 2>/dev/null -mono Radegast/prebuild.exe /target vs2010 /exclude plug_speech +if [ "$(uname -s)" == "Darwin" ]; then + ./build/macosx/premake5 --os=macosx vs2010 +else + ./build/linux/premake5 --os=linux vs2010 +fi if [ x$1 == xbuild ]; then xbuild /p:Configuration=Release Radegast.sln @@ -17,7 +21,7 @@ if [ x$1 == xbuild ]; then if [ x$2 == xdist ]; then tar czvf radegast-latest.tgz bin fi - + exit $RES else echo "Now run:" diff --git a/runprebuild2010.bat b/runprebuild2010.bat old mode 100755 new mode 100644 index 4efffe1f..99a248a0 --- a/runprebuild2010.bat +++ b/runprebuild2010.bat @@ -22,7 +22,7 @@ echo ########################################## if not exist bin mkdir bin :: run prebuild to generate solution/project files from prebuild.xml configuration file -Radegast\prebuild.exe /target vs2010 +Build\Windows\Premake5.exe vs2010 :: build compile.bat file based on command line parameters echo @echo off > compile.bat diff --git a/runprebuild2012.bat b/runprebuild2012.bat old mode 100755 new mode 100644 index c532f613..5e24576a --- a/runprebuild2012.bat +++ b/runprebuild2012.bat @@ -15,14 +15,14 @@ :: echo ########################################## -echo creating prebuild files for: vs2010 +echo creating prebuild files for: vs2012 echo Parameters: %1 %2 echo ########################################## if not exist bin mkdir bin :: run prebuild to generate solution/project files from prebuild.xml configuration file -Radegast\prebuild.exe /target vs2012 +Build\Windows\Premake5.exe vs2012 :: build compile.bat file based on command line parameters echo @echo off > compile.bat diff --git a/runprebuild2013.bat b/runprebuild2013.bat new file mode 100644 index 00000000..6b71ea02 --- /dev/null +++ b/runprebuild2013.bat @@ -0,0 +1,81 @@ +@echo off +:: +:: Prebuild generator for the Radegast +:: +:: Command Line Options: +:: (none) - create solution/project files and create compile.bat file to build solution +:: msbuild - Create project files, compile solution +:: msbuild runtests - create project files, compile solution, run unit tests +:: msbuild docs - create project files, compile solution, build API documentation +:: msbuild docs dist - Create project files, compile solution, run unit tests, build api documentation, create binary zip +:: - and exe installer +:: +:: nant - Create project files, run nant to compile solution +:: nant runtests - Create project files, run nant to compile solution, run unit tests +:: + +echo ########################################## +echo creating prebuild files for: vs2013 +echo Parameters: %1 %2 +echo ########################################## + +if not exist bin mkdir bin + +:: run prebuild to generate solution/project files from prebuild.xml configuration file +Build\Windows\Premake5.exe vs2013 + +:: build compile.bat file based on command line parameters +echo @echo off > compile.bat +if(.%1)==(.) echo %SystemRoot%\Microsoft.NET\Framework\v4.0.30319\msbuild Radegast.sln >> compile.bat + +if(.%1)==(.msbuild) echo echo ==== COMPILE BEGIN ==== >> compile.bat +if(.%1)==(.msbuild) echo %SystemRoot%\Microsoft.NET\Framework\v4.0.30319\MSBuild.exe /p:Configuration=Release Radegast.sln >> compile.bat +if(.%1)==(.msbuild) echo IF ERRORLEVEL 1 GOTO FAIL >> compile.bat + +if(.%1)==(.nant) echo nant >> compile.bat +if(.%1)==(.nant) echo IF ERRORLEVEL 1 GOTO FAIL >> compile.bat + +if(.%3)==(.docs) echo echo ==== GENERATE DOCUMENTATION BEGIN ==== >> compile.bat +if(.%2)==(.docs) echo %SystemRoot%\Microsoft.NET\Framework\v4.0.30319\MSBuild.exe /p:Configuration=Release docs\Radegast.shfbproj >> compile.bat +if(.%2)==(.docs) echo IF ERRORLEVEL 1 GOTO FAIL >> compile.bat +if(.%2)==(.docs) echo 7z.exe a -tzip docs\documentation.zip docs\trunk >> compile.bat +if(.%2)==(.docs) echo IF ERRORLEVEL 1 GOTO FAIL >> compile.bat + +if(.%2)==(.runtests) echo echo ==== UNIT TESTS BEGIN ==== >> compile.bat +if(.%2)==(.runtests) echo nunit-console bin\Radegast.Tests.dll /exclude:Network /nodots /labels /xml:testresults.xml >> compile.bat + +if(.%2)==(.runtests) echo IF ERRORLEVEL 1 GOTO FAIL >> compile.bat + +if not (.%2)==(.dist) goto NODIST +echo echo ==== GENERATE DISTRIBUTION BEGIN ==== >> compile.bat +copy Radegast\radegast.nsi bin +echo del /q Radegast-*-installer.exe >> compile.bat +echo del /q radegast-latest.zip >> compile.bat + +if not exist "%PROGRAMFILES%\NSIS\Unicode\makensis.exe" goto NOUNINSIS +echo "%PROGRAMFILES%\NSIS\Unicode\makensis.exe" bin\radegast.nsi >> compile.bat +goto NONSIS +:NOUNINSIS + +if not exist "%PROGRAMFILES%\NSIS\makensis.exe" goto NONSIS +echo "%PROGRAMFILES%\NSIS\makensis.exe" bin\radegast.nsi >> compile.bat +:NONSIS + +echo cd bin >> compile.bat +echo 7z.exe a -r -tzip ..\radegast-latest.zip *.* >> compile.bat +echo cd .. >> compile.bat + +:NODIST + +echo :SUCCESS >> compile.bat +echo echo Build Successful! >> compile.bat +echo exit /B 0 >> compile.bat +echo :FAIL >> compile.bat +echo echo Build Failed, check log for reason >> compile.bat +echo exit /B 1 >> compile.bat + +:: perform the appropriate action +if(.%1)==(.msbuild) compile.bat +if(.%1)==(.nant) compile.bat +if(.%1)==(.dist) compile.bat + diff --git a/runprebuild2015.bat b/runprebuild2015.bat new file mode 100644 index 00000000..ba39e560 --- /dev/null +++ b/runprebuild2015.bat @@ -0,0 +1,81 @@ +@echo off +:: +:: Prebuild generator for the Radegast +:: +:: Command Line Options: +:: (none) - create solution/project files and create compile.bat file to build solution +:: msbuild - Create project files, compile solution +:: msbuild runtests - create project files, compile solution, run unit tests +:: msbuild docs - create project files, compile solution, build API documentation +:: msbuild docs dist - Create project files, compile solution, run unit tests, build api documentation, create binary zip +:: - and exe installer +:: +:: nant - Create project files, run nant to compile solution +:: nant runtests - Create project files, run nant to compile solution, run unit tests +:: + +echo ########################################## +echo creating prebuild files for: vs2015 +echo Parameters: %1 %2 +echo ########################################## + +if not exist bin mkdir bin + +:: run prebuild to generate solution/project files from prebuild.xml configuration file +Build\Windows\Premake5.exe vs2015 + +:: build compile.bat file based on command line parameters +echo @echo off > compile.bat +if(.%1)==(.) echo %SystemRoot%\Microsoft.NET\Framework\v4.0.30319\msbuild Radegast.sln >> compile.bat + +if(.%1)==(.msbuild) echo echo ==== COMPILE BEGIN ==== >> compile.bat +if(.%1)==(.msbuild) echo %SystemRoot%\Microsoft.NET\Framework\v4.0.30319\MSBuild.exe /p:Configuration=Release Radegast.sln >> compile.bat +if(.%1)==(.msbuild) echo IF ERRORLEVEL 1 GOTO FAIL >> compile.bat + +if(.%1)==(.nant) echo nant >> compile.bat +if(.%1)==(.nant) echo IF ERRORLEVEL 1 GOTO FAIL >> compile.bat + +if(.%3)==(.docs) echo echo ==== GENERATE DOCUMENTATION BEGIN ==== >> compile.bat +if(.%2)==(.docs) echo %SystemRoot%\Microsoft.NET\Framework\v4.0.30319\MSBuild.exe /p:Configuration=Release docs\Radegast.shfbproj >> compile.bat +if(.%2)==(.docs) echo IF ERRORLEVEL 1 GOTO FAIL >> compile.bat +if(.%2)==(.docs) echo 7z.exe a -tzip docs\documentation.zip docs\trunk >> compile.bat +if(.%2)==(.docs) echo IF ERRORLEVEL 1 GOTO FAIL >> compile.bat + +if(.%2)==(.runtests) echo echo ==== UNIT TESTS BEGIN ==== >> compile.bat +if(.%2)==(.runtests) echo nunit-console bin\Radegast.Tests.dll /exclude:Network /nodots /labels /xml:testresults.xml >> compile.bat + +if(.%2)==(.runtests) echo IF ERRORLEVEL 1 GOTO FAIL >> compile.bat + +if not (.%2)==(.dist) goto NODIST +echo echo ==== GENERATE DISTRIBUTION BEGIN ==== >> compile.bat +copy Radegast\radegast.nsi bin +echo del /q Radegast-*-installer.exe >> compile.bat +echo del /q radegast-latest.zip >> compile.bat + +if not exist "%PROGRAMFILES%\NSIS\Unicode\makensis.exe" goto NOUNINSIS +echo "%PROGRAMFILES%\NSIS\Unicode\makensis.exe" bin\radegast.nsi >> compile.bat +goto NONSIS +:NOUNINSIS + +if not exist "%PROGRAMFILES%\NSIS\makensis.exe" goto NONSIS +echo "%PROGRAMFILES%\NSIS\makensis.exe" bin\radegast.nsi >> compile.bat +:NONSIS + +echo cd bin >> compile.bat +echo 7z.exe a -r -tzip ..\radegast-latest.zip *.* >> compile.bat +echo cd .. >> compile.bat + +:NODIST + +echo :SUCCESS >> compile.bat +echo echo Build Successful! >> compile.bat +echo exit /B 0 >> compile.bat +echo :FAIL >> compile.bat +echo echo Build Failed, check log for reason >> compile.bat +echo exit /B 1 >> compile.bat + +:: perform the appropriate action +if(.%1)==(.msbuild) compile.bat +if(.%1)==(.nant) compile.bat +if(.%1)==(.dist) compile.bat +