< prev index next >

src/share/vm/compiler/disassembler.cpp

Print this page
rev 9009 : 8136556: Add the ability to perform static builds of MacOSX x64 binaries
Reviewed-by: ihse, bdelsart, gadams, lfoltan, rriggs, hseigel, twisti

*** 86,103 **** --- 86,110 ---- char ebuf[1024]; char buf[JVM_MAXPATHLEN]; os::jvm_path(buf, sizeof(buf)); int jvm_offset = -1; int lib_offset = -1; + #ifdef STATIC_BUILD + char* p = strrchr(buf, '/'); + *p = '\0'; + strcat(p, "/lib/"); + lib_offset = jvm_offset = strlen(buf); + #else { // Match "jvm[^/]*" in jvm_path. const char* base = buf; const char* p = strrchr(buf, *os::file_separator()); if (p != NULL) lib_offset = p - base + 1; p = strstr(p ? p : base, "jvm"); if (p != NULL) jvm_offset = p - base; } + #endif // Find the disassembler shared library. // Search for several paths derived from libjvm, in this order: // 1. <home>/jre/lib/<arch>/<vm>/libhsdis-<arch>.so (for compatibility) // 2. <home>/jre/lib/<arch>/<vm>/hsdis-<arch>.so // 3. <home>/jre/lib/<arch>/hsdis-<arch>.so
< prev index next >