0003-build-system.patch
4.23 KB
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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
Fix build with BR2_ENABLE_DEBUG=yes, no need for expert mode anymore
Otherwise configure issues this error message:
configure: error: --enable-debug cannot be used in conjunction with --enable-expert-mode
Downloaded from Gentoo:
http://sources.gentoo.org/cgi-bin/viewvc.cgi/gentoo-x86/dev-libs/beecrypt/files/beecrypt-4.2.1-build-system.patch?revision=1.2&view=markup
This patch also removes the hard-coded CFLAGS provided by beecrypt in favour
of the CFLAGS provided by buildroot.
Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
--- beecrypt-4.2.1/configure.ac
+++ beecrypt-4.2.1/configure.ac
@@ -11,7 +11,7 @@
# Checks for package options
AC_ARG_ENABLE(expert-mode, [ --enable-expert-mode follow user-defined CFLAGS settings [[default=no]]],[
- ac_enable_expert_mode=yes
+ ac_enable_expert_mode=$enableval
],[
if test "X$CFLAGS" != "X"; then
echo "enabling expert mode"
@@ -25,7 +25,7 @@
if test "$ac_enable_expert_mode" = yes; then
AC_MSG_ERROR([--enable-debug cannot be used in conjunction with --enable-expert-mode])
fi
- ac_enable_debug=yes
+ ac_enable_debug=$enableval
],[
ac_enable_debug=no
])
@@ -456,7 +456,7 @@
ac_cv_python_include="-I`$PYTHON -c 'import distutils.sysconfig; print distutils.sysconfig.get_python_inc()'`"
])
AC_CACHE_CHECK([where to install python libraries], ac_cv_python_libdir, [
- ac_cv_python_libdir=`$PYTHON -c 'import distutils.sysconfig; print distutils.sysconfig.get_python_lib()'`
+ ac_cv_python_libdir=`$PYTHON -c 'import distutils.sysconfig; print distutils.sysconfig.get_python_lib(1, 0)'`
])
fi
fi
--- beecrypt-4.2.1/acinclude.m4
+++ beecrypt-4.2.1/acinclude.m4
@@ -498,15 +498,6 @@ AC_DEFUN([BEE_GNU_CC],[
AC_SUBST(OPENMP_LIBS,"-lgomp")
fi
case $bc_target_arch in
- x86_64 | athlon64 | athlon-fx | k8 | opteron | em64t | nocona)
- CC="$CC -m64"
- ;;
- i[[3456]]86 | \
- pentium* | \
- athlon*)
- CC="$CC -m32"
- CCAS="$CCAS -m32"
- ;;
ia64)
case $target_os in
# HP/UX on Itanium needs to be told that a long is 64-bit!
@@ -525,17 +516,8 @@ AC_DEFUN([BEE_GNU_CC],[
aix*)
CC="$CC -maix64"
;;
- linux*)
- CC="$CC -m64"
- ;;
esac
;;
- sparc | sparcv8*)
- CC="$CC -m32"
- ;;
- sparc64 | sparcv9*)
- CC="$CC -m64"
- ;;
esac
# Certain platforms needs special flags for multi-threaded code
if test "$ac_enable_threads" = yes; then
@@ -646,14 +646,6 @@ dnl BEE_GNU_CXX
AC_DEFUN([BEE_GNU_CXX],[
AC_REQUIRE([AC_PROG_CXX])
case $bc_target_arch in
- x86_64 | athlon64 | athlon-fx | k8 | opteron | em64t | nocona | core2)
- CXX="$CXX -m64"
- ;;
- i[[3456]]86 | \
- pentium* | \
- athlon*)
- CXX="$CXX -m32"
- ;;
ia64)
case $target_os in
# HP/UX on Itanium needs to be told that a long is 64-bit!
@@ -672,17 +664,8 @@ AC_DEFUN([BEE_GNU_CXX],[
aix*)
CXX="$CXX -maix64"
;;
- linux*)
- CXX="$CXX -m64"
- ;;
esac
;;
- sparc | sparcv8*)
- CXX="$CXX -m32"
- ;;
- sparc64 | sparcv9*)
- CXX="$CXX -m64"
- ;;
esac
# Certain platforms needs special flags for multi-threaded code
if test "$ac_enable_threads" = yes; then
--- beecrypt-4.2.1/java/Makefile.am
+++ beecrypt-4.2.1/java/Makefile.am
@@ -26,7 +26,7 @@
INCLUDES = -I$(top_srcdir)/include
-libaltdir=$(prefix)/lib@LIBALT@
+libaltdir=$(libdir)
libalt_LTLIBRARIES = libbeecrypt_java.la
--- beecrypt-4.2.1/acinclude.m4
+++ beecrypt-4.2.1/acinclude.m4
@@ -1589,20 +1589,5 @@
AC_SUBST(TYPEDEF_BC_THREADID_T,$bc_typedef_bc_threadid_t)
])
-
-AH_BOTTOM([
-#if ENABLE_THREADS
-# ifndef _REENTRANT
-# define _REENTRANT
-# endif
-# if LINUX
-# define _LIBC_REENTRANT
-# endif
-#else
-# ifdef _REENTRANT
-# undef _REENTRANT
-# endif
-#endif
-])
dnl BEE_THREAD_LOCAL_STORAGE
@@ -1623,7 +1609,5 @@
])
AH_BOTTOM([
-#if !ENABLE_THREAD_LOCAL_STORAGE
-# define __thread
-#endif
+#include "config.threads.h"
])
--- beecrypt-4.2.1/config.threads.h
+++ beecrypt-4.2.1/config.threads.h
@@ -0,0 +1,16 @@
+#if ENABLE_THREADS
+# ifndef _REENTRANT
+# define _REENTRANT
+# endif
+# if LINUX
+# define _LIBC_REENTRANT
+# endif
+#else
+# ifdef _REENTRANT
+# undef _REENTRANT
+# endif
+#endif
+
+#if !ENABLE_THREAD_LOCAL_STORAGE
+# define __thread
+#endif