2007-11-21 13:49:44 +00:00
|
|
|
# makefile - Simple makefile to build the various RosBE tools.
|
|
|
|
|
|
|
|
.PHONY: all clean
|
|
|
|
|
|
|
|
CC := gcc
|
|
|
|
CFLAGS := ${HOST_CFLAGS} -Wall -O2 -o
|
|
|
|
STRIP := strip
|
|
|
|
|
|
|
|
ifeq ($(word 1,$(shell gcc -dumpmachine)),mingw32)
|
|
|
|
# Windows host
|
|
|
|
RM := del /f
|
|
|
|
SUFFIX := .exe
|
|
|
|
else
|
2010-08-15 12:14:41 +00:00
|
|
|
ifeq ($(word 1,$(shell gcc -dumpmachine)),i686-w64-mingw32)
|
|
|
|
# Windows host
|
|
|
|
RM := del /f
|
|
|
|
SUFFIX := .exe
|
|
|
|
else
|
|
|
|
# Unix host
|
|
|
|
RM := rm -f
|
|
|
|
SUFFIX :=
|
|
|
|
endif
|
2007-11-21 13:49:44 +00:00
|
|
|
endif
|
|
|
|
|
2011-09-18 12:48:26 +00:00
|
|
|
all: cpucount scut
|
2007-11-21 13:49:44 +00:00
|
|
|
|
|
|
|
cpucount: cpucount.c
|
|
|
|
${CC} ${CFLAGS} cpucount$(SUFFIX) cpucount.c
|
|
|
|
$(STRIP) cpucount$(SUFFIX)
|
|
|
|
|
2007-12-19 22:01:44 +00:00
|
|
|
scut: scut.c
|
|
|
|
${CC} ${CFLAGS} scut$(SUFFIX) scut.c
|
|
|
|
$(STRIP) scut$(SUFFIX)
|
|
|
|
|
2007-11-21 13:49:44 +00:00
|
|
|
clean:
|
|
|
|
$(RM) cpucount$(SUFFIX)
|
2007-12-19 22:01:44 +00:00
|
|
|
$(RM) scut$(SUFFIX)
|