Browse Source
Check for rpi 3
Change `-march=` option
pull/23/head
Leon Mak
8 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with
3 additions and
0 deletions
-
Makefile
|
|
|
@ -10,8 +10,11 @@ PROC?=$(shell uname -m) |
|
|
|
|
|
|
|
CC=gcc |
|
|
|
CFLAGS=-fPIC -O3 -fomit-frame-pointer -fno-exceptions -Wall -std=c99 -pedantic |
|
|
|
MODEL=$(cat /proc/device-tree/model) |
|
|
|
ifeq (${PROC},x86_64) |
|
|
|
CFLAGS+=-m64 -mtune=generic |
|
|
|
elif [[ $MODEL == *"Raspberry Pi"* ]] |
|
|
|
-march=armv7 |
|
|
|
else |
|
|
|
CFLAGS+=-m32 -march=i686 |
|
|
|
endif |
|
|
|
|