mirror of
git://sourceware.org/git/newlib-cygwin.git
synced 2025-01-19 04:49:25 +08:00
* autoload.cc (dll_load): Only perform DONT_RESOLVE_DLL_REFERENCES hack on
systems which need it. * wincap.cc (use_dont_resolve_hack): Set as appropriate. * wincap.h (use_dont_resolve_hack): Define.
This commit is contained in:
parent
8ceb4854b6
commit
ba5f92981d
@ -1,3 +1,10 @@
|
||||
2011-02-28 Christopher Faylor <me+cygwin@cgf.cx>
|
||||
|
||||
* autoload.cc (dll_load): Only perform DONT_RESOLVE_DLL_REFERENCES hack
|
||||
on systems which need it.
|
||||
* wincap.cc (use_dont_resolve_hack): Set as appropriate.
|
||||
* wincap.h (use_dont_resolve_hack): Define.
|
||||
|
||||
2011-02-28 Christopher Faylor <me+cygwin@cgf.cx>
|
||||
|
||||
* autoload.cc (dll_load): Make inline. Clarify logic.
|
||||
|
@ -216,7 +216,8 @@ static __inline bool
|
||||
dll_load (HANDLE& handle, WCHAR *name)
|
||||
{
|
||||
HANDLE h = LoadLibraryW (name);
|
||||
if (!h && in_forkee && handle && GetLastError () == ERROR_INVALID_ADDRESS)
|
||||
if (!h && in_forkee && handle && GetLastError () == ERROR_INVALID_ADDRESS
|
||||
&& wincap.use_dont_resolve_hack ())
|
||||
h = LoadLibraryExW (name, NULL, DONT_RESOLVE_DLL_REFERENCES);
|
||||
if (!h)
|
||||
return false;
|
||||
|
@ -61,6 +61,7 @@ wincaps wincap_nt4sp4 __attribute__((section (".cygwin_dll_common"), shared)) =
|
||||
has_buggy_thread_startup:false,
|
||||
has_fast_cwd:false,
|
||||
has_restricted_raw_disk_access:false,
|
||||
use_dont_resolve_hack:false,
|
||||
};
|
||||
|
||||
wincaps wincap_2000 __attribute__((section (".cygwin_dll_common"), shared)) = {
|
||||
@ -101,6 +102,7 @@ wincaps wincap_2000 __attribute__((section (".cygwin_dll_common"), shared)) = {
|
||||
has_buggy_thread_startup:false,
|
||||
has_fast_cwd:false,
|
||||
has_restricted_raw_disk_access:false,
|
||||
use_dont_resolve_hack:false,
|
||||
};
|
||||
|
||||
wincaps wincap_2000sp4 __attribute__((section (".cygwin_dll_common"), shared)) = {
|
||||
@ -141,6 +143,7 @@ wincaps wincap_2000sp4 __attribute__((section (".cygwin_dll_common"), shared)) =
|
||||
has_buggy_thread_startup:false,
|
||||
has_fast_cwd:false,
|
||||
has_restricted_raw_disk_access:false,
|
||||
use_dont_resolve_hack:false,
|
||||
};
|
||||
|
||||
wincaps wincap_xp __attribute__((section (".cygwin_dll_common"), shared)) = {
|
||||
@ -181,6 +184,7 @@ wincaps wincap_xp __attribute__((section (".cygwin_dll_common"), shared)) = {
|
||||
has_buggy_thread_startup:false,
|
||||
has_fast_cwd:false,
|
||||
has_restricted_raw_disk_access:false,
|
||||
use_dont_resolve_hack:true,
|
||||
};
|
||||
|
||||
wincaps wincap_xpsp1 __attribute__((section (".cygwin_dll_common"), shared)) = {
|
||||
@ -221,6 +225,7 @@ wincaps wincap_xpsp1 __attribute__((section (".cygwin_dll_common"), shared)) = {
|
||||
has_buggy_thread_startup:false,
|
||||
has_fast_cwd:false,
|
||||
has_restricted_raw_disk_access:false,
|
||||
use_dont_resolve_hack:true,
|
||||
};
|
||||
|
||||
wincaps wincap_xpsp2 __attribute__((section (".cygwin_dll_common"), shared)) = {
|
||||
@ -261,6 +266,7 @@ wincaps wincap_xpsp2 __attribute__((section (".cygwin_dll_common"), shared)) = {
|
||||
has_buggy_thread_startup:false,
|
||||
has_fast_cwd:false,
|
||||
has_restricted_raw_disk_access:false,
|
||||
use_dont_resolve_hack:true,
|
||||
};
|
||||
|
||||
wincaps wincap_2003 __attribute__((section (".cygwin_dll_common"), shared)) = {
|
||||
@ -301,6 +307,7 @@ wincaps wincap_2003 __attribute__((section (".cygwin_dll_common"), shared)) = {
|
||||
has_buggy_thread_startup:false,
|
||||
has_fast_cwd:false,
|
||||
has_restricted_raw_disk_access:false,
|
||||
use_dont_resolve_hack:false,
|
||||
};
|
||||
|
||||
wincaps wincap_vista __attribute__((section (".cygwin_dll_common"), shared)) = {
|
||||
@ -341,6 +348,7 @@ wincaps wincap_vista __attribute__((section (".cygwin_dll_common"), shared)) = {
|
||||
has_buggy_thread_startup:true,
|
||||
has_fast_cwd:true,
|
||||
has_restricted_raw_disk_access:true,
|
||||
use_dont_resolve_hack:false,
|
||||
};
|
||||
|
||||
wincaps wincap_7 __attribute__((section (".cygwin_dll_common"), shared)) = {
|
||||
@ -381,6 +389,7 @@ wincaps wincap_7 __attribute__((section (".cygwin_dll_common"), shared)) = {
|
||||
has_buggy_thread_startup:false,
|
||||
has_fast_cwd:true,
|
||||
has_restricted_raw_disk_access:true,
|
||||
use_dont_resolve_hack:false,
|
||||
};
|
||||
|
||||
wincapc wincap __attribute__((section (".cygwin_dll_common"), shared));
|
||||
|
@ -51,6 +51,7 @@ struct wincaps
|
||||
unsigned has_buggy_thread_startup : 1;
|
||||
unsigned has_fast_cwd : 1;
|
||||
unsigned has_restricted_raw_disk_access : 1;
|
||||
unsigned use_dont_resolve_hack : 1;
|
||||
};
|
||||
|
||||
class wincapc
|
||||
@ -107,6 +108,7 @@ public:
|
||||
bool IMPLEMENT (has_buggy_thread_startup)
|
||||
bool IMPLEMENT (has_fast_cwd)
|
||||
bool IMPLEMENT (has_restricted_raw_disk_access)
|
||||
bool IMPLEMENT (use_dont_resolve_hack)
|
||||
|
||||
#undef IMPLEMENT
|
||||
};
|
||||
|
Loading…
x
Reference in New Issue
Block a user