Eric Andersen | 85208e2 | 2002-04-12 12:05:57 +0000 | [diff] [blame] | 1 | # Makefile for busybox |
| 2 | # |
Mike Frysinger | 0d4ee68 | 2005-09-24 06:01:57 +0000 | [diff] [blame] | 3 | # Copyright (C) 1999-2005 by Erik Andersen <andersen@codepoet.org> |
Eric Andersen | 85208e2 | 2002-04-12 12:05:57 +0000 | [diff] [blame] | 4 | # |
Mike Frysinger | 0d4ee68 | 2005-09-24 06:01:57 +0000 | [diff] [blame] | 5 | # Licensed under the GPL v2, see the file LICENSE in this tarball. |
Eric Andersen | 85208e2 | 2002-04-12 12:05:57 +0000 | [diff] [blame] | 6 | |
| 7 | PROCPS_AR:=procps.a |
| 8 | ifndef $(PROCPS_DIR) |
Eric Andersen | 7daa076 | 2004-10-08 07:46:08 +0000 | [diff] [blame] | 9 | PROCPS_DIR:=$(top_builddir)/procps/ |
Eric Andersen | 85208e2 | 2002-04-12 12:05:57 +0000 | [diff] [blame] | 10 | endif |
Eric Andersen | 7daa076 | 2004-10-08 07:46:08 +0000 | [diff] [blame] | 11 | srcdir=$(top_srcdir)/procps |
Eric Andersen | 85208e2 | 2002-04-12 12:05:57 +0000 | [diff] [blame] | 12 | |
Eric Andersen | 506177d | 2002-09-30 20:53:38 +0000 | [diff] [blame] | 13 | PROCPS-y:= |
Eric Andersen | 85208e2 | 2002-04-12 12:05:57 +0000 | [diff] [blame] | 14 | PROCPS-$(CONFIG_FREE) += free.o |
| 15 | PROCPS-$(CONFIG_KILL) += kill.o |
| 16 | PROCPS-$(CONFIG_PIDOF) += pidof.o |
| 17 | PROCPS-$(CONFIG_PS) += ps.o |
| 18 | PROCPS-$(CONFIG_RENICE) += renice.o |
Eric Andersen | 5d38f5b | 2005-09-12 21:42:48 +0000 | [diff] [blame] | 19 | PROCPS-$(CONFIG_BB_SYSCTL) += sysctl.o |
Eric Andersen | 420b208 | 2002-09-17 22:14:58 +0000 | [diff] [blame] | 20 | PROCPS-$(CONFIG_TOP) += top.o |
Eric Andersen | 85208e2 | 2002-04-12 12:05:57 +0000 | [diff] [blame] | 21 | PROCPS-$(CONFIG_UPTIME) += uptime.o |
Rob Landley | aa87276 | 2005-10-28 13:05:12 +0000 | [diff] [blame] | 22 | PROCPS-$(CONFIG_FUSER) += fuser.o |
Eric Andersen | 85208e2 | 2002-04-12 12:05:57 +0000 | [diff] [blame] | 23 | |
Rob Landley | d6e14d8 | 2006-02-21 19:11:35 +0000 | [diff] [blame^] | 24 | ifneq ($(strip $(PROCPS-y)),) |
Eric Andersen | 85208e2 | 2002-04-12 12:05:57 +0000 | [diff] [blame] | 25 | libraries-y+=$(PROCPS_DIR)$(PROCPS_AR) |
Rob Landley | d6e14d8 | 2006-02-21 19:11:35 +0000 | [diff] [blame^] | 26 | endif |
Eric Andersen | 85208e2 | 2002-04-12 12:05:57 +0000 | [diff] [blame] | 27 | |
Bernhard Reutner-Fischer | 7ca61b6 | 2006-01-15 14:04:57 +0000 | [diff] [blame] | 28 | PROCPS_SRC-y:=$(patsubst %.o,$(srcdir)/%.c,$(PROCPS-y)) |
| 29 | PROCPS_SRC-a:=$(wildcard $(srcdir)/*.c) |
| 30 | APPLET_SRC-y+=$(PROCPS_SRC-y) |
| 31 | APPLET_SRC-a+=$(PROCPS_SRC-a) |
| 32 | |
Eric Andersen | 85208e2 | 2002-04-12 12:05:57 +0000 | [diff] [blame] | 33 | $(PROCPS_DIR)$(PROCPS_AR): $(patsubst %,$(PROCPS_DIR)%, $(PROCPS-y)) |
Mike Frysinger | b38673f | 2006-02-02 01:41:53 +0000 | [diff] [blame] | 34 | $(do_ar) |
Eric Andersen | 85208e2 | 2002-04-12 12:05:57 +0000 | [diff] [blame] | 35 | |
Eric Andersen | 7daa076 | 2004-10-08 07:46:08 +0000 | [diff] [blame] | 36 | $(PROCPS_DIR)%.o: $(srcdir)/%.c |
Mike Frysinger | b38673f | 2006-02-02 01:41:53 +0000 | [diff] [blame] | 37 | $(compile.c) |