diff options
Diffstat (limited to 'build/TFbuild.main')
-rw-r--r-- | build/TFbuild.main | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/build/TFbuild.main b/build/TFbuild.main index b33aa49..36c580b 100644 --- a/build/TFbuild.main +++ b/build/TFbuild.main @@ -24,6 +24,23 @@ MANDIR ?= /usr/share/man DOCDIR ?= /usr/share/doc/$(PACKAGE) STATEDIR ?= /var/run +# OS and architecture detection +UNAME_OS := $(shell uname -s) +UNAME_ARCH := $(shell uname -m) + +ifeq ($(UNAME_OS),Linux) +OS_LINUX := y +OS_UNIX := y +else +$(error Sorry your operating system kernel ($(UNAME_OS)) is not supported yet.) +endif + +ifeq ($(patsubst i%86,i86,$(UNAME_ARCH)),i86) +ARCH_X86 := y +else +$(error Sorry your architecture ($(UNAME_ARCH)) is not supported yet.) +endif + # utilities and default flags for them. CROSS_COMPILE ?= CC := $(CROSS_COMPILE)gcc |