Changeset 395 for trunk/openjdk/hotspot
- Timestamp:
- Jul 18, 2012, 9:37:38 PM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/openjdk/hotspot/src/os/os2/vm/os_os2_init.cpp
r346 r395 28 28 // the Windows DllMain() and registers the DLL with Odin 29 29 30 #define INCL_DOS 31 #define INCL_ERRORS 30 32 #include <os2wrap.h> // Odin32 OS/2 api wrappers 31 33 #include <odinlx.h> … … 36 38 #include <emx/startup.h> 37 39 #endif 40 41 #include <string.h> 38 42 39 43 extern "C" BOOL WINAPI DllMain(HINSTANCE hinst, DWORD reason, LPVOID reserved); … … 72 76 CheckVersionFromHMOD(PE2LX_VERSION, hModule); 73 77 78 // Assuming that JVM.DLL is stored in a bin/<type>/ subdirectory (where 79 // type is e.g. "client"), we add this directory, as well as its parent 80 // (which contains all other Java DLLs), to BEGINLIBPATH so that the OS2 81 // DLL loader can satisfy DLL dependencies (i.e. find DLLs referred to 82 // by other DLLs through their import module table) when some Java DLLs 83 // (e.g. JAVA.DLL, JZIP.DLL) are dynamically loaded later by JVM.DLL. 84 // Note that despite the fact that JVM.DLL is already loaded at this 85 // point, we still need to add its directory to BEGINLIBPATH. This is 86 // bcause most likely it's been loaded by full path which does NOT make 87 // it locatable by the loader when referred to by name from the import 88 // table of some other DLL (like JAVA.DLL). 89 90 char dllpath[CCHMAXPATH + 16 /* ";%BEGINLIBPATH%" */]; 91 if (DosQueryModuleName(hModule, sizeof(dllpath), dllpath) == NO_ERROR) 92 { 93 char *end = strrchr(dllpath, '\\'); 94 if (end) 95 { 96 strcpy(end, ";%BEGINLIBPATH%"); 97 DosSetExtLIBPATH(dllpath, BEGIN_LIBPATH); 98 end = strrchr(dllpath, '\\'); 99 if (end) 100 { 101 strcpy(end, ";%BEGINLIBPATH%"); 102 DosSetExtLIBPATH(dllpath, BEGIN_LIBPATH); 103 } 104 } 105 } 106 74 107 #ifdef ODIN_FORCE_WIN32_TIB 75 108 // enable __try/__except support
Note:
See TracChangeset
for help on using the changeset viewer.