add wrapper entry points to allow toolboxes to not link against core.lib instead... 83/10683/3
Antoine ELIAS [Mon, 4 Mar 2013 15:31:27 +0000 (16:31 +0100)]
Change-Id: I5aa0bde6ab7d95a9e783919b3bf79ef93b3926b6

scilab/bin/bin.iss
scilab/modules/core/includes/getmaxMALLOC.h
scilab/modules/core/includes/win_mem_alloc.h
scilab/modules/core/src/c/win_mem_alloc.c

index b52f52a..7bb93e0 100644 (file)
@@ -55,6 +55,9 @@ Source: bin\pcreposix.dll; DestDir: {app}\bin; Components: {#COMPN_SCILAB}
 Source: bin\libf2c.lib; DestDir: {app}\bin; Components: {#COMPN_SCILAB}
 Source: bin\lapack.lib; DestDir: {app}\bin; Components: {#COMPN_SCILAB}
 ;
+Source: bin\MALLOC.lib; DestDir: {app}\bin; Components: {#COMPN_SCILAB}
+Source: bin\MALLOC.dll; DestDir: {app}\bin; Components: {#COMPN_SCILAB}
+;
 Source: bin\scilab_windows.lib; DestDir: {app}\bin; Components: {#COMPN_SCILAB}
 ;
 Source: bin\Scilex.exe; DestDir: {app}\bin; Components: {#COMPN_SCILAB}
index 2c9408c..70ba1b3 100644 (file)
@@ -13,6 +13,7 @@
 #define __GETMAXMALLOC_H__
 /*-----------------------------------------------------------------------------------*/
 unsigned long GetLargestFreeMemoryRegion(void);
+unsigned long GetLargestFreeMemoryRegion2(void);
 
 #endif /* __GETMAXMALLOC_H__ */
 /*-----------------------------------------------------------------------------------*/
index 3b49787..5a2585b 100644 (file)
@@ -27,6 +27,11 @@ void MyHeapFree(void *lpAddress, char *file, int line);
 void *MyVirtualAlloc(size_t dwSize, char *file, int line);
 void MyVirtualFree(void *lpAddress, char *file, int line);
 
+void *MyHeapRealloc2(void *lpAddress, size_t dwSize, char *file, int line);
+void *MyHeapAlloc2(size_t dwSize, char *file, int line);
+void MyHeapFree2(void *lpAddress, char *file, int line);
+void *MyVirtualAlloc2(size_t dwSize, char *file, int line);
+void MyVirtualFree2(void *lpAddress, char *file, int line);
 
 
 #ifdef MALLOC
index 3f1402b..7914f10 100644 (file)
@@ -164,3 +164,28 @@ void MyVirtualFree(void *lpAddress, char *file, int line)
     }
 }
 /*-----------------------------------------------------------------------------------*/
+void *MyHeapRealloc2(void *lpAddress, size_t dwSize, char *file, int line)
+{
+    return MyHeapRealloc(lpAddress, dwSize, file, line);
+}
+
+void *MyHeapAlloc2(size_t dwSize, char *file, int line)
+{
+    return MyHeapAlloc(dwSize, file, line);
+}
+
+void MyHeapFree2(void *lpAddress, char *file, int line)
+{
+    MyHeapFree(lpAddress, file, line);
+}
+
+void *MyVirtualAlloc2(size_t dwSize, char *file, int line)
+{
+    return MyVirtualAlloc(dwSize, file, line);
+}
+
+void MyVirtualFree2(void *lpAddress, char *file, int line)
+{
+    MyVirtualFree(lpAddress, file, line);
+}
+