* fhandler_registry.cc: Drop Mingw.org considerations.

* fhandler_serial.cc: Ditto.
	* fhandler_socket.cc: Ditto.
	* fhandler_tape.cc: Ditto.
	* fhandler_tty.cc: Ditto.
	* net.cc: Ditto.
	* ntdll.h: Ditto.
	* sched.cc: Ditto.
	* sec_helper.cc: Ditto.
This commit is contained in:
Corinna Vinschen 2012-11-26 13:28:53 +00:00
parent 3afc3efbab
commit 5ab123f4aa
10 changed files with 14 additions and 128 deletions

View File

@ -1,3 +1,15 @@
2012-11-26 Corinna Vinschen <corinna@vinschen.de>
* fhandler_registry.cc: Drop Mingw.org considerations.
* fhandler_serial.cc: Ditto.
* fhandler_socket.cc: Ditto.
* fhandler_tape.cc: Ditto.
* fhandler_tty.cc: Ditto.
* net.cc: Ditto.
* ntdll.h: Ditto.
* sched.cc: Ditto.
* sec_helper.cc: Ditto.
2012-11-23 Christopher Faylor <me.cygwin2012@cgf.cx> 2012-11-23 Christopher Faylor <me.cygwin2012@cgf.cx>
* configure.in: Remove unneeded ALLOC substitution. * configure.in: Remove unneeded ALLOC substitution.

View File

@ -77,13 +77,6 @@ static const HKEY registry_keys[] =
static const int ROOT_KEY_COUNT = sizeof (registry_keys) / sizeof (HKEY); static const int ROOT_KEY_COUNT = sizeof (registry_keys) / sizeof (HKEY);
#ifndef __MINGW64_VERSION_MAJOR
extern "C" {
LONG WINAPI RegOpenUserClassesRoot (HANDLE, DWORD, REGSAM, PHKEY);
LONG WINAPI RegOpenCurrentUser (REGSAM, PHKEY);
};
#endif
/* Make sure to access the correct per-user HKCR and HKCU hives, even if /* Make sure to access the correct per-user HKCR and HKCU hives, even if
the current user is only impersonated in another user's session. */ the current user is only impersonated in another user's session. */
static HKEY static HKEY

View File

@ -19,12 +19,8 @@ details. */
#include "sigproc.h" #include "sigproc.h"
#include "pinfo.h" #include "pinfo.h"
#include <asm/socket.h> #include <asm/socket.h>
#ifdef __MINGW64_VERSION_MAJOR
#include <devioctl.h> #include <devioctl.h>
#include <ntddser.h> #include <ntddser.h>
#else
#include <ddk/ntddser.h>
#endif
#include "cygwait.h" #include "cygwait.h"
/**********************************************************************/ /**********************************************************************/

View File

@ -1349,17 +1349,6 @@ fhandler_socket::readv (const struct iovec *const iov, const int iovcnt,
return recv_internal (&wsamsg, false); return recv_internal (&wsamsg, false);
} }
extern "C" {
#ifndef __MINGW64_VERSION_MAJOR
#define WSAID_WSARECVMSG \
{0xf689d7c8,0x6f1f,0x436b,{0x8a,0x53,0xe5,0x4f,0xe3,0x51,0xc3,0x22}};
typedef int (WSAAPI *LPFN_WSARECVMSG)(SOCKET,LPWSAMSG,LPDWORD,LPWSAOVERLAPPED,
LPWSAOVERLAPPED_COMPLETION_ROUTINE);
#endif
int WSAAPI WSASendMsg(SOCKET,LPWSAMSG,DWORD,LPDWORD, LPWSAOVERLAPPED,
LPWSAOVERLAPPED_COMPLETION_ROUTINE);
};
/* There's no DLL which exports the symbol WSARecvMsg. One has to call /* There's no DLL which exports the symbol WSARecvMsg. One has to call
WSAIoctl as below to fetch the function pointer. Why on earth did the WSAIoctl as below to fetch the function pointer. Why on earth did the
MS developers decide not to export a normal symbol for these extension MS developers decide not to export a normal symbol for these extension

View File

@ -15,12 +15,8 @@ details. */
#include <stdlib.h> #include <stdlib.h>
#include <sys/mtio.h> #include <sys/mtio.h>
#include <sys/param.h> #include <sys/param.h>
#ifdef __MINGW64_VERSION_MAJOR
#include <devioctl.h> #include <devioctl.h>
#include <ntddstor.h> #include <ntddstor.h>
#else
#include <ddk/ntddstor.h>
#endif
#include "security.h" #include "security.h"
#include "path.h" #include "path.h"
#include "fhandler.h" #include "fhandler.h"

