summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/rpm/rpm/remove-compiled-tests.patch
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-devtools/rpm/rpm/remove-compiled-tests.patch')
-rw-r--r--meta/recipes-devtools/rpm/rpm/remove-compiled-tests.patch440
1 files changed, 440 insertions, 0 deletions
diff --git a/meta/recipes-devtools/rpm/rpm/remove-compiled-tests.patch b/meta/recipes-devtools/rpm/rpm/remove-compiled-tests.patch
new file mode 100644
index 0000000000..69b7130b9b
--- /dev/null
+++ b/meta/recipes-devtools/rpm/rpm/remove-compiled-tests.patch
@@ -0,0 +1,440 @@
1Index: rpm-5.1.9/configure.ac
2===================================================================
3--- rpm-5.1.9.orig/configure.ac 2009-04-18 17:47:02.000000000 +0100
4+++ rpm-5.1.9/configure.ac 2010-07-06 14:47:28.985462456 +0100
5@@ -643,38 +643,22 @@
6 dnl look for libc features
7 PROVIDES_ERRNO=no
8 AC_MSG_CHECKING(if <netdb.h> defines h_errno)
9-AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <netdb.h>]], [[printf("%d",h_errno)]])],[PROVIDES_ERRNO=yes],[])
10-AC_MSG_RESULT($PROVIDES_ERRNO)
11-if test $PROVIDES_ERRNO = yes; then
12- AC_DEFINE(HAVE_HERRNO, 1, [ Define as 1 if <netdb.h> defines h_errno])
13-fi
14+AC_DEFINE(HAVE_HERRNO, 1, [ Define as 1 if <netdb.h> defines h_errno])
15
16 dnl If a system doesn't have S_IFSOCK, define it as 0 which will
17 dnl make S_ISSOCK always return false (nice, eh?)
18 AC_MSG_CHECKING(if <sys/stat.h> defines S_IFSOCK)
19-AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <sys/stat.h>]], [[printf("%d", S_IFSOCK)]])],[HAS_S_IFSOCK=yes],[HAS_S_IFSOCK=no])
20-AC_MSG_RESULT($HAS_S_IFSOCK)
21-if test $HAS_S_IFSOCK = yes; then
22- AC_DEFINE(HAVE_S_IFSOCK, 1, [Define as 1 if <sys/stat.h> defines S_IFSOCK])
23-fi
24+AC_DEFINE(HAVE_S_IFSOCK, 1, [Define as 1 if <sys/stat.h> defines S_IFSOCK])
25
26 dnl Some Unix's are missing S_ISLNK, S_ISSOCK
27 AC_MSG_CHECKING(if <sys/stat.h> defines S_ISLNK)
28-AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <sys/stat.h>]], [[printf("%d", S_ISLNK(0755))]])],[HAS_S_ISLNK=yes],[HAS_S_ISLNK=no])
29-AC_MSG_RESULT($HAS_S_ISLNK)
30-if test $HAS_S_ISLNK = yes; then
31- AC_DEFINE(HAVE_S_ISLNK, 1, [Define as 1 if <sys/stat.h> defines S_ISLNK])
32-fi
33+AC_DEFINE(HAVE_S_ISLNK, 1, [Define as 1 if <sys/stat.h> defines S_ISLNK])
34
35 AC_MSG_CHECKING(if <sys/stat.h> defines S_ISSOCK)
36-AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <sys/stat.h>]], [[printf("%d", S_ISSOCK(0755))]])],[HAS_S_ISSOCK=yes],[HAS_S_ISSOCK=no])
37-AC_MSG_RESULT($HAS_S_ISSOCK)
38-if test $HAS_S_ISSOCK = yes; then
39- AC_DEFINE(HAVE_S_ISSOCK, 1, [Define as 1 if <sys/stat.h> defines S_ISSOCK])
40-fi
41+AC_DEFINE(HAVE_S_ISSOCK, 1, [Define as 1 if <sys/stat.h> defines S_ISSOCK])
42
43 AC_MSG_CHECKING(if timezone is defined)
44-AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <time.h>]], [[printf("%ld", timezone)]])],[HAS_TIMEZONE=yes],[HAS_TIMEZONE=no])
45+$HAS_TIMEZONE=yes
46 AC_MSG_RESULT($HAS_TIMEZONE)
47
48 dnl check for missing typedefs
49@@ -726,53 +710,12 @@
50 AC_MSG_RESULT(yes)
51 AC_CHECK_HEADERS([libelf.h gelf.h])
52 if test ".$ac_cv_header_libelf_h" = .no; then
53- dnl # <libelf.h> on Solaris is incompatible with LFS. If we couldn't
54- dnl # include <libelf.h>, see if we can when _FILE_OFFSET_BITS is
55- dnl # set for non-LFS. Same applies for <gelf.h>, since it probably
56- dnl # includes <libelf.h>
57- AC_MSG_CHECKING([if libelf.h conflicts with _LARGEFILE_SOURCE])
58- AC_COMPILE_IFELSE([
59- AC_LANG_PROGRAM([[
60-#undef _LARGEFILE64_SOURCE
61-#undef _LARGEFILE_SOURCE
62-#if !defined(_LP64)
63-# undef _FILE_OFFSET_BITS
64-# define _FILE_OFFSET_BITS 32
65-#endif
66-#include <libelf.h>
67- ]], [[
68- Elf_Data foo;
69- ]])
70- ], [
71- AC_DEFINE(HAVE_LIBELF_H, 1, [Define to 1 if you have libelf.h])
72- ac_cv_header_libelf_h=yes
73- AC_DEFINE(LIBELF_H_LFS_CONFLICT, 1, [Define to 1 if libelf.h is incompatible with LFS API])
74- AC_MSG_RESULT(yes)
75- ], [
76- AC_MSG_RESULT(no)
77- ])
78+ AC_DEFINE(HAVE_LIBELF_H, 1, [Define to 1 if you have libelf.h])
79+ ac_cv_header_libelf_h=yes
80 fi
81 if test ".$ac_cv_header_gelf_h" = .no; then
82- AC_MSG_CHECKING([if gelf.h conflicts with _LARGEFILE_SOURCE])
83- AC_COMPILE_IFELSE([
84- AC_LANG_PROGRAM([[
85-#undef _LARGEFILE64_SOURCE
86-#undef _LARGEFILE_SOURCE
87-#if !defined(_LP64)
88-# undef _FILE_OFFSET_BITS
89-# define _FILE_OFFSET_BITS 32
90-#endif
91-#include <gelf.h>
92- ]], [[
93- Elf32_Verdef foo;
94- ]])
95- ], [
96- AC_DEFINE(HAVE_GELF_H, 1, [Define to 1 if you have gelf.h])
97- ac_cv_header_gelf_h=yes
98- AC_MSG_RESULT(yes)
99- ], [
100- AC_MSG_RESULT(no)
101- ])
102+ AC_DEFINE(HAVE_GELF_H, 1, [Define to 1 if you have gelf.h])
103+ ac_cv_header_gelf_h=yes
104 fi
105 if test ".$ac_cv_header_gelf_h" = .yes; then
106 AC_CHECK_LIB([elf], [elf_version], [
107@@ -854,78 +797,9 @@
108 python_version=""
109 ;;
110 esac
111- for python_ver in $python_version ; do
112- if test "$python_ver" != "2.x" ; then
113- AC_MSG_CHECKING([for Python ${python_ver} API])
114- save_CFLAGS="${CFLAGS}"
115- for i in "$prefix" "/usr/local" "/usr"; do
116- CFLAGS="${save_CFLAGS} -I$i/include/python${python_ver}"
117- AC_RUN_IFELSE([AC_LANG_SOURCE(
118- [[#include "Python.h"
119- main() { exit(strncmp("${python_ver}", PY_VERSION, 3)); } ]])
120- ], [
121- PYTHON_VERSION="${python_ver}"
122- AC_MSG_RESULT(yes)
123- PYTHON_PREFIX="${i}"
124- break
125- ], [
126- ], [
127- dnl if we're cross compiling, assume the user has a clue
128- if test "$withval" = "$python_ver"; then
129- PYTHON_VERSION="${python_ver}"
130- AC_MSG_RESULT(yes)
131- break
132- fi
133- ])
134- done
135- CFLAGS="${save_CFLAGS}"
136- if test ".$PYTHON_VERSION" == "."; then
137- dnl check Mac OS X framework
138- save_CFLAGS="${CFLAGS}"
139- for f in "~" "" "/System" "/Network"; do
140- CFLAGS="${save_CFLAGS} -I$f/Library/Frameworks/Python.framework/Versions/${python_ver}/include/python${python_ver}"
141- AC_RUN_IFELSE([AC_LANG_SOURCE(
142- [[#include "Python.h"
143- main() { exit(strncmp("${python_ver}", PY_VERSION, 3)); } ]])
144- ], [
145- PYTHON_VERSION="${python_ver}"
146- AC_MSG_RESULT([yes (using Python.framework)])
147- PYTHON_PREFIX="$f/Library/Frameworks/Python.framework/Versions/${python_ver}"
148- break
149- ], [
150- ])
151- done
152- CFLAGS="${save_CFLAGS}"
153- fi
154- if test ".$PYTHON_VERSION" == "."; then
155- AC_MSG_RESULT(no)
156- fi
157- else
158- AC_MSG_CHECKING([for Python 2.x API])
159- AC_RUN_IFELSE([AC_LANG_SOURCE(
160- [[#include <python/Python.h>
161- main() { exit(strncmp("2.", PY_VERSION, 2)); } ]])
162- ], [
163- PYTHON_VERSION=""
164- AC_MSG_RESULT(yes)
165- ], [
166- AC_MSG_RESULT(no)
167- ], [
168- dnl if we're cross compiling, assume the user has a clue
169- if test "$withval" = "$python_ver"; then
170- PYTHON_VERSION="${python_ver}"
171- AC_MSG_RESULT(yes)
172- else
173- AC_MSG_RESULT(no)
174- fi
175- ])
176- fi
177- if test ".$PYTHON_VERSION" != "."; then
178- WITH_PYTHON_SUBDIR=python
179- WITH_PYTHON_SUBPACKAGE=1
180- break
181- fi
182- done
183+ PYTHON_VERSION="${python_ver}"
184+ WITH_PYTHON_SUBDIR=python
185+ WITH_PYTHON_SUBPACKAGE=1
186 fi
187 AC_ARG_WITH(python-inc-dir, AS_HELP_STRING([--with-python-inc-dir=DIR], [directory with Python include files]),
188 [WITH_PYTHON_INCDIR="$withval"], [WITH_PYTHON_INCDIR="`(python -c 'from distutils.sysconfig import get_python_inc; print get_python_inc()') 2>/dev/null`"])
189@@ -1157,15 +1031,8 @@
190 AC_SUBST(WITH_PCRE_LIBS)
191 else
192 dnl # make sure PCRE POSIX API can be really _USED_ by RPM
193- LIBS_SAVED="$LIBS"
194 LIBS="-lpcreposix $LIBS"
195- AC_LINK_IFELSE([
196- AC_LANG_PROGRAM([#include <pcreposix.h>], [(void)regcomp(0, 0, 0)])
197- ], [
198- AC_DEFINE(WITH_PCRE_POSIX, 1, [Define as 1 if PCRE's POSIX API is available])
199- ], [
200- LIBS="$LIBS_SAVED"
201- ])
202+ AC_DEFINE(WITH_PCRE_POSIX, 1, [Define as 1 if PCRE's POSIX API is available])
203 fi
204 dnl # enable PCRE native API support for embedded Lua
205 if test ".$WITH_LUA" = .yes; then
206@@ -1234,30 +1101,7 @@
207
208 dnl # figure out what root's primary group is
209 AC_MSG_CHECKING([root's primary group])
210-AC_RUN_IFELSE([AC_LANG_SOURCE([[#include <stdio.h>
211-#include <sys/types.h>
212-#include <pwd.h>
213-#include <grp.h>
214-int main()
215-{
216- struct passwd *root = NULL;
217- struct group *roots_group = NULL;
218- FILE * tempfile = NULL;
219- root = getpwuid( (uid_t) 0 );
220- if (root != NULL) {
221- roots_group = getgrgid(root->pw_gid);
222- if (roots_group != NULL) {
223- tempfile = fopen("conftest_rootg", "w");
224- if (tempfile != NULL) {
225- fprintf(tempfile, "%s\n", roots_group->gr_name);
226- fclose(tempfile);
227- exit(0);
228- }
229- }
230- }
231- exit(1);
232-}]])],[ROOT_GROUP=`cat conftest_rootg`; rm -f conftest_rootg],[ROOT_GROUP="root"],[ROOT_GROUP="root"
233-])
234+$ROOT_GROUP="root"
235 AC_MSG_RESULT([$ROOT_GROUP])
236 AC_SUBST(ROOT_GROUP)
237
238Index: rpm-5.1.9/pcre/configure.ac
239===================================================================
240--- rpm-5.1.9.orig/pcre/configure.ac 2009-01-14 20:19:31.000000000 +0000
241+++ rpm-5.1.9/pcre/configure.ac 2010-07-06 14:51:50.769586089 +0100
242@@ -278,34 +278,6 @@
243 # The files below are C++ header files.
244 pcre_have_type_traits="0"
245 pcre_have_bits_type_traits="0"
246-if test "x$enable_cpp" = "xyes" -a -n "$CXX"
247-then
248-AC_LANG_PUSH(C++)
249-
250-# Older versions of pcre defined pcrecpp::no_arg, but in new versions
251-# it's called pcrecpp::RE::no_arg. For backwards ABI compatibility,
252-# we want to make one an alias for the other. Different systems do
253-# this in different ways. Some systems, for instance, can do it via
254-# a linker flag: -alias (for os x 10.5) or -i (for os x <=10.4).
255-OLD_LDFLAGS="$LDFLAGS"
256-for flag in "-alias,__ZN7pcrecpp2RE6no_argE,__ZN7pcrecpp6no_argE" \
257- "-i__ZN7pcrecpp6no_argE:__ZN7pcrecpp2RE6no_argE"; do
258- AC_MSG_CHECKING([for alias support in the linker])
259- LDFLAGS="$OLD_LDFLAGS -Wl,$flag"
260- # We try to run the linker with this new ld flag. If the link fails,
261- # we give up and remove the new flag from LDFLAGS.
262- AC_LINK_IFELSE(AC_LANG_PROGRAM([namespace pcrecpp {
263- class RE { static int no_arg; };
264- int RE::no_arg;
265- }],
266- []),
267- [AC_MSG_RESULT([yes]);
268- EXTRA_LIBPCRECPP_LDFLAGS="$EXTRA_LIBPCRECPP_LDFLAGS -Wl,$flag";
269- break;],
270- AC_MSG_RESULT([no]))
271-done
272-LDFLAGS="$OLD_LDFLAGS"
273-
274 # We could be more clever here, given we're doing AC_SUBST with this
275 # (eg set a var to be the name of the include file we want). But we're not
276 # so it's easy to change back to 'regular' autoconf vars if we needed to.
277@@ -316,7 +288,6 @@
278 AC_CHECK_HEADERS(type_traits.h, [pcre_have_type_traits="1"],
279 [pcre_have_type_traits="0"])
280
281-AC_LANG_POP
282 fi
283 # Using AC_SUBST eliminates the need to include config.h in a public .h file
284 AC_SUBST(pcre_have_type_traits)
285Index: rpm-5.1.9/db/dist/configure.ac
286===================================================================
287--- rpm-5.1.9.orig/db/dist/configure.ac 2008-06-15 08:16:21.000000000 +0100
288+++ rpm-5.1.9/db/dist/configure.ac 2010-07-06 15:36:39.262461127 +0100
289@@ -602,24 +602,6 @@
290 aux*) AC_LIBOBJ([getopt]);;
291 esac
292
293-# Linux has a broken O_DIRECT flag, but you can't detect it at configure time.
294-# Linux and SGI require buffer alignment we may not match, otherwise writes
295-# will fail. Default to not using the O_DIRECT flag.
296-if test "$db_cv_o_direct" = "yes"; then
297- AC_CACHE_CHECK([for open/O_DIRECT], db_cv_open_o_direct, [
298- AC_TRY_LINK([
299- #include <sys/types.h>
300- #include <fcntl.h>], [
301- open("a", O_RDONLY | O_DIRECT, 0);
302- ], [db_cv_open_o_direct=yes], [db_cv_open_o_direct=no])])
303- if test \
304- "$db_cv_o_direct" = "yes" -a "$db_cv_open_o_direct" = "yes"; then
305- AC_DEFINE(HAVE_O_DIRECT)
306- AH_TEMPLATE(HAVE_O_DIRECT,
307- [Define to 1 if you have the O_DIRECT flag.])
308- fi
309-fi
310-
311 # Check for largefile support.
312 AC_SYS_LARGEFILE
313
314Index: rpm-5.1.9/xz/configure.ac
315===================================================================
316--- rpm-5.1.9.orig/xz/configure.ac 2009-02-16 17:07:46.000000000 +0000
317+++ rpm-5.1.9/xz/configure.ac 2010-07-06 15:41:22.632467951 +0100
318@@ -457,26 +457,9 @@
319 #endif
320 ])
321
322-# Even if we have byteswap.h, we may lack the specific macros/functions.
323-if test x$ac_cv_header_byteswap_h = xyes ; then
324- m4_foreach([FUNC], [bswap_16,bswap_32,bswap_64], [
325- AC_MSG_CHECKING([if FUNC is available])
326- AC_LINK_IFELSE([AC_LANG_SOURCE([
327-#include <byteswap.h>
328-int
329-main(void)
330-{
331- FUNC[](42);
332- return 0;
333-}
334- ])], [
335- AC_DEFINE(HAVE_[]m4_toupper(FUNC), [1],
336- [Define to 1 if] FUNC [is available.])
337- AC_MSG_RESULT([yes])
338- ], [AC_MSG_RESULT([no])])
339-
340- ])dnl
341-fi
342+AC_DEFINE(HAVE_BSWAP_16, 1)
343+AC_DEFINE(HAVE_BSWAP_32, 1)
344+AC_DEFINE(HAVE_BSWAP_64, 1)
345
346
347 ###############################################################################
348@@ -527,90 +510,16 @@
349 # xz command line tool uses this to automatically limit its memory usage.
350 # - sysconf() gives all the needed info on GNU+Linux and Solaris.
351 # - BSDs use sysctl().
352-AC_MSG_CHECKING([how to detect the amount of physical memory])
353-AC_COMPILE_IFELSE([AC_LANG_SOURCE([[
354-#include <unistd.h>
355-int
356-main()
357-{
358- long i;
359- i = sysconf(_SC_PAGESIZE);
360- i = sysconf(_SC_PHYS_PAGES);
361- return 0;
362-}
363-]])], [
364- AC_DEFINE([HAVE_PHYSMEM_SYSCONF], [1],
365+AC_DEFINE([HAVE_PHYSMEM_SYSCONF], [1],
366 [Define to 1 if the amount of physical memory can be detected
367 with sysconf(_SC_PAGESIZE) and sysconf(_SC_PHYS_PAGES).])
368- AC_MSG_RESULT([sysconf])
369-], [
370-AC_COMPILE_IFELSE([AC_LANG_SOURCE([[
371-#include <sys/types.h>
372-#ifdef HAVE_SYS_PARAM_H
373-# include <sys/param.h>
374-#endif
375-#include <sys/sysctl.h>
376-int
377-main()
378-{
379- int name[2] = { CTL_HW, HW_PHYSMEM };
380- unsigned long mem;
381- size_t mem_ptr_size = sizeof(mem);
382- sysctl(name, 2, &mem, &mem_ptr_size, NULL, NULL);
383- return 0;
384-}
385-]])], [
386- AC_DEFINE([HAVE_PHYSMEM_SYSCTL], [1],
387- [Define to 1 if the amount of physical memory can be detected
388- with sysctl().])
389- AC_MSG_RESULT([sysctl])
390-], [
391- AC_MSG_RESULT([unknown])
392-])])
393
394 # Check how to find out the number of available CPU cores in the system.
395 # sysconf(_SC_NPROCESSORS_ONLN) works on most systems, except that BSDs
396 # use sysctl().
397-AC_MSG_CHECKING([how to detect the number of available CPU cores])
398-AC_COMPILE_IFELSE([AC_LANG_SOURCE([[
399-#include <unistd.h>
400-int
401-main()
402-{
403- long i;
404- i = sysconf(_SC_NPROCESSORS_ONLN);
405- return 0;
406-}
407-]])], [
408- AC_DEFINE([HAVE_NCPU_SYSCONF], [1],
409+AC_DEFINE([HAVE_NCPU_SYSCONF], [1],
410 [Define to 1 if the number of available CPU cores can be
411 detected with sysconf(_SC_NPROCESSORS_ONLN).])
412- AC_MSG_RESULT([sysconf])
413-], [
414-AC_COMPILE_IFELSE([AC_LANG_SOURCE([[
415-#include <sys/types.h>
416-#ifdef HAVE_SYS_PARAM_H
417-# include <sys/param.h>
418-#endif
419-#include <sys/sysctl.h>
420-int
421-main()
422-{
423- int name[2] = { CTL_HW, HW_NCPU };
424- int cpus;
425- size_t cpus_size = sizeof(cpus);
426- sysctl(name, 2, &cpus, &cpus_size, NULL, NULL);
427- return 0;
428-}
429-]])], [
430- AC_DEFINE([HAVE_NCPU_SYSCTL], [1],
431- [Define to 1 if the number of available CPU cores can be
432- detected with sysctl().])
433- AC_MSG_RESULT([sysctl])
434-], [
435- AC_MSG_RESULT([unknown])
436-])])
437-
438
439 ###############################################################################
440 # If using GCC, set some additional CFLAGS: