mirror of
https://github.com/reactos/reactos.git
synced 2024-06-30 09:50:07 +00:00
[XDK]
Initial work for autogenerating ntdef.h and winnt.h to reduce code duplication by sharing a lot of stuff. svn path=/trunk/; revision=63998
This commit is contained in:
parent
e6b0427c92
commit
bc9e621611
1547
reactos/include/xdk/ntbasedef.h
Normal file
1547
reactos/include/xdk/ntbasedef.h
Normal file
File diff suppressed because it is too large
Load diff
98
reactos/include/xdk/ntdef.template.h
Normal file
98
reactos/include/xdk/ntdef.template.h
Normal file
|
@ -0,0 +1,98 @@
|
|||
/*
|
||||
* ntdef.h
|
||||
*
|
||||
* This file is part of the ReactOS PSDK package.
|
||||
*
|
||||
* Contributors:
|
||||
* Created by Casper S. Hornstrup <chorns@users.sourceforge.net>
|
||||
*
|
||||
* THIS SOFTWARE IS NOT COPYRIGHTED
|
||||
*
|
||||
* This source code is offered for use in the public domain. You may
|
||||
* use, modify or distribute it freely.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful but
|
||||
* WITHOUT ANY WARRANTY. ALL WARRANTIES, EXPRESS OR IMPLIED ARE HEREBY
|
||||
* DISCLAIMED. This includes but is not limited to warranties of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
||||
*
|
||||
*/
|
||||
|
||||
#ifndef _NTDEF_
|
||||
#define _NTDEF_
|
||||
#pragma once
|
||||
|
||||
/* Dependencies */
|
||||
#include <ctype.h>
|
||||
//#include <winapifamily.h>
|
||||
#include <basetsd.h>
|
||||
#include <guiddef.h>
|
||||
#include <excpt.h>
|
||||
#include <sdkddkver.h>
|
||||
#include <specstrings.h>
|
||||
#include <kernelspecs.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/* Default to strict */
|
||||
#ifndef NO_STRICT
|
||||
#ifndef STRICT
|
||||
#define STRICT 1
|
||||
#endif
|
||||
#endif
|
||||
|
||||
/* Pseudo Modifiers for Input Parameters */
|
||||
|
||||
#ifndef IN
|
||||
#define IN
|
||||
#endif
|
||||
|
||||
#ifndef OUT
|
||||
#define OUT
|
||||
#endif
|
||||
|
||||
#ifndef OPTIONAL
|
||||
#define OPTIONAL
|
||||
#endif
|
||||
|
||||
#ifndef NOTHING
|
||||
#define NOTHING
|
||||
#endif
|
||||
|
||||
#ifndef CRITICAL
|
||||
#define CRITICAL
|
||||
#endif
|
||||
|
||||
/* Constant modifier */
|
||||
#ifndef CONST
|
||||
#define CONST const
|
||||
#endif
|
||||
|
||||
/* TRUE/FALSE */
|
||||
#define FALSE 0
|
||||
#define TRUE 1
|
||||
|
||||
/* NULL/NULL64 */
|
||||
#ifndef NULL
|
||||
#ifdef __cplusplus
|
||||
#define NULL 0
|
||||
#define NULL64 0
|
||||
#else
|
||||
#define NULL ((void *)0)
|
||||
#define NULL64 ((void * POINTER_64)0)
|
||||
#endif
|
||||
#endif /* NULL */
|
||||
|
||||
$define(_NTDEF_)
|
||||
$define(ULONG=ULONG)
|
||||
$define(USHORT=USHORT)
|
||||
$define(UCHAR=UCHAR)
|
||||
$include(ntbasedef.h)
|
||||
|
||||
#ifdef __cplusplus
|
||||
} // extern "C"
|
||||
#endif
|
||||
|
||||
#endif /* _NTDEF_ */
|
77
reactos/include/xdk/winnt.template.h
Normal file
77
reactos/include/xdk/winnt.template.h
Normal file
|
@ -0,0 +1,77 @@
|
|||
/*
|
||||
* winnt.h
|
||||
*
|
||||
* Windows NT native definitions for user mode
|
||||
*
|
||||
* This file is part of the ReactOS PSDK package.
|
||||
*
|
||||
* Contributors:
|
||||
* Timo Kreuzer (timo.kreuzer@reactos.org)
|
||||
*
|
||||
* THIS SOFTWARE IS NOT COPYRIGHTED
|
||||
*
|
||||
* This source code is offered for use in the public domain. You may
|
||||
* use, modify or distribute it freely.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful but
|
||||
* WITHOUT ANY WARRANTY. ALL WARRANTIES, EXPRESS OR IMPLIED ARE HEREBY
|
||||
* DISCLAIMED. This includes but is not limited to warranties of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
||||
*
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
#define _WINNT_
|
||||
|
||||
/* We require WDK / VS 2008 or newer */
|
||||
#if defined(_MSC_VER) && (_MSC_VER < 1500)
|
||||
#error Compiler too old!
|
||||
#endif
|
||||
|
||||
/* HACK for wine code */
|
||||
#if !defined(__ROS_LONG64__)
|
||||
#ifdef __WINESRC__
|
||||
#define __ROS_LONG64__
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#include <ctype.h>
|
||||
//#include <winapifamily.h>
|
||||
#include <msvctarget.h>
|
||||
#include <specstrings.h>
|
||||
#include <kernelspecs.h>
|
||||
|
||||
#include <excpt.h>
|
||||
#include <basetsd.h>
|
||||
#include <guiddef.h>
|
||||
#include <intrin.h>
|
||||
|
||||
#undef __need_wchar_t
|
||||
#include <winerror.h>
|
||||
#include <stddef.h>
|
||||
#include <sdkddkver.h>
|
||||
#ifndef RC_INVOKED
|
||||
#include <string.h>
|
||||
#endif
|
||||
|
||||
/* Silence some MSVC warnings */
|
||||
#ifdef _MSC_VER
|
||||
#pragma warning(push)
|
||||
#pragma warning(disable:4201)
|
||||
#pragma warning(disable:4214)
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
$define(_WINNT_)
|
||||
$define(ULONG=DWORD)
|
||||
$define(USHORT=WORD)
|
||||
$define(UCHAR=BYTE)
|
||||
$include(ntbasedef.h)
|
||||
$include(winnt_old.h)
|
||||
|
||||
#ifdef __cplusplus
|
||||
} // extern "C"
|
||||
#endif
|
4790
reactos/include/xdk/winnt_old.h
Normal file
4790
reactos/include/xdk/winnt_old.h
Normal file
File diff suppressed because it is too large
Load diff
Loading…
Reference in a new issue