[FriBidi-commit] fribidi ChangeLog, 1.60.2.20, 1.60.2.21 configure.in, 1.22.2.11, 1.22.2.12 fribidi_config.h.in, 1.2.2.6, 1.2.2.7 fribidi_create_char_types.c, 1.7.2.6, 1.7.2.7 fribidi_types.h, 1.16.2.8, 1.16.2.9

Behdad Esfahbod behdad at freedesktop.org
Sun Sep 25 15:27:41 PDT 2005


Update of /cvs/fribidi/fribidi
In directory gabe:/tmp/cvs-serv3086

Modified Files:
      Tag: STABLE
	ChangeLog configure.in fribidi_config.h.in 
	fribidi_create_char_types.c fribidi_types.h 
Log Message:
Back to not using stdint.h (#4319)


Index: ChangeLog
===================================================================
RCS file: /cvs/fribidi/fribidi/ChangeLog,v
retrieving revision 1.60.2.20
retrieving revision 1.60.2.21
diff -u -d -r1.60.2.20 -r1.60.2.21
--- ChangeLog	25 Sep 2005 20:41:59 -0000	1.60.2.20
+++ ChangeLog	25 Sep 2005 22:27:39 -0000	1.60.2.21
@@ -7,6 +7,7 @@
 	bastards!
 	* *: const added in places.
 	* fribidi_type.c: Define prop array as const.
+	* fribidi_types.h: Back to not using stdint.h. (#4319)
 
 2005-06-08  Behdad Esfahbod <fribidi at behdad.org>
 	* NEWS, README, AUTHORS, THANKS: Updated.

Index: configure.in
===================================================================
RCS file: /cvs/fribidi/fribidi/configure.in,v
retrieving revision 1.22.2.11
retrieving revision 1.22.2.12
diff -u -d -r1.22.2.11 -r1.22.2.12
--- configure.in	25 Sep 2005 18:38:36 -0000	1.22.2.11
+++ configure.in	25 Sep 2005 22:27:39 -0000	1.22.2.12
@@ -81,7 +81,18 @@
 
 
 dnl Checks for typedefs
-AC_CHECK_SIZEOF(char, 1)
+
+AC_CHECK_SIZEOF(short, 2)
+SIZEOF_SHORT=$ac_cv_sizeof_short
+AC_SUBST(SIZEOF_SHORT)
+
+AC_CHECK_SIZEOF(int, 4)
+SIZEOF_INT=$ac_cv_sizeof_int
+AC_SUBST(SIZEOF_INT)
+
+AC_CHECK_SIZEOF(long, 4)
+SIZEOF_LONG=$ac_cv_sizeof_long
+AC_SUBST(SIZEOF_LONG)
 
 
 dnl Checks for compiler characteristics

Index: fribidi_config.h.in
===================================================================
RCS file: /cvs/fribidi/fribidi/fribidi_config.h.in,v
retrieving revision 1.2.2.6
retrieving revision 1.2.2.7
diff -u -d -r1.2.2.6 -r1.2.2.7
--- fribidi_config.h.in	10 Aug 2002 04:17:50 -0000	1.2.2.6
+++ fribidi_config.h.in	25 Sep 2005 22:27:39 -0000	1.2.2.7
@@ -31,19 +31,6 @@
 
 #endif /* WIN32 */
 
-/* __BEGIN_DECLS should be used at the beginning of your declarations,
- * so that C++ compilers don't mangle their names.  Use __END_DECLS at
- * the end of C declarations. */
-#undef __BEGIN_DECLS
-#undef __END_DECLS
-#ifdef __cplusplus
-#define __BEGIN_DECLS extern "C" {
-#define __END_DECLS }
-#else /* NOT __cplusplus */
-#define __BEGIN_DECLS		/* empty */
-#define __END_DECLS		/* empty */
-#endif /* __cplusplus */
-
 #define FRIBIDI_TRUE    1
 #define FRIBIDI_FALSE   0
 
@@ -53,3 +40,7 @@
 #ifndef FALSE
 #define FALSE FRIBIDI_FALSE
 #endif /* FALSE */
+
+#define FRIBIDI_SIZEOF_SHORT @SIZEOF_SHORT@
+#define FRIBIDI_SIZEOF_INT @SIZEOF_INT@
+#define FRIBIDI_SIZEOF_LONG @SIZEOF_LONG@

Index: fribidi_create_char_types.c
===================================================================
RCS file: /cvs/fribidi/fribidi/fribidi_create_char_types.c,v
retrieving revision 1.7.2.6
retrieving revision 1.7.2.7
diff -u -d -r1.7.2.6 -r1.7.2.7
--- fribidi_create_char_types.c	25 Sep 2005 18:58:35 -0000	1.7.2.6
+++ fribidi_create_char_types.c	25 Sep 2005 22:27:39 -0000	1.7.2.7
@@ -28,10 +28,6 @@
 #endif
 #include "fribidi_unicode.h"
 
-#ifndef SIZEOF_CHAR
-#define SIZEOF_CHAR sizeof (char)
-#endif
-
 static void
 err (const char *msg)
 {
@@ -221,7 +217,7 @@
   fprintf (f, "#define PACKTAB_UINT32 fribidi_uint32\n");
 
   if (!pack_table
-      (table, FRIBIDI_UNICODE_CHARS, SIZEOF_CHAR, max_depth, 3, names,
+      (table, FRIBIDI_UNICODE_CHARS, sizeof (char), max_depth, 3, names,
        key_type_name, table_name, macro_name, f))
     err ("error: insufficient memory, decrease max_depth");
 

Index: fribidi_types.h
===================================================================
RCS file: /cvs/fribidi/fribidi/fribidi_types.h,v
retrieving revision 1.16.2.8
retrieving revision 1.16.2.9
diff -u -d -r1.16.2.8 -r1.16.2.9
--- fribidi_types.h	25 Sep 2005 20:48:19 -0000	1.16.2.8
+++ fribidi_types.h	25 Sep 2005 22:27:39 -0000	1.16.2.9
@@ -24,7 +24,22 @@
 #define FRIBIDI_TYPES_H
 
 #include "fribidi_config.h"
-#include <stdint.h>
+#define FRIBIDI_INT8	char
+#if FRIBIDI_SIZEOF_INT+0 == 2
+# define FRIBIDI_INT16	int
+#elif FRIBIDI_SIZEOF_SHORT+0 == 2
+# define FRIBIDI_INT16	short
+#else
+# error cannot determine a 16-bit integer type.  check fribidi_config.h
+#endif
+#if FRIBIDI_SIZEOF_INT+0 == 4
+# define FRIBIDI_INT32	int
+#elif FRIBIDI_SIZEOF_LONG+0 == 4
+# define FRIBIDI_INT32	long
+#else
+# error cannot determine a 32-bit integer type.  check fribidi_config.h
+#endif
+
 
 #ifdef __cplusplus
 extern "C"
@@ -33,13 +48,14 @@
 
   typedef int fribidi_boolean;
 
-  typedef int8_t fribidi_int8;
-  typedef uint8_t fribidi_uint8;
-  typedef int16_t fribidi_int16;
-  typedef uint16_t fribidi_uint16;
-  typedef int32_t fribidi_int32;
-  typedef uint32_t fribidi_uint32;
-  typedef int fribidi_int;
+  typedef signed FRIBIDI_INT8 fribidi_int8;
+  typedef unsigned FRIBIDI_INT8 fribidi_uint8;
+  typedef signed FRIBIDI_INT16 fribidi_int16;
+  typedef unsigned FRIBIDI_INT16 fribidi_uint16;
+  typedef signed FRIBIDI_INT32 fribidi_int32;
+  typedef unsigned FRIBIDI_INT32 fribidi_uint32;
+
+  typedef signed int fribidi_int;
   typedef unsigned int fribidi_uint;
 
 



More information about the fribidi-commit mailing list