diff --git a/Makefile b/Makefile index fe3bc94..ce1d06a 100644 --- a/Makefile +++ b/Makefile @@ -4,9 +4,10 @@ BINDIR=/usr/bin LOCALESDIR=/usr/share/locale MANDIR=/usr/share/man/man8 WARNFLAGS=-Wall -Wshadow -W -Wformat -Wimplicit-function-declaration -Wimplicit-int -CFLAGS?=-O1 -g ${WARNFLAGS} -CC?=gcc - +INCPATH?=-I ~/install/ncurses/usr/include/ -I ../ncurses/include +LIBPATH?=-L ../ncurses/lib -L ~/install/ncurses/usr/lib +CFLAGS?=-O1 -g ${WARNFLAGS} ${INCPATH} ${LIBPATH} -march=armv5 +CC=arm-none-linux-gnueabi-gcc CFLAGS+=-D VERSION=\"$(VERSION)\" # @@ -24,7 +25,7 @@ OBJS = powertop.o config.o process.o misctips.o bluetooth.o display.o suggestion powertop: $(OBJS) Makefile powertop.h - $(CC) ${CFLAGS} $(LDFLAGS) $(OBJS) -lncursesw -o powertop + $(CC) ${CFLAGS} $(LDFLAGS) $(OBJS) -lncurses -o powertop @(cd po/ && $(MAKE)) powertop.8.gz: powertop.8 diff --git a/perf.c b/perf.c index 1ce35a2..f2ed18b 100644 --- a/perf.c +++ b/perf.c @@ -45,7 +45,7 @@ /* some people have stale headers */ #ifndef __NR_perf_event_open -#ifdef __i386__ +#if defined __i386__ || defined __arm__ #define __NR_perf_event_open 336 #endif #if __x86_64__