This tool unfortunately provides token .Net infrastructure support. It can produce a strongly named assembly but it does not have facility to allow user to specify the assembly version data, a vital piece of information to support strict version binding policy.
Every assembly produced by NE Builder, regardless strongly name or not, has the version 0.0.0.0. As a result it is not very useful. According to Matlab forum, Matlab does not have any way to deal with this issue. This blog post provides a recipe of allowing user to add assembly version or any other pieces of information to the NE Builder produced assembly. It does not use any undocumented or hack to produce the result; it simply uses the same standard .Net build specifications the NE Builder Deployment tool uses.
- From the Deployment tool (read NE Builder) build the assembly and making sure that you clear the "Embedded the CTF Archive". This is because when you use embedded CTF archive, the builder deletes the CTF file after building the assembly. We need this file in the subsequent steps and hence not embedding lets us access this file. Furthermore, it is easier if you make the source and output directory the same.
- Save the build steps to a build log and open it with a text editor.
- Look out for the line containing the CSC.exe as we will use that to produce the response file for the C# compiler.
- Copy the text after CSC.exe into a text file. You can insert line break to make it more readable.
- Add AssemblyInfo.cs to the response file. This file contains the assembly information you wish to include into the assembly.
- Save the text file into a file with customary .rsp extension into the same directory as the source.
- Create the AssemblyInfo.cs file if not exist and specify your assembly version and other information.
- Run the CSC with this response file to produce your assembly which will contain the required assembly version.
This recipe then allows one to produce a versionable strong name .Net assembly that carries the Matlab script.