OLD | NEW |
| (Empty) |
1 | |
2 # Copyright (c) 2009 The Chromium OS Authors. All rights reserved. | |
3 # Use of this source code is governed by a BSD-style license that can be | |
4 # found in the LICENSE file. | |
5 | |
6 TOP ?= ../../ | |
7 CC ?= cc | |
8 # Include /usr/include from inside the chroot, so that we get a version | |
9 # of endian.h which contains endian-conversion macros - htole32(), etc. | |
10 INCLUDES += -I$(TOP)/common/include -I$(TOP)/../../../chroot/usr/include/ | |
11 CFLAGS += -Wall -Werror -ggdb | |
12 LIBS += $(FWLIB) | |
13 | |
14 DESTDIR ?= /opt/bin | |
15 | |
16 all: cgpt | |
17 | |
18 cgpt: cgpt.o cgpt_add_modify_delete.o cgpt_attribute.o cgpt_dev.o \ | |
19 cgpt_options.o cgpt_repair.o cgpt_show.o cgpt_tofix.o $(LIBS) | |
20 $(CC) -o cgpt $(CFLAGS) $^ | |
21 | |
22 .c.o: $(INCLUDES) | |
23 $(CC) $(CFLAGS) $(INCLUDES) -c $< -o $@ | |
24 clean: | |
25 rm -f cgpt *.o *~ | |
26 | |
27 install: cgpt | |
28 mkdir -p $(DESTDIR) | |
29 cp -f $^ $(DESTDIR) | |
30 chmod a+rx $(patsubst %,$(DESTDIR)/%,$^) | |
OLD | NEW |