forked from linux-audit/audit-userspace
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add audit.m4 file to aid adding support to other projects
git-svn-id: http://svn.fedorahosted.org/svn/audit/trunk@1131 03a675c2-f56d-4096-908f-63dba836b7e4
- Loading branch information
sgrubb
committed
Oct 30, 2015
1 parent
f70562b
commit 921e77f
Showing
7 changed files
with
71 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
# Makefile.am -- | ||
# Copyright 2015 Red Hat Inc., Durham, North Carolina. | ||
# All Rights Reserved. | ||
# | ||
# This library is free software; you can redistribute it and/or | ||
# modify it under the terms of the GNU Lesser General Public | ||
# License as published by the Free Software Foundation; either | ||
# version 2.1 of the License, or (at your option) any later version. | ||
# | ||
# This library is distributed in the hope that it will be useful, | ||
# but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
# Lesser General Public License for more details. | ||
# | ||
# You should have received a copy of the GNU Lesser General Public | ||
# License along with this library; if not, write to the Free Software | ||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
# | ||
# Authors: | ||
# Steve Grubb <[email protected]> | ||
# | ||
|
||
CONFIG_CLEAN_FILES = *.loT *.rej *.orig | ||
|
||
m4datadir = $(datadir)/aclocal | ||
dist_m4data_DATA = audit.m4 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
# audit.m4 - Checks for the libaudit support | ||
# Copyright (c) 2015 Steve Grubb [email protected] | ||
# | ||
AC_DEFUN([AUDIT_PATH], | ||
[ | ||
AC_ARG_WITH(audit, | ||
[ --with-audit=[auto/yes/no] Add audit support [default=auto]],, | ||
with_audit=auto) | ||
# Check for libaudit API | ||
# | ||
# libaudit detection | ||
if test "x$with_audit" = xno ; then | ||
have_audit=no; | ||
else | ||
# Start by checking for header file | ||
AC_CHECK_HEADER(audit.h, audit_headers=yes, audit_headers=no) | ||
# See if we have libaudit library | ||
AC_CHECK_LIB(audit, audit_open, | ||
AUDIT_LDADD=-laudit,) | ||
# Check that results are usable | ||
if test "x$with_audit" = xyes -a "x$AUDIT_LDADD" = x ; then | ||
AC_MSG_ERROR(audit support was requested and the library was not found) | ||
fi | ||
if test "x$AUDIT_LDADD" != x -a "$audit_headers" = no ; then | ||
AC_MSG_ERROR(audit libraries found but headers are missing) | ||
fi | ||
fi | ||
AC_SUBST(AUDIT_LDADD) | ||
AC_MSG_CHECKING(whether to use audit) | ||
if test "x$AUDIT_LDADD" != x ; then | ||
AC_DEFINE(HAVE_AUDIT,1,[audit support]) | ||
AC_MSG_RESULT(yes) | ||
else | ||
AC_MSG_RESULT(no) | ||
fi | ||
]) |