Include nbtool_config.h as needed. Should fix missing defn of __unused in

some host tool environments.
This commit is contained in:
thorpej 2009-12-29 17:32:18 +00:00
parent 653da907ac
commit 69ceabfc59
2 changed files with 9 additions and 2 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: libelf.h,v 1.5 2009/12/21 18:21:17 thorpej Exp $ */
/* $NetBSD: libelf.h,v 1.6 2009/12/29 17:32:18 thorpej Exp $ */
/*-
* Copyright (c) 2006 Joseph Koshy
@ -36,6 +36,7 @@
#include <inttypes.h>
#if HAVE_NBTOOL_CONFIG_H
# include "nbtool_config.h"
# include <nbinclude/sys/exec_elf.h>
# define __LIBELF_HAVE_ELF_CAP 1
# define __LIBELF_HAVE_ELF_MOVE 1

View File

@ -1,4 +1,6 @@
# $NetBSD: Makefile,v 1.2 2009/12/23 20:28:29 cegger Exp $
# $NetBSD: Makefile,v 1.3 2009/12/29 17:32:18 thorpej Exp $
.include <bsd.own.mk>
HOSTLIB= elf
@ -64,6 +66,10 @@ CPPFLAGS+= -no-cpp-precomp
# other file ops, on many systems, without changing function names.
CPPFLAGS+= -DHAVE_NBTOOL_CONFIG_H=1 -D_FILE_OFFSET_BITS=64
.ifndef NOCOMPATLIB
COMPATOBJ!= cd ${.CURDIR}/../compat && ${PRINTOBJDIR}
CPPFLAGS+= -I${COMPATOBJ}
.endif
.PATH: ${LIBELF_DIR}