3 # Copyright (C) 1999-2005 by Erik Andersen <andersen@codepoet.org>
5 # Licensed under the GPL v2, see the file LICENSE in this tarball.
7 CONSOLETOOLS_AR:=console-tools.a
8 ifndef $(CONSOLETOOLS_DIR)
9 CONSOLETOOLS_DIR:=$(top_builddir)/console-tools/
11 srcdir=$(top_srcdir)/console-tools
14 CONSOLETOOLS_DIR-$(CONFIG_CHVT) += chvt.o
15 CONSOLETOOLS_DIR-$(CONFIG_CLEAR) += clear.o
16 CONSOLETOOLS_DIR-$(CONFIG_DEALLOCVT) += deallocvt.o
17 CONSOLETOOLS_DIR-$(CONFIG_DUMPKMAP) += dumpkmap.o
18 CONSOLETOOLS_DIR-$(CONFIG_SETCONSOLE) += setconsole.o
19 CONSOLETOOLS_DIR-$(CONFIG_LOADFONT) += loadfont.o
20 CONSOLETOOLS_DIR-$(CONFIG_LOADKMAP) += loadkmap.o
21 CONSOLETOOLS_DIR-$(CONFIG_OPENVT) += openvt.o
22 CONSOLETOOLS_DIR-$(CONFIG_RESET) += reset.o
23 CONSOLETOOLS_DIR-$(CONFIG_SETKEYCODES) += setkeycodes.o
25 libraries-y+=$(CONSOLETOOLS_DIR)$(CONSOLETOOLS_AR)
27 $(CONSOLETOOLS_DIR)$(CONSOLETOOLS_AR): $(patsubst %,$(CONSOLETOOLS_DIR)%, $(CONSOLETOOLS_DIR-y))
28 $(AR) $(ARFLAGS) $@ $(patsubst %,$(CONSOLETOOLS_DIR)%, $(CONSOLETOOLS_DIR-y))
30 $(CONSOLETOOLS_DIR)%.o: $(srcdir)/%.c
31 $(CC) $(CFLAGS) $(EXTRA_CFLAGS) -c -o $@ $<