Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 4c3c8c0

Browse files
committed
Remove --enable-recode feature, since it's been broken by IPv6 changes,
and seems to have too few users to justify maintaining.
1 parent f3c3deb commit 4c3c8c0

18 files changed

+12
-920
lines changed

INSTALL

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -342,13 +342,6 @@ are encouraged to read in any case.
342342
installed in non-standard locations.
343343
Example: --with-libraries=/opt/gnu/lib:/usr/sup/lib.
344344

345-
--enable-recode
346-
347-
Enables single-byte character set recode support. See the
348-
Administrator's Guide about this feature. Note that a more general
349-
form of character set conversion is supported in the default
350-
configuration; this feature is obsolete.
351-
352345
--enable-nls[=LANGUAGES]
353346

354347
Enables Native Language Support (NLS), that is, the ability to

configure

Lines changed: 0 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -838,7 +838,6 @@ Optional Features:
838838
--disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
839839
--enable-FEATURE[=ARG] include FEATURE [ARG=yes]
840840
--enable-integer-datetimes enable 64-bit integer date/time support
841-
--enable-recode enable single-byte recode support
842841
--enable-nls[=LANGUAGES] enable Native Language Support
843842
--disable-shared do not build shared libraries
844843
--disable-rpath do not embed shared library search path in executables
@@ -1597,43 +1596,6 @@ echo "$as_me:$LINENO: result: $enable_integer_datetimes" >&5
15971596
echo "${ECHO_T}$enable_integer_datetimes" >&6
15981597

15991598

1600-
# Character set recode (--enable-recode)
1601-
#
1602-
echo "$as_me:$LINENO: checking whether to build with recode support" >&5
1603-
echo $ECHO_N "checking whether to build with recode support... $ECHO_C" >&6
1604-
1605-
1606-
# Check whether --enable-recode or --disable-recode was given.
1607-
if test "${enable_recode+set}" = set; then
1608-
enableval="$enable_recode"
1609-
1610-
case $enableval in
1611-
yes)
1612-
1613-
cat >>confdefs.h <<\_ACEOF
1614-
#define CYR_RECODE 1
1615-
_ACEOF
1616-
1617-
;;
1618-
no)
1619-
:
1620-
;;
1621-
*)
1622-
{ { echo "$as_me:$LINENO: error: no argument expected for --enable-recode option" >&5
1623-
echo "$as_me: error: no argument expected for --enable-recode option" >&2;}
1624-
{ (exit 1); exit 1; }; }
1625-
;;
1626-
esac
1627-
1628-
else
1629-
enable_recode=no
1630-
1631-
fi;
1632-
1633-
echo "$as_me:$LINENO: result: $enable_recode" >&5
1634-
echo "${ECHO_T}$enable_recode" >&6
1635-
1636-
16371599
#
16381600
# NLS
16391601
#

