blob: d44a3d51840787aa5ed55a34eb20542901f20325 [file] [log] [blame]
Eric Andersen85208e22002-04-12 12:05:57 +00001# Makefile for busybox
2#
Eric Andersenc7bda1c2004-03-15 08:29:22 +00003# Copyright (C) 1999-2004 by Erik Andersen <andersen@codepoet.org>
Eric Andersen85208e22002-04-12 12:05:57 +00004#
5# This program is free software; you can redistribute it and/or modify
6# it under the terms of the GNU General Public License as published by
7# the Free Software Foundation; either version 2 of the License, or
8# (at your option) any later version.
9#
10# This program is distributed in the hope that it will be useful,
11# but WITHOUT ANY WARRANTY; without even the implied warranty of
12# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13# General Public License for more details.
14#
15# You should have received a copy of the GNU General Public License
16# along with this program; if not, write to the Free Software
17# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
18#
19
20NETWORKING_AR:=networking.a
21ifndef $(NETWORKING_DIR)
Eric Andersen7daa0762004-10-08 07:46:08 +000022NETWORKING_DIR:=$(top_builddir)/networking/
Eric Andersen85208e22002-04-12 12:05:57 +000023endif
Eric Andersen7daa0762004-10-08 07:46:08 +000024srcdir=$(top_srcdir)/networking
Eric Andersen85208e22002-04-12 12:05:57 +000025NETWORKING-y:=
Mike Frysingerb662f0d2005-05-11 03:59:53 +000026NETWORKING-$(CONFIG_ARPING) += arping.o
27NETWORKING-$(CONFIG_ETHER_WAKE) += ether-wake.o
28NETWORKING-$(CONFIG_FAKEIDENTD) += fakeidentd.o
29NETWORKING-$(CONFIG_FTPGET) += ftpgetput.o
30NETWORKING-$(CONFIG_FTPPUT) += ftpgetput.o
31NETWORKING-$(CONFIG_HOSTNAME) += hostname.o
32NETWORKING-$(CONFIG_HTTPD) += httpd.o
33NETWORKING-$(CONFIG_IFCONFIG) += ifconfig.o
34NETWORKING-$(CONFIG_IFUPDOWN) += ifupdown.o
35NETWORKING-$(CONFIG_INETD) += inetd.o
36NETWORKING-$(CONFIG_IP) += ip.o
37NETWORKING-$(CONFIG_IPCALC) += ipcalc.o
38NETWORKING-$(CONFIG_IPADDR) += ipaddr.o
39NETWORKING-$(CONFIG_IPLINK) += iplink.o
40NETWORKING-$(CONFIG_IPROUTE) += iproute.o
41NETWORKING-$(CONFIG_IPTUNNEL) += iptunnel.o
42NETWORKING-$(CONFIG_NAMEIF) += nameif.o
43NETWORKING-$(CONFIG_NC) += nc.o
44NETWORKING-$(CONFIG_NETSTAT) += netstat.o
45NETWORKING-$(CONFIG_NSLOOKUP) += nslookup.o
46NETWORKING-$(CONFIG_PING) += ping.o
47NETWORKING-$(CONFIG_PING6) += ping6.o
48NETWORKING-$(CONFIG_ROUTE) += route.o
49NETWORKING-$(CONFIG_TELNET) += telnet.o
50NETWORKING-$(CONFIG_TELNETD) += telnetd.o
51NETWORKING-$(CONFIG_TFTP) += tftp.o
52NETWORKING-$(CONFIG_TRACEROUTE) += traceroute.o
53NETWORKING-$(CONFIG_VCONFIG) += vconfig.o
54NETWORKING-$(CONFIG_WGET) += wget.o
55NETWORKING-$(CONFIG_ZCIP) += zcip.o
Eric Andersen85208e22002-04-12 12:05:57 +000056
57libraries-y+=$(NETWORKING_DIR)$(NETWORKING_AR)
58
Eric Andersen35e643b2003-07-28 07:40:39 +000059needcrypt-y:=
60needcrypt-$(CONFIG_FEATURE_HTTPD_AUTH_MD5) := y
61
62ifeq ($(needcrypt-y),y)
Mike Frysingerb662f0d2005-05-11 03:59:53 +000063 LIBRARIES += -lcrypt
Eric Andersen35e643b2003-07-28 07:40:39 +000064endif
65
Eric Andersen85208e22002-04-12 12:05:57 +000066$(NETWORKING_DIR)$(NETWORKING_AR): $(patsubst %,$(NETWORKING_DIR)%, $(NETWORKING-y))
67 $(AR) -ro $@ $(patsubst %,$(NETWORKING_DIR)%, $(NETWORKING-y))
68
Eric Andersen7daa0762004-10-08 07:46:08 +000069$(NETWORKING_DIR)%.o: $(srcdir)/%.c
70 $(CC) $(CFLAGS) $(EXTRA_CFLAGS) -c -o $@ $<