Add qemu 2.4.0
[kvmfornfv.git] / qemu / roms / SLOF / clients / net-snk / app / Makefile
1 # *****************************************************************************
2 # * Copyright (c) 2004, 2011 IBM Corporation
3 # * All rights reserved.
4 # * This program and the accompanying materials
5 # * are made available under the terms of the BSD License
6 # * which accompanies this distribution, and is available at
7 # * http://www.opensource.org/licenses/bsd-license.php
8 # *
9 # * Contributors:
10 # *     IBM Corporation - initial implementation
11 # ****************************************************************************/
12
13 ifndef TOP
14 TOP = $(shell while ! test -e make.rules; do cd ..  ; done; pwd)
15 export TOP
16 endif
17 include $(TOP)/make.rules
18
19 CFLAGS +=$(ADDCFLAGS)
20
21 OBJS = main.o
22 OBJDIRS = netlib/netlib.o netapps/netboot.o 
23 OBJDIRS += netapps/ping.o
24 OBJDIRS += netapps/args.o
25
26 ifeq ($(SNK_BIOSEMU_APPS), 1)
27 OBJDIRS += biosemu/biosemu_app.o
28 CFLAGS += -DSNK_BIOSEMU_APPS
29 endif
30
31 SUBDIRS = $(dir $(OBJDIRS))
32
33 all:    subdirs
34         $(MAKE) app.o
35
36 subdirs:
37         for dir in $(SUBDIRS); do \
38                 $(MAKE) -C $$dir DIRECTORY=$(DIRECTORY)$$dir || exit 1; \
39         done
40
41 app.o: $(OBJS) $(OBJDIRS)
42         $(LD) $(LDFLAGS) $(OBJDIRS) $(OBJS) -o $@ -r 
43
44 clean : 
45         $(RM) -f *.o *.a *.i 
46         for dir in $(SUBDIRS); do \
47                 $(CLEAN) ; \
48                 $(MAKE) -C $$dir DIRECTORY=$(DIRECTORY)$$dir clean; \
49         done
50
51 include $(TOP)/make.depend