...
- Users may wish to conceal IP when working in the UCM on a Windows target, More and more users build models in the Windows version of HYPERSIM and would like to verify the result offline first.
- In this case, knowing how to create a library on a Windows target becomes necessary.
- Note that the variable {HYPERSIM_DIR} is in this case the installation directory of HYPERSIM. By default, it should be something like: C:\OPAL-RT\HYPERSIM\hypersim_R6.0.XX.oYYY
- Note that the variable {TOOLS_MINGW} is in this case the installation directory of HYPERSIM. By default, it should be something like C:\OPAL-RT\HYPERSIM\tools\MinGW\X.X.X
- Note that the library paths are absolute. Each time the library file path is changed (it is moved or the simulation is used on another computer), the paths in the .def file must be updated.
...
- Open a command-line window and go to the directory where your C code is located
- Generate the .o file by replacing 'test' below with your filename
{HYPERSIMTOOLS_DIR}\Windows\MinGW\bin\MINGW}/bin/gcc -c test.c -o test.o
- Generate the dll file using the following command.
- By convention, the DLL file should be lib{name of your lib}.dll.
- In this case the library name is test. The .lib file name is
{HYPERSIMTOOLS_DIR}\Windows\MinGW\bin\MINGW}/bin/gcc -shared -o libtest.dll test.o
...
- Open a command-line window and go to the directory where your C code resides
- Generate the .o file by replacing test with your filename
{HYPERSIMTOOLS_DIRMINGW}\Windows\MinGW\bin\ gcc -c test.c -o test.o
- Generate the lib file using the following, replacing libtest and test as required
{HYPERSIMTOOLS_DIRMINGW}\Windows\MinGW\bin\ar -rcs libtest.lib test.o
...