elfh.h revision 50479
155714Skris/* 255714Skris * Copyright (c) 1998 Robert Nordier 355714Skris * All rights reserved. 455714Skris * 559191Skris * Redistribution and use in source and binary forms, with or without 659191Skris * modification, are permitted provided that the following conditions 755714Skris * are met: 855714Skris * 1. Redistributions of source code must retain the above copyright 955714Skris * notice, this list of conditions and the following disclaimer. 1079998Skris * 2. Redistributions in binary form must reproduce the above copyright 1155714Skris * notice, this list of conditions and the following disclaimer in the 1255714Skris * documentation and/or other materials provided with the distribution. 1379998Skris * 1479998Skris * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS``AS IS'' AND 1555714Skris * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 1655714Skris * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR 1755714Skris * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS 1855714Skris * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, 1955714Skris * OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT 2055714Skris * OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR 2155714Skris * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 2255714Skris * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE 2355714Skris * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, 2455714Skris * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 2555714Skris * 2655714Skris * $FreeBSD: head/usr.sbin/btxld/elfh.h 50479 1999-08-28 01:35:59Z peter $ 2755714Skris */ 2855714Skris 2955714Skris#include <elf.h> 3055714Skris 3155714Skrisstruct elfh { 3255714Skris Elf32_Ehdr e; /* ELF header */ 3355714Skris Elf32_Phdr p[2]; /* program header */ 3455714Skris Elf32_Shdr sh[4]; /* section header */ 3555714Skris char shstrtab[28]; /* section header string table */ 3655714Skris}; 3755714Skris 3855714Skrisconst struct elfh elfhdr; /* ELF header template */ 3959191Skris