configure.in

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
dnl Process this file with autoconf to produce a configure script.
2-
dnl $Header: /cvsroot/pgsql/configure.in,v 1.273 2003/08/03 20:23:14 tgl Exp $
2+
dnl $Header: /cvsroot/pgsql/configure.in,v 1.274 2003/08/04 04:03:03 tgl Exp $
33
dnl
44
dnl Developers, please strive to achieve this order:
55
dnl
@@ -153,15 +153,6 @@ PGAC_ARG_BOOL(enable, integer-datetimes, no, [ --enable-integer-datetimes enab
153153
AC_MSG_RESULT([$enable_integer_datetimes])
154154

155155

156-
# Character set recode (--enable-recode)
157-
#
158-
AC_MSG_CHECKING([whether to build with recode support])
159-
PGAC_ARG_BOOL(enable, recode, no, [ --enable-recode enable single-byte recode support],
160-
[AC_DEFINE([CYR_RECODE], 1,
161-
[Define to 1 if you want single-byte recode support. (--enable-recode)])])
162-
AC_MSG_RESULT([$enable_recode])
163-
164-
165156
#
166157
# NLS
167158
#

doc/src/sgml/charset.sgml

Lines changed: 3 additions & 79 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<!-- $Header: /cvsroot/pgsql/doc/src/sgml/charset.sgml,v 2.36 2003/05/15 15:50:18 petere Exp $ -->
1+
<!-- $Header: /cvsroot/pgsql/doc/src/sgml/charset.sgml,v 2.37 2003/08/04 04:03:03 tgl Exp $ -->
22

33
<chapter id="charset">
44
<title>Localization</>
@@ -7,7 +7,7 @@
77
This chapter describes the available localization features from the
88
point of view of the administrator.
99
<productname>PostgreSQL</productname> supports localization with
10-
three approaches:
10+
two approaches:
1111

1212
<itemizedlist>
1313
<listitem>
@@ -23,17 +23,10 @@
2323
Providing a number of different character sets defined in the
2424
<productname>PostgreSQL</productname> server, including
2525
multiple-byte character sets, to support storing text in all
26-
kinds of languages, and providing character set recoding between
26+
kinds of languages, and providing character set translation between
2727
client and server.
2828
</para>
2929
</listitem>
30-
31-
<listitem>
32-
<para>
33-
Single-byte character recoding provides a more light-weight
34-
solution for users of multiple, yet single-byte character sets.
35-
</para>
36-
</listitem>
3730
</itemizedlist>
3831
</para>
3932

@@ -884,75 +877,6 @@ RESET CLIENT_ENCODING;
884877

885878
</sect1>
886879

887-
888-
<sect1 id="recode">
889-
<title>Single-Byte Character Set Recoding</>
890-
891-
<para>
892-
You can set up this feature with the <option>--enable-recode</> option
893-
to <filename>configure</>. This option was formerly described as
894-
<quote>Cyrillic recode support</> which doesn't express all its
895-
power. It can be used for <emphasis>any</> single-byte character
896-
set recoding.
897-
</para>
898-
899-
<para>
900-
This method uses a file <filename>charset.conf</> file located in
901-
the data directory for configuration. It's a typical
902-
configuration text file where spaces and newlines separate fields
903-
and records and <literal>#</> starts a comment. Three key words with the
904-
following syntax are recognized here:
905-
<synopsis>
906-
BaseCharset <replaceable>server_charset</>
907-
RecodeTable <replaceable>from_charset</> <replaceable>to_charset</> <replaceable>file_name</>
908-
HostCharset <replaceable>host_spec</> <replaceable>host_charset</>
909-
</synopsis>
910-
</para>
911-
912-
<para>
913-
<token>BaseCharset</> defines the character set of the database server.
914-
All character set names are only used for mapping inside of
915-
<filename>charset.conf</> so you can freely use typing-friendly
916-
names.
917-
</para>
918-
919-
<para>
920-
<token>RecodeTable</> records specify conversion tables between
921-
server and client. The file name is relative to the
922-
data directory. The table file format is very
923-
simple. There are no key words, and character mappings are represented by a
924-
pair of decimal or hexadecimal (prefixed by <literal>0x</>) values on single
925-
lines:
926-
<synopsis>
927-
<replaceable>char_value</> <replaceable>converted_char_value</>
928-
</synopsis>
929-
In the <filename>src/data/</> directory in the source distribution you can find an
930-
example <filename>charset.conf</> and a few recoding tables.
931-
</para>
932-
933-
<para>
934-
<token>HostCharset</> records define the client character set by IP
935-
address. You can use a single IP address, an IP mask range starting
936-
from the given address or an IP interval (e.g., <literal>127.0.0.1</>,
937-
<literal>192.168.1.100/24</>, <literal>192.168.1.20-192.168.1.40</>).
938-
</para>
939-
940-
<para>
941-
The <filename>charset.conf</> file is always processed to the
942-
end, so you can easily specify exceptions from preceding rules.
943-
</para>
944-
945-
<para>
946-
As this solution is based on the client's IP address there are
947-
obviously some restrictions as well. You cannot use different
948-
character sets on the same host at the same time. It is also
949-
inconvenient when you boot your client hosts into multiple
950-
operating systems. Nevertheless, when these restrictions are not
951-
limiting and you do not need multibyte characters then it is a
952-
simple and effective solution.
953-
</para>
954-
</sect1>
955-
956880
</chapter>
957881

958882
<!-- Keep this comment at the end of the file

doc/src/sgml/installation.sgml

Lines changed: 1 addition & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<!-- $Header: /cvsroot/pgsql/doc/src/sgml/installation.sgml,v 1.137 2003/08/01 03:10:04 momjian Exp $ -->
1+
<!-- $Header: /cvsroot/pgsql/doc/src/sgml/installation.sgml,v 1.138 2003/08/04 04:03:03 tgl Exp $ -->
22

33
<chapter id="installation">
44
<title><![%standalone-include[<productname>PostgreSQL</>]]>
@@ -699,19 +699,6 @@ JAVACMD=$JAVA_HOME/bin/java
699699
</listitem>
700700
</varlistentry>
701701

702-
<varlistentry>
703-
<term><option>--enable-recode</option></term>
704-
<listitem>
705-
<para>
706-
Enables single-byte character set recode support. See
707-
<![%standalone-include[the documentation]]> <![%standalone-ignore[<xref
708-
linkend="recode">]]> about this feature. Note that a more
709-
general form of character set conversion is supported in the
710-
default configuration; this feature is obsolete.
711-
</para>
712-
</listitem>
713-
</varlistentry>
714-
715702
<varlistentry>
716703
<term><option>--enable-nls<optional>=<replaceable>LANGUAGES</replaceable></optional></option></term>
717704
<listitem>

src/backend/tcop/postgres.c

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
*
99
*
1010
* IDENTIFICATION
11-
* $Header: /cvsroot/pgsql/src/backend/tcop/postgres.c,v 1.355 2003/08/04 02:40:04 momjian Exp $
11+
* $Header: /cvsroot/pgsql/src/backend/tcop/postgres.c,v 1.356 2003/08/04 04:03:06 tgl Exp $
1212
*
1313
* NOTES
1414
* this is the "main" module of the postgres backend and
@@ -2613,14 +2613,6 @@ PostgresMain(int argc, char *argv[], const char *username)
26132613
on_shmem_exit(DumpFreeSpaceMap, 0);
26142614
}
26152615

2616-
/*
2617-
* Set up additional info.
2618-
*/
2619-
2620-
#ifdef CYR_RECODE
2621-
SetCharSet();
2622-
#endif
2623-
26242616
/*
26252617
* General initialization.
26262618
*
@@ -2651,7 +2643,7 @@ PostgresMain(int argc, char *argv[], const char *username)
26512643
if (!IsUnderPostmaster)
26522644
{
26532645
puts("\nPOSTGRES backend interactive interface ");
2654-
puts("$Revision: 1.355 $ $Date: 2003/08/04 02:40:04 $\n");
2646+
puts("$Revision: 1.356 $ $Date: 2003/08/04 04:03:06 $\n");
26552647
}
26562648

26572649
/*

src/backend/utils/adt/varchar.c

Lines changed: 1 addition & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
*
99
*
1010
* IDENTIFICATION
11-
* $Header: /cvsroot/pgsql/src/backend/utils/adt/varchar.c,v 1.101 2003/08/04 02:40:06 momjian Exp $
11+
* $Header: /cvsroot/pgsql/src/backend/utils/adt/varchar.c,v 1.102 2003/08/04 04:03:10 tgl Exp $
1212
*
1313
*-------------------------------------------------------------------------
1414
*/
@@ -130,10 +130,6 @@ bpcharin(PG_FUNCTION_ARGS)
130130
for (; i < maxlen; i++)
131131
*r++ = ' ';
132132

133-
#ifdef CYR_RECODE
134-
convertstr(VARDATA(result), len, 0);
135-
#endif
136-
137133
PG_RETURN_BPCHAR_P(result);
138134
}
139135

