NetBSD/usr.sbin/eeprom/Makefile
nakayama 61db04d3c6 Use explicitly defined macros in Makefile to determine to use
eeprom and/or openprom handlers, instead of predefined compiler
macros (__sun__, __sparc__ ...).
2013-03-15 20:22:44 +00:00

41 lines
849 B
Makefile

# from: @(#)Makefile 5.8 (Berkeley) 7/28/90
# $NetBSD: Makefile,v 1.18 2013/03/15 20:22:44 nakayama Exp $
.if ${MACHINE} == "sun3" || ${MACHINE} == "sun3x" \
|| ${MACHINE} == "sparc" || ${MACHINE} == "sparc64" \
|| ${MACHINE} == "macppc" || ${MACHINE} == "prep" \
|| ${MACHINE} == "shark"
PROG= eeprom
SRCS= main.c
LDADD+=-lutil
DPADD+=${LIBUTIL}
.if ${MACHINE} == "sparc" || ${MACHINE} == "sparc64"
SRCS+= ophandlers.c
CPPFLAGS+= -DUSE_OPENPROM
.endif
.if ${MACHINE} == "sun3" || ${MACHINE} == "sun3x" || ${MACHINE} == "sparc"
SRCS+= eehandlers.c
CPPFLAGS+= -DUSE_EEPROM
.endif
.if ${MACHINE} == "macppc" || ${MACHINE} == "shark"
SRCS+= ofhandlers.c
CPPFLAGS+= -DUSE_OPENFIRM
.endif
.if ${MACHINE} == "prep"
SRCS+= prephandlers.c
CPPFLAGS+= -DUSE_PREPNVRAM
.endif
.endif
MAN= eeprom.8
CPPFLAGS+= -I${.CURDIR}
.include <bsd.prog.mk>