|compiler||You only need to |
|compiler||Mascot Parser library file; see Choosing the correct DLL file and Using the MinGW compiler.|
|Source code for C++ examples. These can all be built from the command line using the |
When using VS 2005, for Mascot Parser 2.5 and later, it is necessary to install Windows SDK 2003 SP1. The only required files are: winhttp.h and winhttp.lib (for 32 and 64 bit), so these files can be copied from the SDK to another location if required. There is no need to install the Windows SDK separately for later versions of the compiler.
For Microsoft Visual C++, there are three choices:
It is normally necessary to use the debug build of Mascot Parser with a debug build of your application, and the release build for release builds of your application.
If the wrong build of
msparser.dll is used, then, for example, Mascot Parser will be using the non-debug version of the Microsoft run time library, while application code will be using the debug version. Since pointers to memory are being passed between msparser and application code, they need to use the same RTL. Note however, that the debug version can be very slow with very large files.
A statically linked library has the advantage that you won't need to ship any extra modules with your application. The disadvantage is increased executable size.
With a dynamically linked library, the advantage is that if there is a bug fix or an enhancement in Mascot Parser, then you would only need to ship a patched version of the
msparser.dll file. The disadvantage is, of course, having to ship the file with the application.
The filenames for the
.dll files and the directories for the test harness are shown below:
When compiling against the static libraries, you need to add the following definition in your source code, or add it to the project file:
If in doubt, check the options in the appropriate test harness.
Note the following:
When using the DLL versions, you must compile your application using the multithreaded DLL runtime library. You cannot use the statically linked runtime.
When using the statically linked library versions, you must compile your application using multithreaded or multithreaded debug runtime library. You cannot use the DLL runtime libraries.
/FORCE:MULTIPLElinker option to avoid an error message about a duplicate
operator new()symbol in debug configurations.
Mascot Parser is being used by some mass spectrometer vendors. This means that there is the possibility that another version of the DLL may be installed on the computer. To avoid any possible conflict, it is strongly recommended that you do not install this DLL in the
system32 directory, but just put it in your application directory.
It is possible to compile the Windows C++ examples from the command line rather than creating a project. For example, to build using the static library:
C:\>cl -D _MATRIX_USE_STATIC_LIB /MT /EHsc -I ..\include resfile_error.cpp /link ../lib/msparserS.lib ws2_32.lib advapi32.lib wininet.lib /OPT:NOREF
There is a cmd file,
build_all.cmd, in the C++ examples directory that builds all the examples.
mingw/lib directory contains three files:
|Static library without debugging information.|
|DLL for use with applications compiled using MinGW|
|Import library for use when compiling an application to be dynamically linked with |
To compile and link one of the example programs statically:
$ g++ -D _MATRIX_USE_STATIC_LIB -I ../include -L ../lib resfile_summary.cpp -lmsparser -lwininet
To compile and link one of the example programs dynamically:
$ g++ -I ../include -L ../lib resfile_summary.cpp -lmsparser_import
In this case, you will need to make sure that
msparser.dll is in the same directory as the
.exe file or is located on the system path.
|Copyright © 2016 Matrix Science Ltd. All Rights Reserved. Generated on Sat Apr 14 2018 01:45:12|