Skip to content

Commit

Permalink
make compileline and makefile library tests respect CXXFLAGS
Browse files Browse the repository at this point in the history
Signed-off-by: Jade Abraham <jade.abraham@hpe.com>
  • Loading branch information
jabraham17 committed Oct 17, 2024
1 parent d71e4a8 commit 23456fe
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions test/gpu/native/interop/gpuLibrary/Makefile
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
include lib/Makefile.udf2
test_udf2_make_cpu: test_udf2.cpp lib/libudf2.a
@$(CHPL_COMPILER) -x c++ -lstdc++ $(CHPL_CFLAGS) -o test_udf2_make $< $(CHPL_LDFLAGS)
@$(CHPL_COMPILER) -x c++ -lstdc++ $(CXXFLAGS) $(CHPL_CFLAGS) -o test_udf2_make $< $(CHPL_LDFLAGS)

test_udf2_make_nvidia: test_udf2.cpp lib/libudf2.a
@$(CHPL_COMPILER) -x cuda -lstdc++ $(CHPL_CFLAGS) -o test_udf2_make $< $(CHPL_LDFLAGS)
@$(CHPL_COMPILER) -x cuda -lstdc++ $(CXXFLAGS) $(CHPL_CFLAGS) -o test_udf2_make $< $(CHPL_LDFLAGS)

test_udf2_make_amd: test_udf2.cpp lib/libudf2.a
@$(CHPL_COMPILER) -x hip -lstdc++ $(CHPL_CFLAGS) -o test_udf2_make $< $(CHPL_LDFLAGS)
@$(CHPL_COMPILER) -x hip -lstdc++ $(CXXFLAGS) $(CHPL_CFLAGS) -o test_udf2_make $< $(CHPL_LDFLAGS)

2 changes: 1 addition & 1 deletion test/gpu/native/interop/gpuLibrary/udf2.prediff
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ if [[ "$chpl_gpu" == "nvidia" ]]; then
elif [[ "$chpl_gpu" == "amd" ]]; then
gpu_flags="-x hip"
fi
$cxx $gpu_flags test_udf2.cpp -Ilib -Llib/ -ludf2 $libs -o test_udf2_compileline
$cxx $CXXFLAGS $gpu_flags test_udf2.cpp -Ilib -Llib/ -ludf2 $libs -o test_udf2_compileline
echo "Running test_udf2_compileline" >> $OUTFILE
./test_udf2_compileline >> $OUTFILE

Expand Down

0 comments on commit 23456fe

Please sign in to comment.