Репозиторий Sisyphus
Последнее обновление: 1 октября 2023 | Пакетов: 18631 | Посещений: 37562371
en ru br
Репозитории ALT

Группа :: Система/Библиотеки
Пакет: gnutls30

 Главная   Изменения   Спек   Патчи   Sources   Загрузить   Gear   Bugs and FR  Repocop 

Патч: gnulib-E2K-fix-for-lcc-1.23.patch
Скачать


From c5a2e5dc6932cf3130a5e93619f5f85bbcc86107 Mon Sep 17 00:00:00 2001
From: Ivan Zakharyaschev <imz@altlinux.org>
Date: Tue, 31 Mar 2020 16:30:26 +0300
Subject: [PATCH] gnulib: fix compilation with lcc-1.23 (E2K platform)
(Based on ideas from communication with MCST.)
Actually, the problem appears only with 1.23 (prior versions of lcc
didn't set __GNUC__ to 5; latter versions will be more compatible in
this respect); so, the "less-or-equal" check could be replaced by an
"equal" check in this patch.
---
 gnutls/src/gl/intprops.h         | 2 +-
 gnutls/src/gl/xalloc-oversized.h | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/gnutls/src/gl/intprops.h b/gnutls/src/gl/intprops.h
index dfbcaae73..3ee79159c 100644
--- a/gnutls/src/gl/intprops.h
+++ b/gnutls/src/gl/intprops.h
@@ -222,7 +222,7 @@
 
 /* True if __builtin_add_overflow (A, B, P) and __builtin_sub_overflow
    (A, B, P) work when P is non-null.  */
-#if 5 <= __GNUC__ && !defined __ICC
+#if 5 <= __GNUC__ && !defined __ICC && !(__LCC__ <= 123)
 # define _GL_HAS_BUILTIN_ADD_OVERFLOW 1
 #elif defined __has_builtin
 # define _GL_HAS_BUILTIN_ADD_OVERFLOW __has_builtin (__builtin_add_overflow)
diff --git a/gnutls/src/gl/xalloc-oversized.h b/gnutls/src/gl/xalloc-oversized.h
index 13ee23031..08a9a4f8e 100644
--- a/gnutls/src/gl/xalloc-oversized.h
+++ b/gnutls/src/gl/xalloc-oversized.h
@@ -44,7 +44,7 @@ typedef size_t __xalloc_count_type;
 #if 7 <= __GNUC__
 # define xalloc_oversized(n, s) \
    __builtin_mul_overflow_p (n, s, (__xalloc_count_type) 1)
-#elif 5 <= __GNUC__ && !defined __ICC && !__STRICT_ANSI__
+#elif 5 <= __GNUC__ && !defined __ICC && !(__LCC__ <= 123) && !__STRICT_ANSI__
 # define xalloc_oversized(n, s) \
    (__builtin_constant_p (n) && __builtin_constant_p (s) \
     ? __xalloc_oversized (n, s) \
-- 
2.25.2
 
дизайн и разработка: Vladimir Lettiev aka crux © 2004-2005, Andrew Avramenko aka liks © 2007-2008
текущий майнтейнер: Michael Shigorin