diff --git a/Makefile b/Makefile index 555d1c467..d31cc9c83 100644 --- a/Makefile +++ b/Makefile @@ -34,9 +34,9 @@ endif LAPACK_NOOPT := $(filter-out -O0 -O1 -O2 -O3 -Ofast,$(LAPACK_FFLAGS)) -SUBDIRS_ALL = $(SUBDIRS) test ctest utest exports benchmark ../laswp ../bench cpp_thread_test +SUBDIRS_ALL = $(SUBDIRS) test ctest utest test_install exports benchmark ../laswp ../bench cpp_thread_test -.PHONY : all libs netlib $(RELA) test ctest shared install +.PHONY : all libs netlib $(RELA) test ctest test_install shared install .NOTPARALLEL : all libs $(RELA) prof lapack-test install blas-test all :: libs netlib $(RELA) tests shared @@ -155,6 +155,11 @@ endif endif endif +test_install : + mkdir -p install + PREFIX=install $(MAKE) install + $(MAKE) -C test_install all + libs : ifeq ($(CORE), UNKNOWN) $(error OpenBLAS: Detecting CPU failed. Please set TARGET explicitly, e.g. make TARGET=your_cpu_target. Please read README for the detail.) @@ -399,4 +404,5 @@ endif @$(MAKE) -C relapack clean @rm -f *.grd Makefile.conf_last config_last.h @(cd $(NETLIB_LAPACK_DIR)/TESTING && rm -f x* *.out testing_results.txt) + @rm -rf install @echo Done. diff --git a/test_install/Makefile b/test_install/Makefile new file mode 100644 index 000000000..29cd81322 --- /dev/null +++ b/test_install/Makefile @@ -0,0 +1,15 @@ +# +# tests of installed headers and libs +# + +INSTALLDIR = ../install + +.PHONY: all +all: test_sched_include + +test_sched_include: test_sched_include.c + $(CC) -c -I$(INSTALLDIR)/include $< + +.PHONY: clean +clean: + rm -f *.o diff --git a/test_install/test_sched_include.c b/test_install/test_sched_include.c new file mode 100644 index 000000000..aea35680d --- /dev/null +++ b/test_install/test_sched_include.c @@ -0,0 +1,5 @@ +// tests that inclusion of openblas_config.h works with musl + +#include + +cpu_set_t* cpu_set = NULL;