Skip to content

Commit

Permalink
Fix issue ponylang#3016
Browse files Browse the repository at this point in the history
The add lines are from PR ponylang#824 which were changed in ponylang#2976.
  • Loading branch information
winksaville committed Feb 21, 2019
1 parent c42ccd3 commit 6e94aec
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion Makefile-ponyc
Expand Up @@ -433,7 +433,17 @@ endif
# (3) a list of include directories for a set of libraries
# (4) a list of the libraries to link against
llvm.ldflags := -L$(CROSS_SYSROOT)$(subst -L,,$(shell $(LLVM_CONFIG) --ldflags $(LLVM_LINK_STATIC)))
llvm.include := $(CROSS_SYSROOT)$(shell sh -c "$(LLVM_CONFIG) --cflags $(LLVM_LINK_STATIC) | grep -oE -- '(^| )-I\s*\S+' | sed 's/^\s*-I\s*/-isystem /g'")
llvm.include.dir := $(CROSS_SYSROOT)$(shell $(LLVM_CONFIG) --includedir $(LLVM_LINK_STATIC))
include.paths := $(shell echo | $(CC) -v -E - 2>&1)
ifeq (,$(findstring $(llvm.include.dir),$(include.paths)))
# LLVM include directory is not in the existing paths;
# put it at the top of the system list
llvm.include := -isystem $(llvm.include.dir)
else
# LLVM include directory is already on the existing paths;
# do nothing
llvm.include :=
endif
llvm.libs := $(shell $(LLVM_CONFIG) --libs $(LLVM_LINK_STATIC)) -lz -lncurses

ifeq ($(OSTYPE), bsd)
Expand Down

0 comments on commit 6e94aec

Please sign in to comment.