summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/rpm/rpm/rpmatch.patch
diff options
context:
space:
mode:
authorKhem Raj <raj.khem@gmail.com>2012-05-31 15:51:52 -0700
committerRichard Purdie <richard.purdie@linuxfoundation.org>2012-06-18 17:24:40 +0100
commiteaedf2e9410a08ff3594b0ec23c543c74ed1e85b (patch)
tree0d25099a95d9929d19e4130d83779111bbee006a /meta/recipes-devtools/rpm/rpm/rpmatch.patch
parent5276472c5e17191e503247257b572ed7643e3889 (diff)
downloadpoky-eaedf2e9410a08ff3594b0ec23c543c74ed1e85b.tar.gz
rpm: Fix compilation on uclibc
rpmatch is not there in uclibc therefore add logic to configure to detect it. x* wrappers need to be defined for uclibc as well. (From OE-Core rev: 0cd3a4f3cfd0eb70915e3b59be8d04ee2d92749e) Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-devtools/rpm/rpm/rpmatch.patch')
-rw-r--r--meta/recipes-devtools/rpm/rpm/rpmatch.patch42
1 files changed, 42 insertions, 0 deletions
diff --git a/meta/recipes-devtools/rpm/rpm/rpmatch.patch b/meta/recipes-devtools/rpm/rpm/rpmatch.patch
new file mode 100644
index 0000000000..8ea349003a
--- /dev/null
+++ b/meta/recipes-devtools/rpm/rpm/rpmatch.patch
@@ -0,0 +1,42 @@
1Add configure check for rpmatch() and
2creates a compatable macro if it is not provided by the C library.
3
4This is needed for uclibc since it does not have the above function
5implemented.
6
7Upstream-Status: Pending
8
9Signed-off-by: Khem Raj <raj.khem@gmail.com>
10
11Index: rpm-5.4.0/configure.ac
12===================================================================
13--- rpm-5.4.0.orig/configure.ac 2012-05-31 15:40:05.985990822 -0700
14+++ rpm-5.4.0/configure.ac 2012-05-31 15:41:15.601995311 -0700
15@@ -800,7 +800,7 @@
16 ftok getaddrinfo getattrlist getcwd getdelim getline getmode getnameinfo dnl
17 getpassphrase getxattr getwd iconv inet_aton lchflags lchmod lchown dnl
18 lgetxattr lsetxattr lutimes madvise mempcpy mkdtemp mkstemp mtrace dnl
19- posix_fadvise posix_fallocate putenv realpath regcomp __secure_getenv dnl
20+ posix_fadvise posix_fallocate putenv realpath regcomp rpmatch __secure_getenv dnl
21 setattrlist setenv setlocale setmode setxattr dnl
22 sigaddset sigdelset sigemptyset sighold sigrelse sigpause dnl
23 sigprocmask sigsuspend sigaction dnl
24Index: rpm-5.4.0/system.h
25===================================================================
26--- rpm-5.4.0.orig/system.h 2012-05-31 15:40:05.997991504 -0700
27+++ rpm-5.4.0/system.h 2012-05-31 15:42:04.941997731 -0700
28@@ -410,6 +410,14 @@
29 #endif /* defined(__GNUC__) */
30 #endif /* HAVE_MCHECK_H */
31
32+#ifndef HAVE_RPMATCH
33+#define rpmatch(line) \
34+ ( (line == NULL)? -1 : \
35+ (*line == 'y' || *line == 'Y')? 1 : \
36+ (*line == 'n' || *line == 'N')? 0 : \
37+ -1 )
38+#endif
39+
40 /* Retrofit glibc __progname */
41 #if defined __GLIBC__ && __GLIBC__ >= 2
42 #if __GLIBC_MINOR__ >= 1