blob: 15633a001fe7f14392d595b537fd2879535e2026 [file] [log] [blame]
Eric Andersen85208e22002-04-12 12:05:57 +00001# Makefile for busybox
2#
Mike Frysinger0d4ee682005-09-24 06:01:57 +00003# Copyright (C) 1999-2005 by Erik Andersen <andersen@codepoet.org>
Eric Andersen85208e22002-04-12 12:05:57 +00004#
Mike Frysinger0d4ee682005-09-24 06:01:57 +00005# Licensed under the GPL v2, see the file LICENSE in this tarball.
Eric Andersen85208e22002-04-12 12:05:57 +00006
7PROCPS_AR:=procps.a
8ifndef $(PROCPS_DIR)
Eric Andersen7daa0762004-10-08 07:46:08 +00009PROCPS_DIR:=$(top_builddir)/procps/
Eric Andersen85208e22002-04-12 12:05:57 +000010endif
Eric Andersen7daa0762004-10-08 07:46:08 +000011srcdir=$(top_srcdir)/procps
Eric Andersen85208e22002-04-12 12:05:57 +000012
Eric Andersen506177d2002-09-30 20:53:38 +000013PROCPS-y:=
Eric Andersen85208e22002-04-12 12:05:57 +000014PROCPS-$(CONFIG_FREE) += free.o
15PROCPS-$(CONFIG_KILL) += kill.o
16PROCPS-$(CONFIG_PIDOF) += pidof.o
17PROCPS-$(CONFIG_PS) += ps.o
18PROCPS-$(CONFIG_RENICE) += renice.o
Eric Andersen5d38f5b2005-09-12 21:42:48 +000019PROCPS-$(CONFIG_BB_SYSCTL) += sysctl.o
Eric Andersen420b2082002-09-17 22:14:58 +000020PROCPS-$(CONFIG_TOP) += top.o
Eric Andersen85208e22002-04-12 12:05:57 +000021PROCPS-$(CONFIG_UPTIME) += uptime.o
22
23libraries-y+=$(PROCPS_DIR)$(PROCPS_AR)
24
25$(PROCPS_DIR)$(PROCPS_AR): $(patsubst %,$(PROCPS_DIR)%, $(PROCPS-y))
Mike Frysinger4d008962005-07-27 01:09:24 +000026 $(AR) $(ARFLAGS) $@ $(patsubst %,$(PROCPS_DIR)%, $(PROCPS-y))
Eric Andersen85208e22002-04-12 12:05:57 +000027
Eric Andersen7daa0762004-10-08 07:46:08 +000028$(PROCPS_DIR)%.o: $(srcdir)/%.c
29 $(CC) $(CFLAGS) $(EXTRA_CFLAGS) -c -o $@ $<
30