openpkg/openssl.patch

Mon, 28 Jan 2013 17:37:18 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Mon, 28 Jan 2013 17:37:18 +0100
changeset 758
a2c6460cfb16
parent 432
aa0488214e35
permissions
-rw-r--r--

Correct socket error reporting improvement with IPv6 portable code,
after helpful recommendation by Saúl Ibarra Corretgé on OSips devlist.

     1 Index: Configure
     2 --- Configure.orig	2012-03-14 23:20:40.000000000 +0100
     3 +++ Configure	2012-06-27 10:10:05.000000000 +0200
     4 @@ -6,7 +6,6 @@
     5  ##
     7  require 5.000;
     8 -use strict;
    10  # see INSTALL for instructions.
    12 @@ -34,6 +33,7 @@
    13  #		(Default: KRB5_DIR/include)
    14  # --with-krb5-flavor  Declare what flavor of Kerberos 5 is used.  Currently
    15  #		supported values are "MIT" and "Heimdal".  A value is required.
    16 +# --with-cc     compiler to use for $CC (useful if cc is a disguised gcc)
    17  #
    18  # --test-sanity Make a number of sanity checks on the data in this file.
    19  #               This is a debugging tool for OpenSSL developers.
    20 @@ -123,6 +123,7 @@
    21  #$bits2="THIRTY_TWO_BIT ";
    22  my $bits1="THIRTY_TWO_BIT ";
    23  my $bits2="SIXTY_FOUR_BIT ";
    24 +my $ccarg;
    26  my $x86_asm="x86cpuid.o:bn-586.o co-586.o x86-mont.o x86-gf2m.o:des-586.o crypt586.o:aes-586.o vpaes-x86.o aesni-x86.o:bf-586.o:md5-586.o:sha1-586.o sha256-586.o sha512-586.o:cast-586.o:rc4-586.o:rmd-586.o:rc5-586.o:wp_block.o wp-mmx.o:cmll-x86.o:ghash-x86.o:";
    28 @@ -460,12 +461,12 @@
    30  #### IBM's AIX.
    31  "aix3-cc",  "cc:-O -DB_ENDIAN -qmaxmem=16384::(unknown):AIX::BN_LLONG RC4_CHAR:::",
    32 -"aix-gcc",  "gcc:-O -DB_ENDIAN::-pthread:AIX::BN_LLONG RC4_CHAR:${ppc32_asm}:aix32:dlfcn:aix-shared::-shared -Wl,-G:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)::-X32",
    33 -"aix64-gcc","gcc:-maix64 -O -DB_ENDIAN::-pthread:AIX::SIXTY_FOUR_BIT_LONG RC4_CHAR:${ppc64_asm}:aix64:dlfcn:aix-shared::-maix64 -shared -Wl,-G:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)::-X64",
    34 +"aix-gcc",  "gcc:-O -DB_ENDIAN::-pthread:AIX::BN_LLONG RC4_CHAR:${ppc32_asm}:aix32:dlfcn:aix-shared::-shared -Wl,-G:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)::",
    35 +"aix64-gcc","gcc:-maix64 -O -DB_ENDIAN::-pthread:AIX::SIXTY_FOUR_BIT_LONG RC4_CHAR:${ppc64_asm}:aix64:dlfcn:aix-shared::-maix64 -shared -Wl,-G:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)::",
    36  # Below targets assume AIX 5. Idea is to effectively disregard $OBJECT_MODE
    37  # at build time. $OBJECT_MODE is respected at ./config stage!
    38 -"aix-cc",   "cc:-q32 -O -DB_ENDIAN -qmaxmem=16384 -qro -qroconst::-qthreaded:AIX::BN_LLONG RC4_CHAR:${ppc32_asm}:aix32:dlfcn:aix-shared::-q32 -G:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)::-X 32",
    39 -"aix64-cc", "cc:-q64 -O -DB_ENDIAN -qmaxmem=16384 -qro -qroconst::-qthreaded:AIX::SIXTY_FOUR_BIT_LONG RC4_CHAR:${ppc64_asm}:aix64:dlfcn:aix-shared::-q64 -G:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)::-X 64",
    40 +"aix-cc",   "cc:-q32 -O -DB_ENDIAN -qmaxmem=16384 -qro -qroconst::-qthreaded:AIX::BN_LLONG RC4_CHAR:${ppc32_asm}:aix32:dlfcn:aix-shared::-q32 -G:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)::",
    41 +"aix64-cc", "cc:-q64 -O -DB_ENDIAN -qmaxmem=16384 -qro -qroconst::-qthreaded:AIX::SIXTY_FOUR_BIT_LONG RC4_CHAR:${ppc64_asm}:aix64:dlfcn:aix-shared::-q64 -G:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)::",
    43  #
    44  # Cray T90 and similar (SDSC)
    45 @@ -828,6 +829,10 @@
    46  			{
    47  			$strict_warnings = 1;
    48  			}
    49 +		elsif (/^--with-cc=(.*)$/)
    50 +			{
    51 +                $ccarg=$1
    52 +			}
    53  		elsif (/^reconfigure/ || /^reconf/)
    54  			{
    55  			if (open(IN,"<$Makefile"))
    56 @@ -1143,7 +1148,7 @@
    57  print "IsMK1MF=$IsMK1MF\n";
    59  my @fields = split(/\s*:\s*/,$table{$target} . ":" x 30 , -1);
    60 -my $cc = $fields[$idx_cc];
    61 +my $cc = $ccarg ? $ccarg : $fields[$idx_cc];
    62  # Allow environment CC to override compiler...
    63  if($ENV{CC}) {
    64      $cc = $ENV{CC};
    65 Index: config
    66 --- config.orig	2011-11-14 22:12:53.000000000 +0100
    67 +++ config	2012-06-27 10:10:05.000000000 +0200
    68 @@ -277,6 +277,9 @@
    69  	    Power*)
    70  		echo "ppc-apple-darwin${VERSION}"
    71  		;;
    72 +	    x86_64 )
    73 +		echo "x86_64-apple-darwin${VERSION}"
    74 +		;;
    75  	    *)
    76  		echo "i686-apple-darwin${VERSION}"
    77  		;;
    78 @@ -411,9 +414,14 @@
    79  # this is where the translation occurs into SSLeay terms
    80  # ---------------------------------------------------------------------------
    82 +# Assume CC is GNU GCC if 'dumpversion' argument produces valid output
    83 +GCCVER=`sh -c "${CC-gcc} -dumpversion" 2>/dev/null`
    84 +GCCVER=`echo $GCCVER | LC_ALL=C sed 's/^[a-zA-Z]*\-//'`
    85 +GCCVER=`echo $GCCVER | sed 's/\([0-9]\)\.\([0-9]\).*/\1\2/'`
    86 +
    87  # Only set CC if not supplied already
    88  if [ -z "$CROSS_COMPILE$CC" ]; then
    89 -  GCCVER=`sh -c "gcc -dumpversion" 2>/dev/null`
    90 +  GCCVER=`sh -c "${CC-gcc} -dumpversion" 2>/dev/null`
    91    if [ "$GCCVER" != "" ]; then
    92      # then strip off whatever prefix egcs prepends the number with...
    93      # Hopefully, this will work for any future prefixes as well.
    94 @@ -424,8 +432,17 @@
    95      # peak single digit before and after first dot, e.g. 2.95.1 gives 29
    96      GCCVER=`echo $GCCVER | sed 's/\([0-9]\)\.\([0-9]\).*/\1\2/'`
    97      CC=gcc
    98 +    SUFFIX=gcc
    99    else
   100      CC=cc
   101 +    SUFFIX=cc
   102 +  fi
   103 +else
   104 +  if [ "$GCCVER" != "" ]; then
   105 +    SUFFIX=gcc
   106 +  else
   107 +    CC=cc
   108 +    SUFFIX=cc
   109    fi
   110  fi
   111  GCCVER=${GCCVER:-0}
   112 @@ -435,7 +452,7 @@
   113    if [ $GCCVER -ge 30 ]; then
   114      # PA64 support only came in with gcc 3.0.x.
   115      # We check if the preprocessor symbol __LP64__ is defined...
   116 -    if echo "__LP64__" | gcc -v -E -x c - 2>/dev/null | grep "^__LP64__" 2>&1 > /dev/null; then
   117 +    if echo "__LP64__" | $CC -v -E -x c - 2>/dev/null | grep "^__LP64__" 2>&1 > /dev/null; then
   118        : # __LP64__ has slipped through, it therefore is not defined
   119      else
   120        GCC_BITS="64"
   121 @@ -446,13 +463,14 @@
   122    if [ $GCCVER -ge 30 ]; then
   123      # 64-bit ABI isn't officially supported in gcc 3.0, but it appears
   124      # to be working, at the very least 'make test' passes...
   125 -    if gcc -v -E -x c /dev/null 2>&1 | grep __arch64__ > /dev/null; then
   126 +    if $CC -v -E -x c /dev/null 2>&1 | grep __arch64__ > /dev/null; then
   127        GCC_ARCH="-m64"
   128      else
   129        GCC_ARCH="-m32"
   130      fi
   131    fi
   132    # check for WorkShop C, expected output is "cc: blah-blah C x.x"
   133 +  if [ $GCCVER -eq 0 ]; then
   134    CCVER=`(cc -V 2>&1) 2>/dev/null | \
   135    	egrep -e '^cc: .* C [0-9]\.[0-9]' | \
   136  	sed 's/.* C \([0-9]\)\.\([0-9]\).*/\1\2/'`
   137 @@ -465,6 +483,7 @@
   138        sleep 5
   139      fi
   140    fi
   141 +  fi
   142  fi
   144  if [ "${SYSTEM}-${MACHINE}" = "Linux-alpha" ]; then
   145 @@ -482,6 +501,7 @@
   147  if [ "${SYSTEM}" = "AIX" ]; then	# favor vendor cc over gcc
   148      (cc) 2>&1 | grep -iv "not found" > /dev/null && CC=cc
   149 +    (gcc) 2>&1 | grep -iv "not found" > /dev/null && CC=gcc
   150  fi
   152  CCVER=${CCVER:-0}
   153 @@ -507,7 +527,7 @@
   154  	if [ $CPU -ge 4000 ]; then
   155  		options="$options -mips2"
   156  	fi
   157 -	OUT="irix-$CC"
   158 +	OUT="irix-$SUFFIX"
   159  	;;
   160    mips3-sgi-irix)
   161  	#CPU=`(hinv -t cpu) 2>/dev/null | head -1 | sed 's/^CPU:[^R]*R\([0-9]*\).*/\1/'`
   162 @@ -517,11 +537,11 @@
   163  	#else
   164  	#	options="$options -mips3"
   165  	#fi
   166 -	OUT="irix-mips3-$CC"
   167 +	OUT="irix-mips3-$SUFFIX"
   168  	;;
   169    mips4-sgi-irix64)
   170  	echo "WARNING! If you wish to build 64-bit library, then you have to"
   171 -	echo "         invoke './Configure irix64-mips4-$CC' *manually*."
   172 +	echo "         invoke './Configure irix64-mips4-$SUFFIX' *manually*."
   173  	if [ "$TEST" = "false" -a -t 1 ]; then
   174  	  echo "         You have about 5 seconds to press Ctrl-C to abort."
   175  	  (trap "stty `stty -g`" 2 0; stty -icanon min 0 time 50; read waste) <&1
   176 @@ -533,7 +553,7 @@
   177          #else
   178          #        options="$options -mips3"
   179          #fi
   180 -	OUT="irix-mips3-$CC"
   181 +	OUT="irix-mips3-$SUFFIX"
   182  	;;
   183    ppc-apple-rhapsody) OUT="rhapsody-ppc-cc" ;;
   184    ppc-apple-darwin*)
   185 @@ -566,6 +586,9 @@
   186  	else
   187  	    OUT="darwin-i386-cc"
   188  	fi ;;
   189 +  x86_64-apple-darwin*)
   190 +    OUT="darwin64-x86_64-cc"
   191 +    ;;
   192    armv6+7-*-iphoneos)
   193  	options="$options -arch%20armv6 -arch%20armv7"
   194  	OUT="iphoneos-cross" ;;
   195 @@ -575,10 +598,10 @@
   196    alpha-*-linux2)
   197          ISA=`awk '/cpu model/{print$4;exit(0);}' /proc/cpuinfo`
   198  	case ${ISA:-generic} in
   199 -	*[678])	OUT="linux-alpha+bwx-$CC" ;;
   200 -	*)	OUT="linux-alpha-$CC" ;;
   201 +	*[678])	OUT="linux-alpha+bwx-$SUFFIX" ;;
   202 +	*)	OUT="linux-alpha-$SUFFIX" ;;
   203  	esac
   204 -	if [ "$CC" = "gcc" ]; then
   205 +	if [ $GCCVER -gt 0 ]; then
   206  	    case ${ISA:-generic} in
   207  	    EV5|EV45)		options="$options -mcpu=ev5";;
   208  	    EV56|PCA56)		options="$options -mcpu=ev56";;
   209 @@ -662,7 +685,7 @@
   210  	;;
   211    x86_64-*-linux?) OUT="linux-x86_64" ;;
   212    *86-*-linux2) OUT="linux-elf"
   213 -	if [ "$GCCVER" -gt 28 ]; then
   214 +	if [ $GCCVER -gt 28 ]; then
   215            if grep '^model.*Pentium' /proc/cpuinfo >/dev/null ; then
   216  	    options="$options -march=pentium"
   217            fi
   218 @@ -676,17 +699,17 @@
   219    *-*-linux1) OUT="linux-aout" ;;
   220    *-*-linux2) OUT="linux-generic32" ;;
   221    sun4[uv]*-*-solaris2)
   222 -	OUT="solaris-sparcv9-$CC"
   223 +	OUT="solaris-sparcv9-$SUFFIX"
   224  	ISA64=`(isalist) 2>/dev/null | grep sparcv9`
   225  	if [ "$ISA64" != "" -a "$KERNEL_BITS" = "" ]; then
   226 -	    if [ "$CC" = "cc" -a $CCVER -ge 50 ]; then
   227 +	    if [ $GCCVER -eq 0 -a $CCVER -ge 50 ]; then
   228  		echo "WARNING! If you wish to build 64-bit library, then you have to"
   229  		echo "         invoke './Configure solaris64-sparcv9-cc' *manually*."
   230  		if [ "$TEST" = "false" -a -t 1 ]; then
   231  		  echo "         You have about 5 seconds to press Ctrl-C to abort."
   232  		  (trap "stty `stty -g`" 2 0; stty -icanon min 0 time 50; read waste) <&1
   233  		fi
   234 -	    elif [ "$CC" = "gcc" -a "$GCC_ARCH" = "-m64" ]; then
   235 +	    elif [ $GCCVER -gt 0 -a "$GCC_ARCH" = "-m64" ]; then
   236  		# $GCC_ARCH denotes default ABI chosen by compiler driver
   237  		# (first one found on the $PATH). I assume that user
   238  		# expects certain consistency with the rest of his builds
   239 @@ -712,21 +735,21 @@
   240  	    OUT="solaris64-sparcv9-$CC"
   241  	fi
   242  	;;
   243 -  sun4m-*-solaris2)	OUT="solaris-sparcv8-$CC" ;;
   244 -  sun4d-*-solaris2)	OUT="solaris-sparcv8-$CC" ;;
   245 -  sun4*-*-solaris2)	OUT="solaris-sparcv7-$CC" ;;
   246 +  sun4m-*-solaris2)	OUT="solaris-sparcv8-$SUFFIX" ;;
   247 +  sun4d-*-solaris2)	OUT="solaris-sparcv8-$SUFFIX" ;;
   248 +  sun4*-*-solaris2)	OUT="solaris-sparcv7-$SUFFIX" ;;
   249    *86*-*-solaris2)
   250  	ISA64=`(isalist) 2>/dev/null | grep amd64`
   251  	if [ "$ISA64" != "" -a ${KERNEL_BITS:-64} -eq 64 ]; then
   252 -	    OUT="solaris64-x86_64-$CC"
   253 +	    OUT="solaris64-x86_64-$SUFFIX"
   254  	else
   255 -	    OUT="solaris-x86-$CC"
   256 +	    OUT="solaris-x86-$SUFFIX"
   257  	    if [ `uname -r | sed -e 's/5\.//'` -lt 10 ]; then
   258  		options="$options no-sse2"
   259  	    fi
   260  	fi
   261  	;;
   262 -  *-*-sunos4)		OUT="sunos-$CC" ;;
   263 +  *-*-sunos4)		OUT="sunos-$SUFFIX" ;;
   265    *86*-*-bsdi4)		OUT="BSD-x86-elf"; options="$options no-sse2 -ldl" ;;
   266    alpha*-*-*bsd*)	OUT="BSD-generic64"; options="$options -DL_ENDIAN" ;;
   267 @@ -750,7 +773,7 @@
   268    *-*-osf)		OUT="osf1-alpha-cc" ;;
   269    *-*-tru64)		OUT="tru64-alpha-cc" ;;
   270    *-*-[Uu]nix[Ww]are7)
   271 -	if [ "$CC" = "gcc" ]; then
   272 +	if [ $GCCVER -gt 0 ]; then
   273  	  OUT="unixware-7-gcc" ; options="$options no-sse2"
   274  	else    
   275  	  OUT="unixware-7" ; options="$options no-sse2 -D__i386__"
   276 @@ -761,12 +784,12 @@
   277    *-*-vos)
   278  	options="$options no-threads no-shared no-asm no-dso"
   279  	EXE=".pm"
   280 -	OUT="vos-$CC" ;;
   281 +	OUT="vos-$SUFFIX" ;;
   282    BS2000-siemens-sysv4) OUT="BS2000-OSD" ;;
   283    RM*-siemens-sysv4) OUT="ReliantUNIX" ;;
   284    *-siemens-sysv4) OUT="SINIX" ;;
   285    *-hpux1*)
   286 -	if [ $CC = "gcc" -a $GCC_BITS = "64" ]; then
   287 +	if [ $GCCVER -gt 0 -a $GCC_BITS = "64" ]; then
   288  	    OUT="hpux64-parisc2-gcc"
   289  	fi
   290  	[ "$KERNEL_BITS" ] || KERNEL_BITS=`(getconf KERNEL_BITS) 2>/dev/null`
   291 @@ -781,8 +804,8 @@
   292  	        OUT="hpux-ia64-cc"
   293               fi
   294  	elif [ $CPU_VERSION -ge 532 ]; then	# PA-RISC 2.x CPU
   295 -	     OUT=${OUT:-"hpux-parisc2-${CC}"}
   296 -	     if [ $KERNEL_BITS -eq 64 -a "$CC" = "cc" ]; then
   297 +	     OUT=${OUT:-"hpux-parisc2-${SUFFIX}"}
   298 +	     if [ $KERNEL_BITS -eq 64 -a $GCCVER -eq 0 ]; then
   299  		echo "WARNING! If you wish to build 64-bit library then you have to"
   300  		echo "         invoke './Configure hpux64-parisc2-cc' *manually*."
   301  		if [ "$TEST" = "false" -a -t 1 ]; then
   302 @@ -791,9 +814,9 @@
   303  		fi
   304  	     fi
   305  	elif [ $CPU_VERSION -ge 528 ]; then	# PA-RISC 1.1+ CPU
   306 -	     OUT="hpux-parisc-${CC}"
   307 +	     OUT="hpux-parisc-${SUFFIX}"
   308  	elif [ $CPU_VERSION -ge 523 ]; then	# PA-RISC 1.0 CPU
   309 -	     OUT="hpux-parisc-${CC}"
   310 +	     OUT="hpux-parisc-${SUFFIX}"
   311  	else					# Motorola(?) CPU
   312  	     OUT="hpux-$CC"
   313  	fi
   314 @@ -803,7 +826,7 @@
   315  	[ "$KERNEL_BITS" ] || KERNEL_BITS=`(getconf KERNEL_BITMODE) 2>/dev/null`
   316  	KERNEL_BITS=${KERNEL_BITS:-32}
   317  	OBJECT_MODE=${OBJECT_MODE:-32}
   318 -	if [ "$CC" = "gcc" ]; then
   319 +	if [ $GCCVER -gt 0 ]; then
   320  	    OUT="aix-gcc"
   321            if [ $OBJECT_MODE -eq 64 ]; then
   322              echo 'Your $OBJECT_MODE was found to be set to 64'
   323 @@ -913,7 +936,7 @@
   324  #fi
   326  if [ -z "$OUT" ]; then
   327 -  OUT="$CC"
   328 +  OUT="$SUFFIX"
   329  fi
   331  if [ ".$PERL" = . ] ; then
   332 @@ -945,9 +968,9 @@
   333  # compiler for the platform ... in which case we add it on
   334  # the end ... otherwise we leave it off
   336 -$PERL ./Configure LIST | grep "$OUT-$CC" > /dev/null
   337 +$PERL ./Configure LIST | grep "$OUT-$SUFFIX" > /dev/null
   338  if [ $? = "0" ]; then
   339 -  OUT="$OUT-$CC"
   340 +  OUT="$OUT-$SUFFIX"
   341  fi
   343  OUT="$PREFIX$OUT"
   344 @@ -957,9 +980,9 @@
   345    echo Configuring for $OUT
   347    if [ "$TEST" = "true" ]; then
   348 -    echo $PERL ./Configure $OUT $options
   349 +    echo $PERL ./Configure $OUT --with-cc=$CC $options
   350    else
   351 -    $PERL ./Configure $OUT $options
   352 +    $PERL ./Configure $OUT --with-cc=$CC $options
   353    fi
   354  else
   355    echo "This system ($OUT) is not supported. See file INSTALL for details."
   356 Index: crypto/aes/asm/aesni-sha1-x86_64.pl
   357 --- crypto/aes/asm/aesni-sha1-x86_64.pl.orig	2011-08-23 22:53:31.000000000 +0200
   358 +++ crypto/aes/asm/aesni-sha1-x86_64.pl	2012-06-27 10:10:05.000000000 +0200
   359 @@ -206,7 +206,7 @@
   360  ___
   362  my $aesenc=sub {
   363 -  use integer;
   364 +  
   365    my ($n,$k)=($r/10,$r%10);
   366      if ($k==0) {
   367        $code.=<<___;
   368 @@ -249,7 +249,7 @@
   369  };
   371  sub Xupdate_ssse3_16_31()		# recall that $Xi starts wtih 4
   372 -{ use integer;
   373 +{ 
   374    my $body = shift;
   375    my @insns = (&$body,&$body,&$body,&$body);	# 40 instructions
   376    my ($a,$b,$c,$d,$e);
   377 @@ -330,7 +330,7 @@
   378  }
   380  sub Xupdate_ssse3_32_79()
   381 -{ use integer;
   382 +{ 
   383    my $body = shift;
   384    my @insns = (&$body,&$body,&$body,&$body);	# 32 to 48 instructions
   385    my ($a,$b,$c,$d,$e);
   386 @@ -397,7 +397,7 @@
   387  }
   389  sub Xuplast_ssse3_80()
   390 -{ use integer;
   391 +{ 
   392    my $body = shift;
   393    my @insns = (&$body,&$body,&$body,&$body);	# 32 instructions
   394    my ($a,$b,$c,$d,$e);
   395 @@ -431,7 +431,7 @@
   396  }
   398  sub Xloop_ssse3()
   399 -{ use integer;
   400 +{ 
   401    my $body = shift;
   402    my @insns = (&$body,&$body,&$body,&$body);	# 32 instructions
   403    my ($a,$b,$c,$d,$e);
   404 @@ -456,7 +456,7 @@
   405  }
   407  sub Xtail_ssse3()
   408 -{ use integer;
   409 +{ 
   410    my $body = shift;
   411    my @insns = (&$body,&$body,&$body,&$body);	# 32 instructions
   412    my ($a,$b,$c,$d,$e);
   413 @@ -465,7 +465,7 @@
   414  }
   416  sub body_00_19 () {
   417 -  use integer;
   418 +  
   419    my ($k,$n);
   420    my @r=(
   421  	'($a,$b,$c,$d,$e)=@V;'.
   422 @@ -488,7 +488,7 @@
   423  }
   425  sub body_20_39 () {
   426 -  use integer;
   427 +  
   428    my ($k,$n);
   429    my @r=(
   430  	'($a,$b,$c,$d,$e)=@V;'.
   431 @@ -509,7 +509,7 @@
   432  }
   434  sub body_40_59 () {
   435 -  use integer;
   436 +  
   437    my ($k,$n);
   438    my @r=(
   439  	'($a,$b,$c,$d,$e)=@V;'.
   440 @@ -723,7 +723,7 @@
   441  ___
   443  my $aesenc=sub {
   444 -  use integer;
   445 +  
   446    my ($n,$k)=($r/10,$r%10);
   447      if ($k==0) {
   448        $code.=<<___;
   449 @@ -766,7 +766,7 @@
   450  };
   452  sub Xupdate_avx_16_31()		# recall that $Xi starts wtih 4
   453 -{ use integer;
   454 +{ 
   455    my $body = shift;
   456    my @insns = (&$body,&$body,&$body,&$body);	# 40 instructions
   457    my ($a,$b,$c,$d,$e);
   458 @@ -842,7 +842,7 @@
   459  }
   461  sub Xupdate_avx_32_79()
   462 -{ use integer;
   463 +{ 
   464    my $body = shift;
   465    my @insns = (&$body,&$body,&$body,&$body);	# 32 to 48 instructions
   466    my ($a,$b,$c,$d,$e);
   467 @@ -907,7 +907,7 @@
   468  }
   470  sub Xuplast_avx_80()
   471 -{ use integer;
   472 +{ 
   473    my $body = shift;
   474    my @insns = (&$body,&$body,&$body,&$body);	# 32 instructions
   475    my ($a,$b,$c,$d,$e);
   476 @@ -941,7 +941,7 @@
   477  }
   479  sub Xloop_avx()
   480 -{ use integer;
   481 +{ 
   482    my $body = shift;
   483    my @insns = (&$body,&$body,&$body,&$body);	# 32 instructions
   484    my ($a,$b,$c,$d,$e);
   485 @@ -965,7 +965,7 @@
   486  }
   488  sub Xtail_avx()
   489 -{ use integer;
   490 +{ 
   491    my $body = shift;
   492    my @insns = (&$body,&$body,&$body,&$body);	# 32 instructions
   493    my ($a,$b,$c,$d,$e);
   494 Index: crypto/asn1/charmap.pl
   495 --- crypto/asn1/charmap.pl.orig	2000-07-28 03:58:11.000000000 +0200
   496 +++ crypto/asn1/charmap.pl	2012-06-27 10:10:05.000000000 +0200
   497 @@ -1,7 +1,5 @@
   498  #!/usr/local/bin/perl -w
   500 -use strict;
   501 -
   502  my ($i, @arr);
   504  # Set up an array with the type of ASCII characters
   505 Index: crypto/bn/asm/modexp512-x86_64.pl
   506 --- crypto/bn/asm/modexp512-x86_64.pl.orig	2011-12-12 16:12:09.000000000 +0100
   507 +++ crypto/bn/asm/modexp512-x86_64.pl	2012-06-27 10:10:05.000000000 +0200
   508 @@ -70,7 +70,6 @@
   510  open STDOUT,"| $^X $xlate $flavour $output";
   512 -use strict;
   513  my $code=".text\n\n";
   514  my $m=0;
   516 Index: crypto/md5/asm/md5-x86_64.pl
   517 --- crypto/md5/asm/md5-x86_64.pl.orig	2008-12-19 12:17:27.000000000 +0100
   518 +++ crypto/md5/asm/md5-x86_64.pl	2012-06-27 10:10:05.000000000 +0200
   519 @@ -7,8 +7,6 @@
   520  # in the public domain.
   521  #
   523 -use strict;
   524 -
   525  my $code;
   527  # round1_step() does:
   528 Index: crypto/objects/obj_dat.pl
   529 --- crypto/objects/obj_dat.pl.orig	2007-09-18 23:05:21.000000000 +0200
   530 +++ crypto/objects/obj_dat.pl	2012-06-27 10:10:05.000000000 +0200
   531 @@ -2,7 +2,6 @@
   533  # fixes bug in floating point emulation on sparc64 when
   534  # this script produces off-by-one output on sparc64
   535 -use integer;
   537  sub obj_cmp
   538  	{
   539 Index: crypto/objects/objxref.pl
   540 --- crypto/objects/objxref.pl.orig	2009-04-06 18:16:23.000000000 +0200
   541 +++ crypto/objects/objxref.pl	2012-06-27 10:10:05.000000000 +0200
   542 @@ -1,7 +1,5 @@
   543  #!/usr/local/bin/perl
   545 -use strict;
   546 -
   547  my %xref_tbl;
   548  my %oid_tbl;
   550 Index: crypto/perlasm/x86_64-xlate.pl
   551 --- crypto/perlasm/x86_64-xlate.pl.orig	2012-03-13 20:19:31.000000000 +0100
   552 +++ crypto/perlasm/x86_64-xlate.pl	2012-06-27 10:10:05.000000000 +0200
   553 @@ -248,7 +248,6 @@
   555  	# Solaris /usr/ccs/bin/as can't handle multiplications
   556  	# in $self->{label}, new gas requires sign extension...
   557 -	use integer;
   558  	$self->{label} =~ s/(?<![\w\$\.])(0x?[0-9a-f]+)/oct($1)/egi;
   559  	$self->{label} =~ s/([0-9]+\s*[\*\/\%]\s*[0-9]+)/eval($1)/eg;
   560  	$self->{label} =~ s/([0-9]+)/$1<<32>>32/eg;
   561 Index: crypto/sha/asm/sha1-586.pl
   562 --- crypto/sha/asm/sha1-586.pl.orig	2011-06-28 15:53:49.000000000 +0200
   563 +++ crypto/sha/asm/sha1-586.pl	2012-06-27 10:10:05.000000000 +0200
   564 @@ -523,7 +523,7 @@
   565  # round]...
   566  #
   567  sub Xupdate_ssse3_16_31()		# recall that $Xi starts wtih 4
   568 -{ use integer;
   569 +{ 
   570    my $body = shift;
   571    my @insns = (&$body,&$body,&$body,&$body);	# 40 instructions
   572    my ($a,$b,$c,$d,$e);
   573 @@ -607,7 +607,7 @@
   574  }
   576  sub Xupdate_ssse3_32_79()
   577 -{ use integer;
   578 +{ 
   579    my $body = shift;
   580    my @insns = (&$body,&$body,&$body,&$body);	# 32 to 48 instructions
   581    my ($a,$b,$c,$d,$e);
   582 @@ -675,7 +675,7 @@
   583  }
   585  sub Xuplast_ssse3_80()
   586 -{ use integer;
   587 +{ 
   588    my $body = shift;
   589    my @insns = (&$body,&$body,&$body,&$body);	# 32 instructions
   590    my ($a,$b,$c,$d,$e);
   591 @@ -710,7 +710,7 @@
   592  }
   594  sub Xloop_ssse3()
   595 -{ use integer;
   596 +{ 
   597    my $body = shift;
   598    my @insns = (&$body,&$body,&$body,&$body);	# 32 instructions
   599    my ($a,$b,$c,$d,$e);
   600 @@ -735,7 +735,7 @@
   601  }
   603  sub Xtail_ssse3()
   604 -{ use integer;
   605 +{ 
   606    my $body = shift;
   607    my @insns = (&$body,&$body,&$body,&$body);	# 32 instructions
   608    my ($a,$b,$c,$d,$e);
   609 @@ -945,7 +945,7 @@
   610  	&jmp	(&label("loop"));
   612  sub Xupdate_avx_16_31()		# recall that $Xi starts wtih 4
   613 -{ use integer;
   614 +{ 
   615    my $body = shift;
   616    my @insns = (&$body,&$body,&$body,&$body);	# 40 instructions
   617    my ($a,$b,$c,$d,$e);
   618 @@ -1023,7 +1023,7 @@
   619  }
   621  sub Xupdate_avx_32_79()
   622 -{ use integer;
   623 +{ 
   624    my $body = shift;
   625    my @insns = (&$body,&$body,&$body,&$body);	# 32 to 48 instructions
   626    my ($a,$b,$c,$d,$e);
   627 @@ -1088,7 +1088,7 @@
   628  }
   630  sub Xuplast_avx_80()
   631 -{ use integer;
   632 +{ 
   633    my $body = shift;
   634    my @insns = (&$body,&$body,&$body,&$body);	# 32 instructions
   635    my ($a,$b,$c,$d,$e);
   636 @@ -1123,7 +1123,7 @@
   637  }
   639  sub Xloop_avx()
   640 -{ use integer;
   641 +{ 
   642    my $body = shift;
   643    my @insns = (&$body,&$body,&$body,&$body);	# 32 instructions
   644    my ($a,$b,$c,$d,$e);
   645 @@ -1147,7 +1147,7 @@
   646  }
   648  sub Xtail_avx()
   649 -{ use integer;
   650 +{ 
   651    my $body = shift;
   652    my @insns = (&$body,&$body,&$body,&$body);	# 32 instructions
   653    my ($a,$b,$c,$d,$e);
   654 Index: crypto/sha/asm/sha1-x86_64.pl
   655 --- crypto/sha/asm/sha1-x86_64.pl.orig	2011-07-04 15:01:42.000000000 +0200
   656 +++ crypto/sha/asm/sha1-x86_64.pl	2012-06-27 10:10:05.000000000 +0200
   657 @@ -367,7 +367,7 @@
   658  }
   660  sub Xupdate_ssse3_16_31()		# recall that $Xi starts wtih 4
   661 -{ use integer;
   662 +{ 
   663    my $body = shift;
   664    my @insns = (&$body,&$body,&$body,&$body);	# 40 instructions
   665    my ($a,$b,$c,$d,$e);
   666 @@ -448,7 +448,7 @@
   667  }
   669  sub Xupdate_ssse3_32_79()
   670 -{ use integer;
   671 +{ 
   672    my $body = shift;
   673    my @insns = (&$body,&$body,&$body,&$body);	# 32 to 48 instructions
   674    my ($a,$b,$c,$d,$e);
   675 @@ -515,7 +515,7 @@
   676  }
   678  sub Xuplast_ssse3_80()
   679 -{ use integer;
   680 +{ 
   681    my $body = shift;
   682    my @insns = (&$body,&$body,&$body,&$body);	# 32 instructions
   683    my ($a,$b,$c,$d,$e);
   684 @@ -549,7 +549,7 @@
   685  }
   687  sub Xloop_ssse3()
   688 -{ use integer;
   689 +{ 
   690    my $body = shift;
   691    my @insns = (&$body,&$body,&$body,&$body);	# 32 instructions
   692    my ($a,$b,$c,$d,$e);
   693 @@ -574,7 +574,7 @@
   694  }
   696  sub Xtail_ssse3()
   697 -{ use integer;
   698 +{ 
   699    my $body = shift;
   700    my @insns = (&$body,&$body,&$body,&$body);	# 32 instructions
   701    my ($a,$b,$c,$d,$e);
   702 @@ -778,7 +778,7 @@
   703  ___
   705  sub Xupdate_avx_16_31()		# recall that $Xi starts wtih 4
   706 -{ use integer;
   707 +{ 
   708    my $body = shift;
   709    my @insns = (&$body,&$body,&$body,&$body);	# 40 instructions
   710    my ($a,$b,$c,$d,$e);
   711 @@ -854,7 +854,7 @@
   712  }
   714  sub Xupdate_avx_32_79()
   715 -{ use integer;
   716 +{ 
   717    my $body = shift;
   718    my @insns = (&$body,&$body,&$body,&$body);	# 32 to 48 instructions
   719    my ($a,$b,$c,$d,$e);
   720 @@ -919,7 +919,7 @@
   721  }
   723  sub Xuplast_avx_80()
   724 -{ use integer;
   725 +{ 
   726    my $body = shift;
   727    my @insns = (&$body,&$body,&$body,&$body);	# 32 instructions
   728    my ($a,$b,$c,$d,$e);
   729 @@ -953,7 +953,7 @@
   730  }
   732  sub Xloop_avx()
   733 -{ use integer;
   734 +{ 
   735    my $body = shift;
   736    my @insns = (&$body,&$body,&$body,&$body);	# 32 instructions
   737    my ($a,$b,$c,$d,$e);
   738 @@ -977,7 +977,7 @@
   739  }
   741  sub Xtail_avx()
   742 -{ use integer;
   743 +{ 
   744    my $body = shift;
   745    my @insns = (&$body,&$body,&$body,&$body);	# 32 instructions
   746    my ($a,$b,$c,$d,$e);
   747 Index: util/clean-depend.pl
   748 --- util/clean-depend.pl.orig	2007-09-19 16:53:18.000000000 +0200
   749 +++ util/clean-depend.pl	2012-06-27 10:10:05.000000000 +0200
   750 @@ -2,8 +2,6 @@
   751  # Clean the dependency list in a makefile of standard includes...
   752  # Written by Ben Laurie <ben@algroup.co.uk> 19 Jan 1999
   754 -use strict;
   755 -
   756  while(<STDIN>) {
   757      print;
   758      last if /^# DO NOT DELETE THIS LINE/;
   759 Index: util/mklink.pl
   760 --- util/mklink.pl.orig	2008-12-19 14:35:09.000000000 +0100
   761 +++ util/mklink.pl	2012-06-27 10:10:05.000000000 +0200
   762 @@ -15,13 +15,12 @@
   763  # Apart from this, this script should be able to handle even the most
   764  # pathological cases.
   766 -use Cwd;
   767 -
   768  my $from = shift;
   769  my @files = @ARGV;
   771  my @from_path = split(/[\\\/]/, $from);
   772 -my $pwd = getcwd();
   773 +my $pwd = `pwd`;
   774 +$pwd =~ s/\r?\n$//s;
   775  chomp($pwd);
   776  my @pwd_path = split(/[\\\/]/, $pwd);

mercurial