From 1ae56f2f43d36618e54cbb8dd47a7107b74505b6 Mon Sep 17 00:00:00 2001 From: Rich Salz Date: Wed, 4 Mar 2020 16:52:22 -0500 Subject: Don't compile commands if disabled Rather than wrapping whole files in "ifndef OPENSSL_NO_xxx" we handle the changes in build.info Reviewed-by: Paul Dale Reviewed-by: Bernd Edlinger (Merged from https://github.com/openssl/openssl/pull/11250) --- apps/srp.c | 38 +++++++++++++++++--------------------- 1 file changed, 17 insertions(+), 21 deletions(-) (limited to 'apps/srp.c') diff --git a/apps/srp.c b/apps/srp.c index 646e86f11a..8fb325feab 100644 --- a/apps/srp.c +++ b/apps/srp.c @@ -12,28 +12,25 @@ */ #include -#ifdef OPENSSL_NO_SRP -NON_EMPTY_TRANSLATION_UNIT -#else -# include -# include -# include -# include -# include -# include -# include -# include -# include -# include "apps.h" -# include "progs.h" +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include "apps.h" +#include "progs.h" -# define BASE_SECTION "srp" -# define CONFIG_FILE "openssl.cnf" +#define BASE_SECTION "srp" +#define CONFIG_FILE "openssl.cnf" -# define ENV_DATABASE "srpvfile" -# define ENV_DEFAULT_SRP "default_srp" +#define ENV_DATABASE "srpvfile" +#define ENV_DEFAULT_SRP "default_srp" static int get_index(CA_DB *db, char *id, char type) { @@ -204,9 +201,9 @@ const OPTIONS srp_options[] = { {"verbose", OPT_VERBOSE, '-', "Talk a lot while doing things"}, {"config", OPT_CONFIG, '<', "A config file"}, {"name", OPT_NAME, 's', "The particular srp definition to use"}, -# ifndef OPENSSL_NO_ENGINE +#ifndef OPENSSL_NO_ENGINE {"engine", OPT_ENGINE, 's', "Use engine, possibly a hardware device"}, -# endif +#endif OPT_SECTION("Action"), {"add", OPT_ADD, '-', "Add a user and srp verifier"}, @@ -625,4 +622,3 @@ int srp_main(int argc, char **argv) release_engine(e); return ret; } -#endif -- cgit v1.2.3