my @disablables = (
"aes",
+ "afalgeng",
"asm",
"async",
"autoalginit",
# Without position independent code, there can be no shared libraries or DSOs
"pic" => [ "shared" ],
"shared" => [ "dynamic-engine" ],
+ "engine" => [ "afalgeng" ],
);
# Avoid protocol support holes. Also disable all versions below N, if version
# ALL MODIFICATIONS TO %config and %target MUST BE DONE FROM HERE ON
-unless ($disabled{engine}) {
- $config{afalg}="";
+unless ($disabled{afalgeng}) {
+ $config{afalgeng}="";
if ($target =~ m/^linux/) {
my $minver = 4*10000 + 1*100 + 0;
if ($config{cross_compile_prefix} eq "") {
($mi2) = $mi2 =~ /(\d+)/;
my $ver = $ma*10000 + $mi1*100 + $mi2;
if ($ver < $minver) {
- $disabled{afalg} = "too-old-kernel";
+ $disabled{afalgeng} = "too-old-kernel";
} else {
push @{$config{engdirs}}, "afalg";
}
}
} else {
- $disabled{afalg} = "not-linux";
+ $disabled{afalgeng} = "not-linux";
}
}
-push @{$config{openssl_other_defines}}, "OPENSSL_NO_AFALGENG" if ($disabled{afalg});
+push @{$config{openssl_other_defines}}, "OPENSSL_NO_AFALGENG" if ($disabled{afalgeng});
# If we use the unified build, collect information from build.info files
my %unified_info = ();
*
*/
#include <stdio.h>
+#include <openssl/opensslconf.h>
+
+#ifndef OPENSSL_NO_AFALGENG
+#include <string.h>
#include <openssl/engine.h>
#include <openssl/evp.h>
#include <openssl/rand.h>
-#include <string.h>
-
-#ifndef OPENSSL_NO_AFALGENG
/* Use a buffer size which is not aligned to block size */
#define BUFFER_SIZE (8 * 1024) - 13
EVP_CIPHER_CTX_free(ctx);
return status;
}
-#endif
int main(int argc, char **argv)
{
-#ifdef OPENSSL_NO_AFALGENG
- fprintf(stderr, "AFALG not supported - skipping AFALG tests\n");
-#else
-
ENGINE *e;
CRYPTO_set_mem_debug(1);
}
ENGINE_free(e);
-#endif
printf("PASS\n");
return 0;
}
+
+#else /* OPENSSL_NO_AFALGENG */
+
+int main(int argc, char **argv)
+{
+ fprintf(stderr, "AFALG not supported - skipping AFALG tests\n");
+ printf("PASS\n");
+ return 0;
+}
+
+#endif