blob: c0185f4aab8e1fcb36580f6a3ee18c67d3df23ba [file] [log] [blame]
Glenn L McGrath8f0722a2002-11-11 03:00:12 +00001# Makefile for busybox
2#
Mike Frysinger0d4ee682005-09-24 06:01:57 +00003# Copyright (C) 1999-2005 by Erik Andersen <andersen@codepoet.org>
Glenn L McGrath8f0722a2002-11-11 03:00:12 +00004#
Mike Frysinger0d4ee682005-09-24 06:01:57 +00005# Licensed under the GPL v2, see the file LICENSE in this tarball.
Glenn L McGrath8f0722a2002-11-11 03:00:12 +00006
7DEBIANUTILS_AR:=debianutils.a
8ifndef $(DEBIANUTILS_DIR)
Eric Andersen7daa0762004-10-08 07:46:08 +00009DEBIANUTILS_DIR:=$(top_builddir)/debianutils/
Glenn L McGrath8f0722a2002-11-11 03:00:12 +000010endif
Eric Andersen7daa0762004-10-08 07:46:08 +000011srcdir=$(top_srcdir)/debianutils
Glenn L McGrath8f0722a2002-11-11 03:00:12 +000012
13DEBIANUTILS-y:=
14DEBIANUTILS-$(CONFIG_MKTEMP) += mktemp.o
Glenn L McGrathe9080c92003-11-14 10:04:33 +000015DEBIANUTILS-$(CONFIG_PIPE_PROGRESS) += pipe_progress.o
Glenn L McGrath8f0722a2002-11-11 03:00:12 +000016DEBIANUTILS-$(CONFIG_READLINK) += readlink.o
17DEBIANUTILS-$(CONFIG_RUN_PARTS) += run_parts.o
Eric Andersena1ed06b2003-07-26 09:16:00 +000018DEBIANUTILS-$(CONFIG_START_STOP_DAEMON) += start_stop_daemon.o
Glenn L McGrath8f0722a2002-11-11 03:00:12 +000019DEBIANUTILS-$(CONFIG_WHICH) += which.o
20
21libraries-y+=$(DEBIANUTILS_DIR)$(DEBIANUTILS_AR)
22
23$(DEBIANUTILS_DIR)$(DEBIANUTILS_AR): $(patsubst %,$(DEBIANUTILS_DIR)%, $(DEBIANUTILS-y))
Mike Frysinger4d008962005-07-27 01:09:24 +000024 $(AR) $(ARFLAGS) $@ $(patsubst %,$(DEBIANUTILS_DIR)%, $(DEBIANUTILS-y))
Glenn L McGrath8f0722a2002-11-11 03:00:12 +000025
Eric Andersen7daa0762004-10-08 07:46:08 +000026$(DEBIANUTILS_DIR)%.o: $(srcdir)/%.c
27 $(CC) $(CFLAGS) $(EXTRA_CFLAGS) -c -o $@ $<
28