From 2fcfb97eec15ccc86231889cf005fc410160f145 Mon Sep 17 00:00:00 2001 From: Stefan Ginsberg Date: Fri, 14 Nov 2008 14:49:11 +0000 Subject: [PATCH] - Don't define PAGE_SIZE in typedefs.h as -- "this value is target specific, host tools MUST not use it and this line has to be removed". Instead, define it locally for cmlib. - Also correct TRUE definition in this header svn path=/trunk/; revision=37358 --- reactos/include/host/typedefs.h | 6 +----- reactos/lib/cmlib/cmlib.h | 15 +++++++++++++++ 2 files changed, 16 insertions(+), 5 deletions(-) diff --git a/reactos/include/host/typedefs.h b/reactos/include/host/typedefs.h index bdc4d3763e2..0ddc3f460e8 100644 --- a/reactos/include/host/typedefs.h +++ b/reactos/include/host/typedefs.h @@ -40,11 +40,7 @@ #define OPTIONAL #define FALSE 0 -#define TRUE (!(FALSE)) - -/* FIXME: this value is target specific, host tools MUST not use it - * and this line has to be removed */ -#define PAGE_SIZE 4096 +#define TRUE 1 #define ANYSIZE_ARRAY 1 diff --git a/reactos/lib/cmlib/cmlib.h b/reactos/lib/cmlib/cmlib.h index ff780d166b1..3f9b00d59ff 100644 --- a/reactos/lib/cmlib/cmlib.h +++ b/reactos/lib/cmlib/cmlib.h @@ -103,6 +103,21 @@ #define ROUND_DOWN(a,b) (((a)/(b))*(b)) #endif +// +// PAGE_SIZE definition +// +#ifndef PAGE_SIZE +#if defined(_M_IX86) +#define PAGE_SIZE 0x1000 +#elif defined(_M_AMD64) +#define PAGE_SIZE 0x1000 +#elif defined(_M_ARM) +#define PAGE_SIZE 0x1000 +#else +#error Local PAGE_SIZE definition required +#endif +#endif + #define TAG_CM 0x68742020 #define CMAPI NTAPI