@@ -154,10 +150,6 @@ bpcharout(PG_FUNCTION_ARGS)
154150
memcpy(result, VARDATA(s), len);
155151
result[len] = '\0';
156152

157-
#ifdef CYR_RECODE
158-
convertstr(result, len, 1);
159-
#endif
160-
161153
PG_RETURN_CSTRING(result);
162154
}
163155

@@ -396,10 +388,6 @@ varcharin(PG_FUNCTION_ARGS)
396388
VARATT_SIZEP(result) = len + VARHDRSZ;
397389
memcpy(VARDATA(result), s, len);
398390

399-
#ifdef CYR_RECODE
400-
convertstr(VARDATA(result), len, 0);
401-
#endif
402-
403391
PG_RETURN_VARCHAR_P(result);
404392
}
405393

@@ -420,10 +408,6 @@ varcharout(PG_FUNCTION_ARGS)
420408
memcpy(result, VARDATA(s), len);
421409
result[len] = '\0';
422410

423-
#ifdef CYR_RECODE
424-
convertstr(result, len, 1);
425-
#endif
426-
427411
PG_RETURN_CSTRING(result);
428412
}
429413

src/backend/utils/adt/varlena.c

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
*
99
*
1010
* IDENTIFICATION
11-
* $Header: /cvsroot/pgsql/src/backend/utils/adt/varlena.c,v 1.104 2003/08/04 02:40:06 momjian Exp $
11+
* $Header: /cvsroot/pgsql/src/backend/utils/adt/varlena.c,v 1.105 2003/08/04 04:03:10 tgl Exp $
1212
*
1313
*-------------------------------------------------------------------------
1414
*/
@@ -268,10 +268,6 @@ textin(PG_FUNCTION_ARGS)
268268

269269
memcpy(VARDATA(result), inputText, len);
270270

271-
#ifdef CYR_RECODE
272-
convertstr(VARDATA(result), len, 0);
273-
#endif
274-
275271
PG_RETURN_TEXT_P(result);
276272
}
277273

@@ -290,10 +286,6 @@ textout(PG_FUNCTION_ARGS)
290286
memcpy(result, VARDATA(t), len);
291287
result[len] = '\0';
292288

293-
#ifdef CYR_RECODE
294-
convertstr(result, len, 1);
295-
#endif
296-
297289
PG_RETURN_CSTRING(result);
298290
}
299291

0 commit comments

Comments
 (0)