summary refs log tree commit diff
path: root/pkgs/development/libraries/openssl/kfreebsd-gnu.patch
blob: 66cedf746ba582b86e5453807f6908fde9073f4c (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
Allow compilation on GNU/kFreeBSD.  Ideally, there'd be a single way to process
all glibc-based system, but the build system is soooo broken.

--- openssl-1.0.0i/config
+++ openssl-1.0.0i/config
@@ -170,6 +170,10 @@ case "${SYSTEM}:${RELEASE}:${VERSION}:${
 	echo "${MACHINE}-whatever-linux1"; exit 0
 	;;
 
+    GNU/kFreeBSD*)
+    	echo "kfreebsd-gnu"; exit 0;
+    	;;
+
     GNU*)
 	echo "hurd-x86"; exit 0;
 	;;
@@ -810,6 +814,7 @@ case "$GUESSOS" in
   beos-*) OUT="$GUESSOS" ;;
   x86pc-*-qnx6) OUT="QNX6-i386" ;;
   *-*-qnx6) OUT="QNX6" ;;
+  kfreebsd-gnu) OUT="kfreebsd-gnu";;
   *) OUT=`echo $GUESSOS | awk -F- '{print $3}'`;;
 esac
 

--- openssl-1.0.0i/Configure
+++ openssl-1.0.0i/Configure
@@ -565,6 +565,9 @@ my %table=(
 ##### GNU Hurd
 "hurd-x86",  "gcc:-DL_ENDIAN -DTERMIOS -O3 -fomit-frame-pointer -march=i486 -Wall::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:linux-shared:-fPIC",
 
+##### GNU/kFreeBSD on x86_64, copied from "linux-x86_64"
+"kfreebsd-gnu",	"gcc:-m64 -DL_ENDIAN -DTERMIOS -O3 -Wall -DMD32_REG_T=int::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_INT DES_UNROLL:${x86_64_asm}:elf:dlfcn:linux-shared:-fPIC:-m64:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):::64",
+
 ##### OS/2 EMX
 "OS2-EMX", "gcc::::::::",