Skip to content

Commit

Permalink
Set the compiler in travis build script
Browse files Browse the repository at this point in the history
  • Loading branch information
Dimitri Vorona committed Dec 6, 2018
1 parent 635871b commit 489e804
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 9 deletions.
4 changes: 4 additions & 0 deletions buildscripts/incremental/install_miniconda.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@ if [[ "$unamestr" == 'Linux' ]]; then
wget https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh -O miniconda.sh
elif [[ "$unamestr" == 'Darwin' ]]; then
wget https://repo.continuum.io/miniconda/Miniconda3-latest-MacOSX-x86_64.sh -O miniconda.sh
# use system clang in travis ci to avoid linking issues
# see https://github.com/bigartm/bigartm/issues/910
export CC=clang
export CXX=clang++
else
echo Error
fi
Expand Down
4 changes: 2 additions & 2 deletions ffi/build.py
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ def main_posix(kind, library_ext):
for lname in libs.split('-l') \
if lname and 'LLVMCore' not in lname
and 'LLVMSupport' not in lname]
# cxxflags.append(' '.join(excluded))
cxxflags.append(' '.join(excluded))
# look for SVML
include_dir = run_llvm_config(llvm_config, ['--includedir']).strip()
svml_indicator = os.path.join(include_dir, 'llvm', 'IR', 'SVML.gen')
Expand Down Expand Up @@ -186,7 +186,7 @@ def build_passes():
generator = find_win32_generator()
try_cmake('..', '.', generator)

subprocess.check_call(['cmake', '--build', '.', '--config', 'Debug'])
subprocess.check_call(['cmake', '--build', '.', '--config', 'Release'])
shutil.copy(os.path.join("hello", hello_pass_library), target_dir)


Expand Down
8 changes: 1 addition & 7 deletions ffi/passes/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,12 +1,5 @@
cmake_minimum_required(VERSION 3.2)

if (APPLE AND "$ENV{CONDA_ENV}" STREQUAL "travisci")
# use system clang in travis ci to avoid linking issues
# see https://github.com/bigartm/bigartm/issues/910
set(CMAKE_CXX_COMPILER clang++)
set(CMAKE_C_COMPILER clang)
endif()

find_package(LLVM REQUIRED CONFIG)

add_definitions(${LLVM_DEFINITIONS})
Expand All @@ -24,3 +17,4 @@ endif()
include_directories(${LLVM_INCLUDE_DIRS})

add_subdirectory(hello)
add_subdirectory(refcntopt)

0 comments on commit 489e804

Please sign in to comment.