dropbear: cherry-pick upstream patches
[openwrt/staging/robimarko.git] / package / network / services / dropbear / patches / 007-fix-building-only-client-or-server.patch
1 From 7a53c7f0f4b3eb23e002819553cb45558642c01d Mon Sep 17 00:00:00 2001
2 From: Matt Johnston <matt@ucc.asn.au>
3 Date: Wed, 4 Jan 2023 20:32:23 +0800
4 Subject: Fix building only client or server
5
6 Regressed when -Wundef was added
7
8 Fixes #210
9 ---
10 sysoptions.h | 8 ++++++++
11 1 file changed, 8 insertions(+)
12
13 --- a/sysoptions.h
14 +++ b/sysoptions.h
15 @@ -10,6 +10,14 @@
16 #define LOCAL_IDENT "SSH-2.0-dropbear_" DROPBEAR_VERSION
17 #define PROGNAME "dropbear"
18
19 +#ifndef DROPBEAR_CLIENT
20 +#define DROPBEAR_CLIENT 0
21 +#endif
22 +
23 +#ifndef DROPBEAR_SERVER
24 +#define DROPBEAR_SERVER 0
25 +#endif
26 +
27 /* Spec recommends after one hour or 1 gigabyte of data. One hour
28 * is a bit too verbose, so we try 8 hours */
29 #ifndef KEX_REKEY_TIMEOUT