diff options
author | Nils Gillmann <ng0@n0.is> | 2018-05-19 14:43:13 +0000 |
---|---|---|
committer | Nils Gillmann <ng0@n0.is> | 2018-05-19 14:43:13 +0000 |
commit | 6ab60d4920bb3199aee8cd872b930e9e3e808ba7 (patch) | |
tree | 3d761dbf8793a1d2422fbd14667255c7e0292ea4 /contrib/patches | |
parent | c2f27dfe8218545c327ab49d225a49910347c5c6 (diff) | |
download | gnunet-6ab60d4920bb3199aee8cd872b930e9e3e808ba7.tar.gz gnunet-6ab60d4920bb3199aee8cd872b930e9e3e808ba7.zip |
Restructure contrib folder.
contrib/pogen.sh -> bin/pogen.sh
bootstrap: Use new pogen location and execute it.
contrib/openvpn-tap32: Move to contrib/3rdparty/Windows/openvpn-tap32.
contrib/gnunet-logo*: Move to contrib/branding/logo/
Delete old patches in contrib, predating git.
Move buildbot data to contrib/ci/buildbot,
move docker data to contrib/ci/docker.
Create contrib/conf and populate it with config files found in contrib and bin.
Move gns related data to contrib/gns.
delete contrib/repeat.sh
Move contrib/log.php into contrib/web/log.php.
Create folder contrib/scripts and use it for most scripts in contrib.
Remove trailing whitespace in doc/Makefile.am
Signed-off-by: Nils Gillmann <ng0@n0.is>
Diffstat (limited to 'contrib/patches')
-rw-r--r-- | contrib/patches/lrn-indent.diff | 83 | ||||
-rw-r--r-- | contrib/patches/texi2html5-indent.diff | 42 | ||||
-rw-r--r-- | contrib/patches/transport_ats_years.diff | 132 |
3 files changed, 257 insertions, 0 deletions
diff --git a/contrib/patches/lrn-indent.diff b/contrib/patches/lrn-indent.diff new file mode 100644 index 000000000..8ba3b77cc --- /dev/null +++ b/contrib/patches/lrn-indent.diff | |||
@@ -0,0 +1,83 @@ | |||
1 | diff -u indent-2.2.11/src/args.c indent-2.2.11.my/src/args.c | ||
2 | --- indent-2.2.11/src/args.c 2008-07-23 23:27:17 +0400 | ||
3 | +++ indent-2.2.11.my/src/args.c 2011-08-16 14:07:30 +0400 | ||
4 | @@ -151,6 +151,7 @@ | ||
5 | static int exp_cpp = 0; | ||
6 | static int exp_cs = 0; | ||
7 | static int exp_d = 0; | ||
8 | +static int exp_ddd = 0; | ||
9 | static int exp_bfda = 0; | ||
10 | static int exp_bfde = 0; | ||
11 | static int exp_di = 0; | ||
12 | @@ -317,6 +318,8 @@ | ||
13 | {"fca", PRO_BOOL, true, ON, &settings.format_comments, &exp_fca}, | ||
14 | {"fc1", PRO_BOOL, true, ON, &settings.format_col1_comments, &exp_fc1}, | ||
15 | {"eei", PRO_BOOL, false, ON, &settings.extra_expression_indent, &exp_eei}, | ||
16 | + {"ddd", PRO_BOOL, true, ON, &settings.diff_decls_and_defs, &exp_ddd}, | ||
17 | + {"nddd", PRO_BOOL, true, OFF, &settings.diff_decls_and_defs, &exp_ddd}, | ||
18 | {"dj", PRO_BOOL, false, ON, &settings.ljust_decl, &exp_dj}, | ||
19 | {"di", PRO_INT, 16, ONOFF_NA, &settings.decl_indent, &exp_di}, | ||
20 | {"d", PRO_INT, 0, ONOFF_NA, &settings.unindent_displace, &exp_d}, | ||
21 | @@ -436,6 +439,8 @@ | ||
22 | {"fca", PRO_BOOL, false, ON, &settings.format_comments, &exp_fca}, | ||
23 | {"fc1", PRO_BOOL, false, ON, &settings.format_col1_comments, &exp_fc1}, | ||
24 | {"eei", PRO_BOOL, false, ON, &settings.extra_expression_indent, &exp_eei}, | ||
25 | + {"ddd", PRO_BOOL, true, ON, &settings.diff_decls_and_defs, &exp_ddd}, | ||
26 | + {"nddd", PRO_BOOL, true, OFF, &settings.diff_decls_and_defs, &exp_ddd}, | ||
27 | {"dj", PRO_BOOL, false, ON, &settings.ljust_decl, &exp_dj}, | ||
28 | {"di", PRO_INT, 2, ONOFF_NA, &settings.decl_indent, &exp_di}, | ||
29 | {"d", PRO_INT, 0, ONOFF_NA, &settings.unindent_displace, &exp_d}, | ||
30 | diff -u indent-2.2.11/src/handletoken.c indent-2.2.11.my/src/handletoken.c | ||
31 | --- indent-2.2.11/src/handletoken.c 2009-02-15 14:20:42 +0300 | ||
32 | +++ indent-2.2.11.my/src/handletoken.c 2011-08-16 14:18:28 +0400 | ||
33 | @@ -1642,6 +1642,11 @@ | ||
34 | { | ||
35 | /* what ? */ | ||
36 | } | ||
37 | + if (parser_state_tos->in_parameter_declaration_prototype) | ||
38 | + { | ||
39 | + parser_state_tos->in_parameter_declaration_prototype = 0; | ||
40 | + parser_state_tos->in_parameter_declaration = 0; | ||
41 | + } | ||
42 | } | ||
43 | |||
44 | /** | ||
45 | diff -u indent-2.2.11/src/indent.h indent-2.2.11.my/src/indent.h | ||
46 | --- indent-2.2.11/src/indent.h 2009-10-11 23:15:34 +0400 | ||
47 | +++ indent-2.2.11.my/src/indent.h 2011-08-16 14:19:37 +0400 | ||
48 | @@ -318,6 +318,11 @@ | ||
49 | int brace_indent; /*!< number of spaces to indent braces from the suround if, while, etc. in -bl | ||
50 | * (bype_2 == 0) code */ | ||
51 | int expect_output_file; /*!< Means "-o" was specified. */ | ||
52 | + int diff_decls_and_defs; /*!< Makes indent think that function prototypes are terminated by ';', | ||
53 | + * without this option indent will not be able to tell a difference between | ||
54 | + * int foo (); and int foo () {} | ||
55 | + * This is the default. | ||
56 | + */ | ||
57 | } user_options_ty; | ||
58 | |||
59 | extern user_options_ty settings; | ||
60 | @@ -430,6 +435,7 @@ | ||
61 | * slightly different */ | ||
62 | int in_stmt; /*!< set to 1 while in a stmt */ | ||
63 | int in_parameter_declaration; | ||
64 | + int in_parameter_declaration_prototype; | ||
65 | int ind_level; /*!< the current indentation level in spaces */ | ||
66 | int ind_stmt; /*!< set to 1 if next line should have an extra | ||
67 | * indentation level because we are in the | ||
68 | diff -u indent-2.2.11/src/lexi.c indent-2.2.11.my/src/lexi.c | ||
69 | --- indent-2.2.11/src/lexi.c 2009-11-11 22:36:32 +0300 | ||
70 | +++ indent-2.2.11.my/src/lexi.c 2011-08-16 14:14:28 +0400 | ||
71 | @@ -616,8 +616,11 @@ | ||
72 | * I've added '=' to this list to keep from breaking | ||
73 | * a non-valid C macro from libc. -jla */ | ||
74 | |||
75 | - if (*tp != ';' && *tp != ',' && *tp != '(' && *tp != '=') | ||
76 | + if ((*tp != ';' || !settings.diff_decls_and_defs) && | ||
77 | + *tp != ',' && *tp != '(' && *tp != '=') | ||
78 | { | ||
79 | + if (*tp == ';') | ||
80 | + parser_state_tos->in_parameter_declaration_prototype = 1; | ||
81 | parser_state_tos->in_parameter_declaration = 1; | ||
82 | } | ||
83 | } | ||
diff --git a/contrib/patches/texi2html5-indent.diff b/contrib/patches/texi2html5-indent.diff new file mode 100644 index 000000000..2abbcb766 --- /dev/null +++ b/contrib/patches/texi2html5-indent.diff | |||
@@ -0,0 +1,42 @@ | |||
1 | diff -ru indent-gnunet/doc/Makefile.am indent-texi2html5/doc/Makefile.am | ||
2 | --- indent-gnunet/doc/Makefile.am 2008-04-14 20:31:19.000000000 +0200 | ||
3 | +++ indent-texi2html5/doc/Makefile.am 2011-08-22 20:24:26.979782439 +0200 | ||
4 | @@ -34,14 +34,14 @@ | ||
5 | html-split: @PACKAGE@_toc.html | ||
6 | |||
7 | @PACKAGE@.html: version.texi $(@PACKAGE@_TEXINFOS) | ||
8 | - $(TEXI2HTML) -expandinfo -number -monolithic `if test -f @PACKAGE@.texinfo; then echo @PACKAGE@.texinfo; else echo $(srcdir)/@PACKAGE@.texinfo; fi` | ||
9 | + $(TEXI2HTML) -expandinfo -monolithic `if test -f @PACKAGE@.texinfo; then echo @PACKAGE@.texinfo; else echo $(srcdir)/@PACKAGE@.texinfo; fi` | ||
10 | |||
11 | @PACKAGE@_toc.html: version.texi $(@PACKAGE@_TEXINFOS) | ||
12 | case "$(TEXI2HTML)" in \ | ||
13 | *"/missing texi2html") \ | ||
14 | - $(TEXI2HTML) -expand info -number -nomenu -split section `if test -f @PACKAGE@.texinfo; then echo @PACKAGE@.texinfo; else echo $(srcdir)/@PACKAGE@.texinfo; fi` || exit 0 ;; \ | ||
15 | + $(TEXI2HTML) -expand info -nomenu -split section `if test -f @PACKAGE@.texinfo; then echo @PACKAGE@.texinfo; else echo $(srcdir)/@PACKAGE@.texinfo; fi` || exit 0 ;; \ | ||
16 | *) $(RM) @PACKAGE@_*.html ; \ | ||
17 | - $(TEXI2HTML) -expand info -number -nomenu -split section `if test -f @PACKAGE@.texinfo; then echo @PACKAGE@.texinfo; else echo $(srcdir)/@PACKAGE@.texinfo; fi` ;; \ | ||
18 | + $(TEXI2HTML) -expand info -nomenu -split section `if test -f @PACKAGE@.texinfo; then echo @PACKAGE@.texinfo; else echo $(srcdir)/@PACKAGE@.texinfo; fi` ;; \ | ||
19 | esac | ||
20 | |||
21 | install-html-monolithic: @PACKAGE@.html | ||
22 | diff -ru indent-gnunet/doc/Makefile.in indent-texi2html5/doc/Makefile.in | ||
23 | --- indent-gnunet/doc/Makefile.in 2010-01-31 17:25:21.000000000 +0100 | ||
24 | +++ indent-texi2html5/doc/Makefile.in 2011-08-22 20:24:41.376449156 +0200 | ||
25 | @@ -663,14 +663,14 @@ | ||
26 | html-split: @PACKAGE@_toc.html | ||
27 | |||
28 | @PACKAGE@.html: version.texi $(@PACKAGE@_TEXINFOS) | ||
29 | - $(TEXI2HTML) -expandinfo -number -monolithic `if test -f @PACKAGE@.texinfo; then echo @PACKAGE@.texinfo; else echo $(srcdir)/@PACKAGE@.texinfo; fi` | ||
30 | + $(TEXI2HTML) -expandinfo -monolithic `if test -f @PACKAGE@.texinfo; then echo @PACKAGE@.texinfo; else echo $(srcdir)/@PACKAGE@.texinfo; fi` | ||
31 | |||
32 | @PACKAGE@_toc.html: version.texi $(@PACKAGE@_TEXINFOS) | ||
33 | case "$(TEXI2HTML)" in \ | ||
34 | *"/missing texi2html") \ | ||
35 | - $(TEXI2HTML) -expand info -number -nomenu -split section `if test -f @PACKAGE@.texinfo; then echo @PACKAGE@.texinfo; else echo $(srcdir)/@PACKAGE@.texinfo; fi` || exit 0 ;; \ | ||
36 | + $(TEXI2HTML) -expand info -nomenu -split section `if test -f @PACKAGE@.texinfo; then echo @PACKAGE@.texinfo; else echo $(srcdir)/@PACKAGE@.texinfo; fi` || exit 0 ;; \ | ||
37 | *) $(RM) @PACKAGE@_*.html ; \ | ||
38 | - $(TEXI2HTML) -expand info -number -nomenu -split section `if test -f @PACKAGE@.texinfo; then echo @PACKAGE@.texinfo; else echo $(srcdir)/@PACKAGE@.texinfo; fi` ;; \ | ||
39 | + $(TEXI2HTML) -expand info -nomenu -split section `if test -f @PACKAGE@.texinfo; then echo @PACKAGE@.texinfo; else echo $(srcdir)/@PACKAGE@.texinfo; fi` ;; \ | ||
40 | esac | ||
41 | |||
42 | install-html-monolithic: @PACKAGE@.html | ||
diff --git a/contrib/patches/transport_ats_years.diff b/contrib/patches/transport_ats_years.diff new file mode 100644 index 000000000..f48c9555d --- /dev/null +++ b/contrib/patches/transport_ats_years.diff | |||
@@ -0,0 +1,132 @@ | |||
1 | Index: src/ats/ats_api_scheduling.c | ||
2 | =================================================================== | ||
3 | --- src/ats/ats_api_scheduling.c (revision 29617) | ||
4 | +++ src/ats/ats_api_scheduling.c (working copy) | ||
5 | @@ -28,7 +28,7 @@ | ||
6 | #include "ats.h" | ||
7 | |||
8 | |||
9 | -#define INTERFACE_PROCESSING_INTERVALL GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_SECONDS, 1) | ||
10 | +#define INTERFACE_PROCESSING_INTERVALL GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_YEARS, 1) | ||
11 | |||
12 | #define NOT_FOUND 0 | ||
13 | |||
14 | Index: src/ats/gnunet-service-ats-solver_proportional.c | ||
15 | =================================================================== | ||
16 | --- src/ats/gnunet-service-ats-solver_proportional.c (revision 29617) | ||
17 | +++ src/ats/gnunet-service-ats-solver_proportional.c (working copy) | ||
18 | @@ -205,12 +205,12 @@ | ||
19 | * | ||
20 | */ | ||
21 | |||
22 | -#define PREF_AGING_INTERVAL GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_SECONDS, 10) | ||
23 | +#define PREF_AGING_INTERVAL GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_YEARS, 10) | ||
24 | #define PREF_AGING_FACTOR 0.95 | ||
25 | |||
26 | #define DEFAULT_REL_PREFERENCE 1.0 | ||
27 | #define DEFAULT_ABS_PREFERENCE 0.0 | ||
28 | -#define MIN_UPDATE_INTERVAL GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_SECONDS, 10) | ||
29 | +#define MIN_UPDATE_INTERVAL GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_YEARS, 10) | ||
30 | |||
31 | /** | ||
32 | * A handle for the proportional solver | ||
33 | Index: src/ats/gnunet-service-ats_normalization.h | ||
34 | =================================================================== | ||
35 | --- src/ats/gnunet-service-ats_normalization.h (revision 29617) | ||
36 | +++ src/ats/gnunet-service-ats_normalization.h (working copy) | ||
37 | @@ -27,7 +27,7 @@ | ||
38 | #include "platform.h" | ||
39 | #include "gnunet_ats_service.h" | ||
40 | |||
41 | -#define PREF_AGING_INTERVAL GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_SECONDS, 10) | ||
42 | +#define PREF_AGING_INTERVAL GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_YEARS, 10) | ||
43 | #define PREF_AGING_FACTOR 0.95 | ||
44 | #define PREF_EPSILON 0.1 | ||
45 | |||
46 | Index: src/include/gnunet_constants.h | ||
47 | =================================================================== | ||
48 | --- src/include/gnunet_constants.h (revision 29617) | ||
49 | +++ src/include/gnunet_constants.h (working copy) | ||
50 | @@ -49,7 +49,7 @@ | ||
51 | * After how long do we consider a connection to a peer dead | ||
52 | * if we don't receive messages from the peer? | ||
53 | */ | ||
54 | -#define GNUNET_CONSTANTS_IDLE_CONNECTION_TIMEOUT GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_MINUTES, 5) | ||
55 | +#define GNUNET_CONSTANTS_IDLE_CONNECTION_TIMEOUT GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_YEARS, 5) | ||
56 | |||
57 | /** | ||
58 | * How long do we delay reading more from a peer after a quota violation? | ||
59 | @@ -61,7 +61,7 @@ | ||
60 | * even if we assume that the service commonly does not | ||
61 | * respond instantly (DNS, Database, etc.). | ||
62 | */ | ||
63 | -#define GNUNET_CONSTANTS_SERVICE_TIMEOUT GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_MINUTES, 10) | ||
64 | +#define GNUNET_CONSTANTS_SERVICE_TIMEOUT GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_YEARS, 10) | ||
65 | |||
66 | /** | ||
67 | * How long do we delay messages to get larger packet sizes (CORKing)? | ||
68 | Index: src/transport/gnunet-service-transport_neighbours.c | ||
69 | =================================================================== | ||
70 | --- src/transport/gnunet-service-transport_neighbours.c (revision 29617) | ||
71 | +++ src/transport/gnunet-service-transport_neighbours.c (working copy) | ||
72 | @@ -65,7 +65,7 @@ | ||
73 | * send 3 keepalives in each interval, so 3 messages would need to be | ||
74 | * lost in a row for a disconnect). | ||
75 | */ | ||
76 | -#define KEEPALIVE_FREQUENCY GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_SECONDS, 100) | ||
77 | +#define KEEPALIVE_FREQUENCY GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_YEARS, 100) | ||
78 | |||
79 | /** | ||
80 | * How long are we willing to wait for a response from ATS before timing out? | ||
81 | Index: src/transport/gnunet-service-transport_validation.c | ||
82 | =================================================================== | ||
83 | --- src/transport/gnunet-service-transport_validation.c (revision 29617) | ||
84 | +++ src/transport/gnunet-service-transport_validation.c (working copy) | ||
85 | @@ -42,7 +42,7 @@ | ||
86 | * OTOH, we don't want to spend too much time generating PONG signatures, | ||
87 | * so they must have some lifetime to reduce our CPU usage. | ||
88 | */ | ||
89 | -#define PONG_SIGNATURE_LIFETIME GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_HOURS, 1) | ||
90 | +#define PONG_SIGNATURE_LIFETIME GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_HOURS, 12) | ||
91 | |||
92 | /** | ||
93 | * After how long do we expire an address in a HELLO that we just | ||
94 | @@ -57,7 +57,7 @@ | ||
95 | * we cannot validate (because after this time we can destroy the | ||
96 | * validation record). | ||
97 | */ | ||
98 | -#define UNVALIDATED_PING_KEEPALIVE GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_MINUTES, 5) | ||
99 | +#define UNVALIDATED_PING_KEEPALIVE GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_HOURS, 4) | ||
100 | |||
101 | /** | ||
102 | * How often do we PING an address that we have successfully validated | ||
103 | @@ -64,17 +64,17 @@ | ||
104 | * in the past but are not actively using? Should be (significantly) | ||
105 | * smaller than HELLO_ADDRESS_EXPIRATION. | ||
106 | */ | ||
107 | -#define VALIDATED_PING_FREQUENCY GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_MINUTES, 15) | ||
108 | +#define VALIDATED_PING_FREQUENCY GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_HOURS, 6) | ||
109 | |||
110 | /** | ||
111 | * How often do we PING an address that we are currently using? | ||
112 | */ | ||
113 | -#define CONNECTED_PING_FREQUENCY GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_MINUTES, 2) | ||
114 | +#define CONNECTED_PING_FREQUENCY GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_YEARS, 2) | ||
115 | |||
116 | /** | ||
117 | * How much delay is acceptable for sending the PING or PONG? | ||
118 | */ | ||
119 | -#define ACCEPTABLE_PING_DELAY GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_SECONDS, 1) | ||
120 | +#define ACCEPTABLE_PING_DELAY GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_MINUTES, 1) | ||
121 | |||
122 | /** | ||
123 | * Size of the validation map hashmap. | ||
124 | @@ -807,7 +807,7 @@ | ||
125 | */ | ||
126 | |||
127 | validation_next = GNUNET_TIME_absolute_get(); | ||
128 | - validation_delay.rel_value_us = (GNUNET_CONSTANTS_IDLE_CONNECTION_TIMEOUT.rel_value_us) / (max_fds / 2); | ||
129 | + validation_delay.rel_value_us = GNUNET_TIME_UNIT_MILLISECONDS.rel_value_us; | ||
130 | validations_fast_start_threshold = (max_fds / 2); | ||
131 | validations_running = 0; | ||
132 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Validation uses a fast start threshold of %u connections and a delay between of %s\n ", | ||