Improve Macports support

This commit is contained in:
İlteriş Eroğlu 2021-08-22 20:40:29 +03:00 committed by GitHub
parent a06765e5a8
commit 456dc8f245
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -21,9 +21,9 @@ TAR = tar
TARFLAGS ?= -v --ignore-failed-read -r
TARFLAGS += -C .. -f
CROSS ?= arm-none-eabi-
CC = gcc
CXX = g++
LD = g++
CC ?= gcc
CXX ?= g++
LD ?= g++
SH = sh
BASH = bash
PERL = perl
@ -50,7 +50,8 @@ else
endif
ifeq ($(platform),Darwin)
USE_BREW = 1
USE_BREW ?= 1
USE_MACPORTS ?= 0
AR= /usr/bin/ar rcs
RANLIB= /usr/bin/ranlib
else
@ -60,11 +61,15 @@ endif
ifeq ($(USE_BREW),1)
BREW_PREFIX = $(shell brew --prefix 2>/dev/null)
ifeq ($(strip $(BREW_PREFIX)),)
MACPORTS_PREFIX ?= /opt/local
ifneq ($(strip $(BREW_PREFIX)),)
USE_BREW = 0
endif
endif
ifeq ($(USE_MACPORTS),1)
MACPORTS_PREFIX ?= /opt/local
endif
ifeq ($(DEBUG),1)
DEFCXXFLAGS = -g -O0 -pipe
DEFCFLAGS = -g -O0 -fstrict-aliasing -pipe