1
0
Fork 0
mirror of https://github.com/betaflight/betaflight.git synced 2025-07-12 19:10:32 +03:00
betaflight/mk/system-id.mk
Dmytro 7b39d3d296
Rename make folder to get rid of build error. (#12880)
When trying to build firmware with current directory in PATH environment
it scans for make command and generates "Permission denied" error in
case if current directory in PATH precedes /usr/bin/ directory.In my
case it was caused by incorrect pyenv init script.

Rename make folder to avoid errors like this.
2023-06-14 21:48:55 +02:00

46 lines
972 B
Makefile

# shared.mk
#
# environment variables common to all operating systems supported by the make system
# Make sure we know a few things about the architecture
UNAME := $(shell uname)
ARCH := $(shell uname -m)
ifneq (,$(filter $(ARCH), x86_64 amd64))
X86-64 := 1
X86_64 := 1
AMD64 := 1
ARCHFAMILY := x86_64
else
ARCHFAMILY := $(ARCH)
endif
# configure some variables dependent upon what type of system this is
# Linux
ifeq ($(UNAME), Linux)
OSFAMILY := linux
endif
# Mac OSX
ifeq ($(UNAME), Darwin)
OSFAMILY := macosx
endif
# Windows using MinGW shell
ifeq (MINGW, $(findstring MINGW,$(UNAME)))
OSFAMILY := windows
MINGW := 1
endif
# Windows using Cygwin shell
ifeq (CYGWIN ,$(findstring CYGWIN,$(UNAME)))
OSFAMILY := windows
CYGWIN := 1
endif
# report an error if we couldn't work out what OS this is running on
ifndef OSFAMILY
$(info uname reports $(UNAME))
$(info uname -m reports $(ARCH))
$(error failed to detect operating system)
endif