better way to do dll (dynamic_link module)
Allan CORNET [Thu, 27 Aug 2009 14:25:15 +0000 (16:25 +0200)]
scilab/modules/dynamic_link/Makefile.am
scilab/modules/dynamic_link/includes/AddFunctionInTable.h
scilab/modules/dynamic_link/includes/addinter.h
scilab/modules/dynamic_link/includes/dynamic_link.h
scilab/modules/dynamic_link/includes/dynlib_dynamic_link.h [new file with mode: 0644]
scilab/modules/dynamic_link/includes/gw_dynamic_link.h
scilab/modules/dynamic_link/includes/ilib_verbose.h
scilab/modules/dynamic_link/src/c/dynamic_link.vcproj
scilab/modules/dynamic_link/src/c/dynamic_link_header.def [deleted file]

index b51b81b..562a1b3 100644 (file)
@@ -62,6 +62,7 @@ libscidynamic_link_la_include_HEADERS = includes/AddFunctionInTable.h \
 includes/addinter.h \
 includes/dynamic_link.h \
 includes/gw_dynamic_link.h \
+includes/dynlib_dynamic_link.h \
 includes/ilib_verbose.h 
 
 #### dynamic_link : compilation scripts #### 
index f7587ab..683ea4f 100644 (file)
@@ -15,6 +15,7 @@
 #ifndef __ADDFUNCTIONINTABLE_H__
 #define __ADDFUNCTIONINTABLE_H__
 
+#include "dynlib_dynamic_link.h"
 
 typedef void (*voidf)();
 
