update readme (#21797)
[mono-project.git] / llvm / Makefile.am
blobffaa2b84e71a5c369274827f887dc8091c40f885
2 EXTRA_DIST=build.mk build_llvm_config.sh
4 if ENABLE_LLVM
6 if HOST_WIN32
7 llvm_config=llvm-config.exe
8 else
9 llvm_config=llvm-config
10 endif
12 if HAVE_STATIC_ZLIB
13 llvm_extra_libs = $(STATIC_ZLIB_PATH)
14 else
15 if HAVE_SYS_ZLIB
16 llvm_extra_libs=-lz
17 else
18 llvm_extra_libs=
19 endif
20 endif
22 if INTERNAL_LLVM_ASSERTS
23 ENABLE_ASSERTS=On
24 else
25 ENABLE_ASSERTS=Off
26 endif
28 if INTERNAL_LLVM
30 all-local: configure-llvm build-llvm install-llvm llvm_config.mk
32 clean-local: clean-llvm clean-llvm-config
34 $(mono_build_root)/llvm/llvm_config.mk: install-llvm
35         $(top_srcdir)/llvm/build_llvm_config.sh "$(top_srcdir)/llvm/usr/bin/$(llvm_config)" "$(LLVM_CODEGEN_LIBS)" "$(llvm_extra_libs)" | tee $@
37 else
38 all-local: llvm_config.mk
40 clean-local: clean-llvm-config
42 $(mono_build_root)/llvm/llvm_config.mk: $(top_srcdir)/llvm/Makefile.am
43         $(top_srcdir)/llvm/build_llvm_config.sh "$(EXTERNAL_LLVM_CONFIG)" "$(LLVM_CODEGEN_LIBS)" "$(llvm_extra_libs)" | tee $@
44 endif
46 llvm_config.mk: $(mono_build_root)/llvm/llvm_config.mk
48 clean-llvm-config:
49         - rm -rf llvm_config.mk
51 else
52 all-local: 
54 clean-local: 
55 endif
57 # Override this so we don't try to re-copy llvm when we install mono
58 install:
60 if TARGET_WASM
61 LLVM_TARGET=wasm32
62 else
63 LLVM_TARGET=
64 endif
66 include build.mk