View File

@ -1487,10 +1487,6 @@ fhandler_pty_slave::fixup_after_exec ()
fixup_after_fork (NULL); fixup_after_fork (NULL);
} }
#ifndef __MINGW64_VERSION_MAJOR
extern "C" BOOL WINAPI GetNamedPipeClientProcessId (HANDLE, PULONG);
#endif
/* This thread function handles the master control pipe. It waits for a /* This thread function handles the master control pipe. It waits for a
client to connect. Then it checks if the client process has permissions client to connect. Then it checks if the client process has permissions
to access the tty handles. If so, it opens the client process and to access the tty handles. If so, it opens the client process and

View File

@ -1525,69 +1525,6 @@ getdomainname (char *domain, size_t len)
/* Fill out an ifconf struct. */ /* Fill out an ifconf struct. */
#ifndef __MINGW64_VERSION_MAJOR
/* Vista/Longhorn: unicast address has additional OnLinkPrefixLength member. */
typedef struct _IP_ADAPTER_UNICAST_ADDRESS_LH {
_ANONYMOUS_UNION union {
ULONGLONG Alignment;
_ANONYMOUS_UNION struct {
ULONG Length;
DWORD Flags;
} DUMMYSTRUCTNAME;
} DUMMYUNIONNAME;
struct _IP_ADAPTER_UNICAST_ADDRESS_VISTA *Next;
SOCKET_ADDRESS Address;
IP_PREFIX_ORIGIN PrefixOrigin;
IP_SUFFIX_ORIGIN SuffixOrigin;
IP_DAD_STATE DadState;
ULONG ValidLifetime;
ULONG PreferredLifetime;
ULONG LeaseLifetime;
unsigned char OnLinkPrefixLength;
} IP_ADAPTER_UNICAST_ADDRESS_LH, *PIP_ADAPTER_UNICAST_ADDRESS_LH;
/* Vista/Longhorn: IP_ADAPTER_ADDRESSES has a lot more info. We pick only
what we need for now. */
typedef struct _IP_ADAPTER_ADDRESSES_LH {
_ANONYMOUS_UNION union {
ULONGLONG Alignment;
_ANONYMOUS_STRUCT struct {
ULONG Length;
DWORD IfIndex;
} DUMMYSTRUCTNAME;
} DUMMYUNIONNAME;
struct _IP_ADAPTER_ADDRESSES* Next;
PCHAR AdapterName;
PIP_ADAPTER_UNICAST_ADDRESS FirstUnicastAddress;
PIP_ADAPTER_ANYCAST_ADDRESS FirstAnycastAddress;
PIP_ADAPTER_MULTICAST_ADDRESS FirstMulticastAddress;
PIP_ADAPTER_DNS_SERVER_ADDRESS FirstDnsServerAddress;
PWCHAR DnsSuffix;
PWCHAR Description;
PWCHAR FriendlyName;
BYTE PhysicalAddress[MAX_ADAPTER_ADDRESS_LENGTH];
DWORD PhysicalAddressLength;
DWORD Flags;
DWORD Mtu;
DWORD IfType;
IF_OPER_STATUS OperStatus;
DWORD Ipv6IfIndex;
DWORD ZoneIndices[16];
PIP_ADAPTER_PREFIX FirstPrefix;
ULONG64 TransmitLinkSpeed;
ULONG64 ReceiveLinkSpeed;
PVOID FirstWinsServerAddress;
PVOID FirstGatewayAddress;
ULONG Ipv4Metric;
ULONG Ipv6Metric;
} IP_ADAPTER_ADDRESSES_LH,*PIP_ADAPTER_ADDRESSES_LH;
#define SIO_GET_INTERFACE_LIST _IOR('t', 127, u_long)
#endif /* !__MINGW64_VERSION_MAJOR */
#ifndef IN_LOOPBACK #ifndef IN_LOOPBACK
#define IN_LOOPBACK(a) ((((long int) (a)) & 0xff000000) == 0x7f000000) #define IN_LOOPBACK(a) ((((long int) (a)) & 0xff000000) == 0x7f000000)
#endif #endif

View File

