Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3171)

Unified Diff: cgpt/Makefile

Issue 2845001: Rework the vboot_reference make system. (Closed) Base URL: ssh://git@chromiumos-git/vboot_reference.git
Patch Set: Rework the vboot_reference make system. Created 10 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « README ('k') | common.mk » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cgpt/Makefile
diff --git a/cgpt/Makefile b/cgpt/Makefile
index 1f8deded9c599ac1b8f0ff5977b1f04e7f17fb93..47856d5bc1fa1ddf7cded8365f1ad51f22bfe788 100644
--- a/cgpt/Makefile
+++ b/cgpt/Makefile
@@ -2,44 +2,36 @@
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
-CC ?= gcc
-TOP ?= ..
-CFLAGS ?= -Wall -DNDEBUG -O3 -Werror
CFLAGS += -static
LDFLAGS += -luuid
-FWDIR=$(TOP)/vboot_firmware
+BUILD_ROOT := ${BUILD}/cgpt
INCLUDES = -I$(FWDIR)/lib/cgptlib/include
-LIBS = $(FWDIR)/vboot_fw.a
+LIBS = ${FWLIB}
DESTDIR ?= /usr/bin
-PROGNAME = cgpt
+PROGNAME = ${BUILD_ROOT}/cgpt
-OBJS= \
- cgpt.o \
- cmd_show.o \
- cmd_repair.o \
- cmd_create.o \
- cmd_add.o \
- cmd_boot.o \
- cgpt_common.o
+ALL_SRCS = \
+ cgpt.c \
+ cmd_show.c \
+ cmd_repair.c \
+ cmd_create.c \
+ cmd_add.c \
+ cmd_boot.c \
+ cgpt_common.c
+include ../common.mk
all: $(PROGNAME)
-$(PROGNAME): $(OBJS) $(LIBS)
+$(PROGNAME): $(ALL_OBJS) $(LIBS)
$(CC) -o $(PROGNAME) $(CFLAGS) $^ $(LDFLAGS)
-.c.o:
- $(CC) $(CFLAGS) $(INCLUDES) -c $< -o $@
-
-clean:
- rm -f $(PROGNAME) *.o *~
-
install: $(PROGNAME)
mkdir -p $(DESTDIR)
cp -f $^ $(DESTDIR)
- chmod a+rx $(patsubst %,$(DESTDIR)/%,$^)
+ chmod a+rx $(patsubst ${BUILD_ROOT}/%,$(DESTDIR)/%,$^)
-.PHONY: all clean install
+.PHONY: all install
« no previous file with comments | « README ('k') | common.mk » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698