merge with rawhide

This commit is contained in:
Ralf Senderek 2022-02-17 16:04:54 +01:00
commit f1dffabf64
7 changed files with 144 additions and 6 deletions

60
COPYING Normal file
View File

@ -0,0 +1,60 @@
This file contains the usage terms for cryptlib. The full details of cryptlib
usage are provided on the cryptlib home page; although this file and the
information on the web page should be identical, in case of any dispute the
web page takes precedence. This file is included because some distributions
require the presence of a COPYING file.
cryptlib is distributed under a dual license that allows free, open-source use
under a GPL-compatible license and closed-source use under a standard
commercial license. The GPL-compatible license (a.k.a. the Sleepycat license)
is given below. Further details on this license are available from the
cryptlib home page.
Copyright 1992-2016 Peter Gutmann. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
3. Redistributions in any form must be accompanied by information on how to
obtain complete source code for the cryptlib software and any accompanying
software that uses the cryptlib software. The source code must either be
included in the distribution or be available for no more than the cost of
distribution, and must be freely redistributable under reasonable
conditions. For an executable file, complete source code means the source
code for all modules it contains or uses. It does not include source code
for modules or files that typically accompany the major components of the
operating system on which the executable file runs.
THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE, OR NON-INFRINGEMENT, ARE DISCLAIMED. IN NO
EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT
OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY
OF SUCH DAMAGE.
Note that decoupling the software from the user, for example by running in a
SaaS configuration, does not exempt you from these requirements.
If you're unable to comply with the above license then the following,
alternate usage conditions apply:
Any large-scale commercial use of cryptlib requires a license. "Large-scale
commercial use" means any revenue-generating purpose such as use for
company-internal purposes, or use of cryptlib in an application or product,
with a total gross revenue of over US$5,000. This allows cryptlib to be
used in freeware and shareware applications, for evaluation and research
purposes, and for non-revenue-generating or personal use without charge. In
addition the author reserves the right to grant free licenses for commercial
use in special cases (for example where there is a general benefit to the
public), contact the author for details if you think you qualify.

View File

@ -1,11 +1,11 @@
--- cl-original/makefile 2021-12-03 15:53:24.172492715 +0100
+++ cl-patched/makefile 2021-12-03 15:54:55.914497971 +0100
@@ -92,7 +92,7 @@
#
# Standard build flags
--- cl-original/makefile 2019-03-10 11:50:35.325298573 +0100
+++ cl-patched/makefile 2019-03-10 11:53:03.663407724 +0100
@@ -90,7 +90,7 @@
# Further cc flags are gathered dynamically at runtime via the ccopts.sh
# script.
-CFLAGS = -c -D__UNIX__ -DNDEBUG -I.
+CFLAGS = -c -D__UNIX__ -DNDEBUG -I. $(ADDFLAGS)
CFLAGS_DEBUG = -c -D__UNIX__ -I. -g -O1
CFLAGS_DEBUGGCC = -c -D__UNIX__ -I. -ggdb3 -fno-omit-frame-pointer -O1
CFLAGS_ANALYSE = -c -D__UNIX__ -I.

Binary file not shown.

Binary file not shown.

33
gccversionpatch Normal file
View File

@ -0,0 +1,33 @@
--- cl-original/tools/ccopts.sh 2019-11-23 17:03:39.315504598 +0100
+++ cl-testpatch/tools/ccopts.sh 2020-01-22 18:49:01.093189548 +0100
@@ -508,10 +508,17 @@
# apparent version less than 10 we add a trailing zero to the string to make
# the checks that follow work.
-GCC_VER="$($CC -dumpversion | tr -d '.' | cut -c 1-2)"
-if [ "$GCC_VER" -lt 10 ] ; then
- GCC_VER="${GCC_VER}0" ;
-fi
+GCC_VER="$($CC -dumpversion)"
+case $GCC_VER in
+ [0-9])
+ GCC_VER="${GCC_VER}0" ;;
+
+ [0-9][0-9]*)
+ GCC_VER="$(echo $GCC_VER | tr -d '.' | cut -c 1-3)" ;;
+
+ *)
+ GCC_VER="$(echo $GCC_VER | tr -d '.' | cut -c 1-2)" ;;
+esac
# Try and determine the CPU type. This is made more complex by a pile of
# *BSE's which, along with antideluvian tools like an as that doesn't
@@ -606,7 +613,7 @@
CCARGS="$CCARGS -march=pentium" ;;
esac ;
else
- CCARGS="$CCARGS -mcpu=pentium" ;
+ CCARGS="$CCARGS -march=native" ;
fi ;
fi

21
perlpatch Normal file
View File

@ -0,0 +1,21 @@
--- cl-original/bindings/PerlCryptLib.xs 2019-03-10 08:45:35.962108583 -0400
+++ cl-patched/bindings/PerlCryptLib.xs 2019-03-10 08:46:27.133451822 -0400
@@ -594,18 +594,3 @@
OUTPUT:
RETVAL
-# Add deprecated functions when CRYPTLIB_VERSION prior 3.4.0
-#if CRYPTLIB_VERSION < 3400
-
-int cryptAsyncCancel(cryptObject)
- const int cryptObject;
-
-
-int cryptAsyncQuery(cryptObject)
- const int cryptObject;
-
-
-int cryptGenerateKeyAsync(cryptContext)
- const int cryptContext;
-
-#endif

24
threadpatch Normal file
View File

@ -0,0 +1,24 @@
--- cl-original/kernel/thread.h 2021-06-24 14:55:26.169597780 +0200
+++ cl-patched/kernel/thread.h 2021-06-24 14:58:02.485568178 +0200
@@ -2979,6 +2979,8 @@
"Posix is portable in the sense that you can use a forklift to move the
printed volumes around" */
+#include <sched.h>
+
#define THREADFUNC_DEFINE( name, arg ) void *name( void *arg )
#define THREAD_CREATE( function, arg, threadHandle, syncHandle, status ) \
{ \
@@ -3016,7 +3018,11 @@
#if defined( __linux__ ) && !defined( __USE_GNU )
void pthread_yield( void );
#endif /* Present but not prototyped unless GNU extensions are enabled */
- #define THREAD_YIELD() pthread_yield()
+
+ #if defined( __linux__ ) && ( OSVERSION > 3 )
+ #define THREAD_YIELD() sched_yield()
+ #endif
+
#endif /* Not-very-portable Posix portability */
#define THREAD_SLEEP( ms ) { \
struct timeval tv = { 0 }; \