summaryrefslogtreecommitdiff
path: root/Build/source/texk/web2c
diff options
context:
space:
mode:
authorPeter Breitenlohner <peb@mppmu.mpg.de>2009-06-18 10:03:26 +0000
committerPeter Breitenlohner <peb@mppmu.mpg.de>2009-06-18 10:03:26 +0000
commit611243024d58336edbf2e252f8536f1513e0d5b5 (patch)
treecabd3266a88c01877b320775693ecbeb0c227ee1 /Build/source/texk/web2c
parente74f6b860dc92eb618499f365f405a2bc6bf9f98 (diff)
enable compiler warnings
git-svn-id: svn://tug.org/texlive/trunk@13809 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/source/texk/web2c')
-rw-r--r--Build/source/texk/web2c/omegafonts/ChangeLog23
-rw-r--r--Build/source/texk/web2c/omegafonts/Makefile.am1
-rw-r--r--Build/source/texk/web2c/omegafonts/Makefile.in1
-rw-r--r--Build/source/texk/web2c/omegafonts/char_routines.c2
-rw-r--r--Build/source/texk/web2c/omegafonts/dimen_routines.c6
-rw-r--r--Build/source/texk/web2c/omegafonts/error_routines.c1
-rw-r--r--Build/source/texk/web2c/omegafonts/extra_routines.c5
-rw-r--r--Build/source/texk/web2c/omegafonts/font_routines.c20
-rw-r--r--Build/source/texk/web2c/omegafonts/font_routines.h2
-rw-r--r--Build/source/texk/web2c/omegafonts/header_routines.c34
-rw-r--r--Build/source/texk/web2c/omegafonts/header_routines.h2
-rw-r--r--Build/source/texk/web2c/omegafonts/pl-lexer.c20
-rw-r--r--Build/source/texk/web2c/omegafonts/pl-lexer.l20
13 files changed, 84 insertions, 53 deletions
diff --git a/Build/source/texk/web2c/omegafonts/ChangeLog b/Build/source/texk/web2c/omegafonts/ChangeLog
index 3bf7b5d35c7..3bdcee0ab8a 100644
--- a/Build/source/texk/web2c/omegafonts/ChangeLog
+++ b/Build/source/texk/web2c/omegafonts/ChangeLog
@@ -1,3 +1,26 @@
+2009-06-17 Peter Breitenlohner <peb@mppmu.mpg.de>
+
+ * Makefile.am (AM_CFLAGS): enable compiler warnings.
+
+ * char_routines.c (get_char_remainder): declare as static.
+ * dimen_routines.c (min_cover, shorten, set_indices):
+ declare as static.
+ * error_routines.c: #include "error_routines.h".
+ * extra_routines.c (init_all_tables): declare as static, unused.
+ * font_routines.c (font_no_incr, packet_ptr_incr, append_to_packet,
+ move_ptr_decr, move_ptr_incr, output_ovf_fonts, in_ovf_4,
+ in_ovf_unsigned_4, in_ovf_3, in_ovf): declare as static.
+ * font_routines.h (in_ovf_4, in_ovf_unsigned_4):
+ remove declaration as external.
+ * header_routines.c (init_header_word, store_header_word,
+ retrieve_header_word, init_face, init_seven_bit_safe_flag):
+ declare as static.
+ (init_ofm_level, init_font_dir): declare as static, unused.
+ * header_routines.h (init_face, init_seven_bit_safe_flag):
+ remove declaration as external.
+ * pl-lexer.l (scan_int, scan_char, scan_fix, scan_string,
+ scan_hex_string): declare as static.
+
2009-06-16 Peter Breitenlohner <peb@mppmu.mpg.de>
* Makefile.am: pl-lexer.l provides yywrap, no need for $(LEXLIB).
diff --git a/Build/source/texk/web2c/omegafonts/Makefile.am b/Build/source/texk/web2c/omegafonts/Makefile.am
index 6fa46691067..645af150332 100644
--- a/Build/source/texk/web2c/omegafonts/Makefile.am
+++ b/Build/source/texk/web2c/omegafonts/Makefile.am
@@ -4,6 +4,7 @@
## You may freely use, modify and/or distribute this file.
##
INCLUDES = -I$(top_builddir)/.. -I$(top_srcdir) $(KPATHSEA_INCLUDES)
+AM_CFLAGS = $(WARNING_CFLAGS)
AM_YFLAGS = -d -v
proglib = ../lib/lib.a
diff --git a/Build/source/texk/web2c/omegafonts/Makefile.in b/Build/source/texk/web2c/omegafonts/Makefile.in
index 4e58397de99..df2d12a0ca6 100644
--- a/Build/source/texk/web2c/omegafonts/Makefile.in
+++ b/Build/source/texk/web2c/omegafonts/Makefile.in
@@ -296,6 +296,7 @@ wlibs = @wlibs@
x_ext_lib = @x_ext_lib@
x_tool_libs = @x_tool_libs@
INCLUDES = -I$(top_builddir)/.. -I$(top_srcdir) $(KPATHSEA_INCLUDES)
+AM_CFLAGS = $(WARNING_CFLAGS)
AM_YFLAGS = -d -v
proglib = ../lib/lib.a
omfonts_SOURCES = \
diff --git a/Build/source/texk/web2c/omegafonts/char_routines.c b/Build/source/texk/web2c/omegafonts/char_routines.c
index 169479235cc..d5f5a26c54f 100644
--- a/Build/source/texk/web2c/omegafonts/char_routines.c
+++ b/Build/source/texk/web2c/omegafonts/char_routines.c
@@ -536,7 +536,7 @@ set_char_remainder(unsigned c, unsigned remainder)
planes[c/PLANE][c%PLANE]->remainder = remainder;
}
-int
+static int
get_char_remainder(unsigned c)
{
ensure_existence(c);
diff --git a/Build/source/texk/web2c/omegafonts/dimen_routines.c b/Build/source/texk/web2c/omegafonts/dimen_routines.c
index 94ec26ce492..d8aa3efbff6 100644
--- a/Build/source/texk/web2c/omegafonts/dimen_routines.c
+++ b/Build/source/texk/web2c/omegafonts/dimen_routines.c
@@ -135,7 +135,7 @@ int next_d;
int excess;
int delta;
-int
+static int
min_cover(int h, int d)
{
in_list L = measure_list[h];
@@ -154,7 +154,7 @@ min_cover(int h, int d)
/* finds best way to round */
-int
+static int
shorten(int h, int m)
{
int d=0; /* the current trial interval length */
@@ -180,7 +180,7 @@ shorten(int h, int m)
/* reduces and indexes a list */
-void
+static void
set_indices(int h, int d)
{
in_list L1; /* the current node of interest */
diff --git a/Build/source/texk/web2c/omegafonts/error_routines.c b/Build/source/texk/web2c/omegafonts/error_routines.c
index dfb234cb539..a727e26c397 100644
--- a/Build/source/texk/web2c/omegafonts/error_routines.c
+++ b/Build/source/texk/web2c/omegafonts/error_routines.c
@@ -23,6 +23,7 @@ along with Omega; if not, write to the Free Software Foundation, Inc.,
#include "cpascal.h"
#include "parser.h"
+#include "error_routines.h"
/* Error routines:
diff --git a/Build/source/texk/web2c/omegafonts/extra_routines.c b/Build/source/texk/web2c/omegafonts/extra_routines.c
index 924417f2f27..afb68a48907 100644
--- a/Build/source/texk/web2c/omegafonts/extra_routines.c
+++ b/Build/source/texk/web2c/omegafonts/extra_routines.c
@@ -127,7 +127,9 @@ output_ofm_extra_stuff(void)
}
}
-void
+#if 0
+/* Not used */
+static void
init_all_tables(void)
{
unsigned i=0;
@@ -141,6 +143,7 @@ init_all_tables(void)
glue_tables[i] = NULL;
}
}
+#endif
void
init_font_ivalue(unsigned tab)
diff --git a/Build/source/texk/web2c/omegafonts/font_routines.c b/Build/source/texk/web2c/omegafonts/font_routines.c
index 32be7d412a6..50ed5690f50 100644
--- a/Build/source/texk/web2c/omegafonts/font_routines.c
+++ b/Build/source/texk/web2c/omegafonts/font_routines.c
@@ -54,7 +54,7 @@ font_table_init(void)
no_fonts = 0;
}
-void
+static void
font_no_incr(void)
{
if (no_fonts * BLOCK == font_table_size) {
@@ -210,7 +210,7 @@ packet_table_init(void)
cur_packet = packet_table;
}
-void
+static void
packet_ptr_incr(void)
{
if (packet_ptr == packet_table_size) {
@@ -221,7 +221,7 @@ packet_ptr_incr(void)
packet_ptr++;
}
-void
+static void
append_to_packet(unsigned val)
{
packet_ptr_incr();
@@ -413,7 +413,7 @@ packet_table_end(void)
}
-void
+static void
move_ptr_decr(void)
{
if (move_ptr==0)
@@ -422,7 +422,7 @@ move_ptr_decr(void)
cur_move = &move_table[move_ptr];
}
-void
+static void
move_ptr_incr(void)
{
if (move_ptr == move_table_size) {
@@ -569,7 +569,7 @@ out_ovf_4(unsigned i)
file_ovf_count += 4;
}
-void
+static void
output_ovf_fonts(void)
{
unsigned i, j, k1, k2;
@@ -623,7 +623,7 @@ output_ovf_file(void)
} while ((file_ovf_count % 4) != 0);
}
-void
+static void
in_ovf_4(int *value)
{
*value = (((*ovf_ptr) & 0xff) << 24) |
@@ -633,7 +633,7 @@ in_ovf_4(int *value)
ovf_ptr += 4;
}
-void
+static void
in_ovf_unsigned_4(unsigned *value)
{
*value = (((*ovf_ptr) & 0xff) << 24) |
@@ -643,7 +643,7 @@ in_ovf_unsigned_4(unsigned *value)
ovf_ptr += 4;
}
-void
+static void
in_ovf_3(int *value)
{
*value = (((*ovf_ptr) & 0xff) << 16) |
@@ -652,7 +652,7 @@ in_ovf_3(int *value)
ovf_ptr += 3;
}
-void
+static void
in_ovf(int *value)
{
*value = (*ovf_ptr) & 0xff;
diff --git a/Build/source/texk/web2c/omegafonts/font_routines.h b/Build/source/texk/web2c/omegafonts/font_routines.h
index 4aafa6647be..d4576a7dc6f 100644
--- a/Build/source/texk/web2c/omegafonts/font_routines.h
+++ b/Build/source/texk/web2c/omegafonts/font_routines.h
@@ -94,5 +94,3 @@ extern void input_command(unsigned *, int *);
extern void input_ovf_fonts(void);
extern void input_ovf_chars(void);
extern void input_ovf_file(void);
-extern void in_ovf_4(int *);
-extern void in_ovf_unsigned_4(unsigned *);
diff --git a/Build/source/texk/web2c/omegafonts/header_routines.c b/Build/source/texk/web2c/omegafonts/header_routines.c
index 48e3ef00ec6..994e5cbd708 100644
--- a/Build/source/texk/web2c/omegafonts/header_routines.c
+++ b/Build/source/texk/web2c/omegafonts/header_routines.c
@@ -112,8 +112,8 @@ retrieve_header_byte(unsigned loc, unsigned char *where)
/* HEADER */
-void
-init_header_word()
+static void
+init_header_word(void)
{
header_list = NULL;
header_max = HEADER_MIN-1;
@@ -159,8 +159,8 @@ set_header_word(unsigned index, unsigned val)
}
}
-void
-store_header_word()
+static void
+store_header_word(void)
{
av_list L = header_list;
unsigned ctr = HEADER_MIN;
@@ -176,8 +176,8 @@ store_header_word()
}
}
-void
-retrieve_header_word()
+static void
+retrieve_header_word(void)
{
unsigned j = HEADER_MIN, value, header_no=lh;
@@ -426,8 +426,8 @@ retrieve_family(void)
/* FACE */
-void
-init_face()
+static void
+init_face(void)
{
face = 0;
face_specified = FALSE;
@@ -462,12 +462,15 @@ retrieve_face(void)
/* OFMLEVEL */
-void
-init_ofm_level()
+#if 0
+/* Not yet used */
+static void
+init_ofm_level(void)
{
ofm_level = OFM_TFM;
ofm_level_specified = FALSE;
}
+#endif
void
set_ofm_level(unsigned level)
@@ -485,12 +488,15 @@ set_ofm_level(unsigned level)
/* FONTDIR */
-void
-init_font_dir()
+#if 0
+/* Not yet used */
+static void
+init_font_dir(void)
{
font_dir = DIR_ORD+DIR_TL;
font_dir_specified = FALSE;
}
+#endif
void
set_font_dir(unsigned direction)
@@ -507,8 +513,8 @@ set_font_dir(unsigned direction)
/* SEVENBITSAFEFLAG */
-void
-init_seven_bit_safe_flag()
+static void
+init_seven_bit_safe_flag(void)
{
seven_bit = 0;
seven_bit_calculated = 1;
diff --git a/Build/source/texk/web2c/omegafonts/header_routines.h b/Build/source/texk/web2c/omegafonts/header_routines.h
index 44b2483e03a..d06eee048fa 100644
--- a/Build/source/texk/web2c/omegafonts/header_routines.h
+++ b/Build/source/texk/web2c/omegafonts/header_routines.h
@@ -86,12 +86,10 @@ extern void set_family(string );
extern void store_family(void);
extern void retrieve_family(void);
-extern void init_face();
extern void set_face(unsigned);
extern void store_face(void);
extern void retrieve_face(void);
-extern void init_seven_bit_safe_flag();
extern void set_seven_bit_safe_flag(unsigned);
extern void store_seven_bit_safe_flag(void);
extern void retrieve_seven_bit_safe_flag(void);
diff --git a/Build/source/texk/web2c/omegafonts/pl-lexer.c b/Build/source/texk/web2c/omegafonts/pl-lexer.c
index 3b3b1fbefb4..bc4090fb839 100644
--- a/Build/source/texk/web2c/omegafonts/pl-lexer.c
+++ b/Build/source/texk/web2c/omegafonts/pl-lexer.c
@@ -1024,11 +1024,11 @@ extern YYSTYPE yylval;
#define MAX_PTR 10000
char saved_text[MAX_PTR];
-extern void scan_int(unsigned);
-extern void scan_char(void);
-extern void scan_fix(void);
-extern void scan_string(char *, unsigned, unsigned);
-extern void scan_hex_string();
+static void scan_int(unsigned);
+static void scan_char(void);
+static void scan_fix(void);
+static void scan_string(char *, unsigned, unsigned);
+static void scan_hex_string(void);
/* from kpathsea, but avoid including kpathsea header files */
extern char *xstrdup (const char *);
@@ -3323,7 +3323,7 @@ int
yywrap (void)
{ return 1; }
-void
+static void
scan_int(unsigned base)
{
register unsigned j, q = 0x10000 / base, c0=0, c1=0, i=1;
@@ -3347,7 +3347,7 @@ scan_int(unsigned base)
yylval.yint = c0 * 0x10000 + c1;
}
-void
+static void
scan_fix(void)
{
unsigned i=1;
@@ -3391,7 +3391,7 @@ scan_fix(void)
yylval.yfix = sign * (int_part*UNITY + acc);
}
-void
+static void
scan_char(void)
{
register unsigned i=1;
@@ -3405,7 +3405,7 @@ scan_char(void)
} else yylval.yint = yytext[i];
}
-void
+static void
scan_string(char *attribute, unsigned keep, unsigned length)
{
register unsigned c, saved_ptr = 0, paren_level = 0;
@@ -3466,7 +3466,7 @@ scan_string(char *attribute, unsigned keep, unsigned length)
}
}
-void
+static void
scan_hex_string(void)
{
register unsigned i=10;
diff --git a/Build/source/texk/web2c/omegafonts/pl-lexer.l b/Build/source/texk/web2c/omegafonts/pl-lexer.l
index 3174ffca8b0..5eba855a25a 100644
--- a/Build/source/texk/web2c/omegafonts/pl-lexer.l
+++ b/Build/source/texk/web2c/omegafonts/pl-lexer.l
@@ -47,11 +47,11 @@ extern YYSTYPE yylval;
#define MAX_PTR 10000
char saved_text[MAX_PTR];
-extern void scan_int(unsigned);
-extern void scan_char(void);
-extern void scan_fix(void);
-extern void scan_string(char *, unsigned, unsigned);
-extern void scan_hex_string();
+static void scan_int(unsigned);
+static void scan_char(void);
+static void scan_fix(void);
+static void scan_string(char *, unsigned, unsigned);
+static void scan_hex_string(void);
/* from kpathsea, but avoid including kpathsea header files */
extern char *xstrdup (const char *);
@@ -333,7 +333,7 @@ int
yywrap (void)
{ return 1; }
-void
+static void
scan_int(unsigned base)
{
register unsigned j, q = 0x10000 / base, c0=0, c1=0, i=1;
@@ -357,7 +357,7 @@ scan_int(unsigned base)
yylval.yint = c0 * 0x10000 + c1;
}
-void
+static void
scan_fix(void)
{
unsigned i=1;
@@ -401,7 +401,7 @@ scan_fix(void)
yylval.yfix = sign * (int_part*UNITY + acc);
}
-void
+static void
scan_char(void)
{
register unsigned i=1;
@@ -415,7 +415,7 @@ scan_char(void)
} else yylval.yint = yytext[i];
}
-void
+static void
scan_string(char *attribute, unsigned keep, unsigned length)
{
register unsigned c, saved_ptr = 0, paren_level = 0;
@@ -476,7 +476,7 @@ scan_string(char *attribute, unsigned keep, unsigned length)
}
}
-void
+static void
scan_hex_string(void)
{
register unsigned i=10;