aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFabian Groffen <grobian@gentoo.org>2019-06-05 09:56:44 +0200
committerFabian Groffen <grobian@gentoo.org>2019-06-05 09:56:44 +0200
commite074e6fa71c94cea6a6693822f33fc3ea6afc1d1 (patch)
tree0a72b3bebb6ca90130012d5248a33df9a71bbf9f
parentTODO: add some things/ideas (diff)
downloadportage-utils-e074e6fa.tar.gz
portage-utils-e074e6fa.tar.bz2
portage-utils-e074e6fa.zip
libq/hash: fix compilation without HAVE_SSL and HAVE_BLAKE2B
Bug: https://bugs.gentoo.org/687374 Signed-off-by: Fabian Groffen <grobian@gentoo.org>
-rw-r--r--libq/hash.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/libq/hash.c b/libq/hash.c
index 8ce29d7d..32d047ac 100644
--- a/libq/hash.c
+++ b/libq/hash.c
@@ -131,6 +131,7 @@ hash_compute_file(
while ((len = fread(data, 1, sizeof(data), f)) > 0) {
*flen += len;
+#if defined(HAVE_SSL) || defined(HAVE_BLAKE2B)
#pragma omp parallel sections
{
#ifdef HAVE_SSL
@@ -158,9 +159,11 @@ hash_compute_file(
}
#endif
}
+#endif /* HAVE_SSL || HAVE_BLAKE2B */
}
fclose(f);
+#if defined(HAVE_SSL) || defined(HAVE_BLAKE2B)
#pragma omp parallel sections
{
#ifdef HAVE_SSL
@@ -199,4 +202,5 @@ hash_compute_file(
}
#endif
}
+#endif /* HAVE_SSL || HAVE_BLAKE2B */
}