diff options
author | Stefan Reinauer <stepan@coresystems.de> | 2009-09-01 09:57:55 +0000 |
---|---|---|
committer | Stefan Reinauer <stepan@openbios.org> | 2009-09-01 09:57:55 +0000 |
commit | e95eb616cc987072a1a17f8b98854645fb82bfce (patch) | |
tree | d4784dc52ec22699fdcc2116fb5684415c318c23 /util/superiotool/Makefile | |
parent | 4db6cbd26c2913549cd3d58c6943e766ccdc6c5e (diff) | |
download | coreboot-e95eb616cc987072a1a17f8b98854645fb82bfce.tar.xz |
* Add OSX/Darwin support
* Add DESTDIR support
Signed-off-by: Stefan Reinauer <stepan@coresystems.de>
Acked-by: Peter Stuge <peter@stuge.se>
git-svn-id: svn://svn.coreboot.org/coreboot/trunk@4623 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1
Diffstat (limited to 'util/superiotool/Makefile')
-rw-r--r-- | util/superiotool/Makefile | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/util/superiotool/Makefile b/util/superiotool/Makefile index d8ac62c1f3..6cb3042739 100644 --- a/util/superiotool/Makefile +++ b/util/superiotool/Makefile @@ -34,17 +34,23 @@ CFLAGS = -O2 -Wall -Werror -Wstrict-prototypes -Wundef -Wstrict-aliasing \ OBJS = superiotool.o ali.o fintek.o ite.o nsc.o smsc.o winbond.o +OS_ARCH = $(shell uname) +ifeq ($(OS_ARCH), Darwin) +LDFLAGS = -framework IOKit -framework DirectIO -lpci -lz +endif + all: $(PROGRAM) superiotool.o: *.c superiotool.h $(PROGRAM): $(OBJS) superiotool.h - $(CC) $(CFLAGS) -o $(PROGRAM) $(OBJS) + $(CC) $(LDFLAGS) -o $(PROGRAM) $(OBJS) install: $(PROGRAM) - $(INSTALL) $(PROGRAM) $(PREFIX)/sbin - mkdir -p $(PREFIX)/share/man/man8 - $(INSTALL) $(PROGRAM).8 $(PREFIX)/share/man/man8 + mkdir -p $(DESTDIR)$(PREFIX)/sbin + $(INSTALL) $(PROGRAM) $(DESTDIR)$(PREFIX)/sbin + mkdir -p $(DESTDIR)$(PREFIX)/share/man/man8 + $(INSTALL) $(PROGRAM).8 $(DESTDIR)$(PREFIX)/share/man/man8 clean: rm -f $(PROGRAM) *.o |