@ -11,11 +11,8 @@
#pragma once #pragma once
#ifndef __MINGW64_VERSION_MAJOR #include <ntstatus.h>
# include <ddk/ntstatus.h>
#else
# include <ntstatus.h>
#endif
/* custom status code: */ /* custom status code: */
#define STATUS_ILLEGAL_DLL_PSEUDO_RELOCATION ((NTSTATUS) 0xe0000269) #define STATUS_ILLEGAL_DLL_PSEUDO_RELOCATION ((NTSTATUS) 0xe0000269)
@ -973,14 +970,6 @@ typedef struct _FILE_MAILSLOT_SET_INFORMATION
typedef VOID NTAPI (*PIO_APC_ROUTINE)(PVOID, PIO_STATUS_BLOCK, ULONG); typedef VOID NTAPI (*PIO_APC_ROUTINE)(PVOID, PIO_STATUS_BLOCK, ULONG);
#ifndef __MINGW64_VERSION_MAJOR
typedef enum _EVENT_TYPE
{
NotificationEvent = 0,
SynchronizationEvent
} EVENT_TYPE, *PEVENT_TYPE;
#endif
typedef struct _EVENT_BASIC_INFORMATION typedef struct _EVENT_BASIC_INFORMATION
{ {
EVENT_TYPE EventType; EVENT_TYPE EventType;
@ -1046,21 +1035,11 @@ typedef struct _KEY_VALUE_PARTIAL_INFORMATION
UCHAR Data[1]; UCHAR Data[1];
} KEY_VALUE_PARTIAL_INFORMATION, *PKEY_VALUE_PARTIAL_INFORMATION; } KEY_VALUE_PARTIAL_INFORMATION, *PKEY_VALUE_PARTIAL_INFORMATION;
#ifndef __MINGW64_VERSION_MAJOR
typedef enum _TIMER_TYPE
{
NotificationTimer,
SynchronisationTimer
} TIMER_TYPE, *PTIMER_TYPE;
#endif
#ifdef __MINGW64_VERSION_MAJOR
typedef enum _SECTION_INHERIT typedef enum _SECTION_INHERIT
{ {
ViewShare = 1, ViewShare = 1,
ViewUnmap = 2 ViewUnmap = 2
} SECTION_INHERIT; } SECTION_INHERIT;
#endif
typedef VOID (APIENTRY *PTIMER_APC_ROUTINE)(PVOID, ULONG, ULONG); typedef VOID (APIENTRY *PTIMER_APC_ROUTINE)(PVOID, ULONG, ULONG);

View File

@ -18,10 +18,6 @@
#include <unistd.h> #include <unistd.h>
#include "registry.h" #include "registry.h"
#ifndef __MINGW64_VERSION_MAJOR
extern "C" HWND WINAPI GetForegroundWindow();
#endif
/* Win32 priority to UNIX priority Mapping. /* Win32 priority to UNIX priority Mapping.
For now, I'm just following the spec: any range of priorities is ok. For now, I'm just following the spec: any range of priorities is ok.
There are probably many many issues with this... There are probably many many issues with this...

View File

@ -25,10 +25,6 @@ details. */
#include "pwdgrp.h" #include "pwdgrp.h"
#include "ntdll.h" #include "ntdll.h"
#ifndef __MINGW64_VERSION_MAJOR
#define SECURITY_NT_NON_UNIQUE SECURITY_NT_NON_UNIQUE_RID
#endif
/* General purpose security attribute objects for global use. */ /* General purpose security attribute objects for global use. */
SECURITY_ATTRIBUTES NO_COPY sec_none; SECURITY_ATTRIBUTES NO_COPY sec_none;
SECURITY_ATTRIBUTES NO_COPY sec_none_nih; SECURITY_ATTRIBUTES NO_COPY sec_none_nih;
@ -378,11 +374,7 @@ static const struct {
{ SE_CREATE_GLOBAL_NAME, false }, { SE_CREATE_GLOBAL_NAME, false },
{ SE_TRUSTED_CREDMAN_ACCESS_NAME, false }, { SE_TRUSTED_CREDMAN_ACCESS_NAME, false },
{ SE_RELABEL_NAME, true }, { SE_RELABEL_NAME, true },
#ifndef __MINGW64_VERSION_MAJOR
{ SE_INCREASE_WORKING_SET_NAME, false },
#else
{ SE_INC_WORKING_SET_NAME, false }, { SE_INC_WORKING_SET_NAME, false },
#endif
{ SE_TIME_ZONE_NAME, true }, { SE_TIME_ZONE_NAME, true },
{ SE_CREATE_SYMBOLIC_LINK_NAME, true } { SE_CREATE_SYMBOLIC_LINK_NAME, true }
}; };