Skip to content

Commit

Permalink
Merge pull request #35 from manodeep/develop
Browse files Browse the repository at this point in the history
Develop
  • Loading branch information
manodeep committed Mar 16, 2016
2 parents e07c4c9 + 68a5f01 commit 617a1b9
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Corrfunc/call_correlation_functions.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
import os.path as path
import time
from Corrfunc import _countpairs
from .utils import read_catalog
from Corrfunc.utils import read_catalog


def main():
Expand Down
18 changes: 17 additions & 1 deletion common.mk
Original file line number Diff line number Diff line change
Expand Up @@ -36,14 +36,27 @@ GSL_LINK := $(shell gsl-config --libs) -Xlinker -rpath -Xlinker $(GSL_LIBDIR)

# Check if code is running on travis
ifeq (osx, $(findstring osx, ${TRAVIS_OS_NAME}))
$(info hererehehehre)
ifeq (USE_AVX, $(findstring USE_AVX,$(OPT)))
$(warning $(ccmagenta) TRAVIS CI OSX workers do not seem to support AVX instructions. Removing USE_AVX from compile options. $(ccreset))
OPT:=$(filter-out -DUSE_AVX,$(OPT))
endif
endif
# done with removing USE_AVX under osx on Travis

# Now check if gcc is set to be the compiler but if clang is really under the hood.
export GCC_IS_CLANG ?= -1
ifeq ($(GCC_IS_CLANG), -1)
GCC_VERSION := $(shell gcc --version)
ifeq (clang,$(findstring clang,$(GCC_VERSION)))
export GCC_IS_CLANG := 1
else
export GCC_IS_CLANG := 0
endif
# $(info $$GCC_VERSION is [${GCC_VERSION}])
# $(info $$GCC_IS_CLANG is [${GCC_IS_CLANG}])
endif


ifneq (USE_OMP,$(findstring USE_OMP,$(OPT)))
ifneq (clang,$(findstring clang,$(CC)))
$(warning $(ccmagenta) Recommended compiler for a serial build is clang $(ccreset))
Expand Down Expand Up @@ -132,8 +145,11 @@ ifeq ($(UNAME), Darwin)
## use the clang assembler instead of GNU assembler
## http://stackoverflow.com/questions/10327939/erroring-on-no-such-instruction-while-assembling-project-on-mac-os-x-lion
ifeq (gcc,$(findstring gcc,$(CC)))
ifneq ($(GCC_IS_CLANG), 1)
## Only add -Wa,-q flag if it is true gcc. if clang is operating under gcc, no need to add this flag
CFLAGS += -Wa,-q
endif
endif

endif

Expand Down

0 comments on commit 617a1b9

Please sign in to comment.