Skip to content

Commit

Permalink
Work on VS2012 Integration.
Browse files Browse the repository at this point in the history
  • Loading branch information
VladD2 committed Oct 1, 2012
1 parent 3900614 commit 862f6c5
Show file tree
Hide file tree
Showing 5 changed files with 105 additions and 11 deletions.
7 changes: 7 additions & 0 deletions DevBuildQuick-4.5.cmd
@@ -0,0 +1,7 @@
set MSBuild="%SystemRoot%\Microsoft.NET\Framework\v4.0.30319\msbuild.exe"
set NoPause=true
%MSBuild% NemerleAll.nproj /target:DevBuildQuick /p:Configuration=Debug /verbosity:n /p:NTargetName=Build /tv:4.0 /p:TargetFrameworkVersion=v4.5

rem /verbosity:n /p:TargetName=Build
IF %errorlevel% == 0 call Reg-bins-2-4.5.cmd
pause
6 changes: 6 additions & 0 deletions DevBuildQuick-ncc-4.5.cmd
@@ -0,0 +1,6 @@
set MSBuild="%SystemRoot%\Microsoft.NET\Framework\v4.0.30319\msbuild.exe"
set NoPause=true
%MSBuild% NemerleAll.nproj /target:DevBuildQuickNccOnly /p:Configuration=Debug /verbosity:n /p:NTargetName=Build /tv:4.0 /p:TargetFrameworkVersion=v4.5
rem /verbosity:n /p:TargetName=Build
IF %errorlevel% == 0 call Reg-bins-2-4.5.cmd
pause
2 changes: 1 addition & 1 deletion NemerleAll.nproj
Expand Up @@ -151,7 +151,7 @@

<ItemGroup Condition="'$(TargetFrameworkVersion)' == 'v4.5'">
<NIntegrationProject Include="$(NRoot)\snippets\VS2010\WpfHint\WpfHint.csproj" />
<NIntegrationProject Include="$(NRoot)\snippets\VS2010\Nemerle.Compiler.Utils\Nemerle.Compiler.Utils.csproj" />
<NIntegrationProject Include="$(NRoot)\snippets\VS2010\Nemerle.Compiler.Utils\Nemerle.Compiler.Utils-VS-2012.csproj" />
<NIntegrationProject Include="$(NRoot)\snippets\VS2010\Nemerle.VisualStudio\Nemerle.VisualStudio-VS-2012.csproj" />
</ItemGroup>

Expand Down
71 changes: 71 additions & 0 deletions Reg-bins-2-4.5.cmd
@@ -0,0 +1,71 @@
@echo off

set NemerleRoot=%~dp0.
set NemerleInstall=%ProgramFiles%\Nemerle\Net-4.5

IF NOT "%PROCESSOR_ARCHITECTURE%" == "x86" goto b64
IF NOT "%PROCESSOR_ARCHITEW6432%" == "" goto b64
set NGen="%SystemRoot%\Microsoft.NET\Framework\v4.0.30319\ngen.exe"
goto b32
:b64
"%NemerleRoot%\ExternalDependences\junction.exe" "%ProgramW6432%\Nemerle" "%ProgramFiles(x86)%\Nemerle"
:skipJunction
set NGen="%SystemRoot%\Microsoft.NET\Framework64\v4.0.30319\ngen.exe"
:b32

set errors=no
goto skip
:err_check
set errors=yes
IF %1 == 0 set errors=no
exit /b %1
:skip


@echo NemerleInstall=%NemerleInstall%
@echo NGen=%NGen%

md "%NemerleInstall%"

%NGen% uninstall "%NemerleInstall%\Nemerle.dll"
%NGen% uninstall "%NemerleInstall%\Nemerle.Compiler.dll"
%NGen% uninstall "%NemerleInstall%\Nemerle.Macros.dll"
%NGen% uninstall "%NemerleInstall%\Nemerle.MSBuild.Tasks.dll"
%NGen% uninstall "%NemerleInstall%\ncc.exe"

@echo errorlevel=%errorlevel%

@echo --------------------------- Update registry ---------------------------

set NemerleMSBuildTargets=%NemerleInstall%\Nemerle.MSBuild.targets

@echo Add NemerleTarget=%NemerleMSBuildTargets%
@echo into HKLM\SOFTWARE\Microsoft\VisualStudio\10.0\MSBuild\SafeImports
reg.exe add HKLM\SOFTWARE\Microsoft\VisualStudio\10.0\MSBuild\SafeImports /v NemerleTarget /d "%NemerleInstall%\Nemerle.MSBuild.targets" /f

@echo into HKCU\Software\Microsoft\VisualStudio\10.0\Configuration\MSBuild\SafeImports
reg.exe add HKCU\Software\Microsoft\VisualStudio\10.0\Configuration\MSBuild\SafeImports /v NemerleTarget /d "%NemerleInstall%\Nemerle.MSBuild.targets" /f

@echo into HKCU\Software\Microsoft\VisualStudio\10.0Exp\Configuration\MSBuild\SafeImports
reg.exe add HKCU\Software\Microsoft\VisualStudio\10.0Exp\Configuration\MSBuild\SafeImports /v NemerleTarget /d "%NemerleInstall%\Nemerle.MSBuild.targets" /f

@echo --------------------------- Registry updated ---------------------------

