SHFBROOT system environment variable was not found

Topics: Developer Forum, User Forum
May 25, 2011 at 12:58 AM


I have installed I need to get the Sandcastle build working on a build server that will not have any installation. Sandcastle/SHFB and any dependancies will be checked into svn and the build will reference the files from the svn repository.  Unfortunatley when i attempt to set the SHFBROOT variable in my MSBuild script the build fails with the error below:

"The SHFBROOT system environment variable was not found.  This variable is usually created during installation and may require a reboot.  It has been defined temporarily for this process as: SHFBROOT=%SHFBROOT%\"

I can work arounf this by adding a the task below and calling it with a value for SHFBROOT before i call my Sandcaslte build.  It would be good if we didnt have to do this and it would just pick up the value of SHFBROOT from the build file property:


    AssemblyFile="$(MSBuildToolsPath)\Microsoft.Build.Tasks.v4.0.dll" >
      <Variable Required="true"/>
	  <Value Required="true"/>
      <Code Type="Fragment" Language="cs">
        Environment.SetEnvironmentVariable(Variable, Value);