Merge pull request #4453 from lambdageek/bug-49721
[mono.git] / mcs / build / library.make
index e604beb8f75e5cdcf411a963970d3423f2f377c6..3ad567a86e05a398f11f26c8fba22cfb0fe3038b 100644 (file)
@@ -72,12 +72,10 @@ the_libdir_base = $(topdir)/class/$(lib_dir)/$(PROFILE)/
 endif
 
 ifdef RESOURCE_STRINGS
-ifdef BOOTSTRAP_PROFILE
-ifneq (basic, $(BUILD_TOOLS_PROFILE))
+ifneq (basic, $(PROFILE))
 RESOURCE_STRINGS_FILES += $(RESOURCE_STRINGS:%=--resourcestrings:%)
 endif
 endif
-endif
 
 #
 # The bare directory contains the plain versions of System and System.Xml
@@ -168,12 +166,14 @@ install-local:
        $(MKINSTALLDIRS) $(DESTDIR)$(LIBRARY_INSTALL_DIR)
        $(INSTALL_LIB) $(the_lib) $(DESTDIR)$(LIBRARY_INSTALL_DIR)/$(LIBRARY_NAME)
        test ! -f $(the_lib).mdb || $(INSTALL_LIB) $(the_lib).mdb $(DESTDIR)$(LIBRARY_INSTALL_DIR)/$(LIBRARY_NAME).mdb
+       test ! -f $(the_lib:.dll=.pdb) || $(INSTALL_LIB) $(the_lib:.dll=.pdb) $(DESTDIR)$(LIBRARY_INSTALL_DIR)/$(LIBRARY_NAME:.dll=.pdb)
+
 ifdef PLATFORM_AOT_SUFFIX
        test ! -f $(aot_lib) || $(INSTALL_LIB) $(aot_lib) $(DESTDIR)$(LIBRARY_INSTALL_DIR)
 endif
 
 uninstall-local:
-       -rm -f $(DESTDIR)$(LIBRARY_INSTALL_DIR)/$(LIBRARY_NAME) $(DESTDIR)$(LIBRARY_INSTALL_DIR)/$(LIBRARY_NAME).mdb
+       -rm -f $(DESTDIR)$(LIBRARY_INSTALL_DIR)/$(LIBRARY_NAME) $(DESTDIR)$(LIBRARY_INSTALL_DIR)/$(LIBRARY_NAME).mdb $(DESTDIR)$(LIBRARY_INSTALL_DIR)/$(LIBRARY_NAME:.dll=.pdb)
 
 else
 
@@ -266,7 +266,7 @@ endif
 # make dist will collect files in .sources files from all profiles
 dist-local: dist-default
        subs=' ' ; \
-       for f in `$(topdir)/tools/removecomments.sh $(wildcard *$(LIBRARY).sources)` $(TEST_FILES) ; do \
+       for f in `$(topdir)/tools/removecomments.sh $(filter-out $(wildcard *_test.dll.sources) $(wildcard *exclude.sources),$(wildcard *.sources))` $(TEST_FILES) ; do \
          case $$f in \
          ../*) : ;; \
          *.g.cs) : ;; \
@@ -377,3 +377,12 @@ $(the_libdir)/.doc-stamp: $(the_lib)
 # Need to be here so it comes after the definition of DEP_DIRS/DEP_LIBS
 gen-deps:
        @echo "$(DEPS_TARGET_DIR): $(DEP_DIRS) $(DEP_LIBS)" >> $(DEPS_FILE)
+
+# Should be $(BUILD_TOOLS_PROFILE) but still missing System.Windows.Forms
+resx2sr=$(topdir)/class/lib/net_4_x/resx2sr.exe
+
+update-corefx-sr: $(resx2sr) $(RESX_RESOURCE_STRING)
+       MONO_PATH="$(topdir)/class/lib/$(BUILD_TOOLS_PROFILE)$(PLATFORM_PATH_SEPARATOR)$$MONO_PATH" $(RUNTIME) $(RUNTIME_FLAGS) $(resx2sr) $(RESX_RESOURCE_STRING) >corefx/SR.cs
+
+$(resx2sr):
+       $(MAKE) -C $(topdir)/tools/resx2sr