[build] Generate all aot images for csc into the profile directory instead of next...
[mono.git] / mcs / packages / Makefile
index 5b3cc08cacfb8bfe87cff0b951325c5ac7837671..d3d99b0614295268f2907b9671a488154f5ca1ad 100644 (file)
@@ -3,23 +3,30 @@ include ../build/rules.make
 
 ROSLYN_CSC_DIR = $(dir $(CSC_LOCATION))
 
+ROSLYN_FILES = \
+       $(ROSLYN_CSC_DIR)/csc.exe                               \
+       $(ROSLYN_CSC_DIR)/csc.rsp                               \
+       $(ROSLYN_CSC_DIR)/csc.exe.config                        \
+       $(ROSLYN_CSC_DIR)/Microsoft.CodeAnalysis.CSharp.dll     \
+       $(ROSLYN_CSC_DIR)/Microsoft.CodeAnalysis.dll            \
+       $(ROSLYN_CSC_DIR)/System.Collections.Immutable.dll      \
+       $(ROSLYN_CSC_DIR)/System.Reflection.Metadata.dll
+
+ROSLYN_AOT_FILES = \
+       $(ROSLYN_CSC_DIR)/csc.exe$(PLATFORM_AOT_SUFFIX)         \
+       $(ROSLYN_CSC_DIR)/System.Reflection.Metadata.dll$(PLATFORM_AOT_SUFFIX)
+
+DISTFILES = $(ROSLYN_FILES)
+
 ifeq ($(PROFILE), $(DEFAULT_PROFILE))
 
 TARGET_DIR = $(DESTDIR)$(mono_libdir)/mono/$(FRAMEWORK_VERSION)
 
 install-local:
-       $(INSTALL_LIB) $(ROSLYN_CSC_DIR)/csc.exe $(TARGET_DIR)
-       $(INSTALL_LIB) $(ROSLYN_CSC_DIR)/csc.rsp $(TARGET_DIR)
-       $(INSTALL_LIB) $(ROSLYN_CSC_DIR)/csc.exe.config $(TARGET_DIR)
-       $(INSTALL_LIB) $(ROSLYN_CSC_DIR)/Microsoft.CodeAnalysis.CSharp.dll $(TARGET_DIR)
-       $(INSTALL_LIB) $(ROSLYN_CSC_DIR)/Microsoft.CodeAnalysis.dll $(TARGET_DIR)
-       $(INSTALL_LIB) $(ROSLYN_CSC_DIR)/System.Collections.Immutable.dll $(TARGET_DIR)
-       $(INSTALL_LIB) $(ROSLYN_CSC_DIR)/System.Reflection.Metadata.dll $(TARGET_DIR)
-
-       $(INSTALL_LIB) $(ROSLYN_CSC_DIR)/csc.exe$(PLATFORM_AOT_SUFFIX) $(TARGET_DIR)
-       $(INSTALL_LIB) $(ROSLYN_CSC_DIR)/System.Reflection.Metadata.dll$(PLATFORM_AOT_SUFFIX) $(TARGET_DIR)
-endif
+       $(MKINSTALLDIRS) $(TARGET_DIR)
+       $(INSTALL_LIB) $(ROSLYN_FILES) $(TARGET_DIR)
+       if test x$(ENABLE_AOT) != x; then $(INSTALL_LIB) $(ROSLYN_AOT_FILES) $(TARGET_DIR); fi
 
+endif
 
 dist-local: dist-default
-