Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions apps/linear_algebra/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,16 @@ BENCHMARKS = \
all: build
make run_benchmarks

# This is a hack: disable this test when compiling 32-bit systems, as it's hard to find the right 32-bit versions
# of these libraries on 64-bit hosts. Can't rely on HL_TARGET because it might be 'host' even for cross-compiling.
# Look instead for `-m32` being passed to CXX, which is the cross-compiling flag we use. This is regrettable
# but expedient. (Note that CMake is able to find this correctly, and so we have test coverage there; this is
# simply not worth debugging as an edge case at the moment.)
ifneq (,$(findstring -m32,$(CXX)))
build:
@echo linear_algebra not support using Make on 32-bit systems: skipping linear_algebra tests...
test: build
else
ifneq ("$(wildcard /usr/include/cblas.h /usr/include/*/cblas.h)","")
build: $(BENCHMARKS) $(BIN)/test_halide_blas
test: $(BIN)/test_halide_blas
Expand All @@ -86,6 +96,7 @@ build:
@echo /usr/include/cblas.h not found: skipping linear_algebra tests...
test: build
endif
endif

clean:
rm -rf $(BIN)
Expand Down