@@ -34,7 +35,7 @@ typedef struct {
 * @param table functions hashtable
 * @return a pointer on function in functions hashtable
 */
-voidf AddFunctionInTable (char *name, int *rep, FTAB *table);  
+DYNAMIC_LINK_IMPEXP voidf AddFunctionInTable (char *name, int *rep, FTAB *table);  
 
 #endif /* __ADDFUNCTIONINTABLE_H__ */
 /*--------------------------------------------------------------------------*/
index 7b8f961..12bd474 100644 (file)
@@ -13,6 +13,8 @@
 #ifndef __ADDINTER_H__
 #define  __ADDINTER_H__
 
+#include "dynlib_dynamic_link.h"
+
 /** 
 * the first dynamic interface is at position 500+1 
 */
@@ -32,7 +34,7 @@
 * Remove interface in scilab
 * @param[in] id of interface
 */
-void RemoveInterf(int id);
+DYNAMIC_LINK_IMPEXP void RemoveInterf(int id);
 
 /**
 * Add a interface in Scilab
@@ -42,6 +44,11 @@ void RemoveInterf(int id);
 * @param[in] sizefcts size of fcts array
 * @return a int id of interface (-1 failed)
 */
-int AddInterfaceToScilab(char *filenamelib,char *spname,char **fcts,int sizefcts);
+DYNAMIC_LINK_IMPEXP int AddInterfaceToScilab(char *filenamelib,char *spname,char **fcts,int sizefcts);
+
+/**
+* TO DO: comments 
+*/
+DYNAMIC_LINK_IMPEXP void C2F(userlk)(int *k);
 
 #endif /*  __ADDINTER_H__ */
index 6139374..d61981a 100644 (file)
@@ -14,6 +14,7 @@
 #ifndef __DYNAMIC_LINK_H__
 #define __DYNAMIC_LINK_H__
 
+#include "dynlib_dynamic_link.h"
 #include "BOOL.h"
 #include "machine.h" /* C2F */
 
@@ -22,7 +23,7 @@
 /**
 * Initialize tables 
 */
-void initializeLink(void);
+DYNAMIC_LINK_IMPEXP void initializeLink(void);
 
 /**
 * check that a routine name is a loaded
@@ -36,7 +37,7 @@ void initializeLink(void);
 * @param[in/out] ilib number in the function table (-1 if FALSE)
 * @return a BOOL
 */
-BOOL c_link(char *routinename,int *ilib);
+DYNAMIC_LINK_IMPEXP BOOL c_link(char *routinename,int *ilib);
 
 /**
 * OBSOLETE 
@@ -48,7 +49,7 @@ BOOL c_link(char *routinename,int *ilib);
 * @param[in] routinename
 * @param[in/out] ilib
 */
-void C2F(iislink)(char *routinename, int *ilib);
+DYNAMIC_LINK_IMPEXP void C2F(iislink)(char *routinename, int *ilib);
 
 
 /**
@@ -56,7 +57,7 @@ void C2F(iislink)(char *routinename, int *ilib);
 * @param ii
 * @param ptr on functions
 */
-void GetDynFunc(int ii, void (**realop) ());
+DYNAMIC_LINK_IMPEXP void GetDynFunc(int ii, void (**realop) ());
 
 /**
 * Search a function in the table 
@@ -64,23 +65,23 @@ void GetDynFunc(int ii, void (**realop) ());
 * @param 
 * @param 
 */
-int SearchInDynLinks(char *op, void (**realop) ());
+DYNAMIC_LINK_IMPEXP int SearchInDynLinks(char *op, void (**realop) ());
 
 /**
 * Show the linked files 
 */
-void ShowDynLinks(void);
+DYNAMIC_LINK_IMPEXP void ShowDynLinks(void);
 
 /**
 * unlink all linked files 
 */
-void unlinkallsharedlib(void);
+DYNAMIC_LINK_IMPEXP void unlinkallsharedlib(void);
 
 /**
 * Unlink a shared lib 
 * @param i (number of shared lib)
 */
-void unlinksharedlib(int *i);
+DYNAMIC_LINK_IMPEXP void unlinksharedlib(int *i);
 
 
 /**
@@ -89,27 +90,27 @@ void unlinksharedlib(int *i);
 * return value is == -1 if the LoadDynLibrary failed 
 * @param loaded_file
 */
-int Sci_dlopen( char *loaded_file);
+DYNAMIC_LINK_IMPEXP int Sci_dlopen( char *loaded_file);
 
 /**
 * This routine load the entryname ename 
 * from shared lib ishared 
 * @return TRUE or FALSE
 */
-BOOL Sci_dlsym(char *ename,int ishared,char *strf);
+DYNAMIC_LINK_IMPEXP BOOL Sci_dlsym(char *ename,int ishared,char *strf);
 
 /**
 * Delete entry points associated with shared lib ishared
 * then delete the shared lib 
 @param ishared
 */
-void Sci_Delsym(int ishared);
+DYNAMIC_LINK_IMPEXP void Sci_Delsym(int ishared);
 
 /**
 * @param sizearray returns size of string array returned
 * @return string array with functions names loaded
 */
-char **getNamesOfFunctionsInSharedLibraries(int *sizearray);
+DYNAMIC_LINK_IMPEXP char **getNamesOfFunctionsInSharedLibraries(int *sizearray);
 
 /**
 * call link for scilab
@@ -121,7 +122,7 @@ char **getNamesOfFunctionsInSharedLibraries(int *sizearray);
 * @param ierr (last error)
 * @return id 
 */
-int scilabLink(int idsharedlibrary,
+DYNAMIC_LINK_IMPEXP int scilabLink(int idsharedlibrary,
                           char *filename,
                           char **subnamesarray,int sizesubnamesarray,
                           BOOL fflag,int *ierr);
@@ -131,7 +132,7 @@ int scilabLink(int idsharedlibrary,
 * @param size of returned list
 * @return list of Id
 */
-int *getAllIdSharedLib(int *sizeList);
+DYNAMIC_LINK_IMPEXP int *getAllIdSharedLib(int *sizeList);
 
 #endif /* __DYNAMIC_LINK_H__ */
 /*-----------------------------------------------------------------------------------*/
diff --git a/scilab/modules/dynamic_link/includes/dynlib_dynamic_link.h b/scilab/modules/dynamic_link/includes/dynlib_dynamic_link.h
new file mode 100644 (file)
index 0000000..d874ec0
--- /dev/null
@@ -0,0 +1,29 @@
+/*
+* Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
+* Copyright (C) DIGITEO - 2009 - Allan CORNET
+* 
+* This file must be used under the terms of the CeCILL.
+* This source file is licensed as described in the file COPYING, which
+* you should have received as part of this distribution.  The terms
+* are also available at    
+* http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+*
+*/
+
+/*--------------------------------------------------------------------------*/ 
+#ifndef __DYNLIB_DYNAMIC_LINK_H__
+#define __DYNLIB_DYNAMIC_LINK_H__
+
+#ifdef _MSC_VER
+#ifdef DYNAMIC_LINK_EXPORTS
+#define DYNAMIC_LINK_IMPEXP __declspec(dllexport)
+#else
+#define DYNAMIC_LINK_IMPEXP __declspec(dllimport)
+#endif
+#else
+#define DYNAMIC_LINK_IMPEXP
+#endif
+
+#endif /* __DYNLIB_DYNAMIC_LINK_H__ */
+/*--------------------------------------------------------------------------*/ 
+
index 84587f3..0867571 100644 (file)
 #ifndef __GW_DYNAMIC_LINK__
 #define __GW_DYNAMIC_LINK__
 
+#include "dynlib_dynamic_link.h"
 #include "api_common.h"
 /*--------------------------------------------------------------------------*/ 
-int gw_dynamic_link(void);
+DYNAMIC_LINK_IMPEXP int gw_dynamic_link(void);
 /*--------------------------------------------------------------------------*/
 /* Declaration of all the profile function declared and */
 /* used in sci_gateway */
 /*--------------------------------------------------------------------------*/ 
-int sci_getdynlibext(char *fname,unsigned long fname_len);
-int sci_addinter(char *fname,unsigned long fname_len);
-int sci_fort(char *fname,unsigned long fname_len);
-int sci_call(char *fname,unsigned long fname_len);
-int sci_link(char *fname,unsigned long fname_len);
-int sci_ulink(char *fname,unsigned long fname_len);
-int sci_c_link(char *fname,unsigned long fname_len);
-int sci_ilib_verbose(char *fname,unsigned long fname_len);
+DYNAMIC_LINK_IMPEXP int sci_getdynlibext(char *fname,unsigned long fname_len);
+DYNAMIC_LINK_IMPEXP int sci_addinter(char *fname,unsigned long fname_len);
+DYNAMIC_LINK_IMPEXP int sci_fort(char *fname,unsigned long fname_len);
+DYNAMIC_LINK_IMPEXP int sci_call(char *fname,unsigned long fname_len);
+DYNAMIC_LINK_IMPEXP int sci_link(char *fname,unsigned long fname_len);
+DYNAMIC_LINK_IMPEXP int sci_ulink(char *fname,unsigned long fname_len);
+DYNAMIC_LINK_IMPEXP int sci_c_link(char *fname,unsigned long fname_len);
+DYNAMIC_LINK_IMPEXP int sci_ilib_verbose(char *fname,unsigned long fname_len);
 /*--------------------------------------------------------------------------*/ 
 #endif /* __GW_DYNAMIC_LINK__ */
 /*--------------------------------------------------------------------------*/ 
index 4ec5183..c7f652f 100644 (file)
@@ -14,6 +14,7 @@
 #ifndef __ILIB_VERBOSE_H__
 #define __ILIB_VERBOSE_H__
 
+#include "dynlib_dynamic_link.h"
 #include "BOOL.h"
 #include "machine.h"
 
@@ -28,19 +29,19 @@ typedef enum {
 * @param[in] level
 * @return TRUE if level is modified
 */
-BOOL setIlibVerboseLevel(ilib_verbose_level _level);
+DYNAMIC_LINK_IMPEXP BOOL setIlibVerboseLevel(ilib_verbose_level _level);
 
 /**
 * get verbose level for dynamic link functions
 * @return level
 */
-ilib_verbose_level getIlibVerboseLevel(void);
+DYNAMIC_LINK_IMPEXP ilib_verbose_level getIlibVerboseLevel(void);
 
 /**
 * get verbose level for dynamic link functions (for fortran external subroutines)
 * @param[out] level
 */
-int C2F(getilibverboselevel)(int *_level);
+DYNAMIC_LINK_IMPEXP int C2F(getilibverboselevel)(int *_level);
 
 #endif /* __ILIB_VERBOSE_H__ */
 /*---------------------------------------------------------------------------*/
index 64e0971..5e4828e 100644 (file)
                        <Tool
                                Name="VCPreLinkEventTool"
                                Description="Make dependencies"
-                               CommandLine="lib /DEF:&quot;$(InputDir)LibScilab_Import.def&quot; /SUBSYSTEM:WINDOWS /MACHINE:X86 /OUT:&quot;$(InputDir)LibScilab.lib&quot; 1&gt;NUL 2&gt;NUL&#x0D;&#x0A;lib /DEF:&quot;$(InputDir)dynamic_link_f_Import.def&quot; /SUBSYSTEM:WINDOWS /MACHINE:X86 /OUT:&quot;$(InputDir)dynamic_link_f.lib&quot; 1&gt;NUL 2&gt;NUL&#x0D;&#x0A;lib /DEF:&quot;$(InputDir)Io_Import.def&quot; /SUBSYSTEM:WINDOWS /MACHINE:X86 /OUT:&quot;$(InputDir)Io.lib&quot; 1&gt;NUL 2&gt;NUL&#x0D;&#x0A;lib /DEF:&quot;$(InputDir)Scilab_Windows_Import.def&quot; /SUBSYSTEM:WINDOWS /MACHINE:X86 /OUT:&quot;$(InputDir)Scilab_windows.lib&quot; 1&gt;NUL 2&gt;NUL&#x0D;&#x0A;cd $(IntDir) &gt;nul&#x0D;&#x0A;for %%f in (*.obj) do  ..\..\..\..\..\bin\dumpexts -o %%~nf.def -n dynamic_link.dll %%f &gt;nul&#x0D;&#x0A;copy *.def dynamic_linktmp.def &gt;nul&#x0D;&#x0A;copy ..\dynamic_link_header.def+dynamic_linktmp.def  ..\dynamic_link.def &gt;nul&#x0D;&#x0A;del *.def &gt;nul&#x0D;&#x0A;cd .. &gt;nul&#x0D;&#x0A;"
+                               CommandLine="lib /DEF:&quot;$(InputDir)LibScilab_Import.def&quot; /SUBSYSTEM:WINDOWS /MACHINE:X86 /OUT:&quot;$(InputDir)LibScilab.lib&quot; 1&gt;NUL 2&gt;NUL&#x0D;&#x0A;lib /DEF:&quot;$(InputDir)dynamic_link_f_Import.def&quot; /SUBSYSTEM:WINDOWS /MACHINE:X86 /OUT:&quot;$(InputDir)dynamic_link_f.lib&quot; 1&gt;NUL 2&gt;NUL&#x0D;&#x0A;lib /DEF:&quot;$(InputDir)Io_Import.def&quot; /SUBSYSTEM:WINDOWS /MACHINE:X86 /OUT:&quot;$(InputDir)Io.lib&quot; 1&gt;NUL 2&gt;NUL&#x0D;&#x0A;lib /DEF:&quot;$(InputDir)Scilab_Windows_Import.def&quot; /SUBSYSTEM:WINDOWS /MACHINE:X86 /OUT:&quot;$(InputDir)Scilab_windows.lib&quot; 1&gt;NUL 2&gt;NUL&#x0D;&#x0A;"
                        />
                        <Tool
                                Name="VCLinkerTool"
                                AdditionalDependencies="LibScilab.lib dynamic_link_f.lib io.lib scilab_windows.lib"
                                OutputFile="../../../../bin/$(ProjectName).dll"
                                LinkIncremental="1"
-                               ModuleDefinitionFile="dynamic_link.def"
+                               ModuleDefinitionFile=""
                                GenerateDebugInformation="true"
                                SubSystem="2"
                                RandomizedBaseAddress="1"
                        <Tool
                                Name="VCPreLinkEventTool"
                                Description="Make dependencies"
-                               CommandLine="lib /DEF:&quot;$(InputDir)LibScilab_Import.def&quot; /SUBSYSTEM:WINDOWS /MACHINE:X64 /OUT:&quot;$(InputDir)LibScilab.lib&quot; 1&gt;NUL 2&gt;NUL&#x0D;&#x0A;lib /DEF:&quot;$(InputDir)dynamic_link_f_Import.def&quot; /SUBSYSTEM:WINDOWS /MACHINE:X64 /OUT:&quot;$(InputDir)dynamic_link_f.lib&quot; 1&gt;NUL 2&gt;NUL&#x0D;&#x0A;lib /DEF:&quot;$(InputDir)Io_Import.def&quot; /SUBSYSTEM:WINDOWS /MACHINE:X64 /OUT:&quot;$(InputDir)Io.lib&quot; 1&gt;NUL 2&gt;NUL&#x0D;&#x0A;lib /DEF:&quot;$(InputDir)Scilab_Windows_Import.def&quot; /SUBSYSTEM:WINDOWS /MACHINE:X64 /OUT:&quot;$(InputDir)Scilab_windows.lib&quot; 1&gt;NUL 2&gt;NUL&#x0D;&#x0A;cd $(IntDir) &gt;nul&#x0D;&#x0A;for %%f in (*.obj) do  ..\..\..\..\..\bin\dumpexts -o %%~nf.def -n dynamic_link.dll %%f &gt;nul&#x0D;&#x0A;copy *.def dynamic_linktmp.def &gt;nul&#x0D;&#x0A;copy ..\dynamic_link_header.def+dynamic_linktmp.def  ..\dynamic_link.def &gt;nul&#x0D;&#x0A;del *.def &gt;nul&#x0D;&#x0A;cd .. &gt;nul&#x0D;&#x0A;"
+                               CommandLine="lib /DEF:&quot;$(InputDir)LibScilab_Import.def&quot; /SUBSYSTEM:WINDOWS /MACHINE:X64 /OUT:&quot;$(InputDir)LibScilab.lib&quot; 1&gt;NUL 2&gt;NUL&#x0D;&#x0A;lib /DEF:&quot;$(InputDir)dynamic_link_f_Import.def&quot; /SUBSYSTEM:WINDOWS /MACHINE:X64 /OUT:&quot;$(InputDir)dynamic_link_f.lib&quot; 1&gt;NUL 2&gt;NUL&#x0D;&#x0A;lib /DEF:&quot;$(InputDir)Io_Import.def&quot; /SUBSYSTEM:WINDOWS /MACHINE:X64 /OUT:&quot;$(InputDir)Io.lib&quot; 1&gt;NUL 2&gt;NUL&#x0D;&#x0A;lib /DEF:&quot;$(InputDir)Scilab_Windows_Import.def&quot; /SUBSYSTEM:WINDOWS /MACHINE:X64 /OUT:&quot;$(InputDir)Scilab_windows.lib&quot; 1&gt;NUL 2&gt;NUL&#x0D;&#x0A;"
                        />
                        <Tool
                                Name="VCLinkerTool"
                                AdditionalDependencies="LibScilab.lib dynamic_link_f.lib io.lib scilab_windows.lib"
                                OutputFile="../../../../bin/$(ProjectName).dll"
                                LinkIncremental="1"
-                               ModuleDefinitionFile="dynamic_link.def"
+                               ModuleDefinitionFile=""
                                GenerateDebugInformation="true"
                                SubSystem="2"
                                RandomizedBaseAddress="1"
                        <Tool
                                Name="VCPreLinkEventTool"
                                Description="Make dependencies"
-                               CommandLine="lib /DEF:&quot;$(InputDir)LibScilab_Import.def&quot; /SUBSYSTEM:WINDOWS /MACHINE:X86 /OUT:&quot;$(InputDir)LibScilab.lib&quot; 1&gt;NUL 2&gt;NUL&#x0D;&#x0A;lib /DEF:&quot;$(InputDir)dynamic_link_f_Import.def&quot; /SUBSYSTEM:WINDOWS /MACHINE:X86 /OUT:&quot;$(InputDir)dynamic_link_f.lib&quot; 1&gt;NUL 2&gt;NUL&#x0D;&#x0A;lib /DEF:&quot;$(InputDir)Io_Import.def&quot; /SUBSYSTEM:WINDOWS /MACHINE:X86 /OUT:&quot;$(InputDir)Io.lib&quot; 1&gt;NUL 2&gt;NUL&#x0D;&#x0A;lib /DEF:&quot;$(InputDir)Scilab_Windows_Import.def&quot; /SUBSYSTEM:WINDOWS /MACHINE:X86 /OUT:&quot;$(InputDir)Scilab_windows.lib&quot; 1&gt;NUL 2&gt;NUL&#x0D;&#x0A;cd $(IntDir) &gt;nul&#x0D;&#x0A;for %%f in (*.obj) do  ..\..\..\..\..\bin\dumpexts -o %%~nf.def -n dynamic_link.dll %%f &gt;nul&#x0D;&#x0A;copy *.def dynamic_linktmp.def &gt;nul&#x0D;&#x0A;copy ..\dynamic_link_header.def+dynamic_linktmp.def  ..\dynamic_link.def &gt;nul&#x0D;&#x0A;del *.def &gt;nul&#x0D;&#x0A;cd .. &gt;nul&#x0D;&#x0A;"
+                               CommandLine="lib /DEF:&quot;$(InputDir)LibScilab_Import.def&quot; /SUBSYSTEM:WINDOWS /MACHINE:X86 /OUT:&quot;$(InputDir)LibScilab.lib&quot; 1&gt;NUL 2&gt;NUL&#x0D;&#x0A;lib /DEF:&quot;$(InputDir)dynamic_link_f_Import.def&quot; /SUBSYSTEM:WINDOWS /MACHINE:X86 /OUT:&quot;$(InputDir)dynamic_link_f.lib&quot; 1&gt;NUL 2&gt;NUL&#x0D;&#x0A;lib /DEF:&quot;$(InputDir)Io_Import.def&quot; /SUBSYSTEM:WINDOWS /MACHINE:X86 /OUT:&quot;$(InputDir)Io.lib&quot; 1&gt;NUL 2&gt;NUL&#x0D;&#x0A;lib /DEF:&quot;$(InputDir)Scilab_Windows_Import.def&quot; /SUBSYSTEM:WINDOWS /MACHINE:X86 /OUT:&quot;$(InputDir)Scilab_windows.lib&quot; 1&gt;NUL 2&gt;NUL&#x0D;&#x0A;"
                        />
                        <Tool
                                Name="VCLinkerTool"
                                AdditionalDependencies="LibScilab.lib dynamic_link_f.lib io.lib scilab_windows.lib"
                                OutputFile="../../../../bin/$(ProjectName).dll"
                                LinkIncremental="1"
-                               ModuleDefinitionFile="dynamic_link.def"
+                               ModuleDefinitionFile=""
                                GenerateDebugInformation="false"
                                SubSystem="2"
                                OptimizeReferences="2"
                        <Tool
                                Name="VCPreLinkEventTool"
                                Description="Make dependencies"
-                               CommandLine="lib /DEF:&quot;$(InputDir)LibScilab_Import.def&quot; /SUBSYSTEM:WINDOWS /MACHINE:X64 /OUT:&quot;$(InputDir)LibScilab.lib&quot; 1&gt;NUL 2&gt;NUL&#x0D;&#x0A;lib /DEF:&quot;$(InputDir)dynamic_link_f_Import.def&quot; /SUBSYSTEM:WINDOWS /MACHINE:X64 /OUT:&quot;$(InputDir)dynamic_link_f.lib&quot; 1&gt;NUL 2&gt;NUL&#x0D;&#x0A;lib /DEF:&quot;$(InputDir)Io_Import.def&quot; /SUBSYSTEM:WINDOWS /MACHINE:X64 /OUT:&quot;$(InputDir)Io.lib&quot; 1&gt;NUL 2&gt;NUL&#x0D;&#x0A;lib /DEF:&quot;$(InputDir)Scilab_Windows_Import.def&quot; /SUBSYSTEM:WINDOWS /MACHINE:X64 /OUT:&quot;$(InputDir)Scilab_windows.lib&quot; 1&gt;NUL 2&gt;NUL&#x0D;&#x0A;cd $(IntDir) &gt;nul&#x0D;&#x0A;for %%f in (*.obj) do  ..\..\..\..\..\bin\dumpexts -o %%~nf.def -n dynamic_link.dll %%f &gt;nul&#x0D;&#x0A;copy *.def dynamic_linktmp.def &gt;nul&#x0D;&#x0A;copy ..\dynamic_link_header.def+dynamic_linktmp.def  ..\dynamic_link.def &gt;nul&#x0D;&#x0A;del *.def &gt;nul&#x0D;&#x0A;cd .. &gt;nul&#x0D;&#x0A;"
+                               CommandLine="lib /DEF:&quot;$(InputDir)LibScilab_Import.def&quot; /SUBSYSTEM:WINDOWS /MACHINE:X64 /OUT:&quot;$(InputDir)LibScilab.lib&quot; 1&gt;NUL 2&gt;NUL&#x0D;&#x0A;lib /DEF:&quot;$(InputDir)dynamic_link_f_Import.def&quot; /SUBSYSTEM:WINDOWS /MACHINE:X64 /OUT:&quot;$(InputDir)dynamic_link_f.lib&quot; 1&gt;NUL 2&gt;NUL&#x0D;&#x0A;lib /DEF:&quot;$(InputDir)Io_Import.def&quot; /SUBSYSTEM:WINDOWS /MACHINE:X64 /OUT:&quot;$(InputDir)Io.lib&quot; 1&gt;NUL 2&gt;NUL&#x0D;&#x0A;lib /DEF:&quot;$(InputDir)Scilab_Windows_Import.def&quot; /SUBSYSTEM:WINDOWS /MACHINE:X64 /OUT:&quot;$(InputDir)Scilab_windows.lib&quot; 1&gt;NUL 2&gt;NUL&#x0D;&#x0A;"
                        />
                        <Tool
                                Name="VCLinkerTool"
                                AdditionalDependencies="LibScilab.lib dynamic_link_f.lib io.lib scilab_windows.lib"
                                OutputFile="../../../../bin/$(ProjectName).dll"
                                LinkIncremental="1"
-                               ModuleDefinitionFile="dynamic_link.def"
+                               ModuleDefinitionFile=""
                                GenerateDebugInformation="false"
                                SubSystem="2"
                                OptimizeReferences="2"
                                >
                        </File>
                        <File
+                               RelativePath="..\..\includes\dynlib_dynamic_link.h"
+                               >
+                       </File>
+                       <File
                                RelativePath="..\..\includes\gw_dynamic_link.h"
                                >
                        </File>
                                >
                        </File>
                        <File
-                               RelativePath=".\dynamic_link_header.def"
-                               >
-                       </File>
-                       <File
                                RelativePath=".\Io_Import.def"
                                >
                        </File>
diff --git a/scilab/modules/dynamic_link/src/c/dynamic_link_header.def b/scilab/modules/dynamic_link/src/c/dynamic_link_header.def
deleted file mode 100644 (file)
index c937ef9..0000000
+++ /dev/null
@@ -1,7 +0,0 @@
-LIBRARY   dynamic_link.dll
-
-
-EXPORTS
-; --------------------------------------- 
-; dynamic_link
-; ---------------------------------------