Add support for the ITE IT8661F/IT8770F, IT8673F, and IT8671F/IT8687R.
[coreboot.git] / util / superiotool / Makefile
index 6e86d01352346445a311b775dca28de0e61563c6..d8ac62c1f355efd47f89e960cf006d55f864cd3c 100644 (file)
@@ -1,5 +1,5 @@
 ##
-## This file is part of the LinuxBIOS project.
+## This file is part of the superiotool project.
 ##
 ## Copyright (C) 2007 Uwe Hermann <uwe@hermann-uwe.de>
 ##
@@ -24,19 +24,27 @@ CC      = gcc
 INSTALL = /usr/bin/install
 PREFIX  = /usr/local
 
-# TODO: -ansi, -pedantic
+# Set the superiotool version string from the highest revision number
+# of the checked out superiotool files.
+SVNDEF := -D'SUPERIOTOOL_VERSION="$(shell svnversion -cn . \
+          | sed -e "s/.*://" -e "s/\([0-9]*\).*/\1/")"'
+
 CFLAGS = -O2 -Wall -Werror -Wstrict-prototypes -Wundef -Wstrict-aliasing \
-         -Werror-implicit-function-declaration
+         -Werror-implicit-function-declaration -ansi -pedantic $(SVNDEF)
 
-OBJS = superiotool.o fintek.o ite.o nsc.o smsc.o
+OBJS = superiotool.o ali.o fintek.o ite.o nsc.o smsc.o winbond.o
 
 all: $(PROGRAM)
 
+superiotool.o: *.c superiotool.h
+
 $(PROGRAM): $(OBJS) superiotool.h
        $(CC) $(CFLAGS) -o $(PROGRAM) $(OBJS)
 
 install: $(PROGRAM)
-       $(INSTALL) $(PROGRAM) $(PREFIX)/bin
+       $(INSTALL) $(PROGRAM) $(PREFIX)/sbin
+       mkdir -p $(PREFIX)/share/man/man8
+       $(INSTALL) $(PROGRAM).8 $(PREFIX)/share/man/man8
 
 clean:
        rm -f $(PROGRAM) *.o