File tree Expand file tree Collapse file tree 7 files changed +42
-9
lines changed Expand file tree Collapse file tree 7 files changed +42
-9
lines changed Original file line number Diff line number Diff line change 1+ 2004-01-23 Bruno Haible <bruno@clisp.org>
2+
3+ * tests/table-from.c: Include binary-io.h.
4+ (main): Switch stdout to binary mode.
5+ * tests/table-to.c: Include binary-io.h.
6+ (main): Switch stdout to binary mode.
7+ * tests/genutf8.c: Include binary-io.h.
8+ (main): Switch stdout to binary mode.
9+ * tests/Makefile.in (INCLUDES): Also look in srclib.
10+ (check): Pass INCLUDES when compiling genutf8.c.
11+ * tests/Makefile.os2 (INCLUDES): Also look in srclib.
12+ (genutf8.exe): Pass INCLUDES when compiling genutf8.c.
13+ * tests/Makefile.msvc (INCLUDES): Also look in srclib.
14+ (check): Pass INCLUDES when compiling genutf8.c.
15+
1162004-01-21 Bruno Haible <bruno@clisp.org>
217
318 * src/iconv.c (force_binary): Remove variable.
Original file line number Diff line number Diff line change @@ -10,7 +10,7 @@ CC = @CC@
1010CFLAGS = @CFLAGS@
1111CPPFLAGS = @CPPFLAGS@
1212LDFLAGS = @LDFLAGS@
13- INCLUDES = -I. -I$(srcdir ) -I../include -I$(srcdir ) /../include -I../lib
13+ INCLUDES = -I. -I$(srcdir ) -I../include -I$(srcdir ) /../include -I../srclib -I $( srcdir ) /../srclib -I../ lib
1414LIBTOOL = @LIBTOOL@
1515LIBTOOL_COMPILE = $(LIBTOOL ) --mode=compile
1616LIBTOOL_LINK = $(LIBTOOL ) --mode=link
3131check : all table-from table-to ../src/iconv_no_i18n
3232 $(srcdir ) /check-stateless $(srcdir ) ASCII
3333# /* General multi-byte encodings */
34- $(CC) $(LDFLAGS) $(CFLAGS) $(CPPFLAGS) $(srcdir)/genutf8.c -o genutf8 && \
34+ $(CC) $(LDFLAGS) $(INCLUDES) $( CFLAGS) $(CPPFLAGS) $(srcdir)/genutf8.c -o genutf8 && \
3535 ./genutf8 > UTF-8.TXT && \
3636 $(srcdir)/check-stateless . UTF-8 && \
3737 $(RM) genutf8 UTF-8.TXT
Original file line number Diff line number Diff line change @@ -39,7 +39,7 @@ srcdir = .
3939# Programs used by "make":
4040CC = cl
4141CFLAGS = $(MFLAGS ) -W1 $(OPTIMFLAGS )
42- INCLUDES = -I. -I..\include -I..\lib
42+ INCLUDES = -I. -I..\include -I..\srclib -I..\ lib
4343RM = -del
4444
4545# ### End of system configuration section. ####
@@ -57,7 +57,7 @@ uninstall :
5757check : all table-from.exe table-to.exe ../src/iconv.exe uniq-u.exe
5858 $(srcdir ) \c heck-stateless.bat $(srcdir ) ASCII
5959# /* General multi-byte encodings */
60- $(CC) $(CFLAGS) $(srcdir)\genutf8.c -Fegenutf8.exe
60+ $(CC) $(INCLUDES) $( CFLAGS) $(srcdir)\genutf8.c -Fegenutf8.exe
6161 $(RM) genutf8.obj
6262 .\genutf8 > UTF-8.TXT
6363 $(srcdir)\check-stateless.bat . UTF-8
Original file line number Diff line number Diff line change 99# Programs used by "make":
1010CC = gcc
1111CFLAGS = -O2 -Zmtd
12- INCLUDES = -I. -I../include -I../lib
12+ INCLUDES = -I. -I../include -I../srclib -I../ lib
1313
1414#### End of system configuration section. ####
1515
@@ -136,7 +136,7 @@ table-to.exe : table-to.c
136136 copy ..\lib\iconv.dll iconv.dll
137137
138138genutf8.exe : genutf8.c
139- $(CC) $(CFLAGS) genutf8.c
139+ $(CC) $(INCLUDES) $( CFLAGS) genutf8.c
140140
141141mostlyclean : clean
142142
Original file line number Diff line number Diff line change 1- /* Copyright (C) 2000 Free Software Foundation, Inc.
1+ /* Copyright (C) 2000, 2004 Free Software Foundation, Inc.
22 This file is part of the GNU LIBICONV Library.
33
44 The GNU LIBICONV Library is free software; you can redistribute it
2121#include <stdio.h>
2222#include <stdlib.h>
2323
24+ #include "binary-io.h"
25+
2426int main ()
2527{
2628 int i1 , i2 , i3 ;
2729
30+ #if O_BINARY
31+ SET_BINARY (fileno (stdout ));
32+ #endif
33+
2834 /* Range 0x0000..0x007f */
2935 for (i1 = 0 ; i1 < 0x80 ; i1 ++ )
3036 printf ("0x%02X\t0x%04X\n" , i1 , i1 );
Original file line number Diff line number Diff line change 1- /* Copyright (C) 2000-2002 Free Software Foundation, Inc.
1+ /* Copyright (C) 2000-2002, 2004 Free Software Foundation, Inc.
22 This file is part of the GNU LIBICONV Library.
33
44 The GNU LIBICONV Library is free software; you can redistribute it
2727#include <iconv.h>
2828#include <errno.h>
2929
30+ #include "binary-io.h"
31+
3032/* If nonzero, ignore conversions outside Unicode plane 0. */
3133static int bmp_only ;
3234
@@ -106,6 +108,10 @@ int main (int argc, char* argv[])
106108 }
107109 charset = argv [1 ];
108110
111+ #if O_BINARY
112+ SET_BINARY (fileno (stdout ));
113+ #endif
114+
109115 cd = iconv_open ("UCS-4-INTERNAL" ,charset );
110116 if (cd == (iconv_t )(-1 )) {
111117 perror ("iconv_open" );
Original file line number Diff line number Diff line change 1- /* Copyright (C) 2000-2002 Free Software Foundation, Inc.
1+ /* Copyright (C) 2000-2002, 2004 Free Software Foundation, Inc.
22 This file is part of the GNU LIBICONV Library.
33
44 The GNU LIBICONV Library is free software; you can redistribute it
2727#include <iconv.h>
2828#include <errno.h>
2929
30+ #include "binary-io.h"
31+
3032int main (int argc , char * argv [])
3133{
3234 const char * charset ;
@@ -39,6 +41,10 @@ int main (int argc, char* argv[])
3941 }
4042 charset = argv [1 ];
4143
44+ #if O_BINARY
45+ SET_BINARY (fileno (stdout ));
46+ #endif
47+
4248 cd = iconv_open (charset ,"UCS-4-INTERNAL" );
4349 if (cd == (iconv_t )(-1 )) {
4450 perror ("iconv_open" );
You can’t perform that action at this time.
0 commit comments