This is the mail archive of the
libc-ports@sources.redhat.com
mailing list for the libc-ports project.
Re: Audit macros and add-on ports
- From: Daniel Jacobowitz <drow at false dot org>
- To: Roland McGrath <roland at redhat dot com>
- Cc: libc-ports at sourceware dot org
- Date: Wed, 5 Oct 2005 11:59:24 -0400
- Subject: Re: Audit macros and add-on ports
- References: <20050930214645.GA21892@nevyn.them.org> <20051001030822.B5AB8180E1F@magilla.sf.frob.com>
On Fri, Sep 30, 2005 at 08:08:22PM -0700, Roland McGrath wrote:
> > My current plan is to define ARCH_PLTENTER and ARCH_PLTEXIT as macros
> > which expand to something like the existing union members [...]
>
> I'd sort of thought we already did that too. That is the way I figured it
> would be done.
Then is this patch OK? Tested, with various others to fix the build,
on arm-none-linux-gnu.
--
Daniel Jacobowitz
CodeSourcery, LLC
2005-10-05 Daniel Jacobowitz <dan@codesourcery.com>
* sysdeps/generic/ldsodefs.h (struct audit_ifaces): Use
ARCH_PLTENTER_MEMBERS and ARCH_PLTEXIT_MEMBERS.
* elf/tst-auditmod1.c: Include <tst-audit.h> for
architecture-specific code.
Index: glibc/sysdeps/generic/ldsodefs.h
===================================================================
--- glibc.orig/sysdeps/generic/ldsodefs.h 2005-10-03 18:16:20.000000000 -0400
+++ glibc/sysdeps/generic/ldsodefs.h 2005-10-03 18:16:33.000000000 -0400
@@ -292,6 +292,9 @@ struct audit_ifaces
const struct La_sparc64_regs *,
unsigned int *, const char *name,
long int *framesizep);
+#ifdef ARCH_PLTENTER_MEMBERS
+ ARCH_PLTENTER_MEMBERS;
+#endif
};
union
{
@@ -360,6 +363,9 @@ struct audit_ifaces
const struct La_sparc32_regs *,
struct La_sparc32_retval *,
const char *);
+#ifdef ARCH_PLTEXIT_MEMBERS
+ ARCH_PLTEXIT_MEMBERS;
+#endif
};
unsigned int (*objclose) (uintptr_t *);
Index: glibc/elf/tst-auditmod1.c
===================================================================
--- glibc.orig/elf/tst-auditmod1.c 2005-10-03 18:16:16.000000000 -0400
+++ glibc/elf/tst-auditmod1.c 2005-10-03 18:16:33.000000000 -0400
@@ -193,7 +193,11 @@ la_symbind64 (Elf64_Sym *sym, unsigned i
# define La_retval La_sparc64_retval
# define int_retval lrv_reg[0]
#else
-# error "architecture specific code needed"
+# include <tst-audit.h>
+# if (!defined (pltenter) || !defined (pltexit) || !defined (La_regs) \
+ || !defined (La_retval) || !defined (int_retval))
+# error "architecture specific code needed"
+# endif
#endif