cmake,options: Allow to set global client config file

This allows the global client (ssh_session) configuration file path to
be set in configuration time by defining GLOBAL_CLIENT_CONFIG when
calling cmake.  If it is not defined, the default path is set as
"/etc/ssh/ssh_config".

usage example:

$ cmake -DGLOBAL_CLIENT_CONFIG=/etc/my/custom/path ..

Signed-off-by: Anderson Toshiyuki Sasaki <ansasaki@redhat.com>
Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
This commit is contained in:
Anderson Toshiyuki Sasaki
2019-05-06 15:19:40 +02:00
committed by Andreas Schneider
parent 248e5acd5c
commit 7cc159d720
5 changed files with 11 additions and 1 deletions

View File

@@ -394,6 +394,8 @@ static void torture_config_unknown(void **state) {
assert_true(ret == 0);
ret = ssh_config_parse_file(session, "/etc/ssh/ssh_config");
assert_true(ret == 0);
ret = ssh_config_parse_file(session, GLOBAL_CLIENT_CONFIG);
assert_true(ret == 0);
}