blob: 693319839f69ec93083b03d3f267d92c85f7c4fb [file] [log] [blame]
Linus Torvalds1da177e2005-04-16 15:20:36 -07001#
2# Copyright (C) 2000, 2002, 2003 Jeff Dike (jdike@karaya.com)
3# Licensed under the GPL
4#
5
6# pcap is broken in 2.5 because kbuild doesn't allow pcap.a to be linked
7# in to pcap.o
8
9slip-objs := slip_kern.o slip_user.o
10slirp-objs := slirp_kern.o slirp_user.o
11daemon-objs := daemon_kern.o daemon_user.o
Anton Ivanov49da7e62017-11-20 21:17:59 +000012vector-objs := vector_kern.o vector_user.o vector_transports.o
Nolan Leake4ff4d8d2011-05-24 17:13:02 -070013umcast-objs := umcast_kern.o umcast_user.o
Linus Torvalds1da177e2005-04-16 15:20:36 -070014net-objs := net_kern.o net_user.o
15mconsole-objs := mconsole_kern.o mconsole_user.o
16hostaudio-objs := hostaudio_kern.o
Jeff Dike91acb212005-10-10 23:10:32 -040017ubd-objs := ubd_kern.o ubd_user.o
Linus Torvalds1da177e2005-04-16 15:20:36 -070018port-objs := port_kern.o port_user.o
19harddog-objs := harddog_kern.o harddog_user.o
20
Sam Ravnborga0f97e02007-10-14 22:21:35 +020021LDFLAGS_pcap.o := -r $(shell $(CC) $(KBUILD_CFLAGS) -print-file-name=libpcap.a)
Paolo 'Blaisorblade' Giarrussoecc354a2005-07-14 00:33:41 -070022
Jeff Dikead43c352007-10-16 01:26:48 -070023LDFLAGS_vde.o := -r $(shell $(CC) $(CFLAGS) -print-file-name=libvdeplug.a)
24
25targets := pcap_kern.o pcap_user.o vde_kern.o vde_user.o
Paolo 'Blaisorblade' Giarrusso8afe07c2005-07-28 21:16:03 -070026
Paolo 'Blaisorblade' Giarrussoecc354a2005-07-14 00:33:41 -070027$(obj)/pcap.o: $(obj)/pcap_kern.o $(obj)/pcap_user.o
Masahiro Yamada2fb92792018-07-12 17:01:35 +090028 $(LD) -r -dp -o $@ $^ $(ld_flags)
Jeff Dikead43c352007-10-16 01:26:48 -070029
30$(obj)/vde.o: $(obj)/vde_kern.o $(obj)/vde_user.o
Masahiro Yamada2fb92792018-07-12 17:01:35 +090031 $(LD) -r -dp -o $@ $^ $(ld_flags)
Jeff Dikead43c352007-10-16 01:26:48 -070032
Paolo 'Blaisorblade' Giarrussoecc354a2005-07-14 00:33:41 -070033#XXX: The call below does not work because the flags are added before the
34# object name, so nothing from the library gets linked.
35#$(call if_changed,ld)
36
37# When the above is fixed, don't forget to add this too!
Paolo 'Blaisorblade' Giarrusso8afe07c2005-07-28 21:16:03 -070038#targets += $(obj)/pcap.o
Paolo 'Blaisorblade' Giarrussoecc354a2005-07-14 00:33:41 -070039
Linus Torvalds1da177e2005-04-16 15:20:36 -070040obj-y := stdio_console.o fd.o chan_kern.o chan_user.o line.o
41obj-$(CONFIG_SSL) += ssl.o
42obj-$(CONFIG_STDERR_CONSOLE) += stderr_console.o
43
Jeff Dikea3c77c62005-06-13 15:52:18 -070044obj-$(CONFIG_UML_NET_SLIP) += slip.o slip_common.o
45obj-$(CONFIG_UML_NET_SLIRP) += slirp.o slip_common.o
Linus Torvalds1da177e2005-04-16 15:20:36 -070046obj-$(CONFIG_UML_NET_DAEMON) += daemon.o
Anton Ivanov49da7e62017-11-20 21:17:59 +000047obj-$(CONFIG_UML_NET_VECTOR) += vector.o
Jeff Dikead43c352007-10-16 01:26:48 -070048obj-$(CONFIG_UML_NET_VDE) += vde.o
Nolan Leake4ff4d8d2011-05-24 17:13:02 -070049obj-$(CONFIG_UML_NET_MCAST) += umcast.o
Paolo 'Blaisorblade' Giarrussoecc354a2005-07-14 00:33:41 -070050obj-$(CONFIG_UML_NET_PCAP) += pcap.o
Linus Torvalds1da177e2005-04-16 15:20:36 -070051obj-$(CONFIG_UML_NET) += net.o
52obj-$(CONFIG_MCONSOLE) += mconsole.o
53obj-$(CONFIG_MMAPPER) += mmapper_kern.o
54obj-$(CONFIG_BLK_DEV_UBD) += ubd.o
55obj-$(CONFIG_HOSTAUDIO) += hostaudio.o
56obj-$(CONFIG_NULL_CHAN) += null.o
57obj-$(CONFIG_PORT_CHAN) += port.o
58obj-$(CONFIG_PTY_CHAN) += pty.o
59obj-$(CONFIG_TTY_CHAN) += tty.o
60obj-$(CONFIG_XTERM_CHAN) += xterm.o xterm_kern.o
61obj-$(CONFIG_UML_WATCHDOG) += harddog.o
62obj-$(CONFIG_BLK_DEV_COW_COMMON) += cow_user.o
63obj-$(CONFIG_UML_RANDOM) += random.o
64
Paolo 'Blaisorblade' Giarrussoecc354a2005-07-14 00:33:41 -070065# pcap_user.o must be added explicitly.
Anton Ivanov49da7e62017-11-20 21:17:59 +000066USER_OBJS := fd.o null.o pty.o tty.o xterm.o slip_common.o pcap_user.o vde_user.o vector_user.o
Al Viroec82c322008-08-25 04:14:29 -040067CFLAGS_null.o = -DDEV_NULL=$(DEV_NULL_PATH)
Linus Torvalds1da177e2005-04-16 15:20:36 -070068
69include arch/um/scripts/Makefile.rules