Skip to content

Commit

Permalink
Added relevant flags for compilation on linux
Browse files Browse the repository at this point in the history
  • Loading branch information
giacomov committed May 25, 2017
1 parent e1a53c2 commit 80fa99f
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions conda_recipe/xspec-modelsonly/build.sh
Original file line number Diff line number Diff line change
@@ -1,20 +1,24 @@
cd BUILD_DIR
./configure --prefix=${SRC_DIR}/xspec-modelsonly-build

if [ "$(uname)" == "Linux" ]; then

# We need a custom include and library path to use the packages installed
# in the build environment

export CFLAGS='-I${PREFIX}/include -O2 -Wall --pedantic -Wno-comment -Wno-long-long -g -ffloat-store -fPIC'
export CXXFLAGS='-I${PREFIX}/include -O2 -Wall --pedantic -Wno-comment -Wno-long-long -g -ffloat-store -fPIC'
export CPPFLAGS="-I${PREFIX}/include"
export LDFLAGS="-L${PREFIX}/lib -lCCfits -lcfitsio -lwcslib"
export LDFLAGS="-L${PREFIX}/lib"

./configure --prefix=${SRC_DIR}/xspec-modelsonly-build

./hmake 'XSLM_USER_FLAGS="-I${PREFIX}/include"' 'XSLM_USER_LIBS="-L${PREFIX}/lib -lCCfits -lcfitsio -lwcslib"'

fi

if [ "$(uname)" == "Darwin" ]; then

./configure --prefix=${SRC_DIR}/xspec-modelsonly-build

./hmake 'LDFLAGS_CXX=-headerpad_max_install_names -lcfitsio -lCCfits -lccfits -lwcs'

fi
Expand Down

0 comments on commit 80fa99f

Please sign in to comment.