From 51b8f05ab3082d8dae5077ff01753d29546f8ce6 Mon Sep 17 00:00:00 2001 From: Raymond Danks Date: Fri, 27 Apr 2012 08:51:02 -0600 Subject: ectool: Allow build under Cygwin To build under Cygwin, ectool depends upon the package ioperm: http://openwince.sourceforge.net/ioperm/ for sys/io.h and sys/perm.h. This change causes the ectool make to correctly include and link against these headers and libraries. Change-Id: I7d54ab5110c2bb1fd21dfa48d56031f3f29cd54e Signed-off-by: Raymond Danks Reviewed-on: http://review.coreboot.org/941 Tested-by: build bot (Jenkins) Reviewed-by: Ronald G. Minnich --- util/ectool/Makefile | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'util/ectool') diff --git a/util/ectool/Makefile b/util/ectool/Makefile index c817395b0f..16a1ce9d10 100644 --- a/util/ectool/Makefile +++ b/util/ectool/Makefile @@ -24,10 +24,15 @@ PROGRAM = ectool INSTALL = /usr/bin/install PREFIX = /usr/local +OS_ARCH = $(shell uname -o) +ifeq ($(OS_ARCH), Cygwin) +LDFLAGS = -lioperm +endif + all: $(PROGRAM) $(PROGRAM): ec.o ectool.o - $(CC) $(CFLAGS) -o $@ $^ + $(CC) $(CFLAGS) -o $@ $^ $(LDFLAGS) install: $(PROGRAM) $(INSTALL) $(PROGRAM) $(PREFIX)/sbin -- cgit v1.2.3