diff options
author | Ben Wiederhake <BenWiederhake.GitHub@gmx.de> | 2015-10-25 17:11:15 +0300 |
---|---|---|
committer | Ben Wiederhake <BenWiederhake.GitHub@gmx.de> | 2015-11-01 22:45:10 +0300 |
commit | 05d9680c36f3fcd62aebf2abd34e3622e03299af (patch) | |
tree | 5d15dec92b5478ee2411732770c41a3073fc5862 | |
parent | ed8503949adf61f77b6e29a63730b7cbce12e34b (diff) |
Drop code on --disable-extf
-rw-r--r-- | auto-static-print-ds.c | 5 | ||||
-rw-r--r-- | generate.c | 10 |
2 files changed, 14 insertions, 1 deletions
diff --git a/auto-static-print-ds.c b/auto-static-print-ds.c index cfec470..a0e645b 100644 --- a/auto-static-print-ds.c +++ b/auto-static-print-ds.c @@ -1,3 +1,8 @@ +#include "config.h" +#ifdef DISABLE_EXTF +#error "EXTF disabled, so nothing uses auto-print anymore." +#endif + static int multiline_output = 1; static int multiline_offset; static int multiline_offset_size = 2; @@ -2738,6 +2738,9 @@ void gen_store_ds_header (void) { } void gen_print_ds_header (void) { + printf ("#include \"config.h\"\n"); + printf ("#ifndef DISABLE_EXTF\n"); + printf ("\n"); printf ("#include \"auto.h\"\n"); printf ("#include \"auto-types.h\"\n"); printf ("#include <assert.h>\n"); @@ -2763,12 +2766,16 @@ void gen_print_ds_header (void) { printf ("DS, struct paramed_type *T);\n"); } printf ("int print_ds_type_any (void *DS, struct paramed_type *T);\n"); + printf ("#endif\n"); } void gen_print_ds_source (void) { + printf ("#include \"config.h\"\n"); + printf ("#ifndef DISABLE_EXTF\n"); + printf ("\n"); printf ("#include \"auto.h\"\n"); printf ("#include <assert.h>\n"); - + printf ("\n"); printf ("#include \"auto/auto-print-ds.h\"\n"); printf ("#include \"auto/auto-skip.h\"\n"); printf ("#include \"auto-static-print-ds.c\"\n"); @@ -2790,6 +2797,7 @@ void gen_print_ds_source (void) { } printf (" default: return -1; }\n"); printf ("}\n"); + printf ("#endif\n"); } int parse_tlo_file (void) { |