Commit e32aae96 authored by Maxime Perrotin's avatar Maxime Perrotin

Fix Makefile to detect 64bits architectures

uname -a could return 64 bits even in a 32 bits OS, if the OS is within
a docker or chroot hosted on a 64bits OS
parent df13f1af
UNAME := $(shell uname)
ARCH := $(shell getconf LONG_BIT)
CC=gcc
exec = buildsupport
......@@ -26,7 +27,7 @@ ifeq ($(UNAME), Linux)
fi ; \
fi
endif
uname -a | grep x86_64 && EXTRAFLAG="--target=x86_64-linux" ; \
[ $(ARCH) == 64 ] && EXTRAFLAG="--target=x86_64-linux" ; \
ADA_PROJECT_PATH=`ocarina-config --prefix`/lib/gnat:$$ADA_PROJECT_PATH \
$(gnatpath)gprbuild -x -g $(exec) -p -P buildsupport.gpr -XBUILD="debug" $$EXTRAFLAG
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment