Makefile.inc: replace uname -p with uname -m

uname -p returns "unknown" on many systems effectively breaking the
build. Replace it with uname -m which yields the correct architecture.
This commit is contained in:
Simon Ruderich 2017-08-18 14:48:43 +02:00
parent e09078b7ea
commit 78bfbcc4a5
2 changed files with 2 additions and 2 deletions

View File

@ -3,7 +3,7 @@ CC = gcc
INSTALL = /usr/bin/install
ARCH = $(shell uname -p)
ARCH = $(shell uname -m)
PREFIX ?= /usr/local
LIBDIR ?= lib

View File

@ -6,7 +6,7 @@ LDFLAGS += $(KPATCH_LDFLAGS)
# ppc64le kernel modules are expected to compile with the
# -mcmodel=large flag. This enables 64-bit relocations
# instead of a 32-bit offset from the TOC pointer.
PROCESSOR = $(shell uname -p)
PROCESSOR = $(shell uname -m)
ifeq ($(PROCESSOR), ppc64le)
KBUILD_CFLAGS_MODULE += -mcmodel=large
endif