This patch modifies the libdecnumber source code so that it fits properly with QEMU's include directory structure. Specifically, directives of the form
#include "xxx.h" are modified to look like: #include "libdecnumber/xxx.h" Signed-off-by: Tom Musta <tommu...@gmail.com> --- include/libdecnumber/decContext.h | 2 +- include/libdecnumber/decDouble.h | 2 +- include/libdecnumber/decNumber.h | 4 ++-- include/libdecnumber/decNumberLocal.h | 2 +- include/libdecnumber/decQuad.h | 2 +- include/libdecnumber/dpd/decimal128.h | 2 +- include/libdecnumber/dpd/decimal64.h | 2 +- libdecnumber/decContext.c | 6 +++--- libdecnumber/decNumber.c | 6 +++--- libdecnumber/dpd/decimal128.c | 8 ++++---- libdecnumber/dpd/decimal64.c | 12 ++++++------ 11 files changed, 24 insertions(+), 24 deletions(-) diff --git a/include/libdecnumber/decContext.h b/include/libdecnumber/decContext.h index cdbb244..2e8f2e1 100644 --- a/include/libdecnumber/decContext.h +++ b/include/libdecnumber/decContext.h @@ -232,7 +232,7 @@ see the files COPYING3 and COPYING.RUNTIME respectively. If not, see /* decContext routines */ - #include "decContextSymbols.h" + #include "libdecnumber/decContextSymbols.h" extern decContext * decContextClearStatus(decContext *, uint32_t); extern decContext * decContextDefault(decContext *, int32_t); diff --git a/include/libdecnumber/decDouble.h b/include/libdecnumber/decDouble.h index 136bb9d..ddbafd1 100644 --- a/include/libdecnumber/decDouble.h +++ b/include/libdecnumber/decDouble.h @@ -50,7 +50,7 @@ see the files COPYING3 and COPYING.RUNTIME respectively. If not, see #define DECDOUBLE_Ehigh (DECDOUBLE_Emax + DECDOUBLE_Bias - (DECDOUBLE_Pmax-1)) /* Required includes */ - #include "decContext.h" + #include "libdecnumber/decContext.h" #include "decQuad.h" /* The decDouble decimal 64-bit type, accessible by various types */ diff --git a/include/libdecnumber/decNumber.h b/include/libdecnumber/decNumber.h index 5cf18ab..0e912db 100644 --- a/include/libdecnumber/decNumber.h +++ b/include/libdecnumber/decNumber.h @@ -34,7 +34,7 @@ see the files COPYING3 and COPYING.RUNTIME respectively. If not, see #define DECAUTHOR "Mike Cowlishaw" /* Who to blame */ #if !defined(DECCONTEXT) - #include "decContext.h" + #include "libdecnumber/decContext.h" #endif /* Bit settings for decNumber.bits */ @@ -106,7 +106,7 @@ see the files COPYING3 and COPYING.RUNTIME respectively. If not, see /* decNumber public functions and macros */ /* ---------------------------------------------------------------- */ - #include "decNumberSymbols.h" + #include "libdecnumber/decNumberSymbols.h" /* Conversions */ decNumber * decNumberFromInt32(decNumber *, int32_t); diff --git a/include/libdecnumber/decNumberLocal.h b/include/libdecnumber/decNumberLocal.h index 71c8467..431e4e6 100644 --- a/include/libdecnumber/decNumberLocal.h +++ b/include/libdecnumber/decNumberLocal.h @@ -39,7 +39,7 @@ see the files COPYING3 and COPYING.RUNTIME respectively. If not, see #include <stdlib.h> /* for abs */ #include <string.h> /* for memset, strcpy */ - #include "dconfig.h" /* for WORDS_BIGENDIAN */ + #include "libdecnumber/dconfig.h" /* Conditional code flag -- set this to match hardware platform */ /* 1=little-endian, 0=big-endian */ diff --git a/include/libdecnumber/decQuad.h b/include/libdecnumber/decQuad.h index c8ec11c..ed91c39 100644 --- a/include/libdecnumber/decQuad.h +++ b/include/libdecnumber/decQuad.h @@ -52,7 +52,7 @@ see the files COPYING3 and COPYING.RUNTIME respectively. If not, see #define DECQUAD_Ehigh (DECQUAD_Emax + DECQUAD_Bias - (DECQUAD_Pmax-1)) /* Required include */ - #include "decContext.h" + #include "libdecnumber/decContext.h" /* The decQuad decimal 128-bit type, accessible by various types */ typedef union { diff --git a/include/libdecnumber/dpd/decimal128.h b/include/libdecnumber/dpd/decimal128.h index 9fc532b..ee29b2d 100644 --- a/include/libdecnumber/dpd/decimal128.h +++ b/include/libdecnumber/dpd/decimal128.h @@ -55,7 +55,7 @@ see the files COPYING3 and COPYING.RUNTIME respectively. If not, see #define DECNUMDIGITS DECIMAL128_Pmax /* size if not already defined*/ #endif #ifndef DECNUMBER - #include "decNumber.h" /* context and number library */ + #include "libdecnumber/decNumber.h" #endif /* Decimal 128-bit type, accessible by bytes */ diff --git a/include/libdecnumber/dpd/decimal64.h b/include/libdecnumber/dpd/decimal64.h index 7a9f8ee..180e458 100644 --- a/include/libdecnumber/dpd/decimal64.h +++ b/include/libdecnumber/dpd/decimal64.h @@ -57,7 +57,7 @@ see the files COPYING3 and COPYING.RUNTIME respectively. If not, see #define DECNUMDIGITS DECIMAL64_Pmax /* size if not already defined*/ #endif #ifndef DECNUMBER - #include "decNumber.h" /* context and number library */ + #include "libdecnumber/decNumber.h" #endif /* Decimal 64-bit type, accessible by bytes */ diff --git a/libdecnumber/decContext.c b/libdecnumber/decContext.c index c68101b..a8b3483 100644 --- a/libdecnumber/decContext.c +++ b/libdecnumber/decContext.c @@ -32,9 +32,9 @@ see the files COPYING3 and COPYING.RUNTIME respectively. If not, see #include <string.h> /* for strcmp */ #include <stdio.h> /* for printf if DECCHECK */ -#include "dconfig.h" /* for GCC definitions */ -#include "decContext.h" /* context and base types */ -#include "decNumberLocal.h" /* decNumber local types, etc. */ +#include "libdecnumber/dconfig.h" +#include "libdecnumber/decContext.h" +#include "libdecnumber/decNumberLocal.h" #if DECCHECK /* compile-time endian tester [assumes sizeof(Int)>1] */ diff --git a/libdecnumber/decNumber.c b/libdecnumber/decNumber.c index ba57163..c0429e5 100644 --- a/libdecnumber/decNumber.c +++ b/libdecnumber/decNumber.c @@ -165,9 +165,9 @@ see the files COPYING3 and COPYING.RUNTIME respectively. If not, see #include <stdio.h> /* for printf [if needed] */ #include <string.h> /* for strcpy */ #include <ctype.h> /* for lower */ -#include "dconfig.h" /* for GCC definitions */ -#include "decNumber.h" /* base number library */ -#include "decNumberLocal.h" /* decNumber local types, etc. */ +#include "libdecnumber/dconfig.h" +#include "libdecnumber/decNumber.h" +#include "libdecnumber/decNumberLocal.h" /* Constants */ /* Public lookup table used by the D2U macro */ diff --git a/libdecnumber/dpd/decimal128.c b/libdecnumber/dpd/decimal128.c index 9fb2b3e..c0f5786 100644 --- a/libdecnumber/dpd/decimal128.c +++ b/libdecnumber/dpd/decimal128.c @@ -37,11 +37,11 @@ see the files COPYING3 and COPYING.RUNTIME respectively. If not, see #include <string.h> /* [for memset/memcpy] */ #include <stdio.h> /* [for printf] */ -#include "dconfig.h" /* GCC definitions */ +#include "libdecnumber/dconfig.h" #define DECNUMDIGITS 34 /* make decNumbers with space for 34 */ -#include "decNumber.h" /* base number library */ -#include "decNumberLocal.h" /* decNumber local types, etc. */ -#include "decimal128.h" /* our primary include */ +#include "libdecnumber/decNumber.h" +#include "libdecnumber/decNumberLocal.h" +#include "libdecnumber/dpd/decimal128.h" /* Utility routines and tables [in decimal64.c] */ extern const uInt COMBEXP[32], COMBMSD[32]; diff --git a/libdecnumber/dpd/decimal64.c b/libdecnumber/dpd/decimal64.c index 1456133..53386ab 100644 --- a/libdecnumber/dpd/decimal64.c +++ b/libdecnumber/dpd/decimal64.c @@ -37,11 +37,11 @@ see the files COPYING3 and COPYING.RUNTIME respectively. If not, see #include <string.h> /* [for memset/memcpy] */ #include <stdio.h> /* [for printf] */ -#include "dconfig.h" /* GCC definitions */ +#include "libdecnumber/dconfig.h" #define DECNUMDIGITS 16 /* make decNumbers with space for 16 */ -#include "decNumber.h" /* base number library */ -#include "decNumberLocal.h" /* decNumber local types, etc. */ -#include "decimal64.h" /* our primary include */ +#include "libdecnumber/decNumber.h" +#include "libdecnumber/decNumberLocal.h" +#include "libdecnumber/dpd/decimal64.h" /* Utility routines and tables [in decimal64.c]; externs for C++ */ extern const uInt COMBEXP[32], COMBMSD[32]; @@ -65,7 +65,7 @@ extern void decNumberShow(const decNumber *); /* .. */ #define DEC_BIN2CHAR 1 #define DEC_DPD2BIN 1 #define DEC_BIN2DPD 1 /* used for all sizes */ -#include "decDPD.h" /* lookup tables */ +#include "libdecnumber/decDPD.h" /* ------------------------------------------------------------------ */ /* decimal64FromNumber -- convert decNumber to decimal64 */ @@ -554,7 +554,7 @@ void decimal64Show(const decimal64 *d64) { #else #define DEC_DPD2BCD 1 #endif -#include "decDPD.h" /* lookup tables */ +#include "libdecnumber/decDPD.h" /* The maximum number of decNumberUnits needed for a working copy of */ /* the units array is the ceiling of digits/DECDPUN, where digits is */ -- 1.7.1