2007-02-19 21:26:22 +03:00
|
|
|
# $NetBSD: Makefile,v 1.3 2007/02/19 18:26:22 chs Exp $
|
2006-05-15 20:31:37 +04:00
|
|
|
|
|
|
|
.include "../Makefile.inc"
|
|
|
|
|
|
|
|
TOP= ${NETBSDSRCDIR}/gnu
|
|
|
|
DIST= ${TOP}/dist/gdb6
|
|
|
|
|
|
|
|
.include "${.CURDIR}/../arch/${MACHINE_ARCH}/defs.mk"
|
|
|
|
|
|
|
|
PROG= gdbtui
|
|
|
|
|
|
|
|
SRCS= tui-main.c
|
|
|
|
CPPFLAGS= -I${.CURDIR} \
|
|
|
|
-I${.CURDIR}/../arch/${MACHINE_ARCH} \
|
|
|
|
-I${DIST}/gdb \
|
|
|
|
-I${DIST}/gdb/config \
|
|
|
|
-I${DIST}/include/opcode \
|
|
|
|
-I${DIST} \
|
2006-05-29 23:20:05 +04:00
|
|
|
-I${.CURDIR}/../bfd/arch/${MACHINE_ARCH} \
|
|
|
|
-I${DIST}/bfd \
|
|
|
|
-I${DIST}/include \
|
|
|
|
${GCPPFLAGS:M-D*}
|
2006-05-15 20:31:37 +04:00
|
|
|
|
2006-05-29 23:20:05 +04:00
|
|
|
NOMAN= # defined
|
2006-05-15 20:31:37 +04:00
|
|
|
|
|
|
|
.include "../../Makefile.inc"
|
|
|
|
.include <bsd.prog.mk>
|
|
|
|
|
2006-05-29 23:20:05 +04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
LIBOPCODESDIR!= cd ${.CURDIR}/../opcodes && ${PRINTOBJDIR}
|
|
|
|
LIBBFDDIR!= cd ${.CURDIR}/../bfd && ${PRINTOBJDIR}
|
2006-05-15 20:31:37 +04:00
|
|
|
LIBIBERTYDIR!= cd ${.CURDIR}/../libiberty && ${PRINTOBJDIR}
|
2006-05-29 23:20:05 +04:00
|
|
|
LIBGDBDIR!= cd ${.CURDIR}/../libgdb && ${PRINTOBJDIR}
|
2006-05-15 20:31:37 +04:00
|
|
|
|
|
|
|
.if ${USE_LIBEDIT} == yes
|
|
|
|
LIBEDIT=-ledit
|
|
|
|
.else
|
|
|
|
LIBREADLINEDIR!= cd ${.CURDIR}/../readline && ${PRINTOBJDIR}
|
|
|
|
LIBEDIT= -L${LIBREADLINEDIR} -lreadline
|
|
|
|
.endif
|
|
|
|
|
|
|
|
LDADD+= -L${LIBGDBDIR} -lgdb
|
|
|
|
DPADD+= ${LIBGDBDIR}/libgdb.a
|
|
|
|
|
2006-05-29 23:20:05 +04:00
|
|
|
# Simulator support
|
2006-05-15 20:31:37 +04:00
|
|
|
.if ${MACHINE_ARCH} == powerpc || ${MACHINE_ARCH} == powerpcle
|
2006-05-29 23:20:05 +04:00
|
|
|
SIMOBJ!= cd ${.CURDIR}/../sim/ppc && ${PRINTOBJDIR}
|
|
|
|
LDADD+= -L${SIMOBJ} -lsim
|
|
|
|
DPADD+= ${SIMOBJ}/libsim.a
|
2007-02-19 21:26:22 +03:00
|
|
|
.elif ${MACHINE_CPU} == xxmips
|
2006-05-29 23:20:05 +04:00
|
|
|
SIMOBJ!= cd ${.CURDIR}/../sim/mips && ${PRINTOBJDIR}
|
|
|
|
LDADD+= -L${SIMOBJ} -lsim
|
|
|
|
DPADD+= ${SIMOBJ}/libsim.a
|
2006-05-15 20:31:37 +04:00
|
|
|
.endif
|
|
|
|
|
|
|
|
LDADD+= -L${LIBOPCODESDIR} -lopcodes \
|
|
|
|
-L${LIBBFDDIR} -lbfd \
|
|
|
|
${LIBEDIT} \
|
|
|
|
-ltermcap \
|
|
|
|
-L${LIBIBERTYDIR} -liberty
|
|
|
|
|
2006-05-29 23:20:05 +04:00
|
|
|
DPADD+= ${LIBOPCODESDIR}/libopcodes.a \
|
2006-05-15 20:31:37 +04:00
|
|
|
${LIBBFDDIR}/libbfd.a \
|
|
|
|
${LIBEDIT} \
|
|
|
|
${LIBTERMCAP} \
|
|
|
|
${LIBIBERTYDIR}/libiberty.a
|
|
|
|
|
2006-05-29 23:20:05 +04:00
|
|
|
LDADD+= -lcurses -lintl -lm -lkvm
|
|
|
|
DPADD+= ${LIBCURSES} ${LIBINTL} ${LIBM} ${LIBKVM}
|
|
|
|
|
|
|
|
.if ${SRCS:Mnbsd-thread.c} != ""
|
|
|
|
LDADD+= -lpthread_dbg
|
|
|
|
.endif
|
|
|
|
|
2006-05-15 20:31:37 +04:00
|
|
|
.PATH: ${DIST}/gdb ${DIST}/gdb/mi ${DIST}/gdb/cli ${DIST}/gdb/tui \
|
|
|
|
${DIST}/gdb/signals ${DIST}/gdb/doc ${.CURDIR}/../arch/${MACHINE_ARCH}
|