Skip to content
⌘ NSIS Forum Archive

NSIS and VS2013 - error MSB3721

10 posts

CelesteBlanca10#

NSIS and VS2013 - error MSB3721

I just joined a company and inherited a few installer projects. I'm very new to NSIS, so probably missing common knowledge here, but it looks like NSIS is integrated into VS2013 as there is a "NSIS Compiler" node in the project's properties dialog.

The error that I'm getting is: error MSB3721: The command ""C:\Program Files (x86)\NSIS\Unicode\makensis" /DConfig="Debug" /DOutdir="../Output/Setup/Release\\"
/DInstallName="MyCompany" /DTargetName="MyInstaller.exe" /DPlatform="Win32" MyInstaller.nsi" exited with code 1.


It looks to me as the Outdir value has some extra slashes in there, but I can't seem to get them out of there.

The NSISComplier.rules file shows this:
<StringProperty
Name="OutputDirectory"
DisplayName="OuputDirectory"
Switch="/DOutdir=&quot;[value]&quot;"
DefaultValue="$(OutDir)"
/>

So I looked at the OutputDirectory of the project in VS, and it did seem to have an extra slash in there, but whatever I do, it doesn't seem to change the NSIS command line value. I even put a direct path there, but nothing.

Thanks
Anders#
NSIS itself does not integrate with VS so you must be using a 3rd-party extension.

(Stackoverflow duplicate: https://stackoverflow.com/questions/...-error-msb3721 )
CelesteBlanca10#
OK. So what about this error in makensis.exe? Can you tell me anything about it?

The error that I'm getting is: error MSB3721: The command ""C:\Program Files (x86)\NSIS\Unicode\makensis" /DConfig="Debug" /DOutdir="../Output/Setup/Release\\"
/DInstallName="MyCompany" /DTargetName="MyInstaller.exe" /DPlatform="Win32" MyInstaller.nsi" exited with code 1.
Anders#
That is not a message from makensis.exe. Make sure the path to makensis is correct, yours is missing .exe. I'm also guessing you are using the old Unicode fork?
CelesteBlanca10#
Thanks, yea forced to use that Unicode fork.

Any idea where "ToolPath="%(NSIS_Compiller.ToolPath)"
" could be declared?



<NSIS_Compiller
Condition="'@(NSIS_Compiller)' != '' and '%(NSIS_Compiller.ExcludedFromBuild)' != 'true'"
CommandLineTemplate="%(NSIS_Compiller.CommandLineTemplate)"
ToolPath="%(NSIS_Compiller.ToolPath)"
Configuration="%(NSIS_Compiller.Configuration)"
OutputDirectory="%(NSIS_Compiller.OutputDirectory)"
InstallName="%(NSIS_Compiller.InstallName)"
TargetName="%(NSIS_Compiller.TargetName)"
Platform="%(NSIS_Compiller.Platform)"
AdditionalOptions="%(NSIS_Compiller.AdditionalOptions)"
Inputs="@(NSIS_Compiller)" />
</Target>
Anders#
Why are you forced to use the fork and not NSIS v3?

I don't even know which tool you are using that provides this integration.

MSB* is perhaps MSBuild?
CelesteBlanca10#
Does NSIS v3 have all the Unicode support that the fork had? I don't know why they used it, the dev is no longer here and they haven't touched the installer in years.

Would the move to v3 be difficult? Using 2.4.6 now.
T.Slappy#
Originally Posted by CelesteBlanca10 View Post
Does NSIS v3 have all the Unicode support that the fork had? I don't know why they used it, the dev is no longer here and they haven't touched the installer in years.

Would the move to v3 be difficult? Using 2.4.6 now.
Using NSIS 3 is really recommended, it contains many important fixes and improvements for latest Windows versions, do not hesitate and upgrade immediately.

Back to your question: It looks like there is something wrong with your MSBuild configuration and/or NSIS cannot be recognized correctly.

As it is some custom tool there is no general answer for you. Simply try to track the problem and isolate the issue. Try to turn on detailed (diagnostic) output in MSBuild which can provide you more info.