diff options
author | Sergey Poznyakoff <gray@nxc.no> | 2018-02-01 22:18:58 +0100 |
---|---|---|
committer | Sergey Poznyakoff <gray@nxc.no> | 2018-02-01 22:18:58 +0100 |
commit | 83919b99e222077a1bb61757403779cc4f456edc (patch) | |
tree | c2ffe0d33dae1f0051797fe5bbc9b10ef8f617b0 | |
parent | 8bba300e4118da5737b2f015028a9ca425e83628 (diff) | |
download | varnish-mib-83919b99e222077a1bb61757403779cc4f456edc.tar.gz varnish-mib-83919b99e222077a1bb61757403779cc4f456edc.tar.bz2 |
Minor changes
* bootstrap: Remove generation of m4/varnish_mib.m4
* src/varnish_mib.mib2c: Remove stray comment.
-rwxr-xr-x | bootstrap | 51 | ||||
-rw-r--r-- | src/varnish_mib.mib2c | 1 |
2 files changed, 0 insertions, 52 deletions
@@ -19,59 +19,8 @@ This file is a placeholder. It will be filled with actual data by the first | |||
19 | run of make. | 19 | run of make. |
20 | EOT | 20 | EOT |
21 | ; | 21 | ; |
22 | close $fd; | 22 | close $fd; |
23 | } | 23 | } |
24 | 24 | ||
25 | print "$0: generating m4/varnish_mib.m4\n"; | ||
26 | open(my $fd, '<', $mib2c_config); | ||
27 | my $prog; | ||
28 | while (<$fd>) { | ||
29 | if (defined($prog)) { | ||
30 | last if /^\@endperl\@/; | ||
31 | $prog .= $_; | ||
32 | } else { | ||
33 | if (/^\@startperl\@/) { | ||
34 | $prog = "no strict \"vars\";\n"; | ||
35 | } | ||
36 | } | ||
37 | } | ||
38 | |||
39 | my %vars; | ||
40 | eval $prog; | ||
41 | die $@ if $@; | ||
42 | die "$mib2c_config does not declare translation table" | ||
43 | unless exists $vars{'varnish_translate_table'}; | ||
44 | |||
45 | open(my $fd, '>', 'm4/varnish_mib.m4'); | ||
46 | print $fd <<'EOT'; | ||
47 | AC_DEFUN([AC_CHECK_VSC_C_MAIN_MEMBERS], | ||
48 | [save_CFLAGS="$CFLAGS" | ||
49 | CFLAGS="$CFLAGS $VARNISHAPI_CFLAGS" | ||
50 | EOT | ||
51 | ; | ||
52 | |||
53 | foreach my $member (sort | ||
54 | map { $_->[1] } | ||
55 | grep { $_->[0] eq 'MAIN' } | ||
56 | values %{$vars{'varnish_translate_table'}}) { | ||
57 | print $fd <<EOT | ||
58 | AC_CHECK_MEMBERS([struct VSC_C_main.$member],,, | ||
59 | [#include <stddef.h> | ||
60 | #include <stdlib.h> | ||
61 | #include <stdint.h> | ||
62 | #include <limits.h> | ||
63 | #include <vapi/vsc.h> | ||
64 | #include <vapi/vsm.h> | ||
65 | #include <vcli.h>]) | ||
66 | EOT | ||
67 | ; | ||
68 | } | ||
69 | print $fd <<'EOT' | ||
70 | CFLAGS="$save_CFLAGS" | ||
71 | ]) | ||
72 | EOT | ||
73 | ; | ||
74 | close $fd; | ||
75 | |||
76 | print "$0: reconfiguring\n"; | 25 | print "$0: reconfiguring\n"; |
77 | exec('autoreconf -f -i -s'); | 26 | exec('autoreconf -f -i -s'); |
diff --git a/src/varnish_mib.mib2c b/src/varnish_mib.mib2c index 155df42..6915689 100644 --- a/src/varnish_mib.mib2c +++ b/src/varnish_mib.mib2c | |||
@@ -250,13 +250,12 @@ varnish_get_vsm_data() | |||
250 | 250 | ||
251 | An instance handler only hands us one request at a time, unwrapping | 251 | An instance handler only hands us one request at a time, unwrapping |
252 | any eventual GETNEXT requests. | 252 | any eventual GETNEXT requests. |
253 | */ | 253 | */ |
254 | 254 | ||
255 | @foreach $i scalar@ | 255 | @foreach $i scalar@ |
256 | /* COMMX $i */ | ||
257 | @startperl@ | 256 | @startperl@ |
258 | &{$vars{'varnish_translate'}}($vars{'i'}); | 257 | &{$vars{'varnish_translate'}}($vars{'i'}); |
259 | @endperl@ | 258 | @endperl@ |
260 | @if $varnish_type ne 'NULL'@ | 259 | @if $varnish_type ne 'NULL'@ |
261 | $varnish_if | 260 | $varnish_if |
262 | static int | 261 | static int |