Skip to content

Commit 3b8abf3

Browse files
authored
Merge pull request #100 from isuruf/debug
Fix CUDA_HOME
2 parents d49b188 + 266efbd commit 3b8abf3

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

recipe/build-mpi.sh

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
# unset unused old fortran compiler vars
44
unset F90 F77
55

6-
set -e
6+
set -ex
77

88
export FCFLAGS="$FFLAGS"
99

@@ -24,8 +24,8 @@ fi
2424
if [[ -z $CUDA_HOME ]]; then
2525
build_with_cuda=""
2626
else
27-
export CFLAGS="$CFLAGS -isystem $CUDA_HOME"
28-
export CXXFLAGS="$CXXFLAGS -isystem $CUDA_HOME"
27+
export CFLAGS="$CFLAGS -I$CUDA_HOME/include"
28+
export CXXFLAGS="$CXXFLAGS -I$CUDA_HOME/include"
2929
build_with_cuda="--with-cuda --with-ucx=$PREFIX"
3030
fi
3131

@@ -151,7 +151,7 @@ export LIBRARY_PATH="$PREFIX/lib"
151151
--with-wrapper-fcflags="-I$PREFIX/include" \
152152
--with-wrapper-ldflags="-L$PREFIX/lib -Wl,-rpath,$PREFIX/lib" \
153153
--with-sge \
154-
$build_with_cuda
154+
$build_with_cuda || (cat config.log; false)
155155

156156
make -j"${CPU_COUNT:-1}"
157157
make install
@@ -166,7 +166,7 @@ if [ ! -z "$build_with_cuda" ]; then
166166
echo "pml = ^ucx" >> $PREFIX/etc/openmpi-mca-params.conf
167167
echo "setting the mca osc to ^ucx..."
168168
echo "osc = ^ucx" >> $PREFIX/etc/openmpi-mca-params.conf
169-
169+
170170
POST_LINK=$PREFIX/bin/.openmpi-post-link.sh
171171
cp $RECIPE_DIR/post-link.sh $POST_LINK
172172
chmod +x $POST_LINK

recipe/meta.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{% set version = "4.1.3" %}
22
{% set major = version.rpartition('.')[0] %}
3-
{% set build = 2 %}
3+
{% set build = 3 %}
44

55
# give conda package a higher build number
66
{% if mpi_type == 'conda' %}
@@ -19,8 +19,6 @@ source:
1919

2020
build:
2121
number: {{ build }}
22-
script_env:
23-
- CUDA_HOME
2422
skip: true # [win]
2523

2624
outputs:
@@ -41,6 +39,8 @@ outputs:
4139
build:
4240
run_exports:
4341
- {{ pin_subpackage('openmpi', min_pin='x.x.x', max_pin='x') }}
42+
script_env:
43+
- CUDA_HOME # [enable_cuda]
4444
requirements:
4545
build:
4646
- {{ compiler('c') }}

0 commit comments

Comments
 (0)