%NGen% install "%NemerleInstall%\Nemerle.dll"
%NGen% install "%NemerleInstall%\Nemerle.Compiler.dll"
%NGen% install "%NemerleInstall%\Nemerle.Macros.dll"
%NGen% install "%NemerleInstall%\Nemerle.MSBuild.Tasks.dll"
%NGen% install "%NemerleInstall%\ncc.exe"

%VS100COMNTOOLS%\..\IDE\VSIXInstaller.exe /q "%NemerleInstall%\Nemerle.VisualStudio.vsix


IF NOT "%NoPause%"=="true" pause

exit /b 0

:strong_fail
exit /b 1

:Error
call :strong_fail
30 changes: 20 additions & 10 deletions snippets/VS2010/Nemerle.VS2012.sln
@@ -1,30 +1,40 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 2012
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Nemerle.Compiler.Utils", "Nemerle.Compiler.Utils\Nemerle.Compiler.Utils-VS-2012.csproj", "{8DEC5A24-95AB-4B5D-ABD8-BE53EF793BBE}"
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Nemerle.Compiler.Utils-VS-2012", "Nemerle.Compiler.Utils\Nemerle.Compiler.Utils-VS-2012.csproj", "{8DEC5A24-95AB-4B5D-ABD8-BE53EF793BBE}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "WpfHint", "WpfHint\WpfHint.csproj", "{7670DE22-B023-4783-BA19-BB2DB50E1762}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Nemerle.VisualStudio", "Nemerle.VisualStudio\Nemerle.VisualStudio-VS-2012.csproj", "{16041FE4-7A5D-4DFD-9A79-A92B6A81E291}"
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Nemerle.VisualStudio-VS-2012", "Nemerle.VisualStudio\Nemerle.VisualStudio-VS-2012.csproj", "{16041FE4-7A5D-4DFD-9A79-A92B6A81E291}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Debug|x86 = Debug|x86
Release|Any CPU = Release|Any CPU
Release|x86 = Release|x86
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{16041FE4-7A5D-4DFD-9A79-A92B6A81E291}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{16041FE4-7A5D-4DFD-9A79-A92B6A81E291}.Debug|Any CPU.Build.0 = Debug|Any CPU
{16041FE4-7A5D-4DFD-9A79-A92B6A81E291}.Release|Any CPU.ActiveCfg = Release|Any CPU
{16041FE4-7A5D-4DFD-9A79-A92B6A81E291}.Release|Any CPU.Build.0 = Release|Any CPU
{7670DE22-B023-4783-BA19-BB2DB50E1762}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{7670DE22-B023-4783-BA19-BB2DB50E1762}.Debug|Any CPU.Build.0 = Debug|Any CPU
{7670DE22-B023-4783-BA19-BB2DB50E1762}.Release|Any CPU.ActiveCfg = Release|Any CPU
{7670DE22-B023-4783-BA19-BB2DB50E1762}.Release|Any CPU.Build.0 = Release|Any CPU
{8DEC5A24-95AB-4B5D-ABD8-BE53EF793BBE}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{8DEC5A24-95AB-4B5D-ABD8-BE53EF793BBE}.Debug|Any CPU.Build.0 = Debug|Any CPU
{8DEC5A24-95AB-4B5D-ABD8-BE53EF793BBE}.Debug|x86.ActiveCfg = Debug|Any CPU
{8DEC5A24-95AB-4B5D-ABD8-BE53EF793BBE}.Debug|x86.Build.0 = Debug|Any CPU
{8DEC5A24-95AB-4B5D-ABD8-BE53EF793BBE}.Release|Any CPU.ActiveCfg = Release|Any CPU
{8DEC5A24-95AB-4B5D-ABD8-BE53EF793BBE}.Release|Any CPU.Build.0 = Release|Any CPU
{8DEC5A24-95AB-4B5D-ABD8-BE53EF793BBE}.Release|x86.ActiveCfg = Release|Any CPU
{7670DE22-B023-4783-BA19-BB2DB50E1762}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{7670DE22-B023-4783-BA19-BB2DB50E1762}.Debug|Any CPU.Build.0 = Debug|Any CPU
{7670DE22-B023-4783-BA19-BB2DB50E1762}.Debug|x86.ActiveCfg = Debug|Any CPU
{7670DE22-B023-4783-BA19-BB2DB50E1762}.Debug|x86.Build.0 = Debug|Any CPU
{7670DE22-B023-4783-BA19-BB2DB50E1762}.Release|Any CPU.ActiveCfg = Release|Any CPU
{7670DE22-B023-4783-BA19-BB2DB50E1762}.Release|Any CPU.Build.0 = Release|Any CPU
{7670DE22-B023-4783-BA19-BB2DB50E1762}.Release|x86.ActiveCfg = Release|Any CPU
{16041FE4-7A5D-4DFD-9A79-A92B6A81E291}.Debug|Any CPU.ActiveCfg = Debug|x86
{16041FE4-7A5D-4DFD-9A79-A92B6A81E291}.Debug|x86.ActiveCfg = Debug|x86
{16041FE4-7A5D-4DFD-9A79-A92B6A81E291}.Debug|x86.Build.0 = Debug|x86
{16041FE4-7A5D-4DFD-9A79-A92B6A81E291}.Release|Any CPU.ActiveCfg = Release|x86
{16041FE4-7A5D-4DFD-9A79-A92B6A81E291}.Release|x86.ActiveCfg = Release|x86
{16041FE4-7A5D-4DFD-9A79-A92B6A81E291}.Release|x86.Build.0 = Release|x86
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
Expand Down

0 comments on commit 862f6c5

Please sign in to comment.