Merge tag 'upstream/3.14'
[debian/elilo] / ia32 / Makefile
1 #
2 #  Copyright (C) 2001-2003 Hewlett-Packard Co.
3 #       Contributed by Stephane Eranian <eranian@hpl.hp.com>
4 #
5 # This file is part of the ELILO, the EFI Linux boot loader.
6 #
7 #  ELILO is free software; you can redistribute it and/or modify
8 #  it under the terms of the GNU General Public License as published by
9 #  the Free Software Foundation; either version 2, or (at your option)
10 #  any later version.
11 #
12 #  ELILO is distributed in the hope that it will be useful,
13 #  but WITHOUT ANY WARRANTY; without even the implied warranty of
14 #  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
15 #  GNU General Public License for more details.
16 #
17 #  You should have received a copy of the GNU General Public License
18 #  along with ELILO; see the file COPYING.  If not, write to the Free
19 #  Software Foundation, 59 Temple Place - Suite 330, Boston, MA
20 #  02111-1307, USA.
21 #
22 # Please check out the elilo.txt for complete documentation on how
23 # to use this program.
24 #
25
26 include ../Make.defaults
27 include ../Make.rules
28
29 TOPDIR=$(CDIR)/..
30
31 FILES=system.o config.o bzimage.o plain_loader.o gzip_loader.o gzip.o
32
33 TARGET=sysdeps.o
34
35 all: $(TARGET)
36
37 system.o: rmswitch.h
38
39 rmswitch.h: bin_to_h.c rmswitch.S
40         $(CC) -o bin_to_h bin_to_h.c
41         $(AS) -o rmswitch.o rmswitch.S
42         $(LD) -Ttext 0x0 -s --oformat binary -o rmswitch rmswitch.o
43         ./bin_to_h <rmswitch >rmswitch.h
44
45 $(TARGET): $(FILES)
46         $(LD) -r -o $@ $(FILES)
47
48 clean:
49         $(RM) -f $(TARGET) $(FILES)
50         $(RM) -f bin_to_h.o bin_to_h
51         $(RM) -f rmswitch.h rmswitch.o rmswitch