From e2190be0460e5755eb4f912004769afd056f1ee4 Mon Sep 17 00:00:00 2001 From: Steve Grubb Date: Jan 29 2010 18:57:22 +0000 Subject: - Split out static libs (#556039) --- diff --git a/audit-2.0.5-auparse-empty-FILE_ARRAY.patch b/audit-2.0.5-auparse-empty-FILE_ARRAY.patch new file mode 100644 index 0000000..3dfc158 --- /dev/null +++ b/audit-2.0.5-auparse-empty-FILE_ARRAY.patch @@ -0,0 +1,14 @@ +diff -urp audit-2.0.5.orig/auparse/auparse.c audit-2.0.5/auparse/auparse.c +--- audit-2.0.5.orig/auparse/auparse.c 2009-12-09 09:49:10.000000000 -0500 ++++ audit-2.0.5/auparse/auparse.c 2009-12-09 09:49:24.000000000 -0500 +@@ -782,6 +782,10 @@ static int retrieve_next_line(auparse_st + case AUSOURCE_FILE_ARRAY: + // if the first time through, open file + if (au->list_idx == 0 && au->in == NULL) { ++ if (au->source_list[au->list_idx] == NULL) { ++ errno = 0; ++ return -2; ++ } + au->line_number = 0; + au->in = fopen(au->source_list[au->list_idx], + "r"); diff --git a/audit-2.0.5-glibc.patch b/audit-2.0.5-glibc.patch new file mode 100644 index 0000000..2fe137e --- /dev/null +++ b/audit-2.0.5-glibc.patch @@ -0,0 +1,11 @@ +diff -urp audit-2.0.5.orig/lib/libaudit.c audit-2.0.5/lib/libaudit.c +--- audit-2.0.5.orig/lib/libaudit.c 2009-12-09 09:49:10.000000000 -0500 ++++ audit-2.0.5/lib/libaudit.c 2010-01-13 19:28:10.000000000 -0500 +@@ -34,6 +34,7 @@ + #include + #include + #include ++#include + #include /* O_NOFOLLOW needs gnu defined */ + #include /* for PATH_MAX */ + diff --git a/audit-2.0.5-i386-inode.patch b/audit-2.0.5-i386-inode.patch new file mode 100644 index 0000000..480c830 --- /dev/null +++ b/audit-2.0.5-i386-inode.patch @@ -0,0 +1,17 @@ +diff -urp audit-2.0.5.orig/lib/libaudit.c audit-2.0.5/lib/libaudit.c +--- audit-2.0.5.orig/lib/libaudit.c 2009-12-09 09:49:10.000000000 -0500 ++++ audit-2.0.5/lib/libaudit.c 2010-01-13 14:28:52.000000000 -0500 +@@ -1130,7 +1130,12 @@ int audit_rule_fieldpair_data(struct aud + if (!isdigit((char)*(v))) + return -21; + +- rule->values[rule->field_count] = strtol(v, NULL, 0); ++ if (field == AUDIT_INODE) ++ rule->values[rule->field_count] = ++ strtoul(v, NULL, 0); ++ else ++ rule->values[rule->field_count] = ++ strtol(v, NULL, 0); + break; + } + rule->field_count++; diff --git a/audit.spec b/audit.spec index 149c6c5..c92c2cc 100644 --- a/audit.spec +++ b/audit.spec @@ -8,6 +8,9 @@ License: GPLv2+ Group: System Environment/Daemons URL: http://people.redhat.com/sgrubb/audit/ Source0: http://people.redhat.com/sgrubb/audit/%{name}-%{version}.tar.gz +Patch1: audit-2.0.5-auparse-empty-FILE_ARRAY.patch +Patch2: audit-2.0.5-i386-inode.patch +Patch3: audit-2.0.5-glibc.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: swig python-devel BuildRequires: tcp_wrappers-devel libcap-ng-devel @@ -80,6 +83,9 @@ behavior. %prep %setup -q +%patch1 -p1 +%patch2 -p1 +%patch3 -p1 %build %configure --sbindir=/sbin --libdir=/%{_lib} --with-prelude --with-libwrap --enable-gssapi-krb5=no --with-libcap-ng=yes