2008-03-05 12:27:11 +00:00
|
|
|
DIR= ${SYSCONFDIR}
|
2008-01-10 16:35:59 +00:00
|
|
|
CONF= rc.conf
|
2007-11-23 12:04:11 +00:00
|
|
|
|
2008-11-03 15:31:01 +00:00
|
|
|
CLEANFILES+= rc.conf
|
|
|
|
|
2008-01-10 16:35:59 +00:00
|
|
|
MK= ../mk
|
2008-03-25 14:06:05 +00:00
|
|
|
include ${MK}/os.mk
|
2011-10-17 20:18:39 -05:00
|
|
|
|
|
|
|
ifeq ($(OS),FreeBSD)
|
|
|
|
SED_EXTRA= -e 's:@TERM@:cons25:g'
|
|
|
|
SRCS+= rc.conf.in rc.in rc.shutdown.in
|
|
|
|
CONF+= devd.conf
|
|
|
|
BIN+= rc rc.shutdown rc.devd
|
|
|
|
else ifeq ($(OS),Linux)
|
|
|
|
SED_EXTRA= -e 's:@TERM@:wsvt25:g'
|
|
|
|
SRCS+= rc.conf.in rc.in rc.shutdown.in
|
|
|
|
else ifeq ($(OS),NetBSD)
|
|
|
|
SED_EXTRA= -e 's:@TERM@:wsvt25:g'
|
|
|
|
SRCS+= rc.conf.in rc.in rc.shutdown.in
|
|
|
|
BIN+= rc rc.shutdown
|
|
|
|
endif
|
|
|
|
|
2008-01-10 16:35:59 +00:00
|
|
|
include ${MK}/scripts.mk
|
2011-01-05 22:03:43 -08:00
|
|
|
|
2011-03-10 20:24:28 -05:00
|
|
|
# We can't use "ifndef" here because that treats set-but-empty
|
|
|
|
# as not-set which is not what we want
|
|
|
|
MKRCSYS ?= automagicplease
|
|
|
|
ifeq ($(MKRCSYS),automagicplease)
|
|
|
|
# If the user isn't picking a default, then have the
|
|
|
|
# config go with runtime automagic detection #357247
|
|
|
|
rc.conf: SED_EXTRA += -e '/^rc_sys=""/s:^:\#:'
|
|
|
|
MKRCSYS =
|
|
|
|
endif
|
2011-01-05 22:03:43 -08:00
|
|
|
rc.conf: rc.conf.in rc.conf.${OS}
|
|
|
|
${SED} ${SED_REPLACE} ${SED_EXTRA} $^ > $@
|