Remove bitrotted support for a separate mono submodule for watchOS support. (#5022)

Unce upon a time we used a separate mono submodule for watchOS support, to make
development of watchOS support easier (we referenced mono/master, to avoid
backporting fixes for watchOS support through various release branches in
mono).

This only worked until our watchOS support became stable, since then we had to
start using a stable version of mono for watchOS support.

This means that our build support for using a separate mono clone for watchOS
support is no longer needed; and in any case it's broken because of build
changes done later.
This commit is contained in:
Rolf Bjarne Kvinge 2018-10-22 16:14:26 +02:00 коммит произвёл GitHub
Родитель f87f3b88f8
Коммит d899d4fb70
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: 4AEE18F83AFDEB23
6 изменённых файлов: 17 добавлений и 112 удалений

Просмотреть файл

@ -230,7 +230,6 @@ DEVICETV_OBJC_CFLAGS = $(DEVICETV_CFLAGS) $(DEVICE_OBJC_CFLAGS)
# paths to the modules we depend on, as variables, so people can put
# things in other places if they absolutely must.
MONO_PATH=$(TOP)/external/mono
WATCH_MONO_PATH=$(TOP)/external/mono
TOUCH_UNIT_PATH=$(TOP)/external/Touch.Unit
NUNITLITE_PATH=$(TOP)/external/mono/external/nunit-lite
OPENTK_PATH=$(TOP)/external/opentk

Просмотреть файл

@ -390,11 +390,6 @@ endif
$(MONO_PATH)/configure: $(MONO_PATH)/configure.ac $(BUILDS_MAKEFILE_DEP)
$(Q) ./wrap-autogen.sh $(MONO_PATH) mono $(XAMARIN_AUTOGEN_FLAGS)
ifneq ($(WATCH_MONO_PATH),$(MONO_PATH))
$(WATCH_MONO_PATH)/configure: $(WATCH_MONO_PATH)/configure.ac $(BUILDS_MAKEFILE_DEP)
$(Q) ./wrap-autogen.sh $(WATCH_MONO_PATH) mono
endif
configure-mono:
rm -f $(MONO_PATH)/configure
$(MAKE) $(MONO_PATH)/configure
@ -422,6 +417,7 @@ TOOLS64_LDFLAGS=-arch x86_64 -mmacosx-version-min=$(MIN_OSX_SDK_VERSION) $(COMMO
TOOLS64_CONFIGURE_FLAGS= --build=x86_64-apple-darwin10 \
--with-monotouch_tv=yes \
--with-monotouch_watch=yes \
--prefix=$(BUILD_DESTDIR)/tools64 \
--enable-maintainer-mode \
--cache-file=../tools64.config.cache \
@ -436,12 +432,6 @@ TOOLS64_CONFIGURE_FLAGS= --build=x86_64-apple-darwin10 \
--disable-boehm \
$(XAMARIN_IOS_CONFIGURE_FLAGS) \
ifeq ($(WATCH_MONO_PATH),$(MONO_PATH))
TOOLS64_CONFIGURE_FLAGS += --with-monotouch_watch=yes
else
TOOLS64_CONFIGURE_FLAGS += --with-monotouch_watch=no
endif
TOOLS64_ACVARS = $(COMMON_ACVARS)
TOOLS64_CONFIGURE_ENVIRONMENT = \
@ -495,79 +485,6 @@ install-local:: install-tools-tvos
install-tools:: install-tools-tvos
endif
#
# Xamarin.WatchOS BCL assemblies
#
# We need to build the WatchOS BCL using the same mono checkout as we're using for the
# corresponding Mono runtimes, which means we can't use the normal tools64 build
#
# Also we can't reuse the existing watchsimulator/targetwatch builds, since their
# monos don't run (correctly) on desktop OSX.
#
# So we build an entire Mono just to build the WatchOS BCL.
#
WATCHBCL_CFLAGS=-arch x86_64 -mmacosx-version-min=$(MIN_OSX_SDK_VERSION)
WATCHBCL_CXXFLAGS=-arch x86_64 -mmacosx-version-min=$(MIN_OSX_SDK_VERSION)
WATCHBCL_LDFLAGS=-arch x86_64 -mmacosx-version-min=$(MIN_OSX_SDK_VERSION) $(COMMON_LDFLAGS)
WATCHBCL_ACVARS = $(COMMON_ACVARS)
WATCHBCL_CONFIGURE_FLAGS= --build=x86_64-apple-darwin10 \
--prefix=$(BUILD_DESTDIR)/watchbcl \
--enable-maintainer-mode \
--cache-file=../watchbcl.config.cache \
--with-glib=embedded \
--enable-minimal=com \
--with-profile4_x=no \
--with-monotouch=no \
--with-monotouch_watch=yes \
--with-monotouch_tv=no \
--with-xammac=no \
--with-mcs-docs=no \
--disable-nls \
--disable-iconv \
--disable-boehm \
$(XAMARIN_IOS_CONFIGURE_FLAGS)
WATCHBCL_CONFIGURE_ENVIRONMENT = \
$(WATCHBCL_ACVARS) \
CFLAGS="$(WATCHBCL_CFLAGS)" \
CXXFLAGS="$(WATCHBCL_CXXFLAGS)" \
LDFLAGS="$(WATCHBCL_LDFLAGS)" \
CC="$(MAC_CC)" \
CXX="$(MAC_CXX)" \
ifdef INCLUDE_WATCH
setup:: setup-watchbcl
build:: build-watchbcl
clean-local:: clean-watchbcl
endif
watchbcl: build-watchbcl install-tools-watch
setup-watchbcl: .stamp-configure-watchbcl
ifneq ($(WATCH_MONO_PATH),$(MONO_PATH))
.stamp-configure-watchbcl: $(WATCH_MONO_PATH)/configure
$(Q) $(WATCHBCL_CONFIGURE_ENVIRONMENT) ./wrap-configure.sh watchbcl ../$(WATCH_MONO_PATH)/configure $(WATCHBCL_CONFIGURE_FLAGS)
endif
build-tools-bcl: build-watchbcl
build-tools: build-watchbcl
ifeq ($(WATCH_MONO_PATH),$(MONO_PATH))
.stamp-build-watchbcl: .stamp-build-tools64 $(MONO_DEPENDENCIES)
else
.stamp-build-watchbcl: .stamp-configure-watchbcl .stamp-build-tools64 $(MONO_DEPENDENCIES)
$(MAKE) -C watchbcl all EXTERNAL_MCS=$(SYSTEM_CSC) EXTERNAL_RUNTIME=$(SYSTEM_MONO)
$(MAKE) -C watchbcl install EXTERNAL_MCS=$(SYSTEM_CSC) EXTERNAL_RUNTIME=$(SYSTEM_MONO)
endif
$(Q) touch $@
clean-watchbcl:
rm -rf watchbcl .stamp-*-watchbcl watchbcl.config.cache
#
# Xamarin.iOS/WatchOS/TVOS BCL assemblies
#
@ -589,7 +506,6 @@ IOS_REPL_ASSEMBLIES = mscorlib System System.Core System.Xml Mono.CSharp
IOS_FACADE_ASSEMBLIES = $(monotouch_PARALLEL_SUBDIRS) $(monotouch_SUBDIRS)
# TVOS/WATCHOS BCL is built from a different mono branch and the assembly list might differ across time
TVOS_ASSEMBLIES = $(IOS_ASSEMBLIES)
WATCHOS_ASSEMBLIES = $(filter-out Mono.Security Mono.Data.Tds,$(IOS_ASSEMBLIES))
TVOS_FACADE_ASSEMBLIES = $(IOS_FACADE_ASSEMBLIES)
@ -610,8 +526,8 @@ watch-facade-check: $(WATCH_BCL_TARGETS)
disabled-watch-facade-check: $(WATCH_BCL_TARGETS)
$(Q) rm -f .$@*
$(Q) echo $(WATCHOS_FACADE_ASSEMBLIES) | tr ' ' '\n' | sort > .$@1
$(Q) ls -1 $(WATCH_MONO_PATH)/mcs/class/lib/monotouch_watch/Facades | grep dll$$ | sed 's/[.]dll//' | sort > .$@2
$(Q) if ! diff -u .$@1 .$@2; then echo "\n*** There are Facade assemblies in "$(WATCH_MONO_PATH)/mcs/class/lib/monotouch_watch/Facades" not defined in "$(FACADE_SUBDIRS_MK)" ***\n"; exit 1; fi
$(Q) ls -1 $(MONO_PATH)/mcs/class/lib/monotouch_watch/Facades | grep dll$$ | sed 's/[.]dll//' | sort > .$@2
$(Q) if ! diff -u .$@1 .$@2; then echo "\n*** There are Facade assemblies in "$(MONO_PATH)/mcs/class/lib/monotouch_watch/Facades" not defined in "$(FACADE_SUBDIRS_MK)" ***\n"; exit 1; fi
$(Q) rm -f .$@*
tvos-facade-check: $(TVOS_BCL_TARGETS)
@ -1546,11 +1462,6 @@ llvm64: install-llvm64
$(MONO_PATH)/tools/offsets-tool/MonoAotOffsetsDumper.exe: $(MONO_PATH)/configure $(wildcard $(MONO_PATH)/tools/offsets-tool/*.cs)
$(Q) $(MAKE) -C $(dir $@) MonoAotOffsetsDumper.exe
ifneq ($(WATCH_MONO_PATH),$(MONO_PATH))
$(WATCH_MONO_PATH)/tools/offsets-tool/MonoAotOffsetsDumper.exe: $(wildcard $(WATCH_MONO_PATH)/tools/offsets-tool/*.cs)
$(Q) $(MAKE) -C $(dir $@) MonoAotOffsetsDumper.exe
endif
targetwatch/mono/arch/arm/arm_dpimacros.h: .stamp-configure-targetwatch
$(Q) $(MAKE) -C $(dir $@) $(notdir $@)

Просмотреть файл

@ -667,7 +667,7 @@ WATCH_BMONO = MONO_PATH=$(WATCH_LIBDIR)/repl $(IOS_DESTDIR)$(MONOTOUCH_PREFIX)/b
WATCH_GENERATOR=$(BUILD_DIR)/common/bgen.exe
WATCH_GENERATE=$(SYSTEM_MONO) --debug $(WATCH_GENERATOR)
WATCH_GENERATED_DEFINES= -d:WATCH -d:XAMCORE_3_0 -d:XAMCORE_2_0 -d:__UNIFIED__
WATCH_BCL_DIR = $(WATCH_MONO_PATH)/mcs/class/lib/monotouch_watch
WATCH_BCL_DIR = $(MONO_PATH)/mcs/class/lib/monotouch_watch
WATCHOS_EXTRA_CORE_SOURCES = \
$(WATCH_BUILD_DIR)/Constants.cs \
@ -732,7 +732,7 @@ $(BUILD_DIR)/watchos.rsp: Makefile Makefile.generator frameworks.sources
-tmpdir=$(WATCH_BUILD_DIR)/watch \
-baselib=$(WATCH_BUILD_DIR)/watch/core.dll \
-attributelib=$(WATCH_BUILD_DIR)/Xamarin.WatchOS.BindingAttributes.dll \
-r=$(WATCH_MONO_PATH)/mcs/class/lib/monotouch_watch/System.dll \
-r=$(MONO_PATH)/mcs/class/lib/monotouch_watch/System.dll \
-ns=MonoTouch.ObjCRuntime \
-native-exception-marshalling \
$(WATCH_GENERATED_DEFINES) \
@ -766,42 +766,42 @@ $(WATCH_BUILD_DIR)/reference/MonoTouch.NUnitLite%dll $(WATCH_BUILD_DIR)/referenc
# System.Drawing.Primitives.dll is special
$(WATCH_MONO_PATH)/mcs/class/lib/monotouch_watch/reference_Facades/System.Drawing.Primitives.dll: $(WATCH_BUILD_DIR)/reference/Xamarin.WatchOS.dll
$(call Q_PROF_CSC,watch) $(MAKE) $(if $(V),,-s) -C $(WATCH_MONO_PATH)/mcs/class/Facades/System.Drawing.Primitives PROFILE=monotouch_watch LIBRARY_SUBDIR=reference_Facades EXTERNAL_FACADE_DRAWING_REFERENCE="$(abspath $(WATCH_BUILD_DIR)/reference/Xamarin.WatchOS.dll)"
$(MONO_PATH)/mcs/class/lib/monotouch_watch/reference_Facades/System.Drawing.Primitives.dll: $(WATCH_BUILD_DIR)/reference/Xamarin.WatchOS.dll
$(call Q_PROF_CSC,watch) $(MAKE) $(if $(V),,-s) -C $(MONO_PATH)/mcs/class/Facades/System.Drawing.Primitives PROFILE=monotouch_watch LIBRARY_SUBDIR=reference_Facades EXTERNAL_FACADE_DRAWING_REFERENCE="$(abspath $(WATCH_BUILD_DIR)/reference/Xamarin.WatchOS.dll)"
@touch $@
$(WATCH_BUILD_DIR)/%/Facades/System.Drawing.Primitives.dll: $(WATCH_MONO_PATH)/mcs/class/lib/monotouch_watch/%_Facades/System.Drawing.Primitives.dll | $(WATCH_BUILD_DIR)/reference/Facades
$(WATCH_BUILD_DIR)/%/Facades/System.Drawing.Primitives.dll: $(MONO_PATH)/mcs/class/lib/monotouch_watch/%_Facades/System.Drawing.Primitives.dll | $(WATCH_BUILD_DIR)/reference/Facades
$(Q) cp $< $@
# netstandard.dll is special
$(WATCH_MONO_PATH)/mcs/class/lib/monotouch_watch/reference_Facades/netstandard.dll: $(WATCH_BUILD_DIR)/reference/Xamarin.WatchOS.dll
$(call Q_PROF_CSC,watch) $(MAKE) $(if $(V),,-s) -C $(WATCH_MONO_PATH)/mcs/class/Facades/netstandard PROFILE=monotouch_watch LIBRARY_SUBDIR=reference_Facades EXTERNAL_FACADE_DRAWING_REFERENCE="$(abspath $(WATCH_BUILD_DIR)/reference/Xamarin.WatchOS.dll)"
$(MONO_PATH)/mcs/class/lib/monotouch_watch/reference_Facades/netstandard.dll: $(WATCH_BUILD_DIR)/reference/Xamarin.WatchOS.dll
$(call Q_PROF_CSC,watch) $(MAKE) $(if $(V),,-s) -C $(MONO_PATH)/mcs/class/Facades/netstandard PROFILE=monotouch_watch LIBRARY_SUBDIR=reference_Facades EXTERNAL_FACADE_DRAWING_REFERENCE="$(abspath $(WATCH_BUILD_DIR)/reference/Xamarin.WatchOS.dll)"
@touch $@
$(WATCH_BUILD_DIR)/%/Facades/netstandard.dll: $(WATCH_MONO_PATH)/mcs/class/lib/monotouch_watch/%_Facades/netstandard.dll | $(WATCH_BUILD_DIR)/reference/Facades
$(WATCH_BUILD_DIR)/%/Facades/netstandard.dll: $(MONO_PATH)/mcs/class/lib/monotouch_watch/%_Facades/netstandard.dll | $(WATCH_BUILD_DIR)/reference/Facades
$(Q) cp $< $@
# System.Net.Http.dll is special. See comment in src/Makefile
WATCH_EXTRA_SYSTEM_NET_HTTP_FILES = \
$(abspath $(WATCH_MONO_PATH)/mcs/class/System.Net.Http/HttpClientEx.cs) \
$(abspath $(MONO_PATH)/mcs/class/System.Net.Http/HttpClientEx.cs) \
$(abspath $(TOP)/src/Foundation/NSUrlSessionHandler.cs) \
$(abspath $(TOP)/src/ObjCRuntime/RuntimeOptions.cs) \
# build (into custom LIBRARY_SUBDIR)
$(WATCH_MONO_PATH)/mcs/class/lib/monotouch_watch/reference/System.Net.Http%dll $(WATCH_MONO_PATH)/mcs/class/lib/monotouch_watch/reference/System.Net.Http%pdb: $(WATCH_EXTRA_SYSTEM_NET_HTTP_FILES) $(WATCH_MONO_PATH)/mcs/class/lib/monotouch_watch/System.Net.Http.dll $(WATCH_BUILD_DIR)/reference/Xamarin.WatchOS.dll
$(call Q_PROF_CSC,watch) $(MAKE) $(if $(V),,-s) -C $(WATCH_MONO_PATH)/mcs/class/System.Net.Http PROFILE=monotouch_watch LIBRARY_SUBDIR=reference MONOTOUCH_MCS_FLAGS=$(IOS_CSC_FLAGS) EXTRA_LIB_MCS_FLAGS="-r:$(abspath $(WATCH_BUILD_DIR)/reference/Xamarin.WatchOS.dll) $(WATCH_EXTRA_SYSTEM_NET_HTTP_FILES) -D:XAMCORE_2_0 -D:XAMCORE_3_0 -D:XAMARIN_MODERN -D:SYSTEM_NET_HTTP -D:UNIFIED -D:__UNIFIED__"
$(MONO_PATH)/mcs/class/lib/monotouch_watch/reference/System.Net.Http%dll $(MONO_PATH)/mcs/class/lib/monotouch_watch/reference/System.Net.Http%pdb: $(WATCH_EXTRA_SYSTEM_NET_HTTP_FILES) $(MONO_PATH)/mcs/class/lib/monotouch_watch/System.Net.Http.dll $(WATCH_BUILD_DIR)/reference/Xamarin.WatchOS.dll
$(call Q_PROF_CSC,watch) $(MAKE) $(if $(V),,-s) -C $(MONO_PATH)/mcs/class/System.Net.Http PROFILE=monotouch_watch LIBRARY_SUBDIR=reference MONOTOUCH_MCS_FLAGS=$(IOS_CSC_FLAGS) EXTRA_LIB_MCS_FLAGS="-r:$(abspath $(WATCH_BUILD_DIR)/reference/Xamarin.WatchOS.dll) $(WATCH_EXTRA_SYSTEM_NET_HTTP_FILES) -D:XAMCORE_2_0 -D:XAMCORE_3_0 -D:XAMARIN_MODERN -D:SYSTEM_NET_HTTP -D:UNIFIED -D:__UNIFIED__"
@# If the make we executed didn't result in building the dll/pdb (because make determined it wasn't necessary to rebuild),
@# then this make can end up confused and in an infinite loop. So touch the output files, to make sure they look rebuilt to make.
$(Q) touch $(basename $@).dll $(basename $@).pdb
# sign dll
$(WATCH_BUILD_DIR)/reference/System.Net.Http.dll: $(WATCH_MONO_PATH)/mcs/class/lib/monotouch_watch/reference/System.Net.Http.dll | $(WATCH_BUILD_DIR)/reference
$(WATCH_BUILD_DIR)/reference/System.Net.Http.dll: $(MONO_PATH)/mcs/class/lib/monotouch_watch/reference/System.Net.Http.dll | $(WATCH_BUILD_DIR)/reference
$(Q) cp $< $@
$(call Q_PROF_SN,watch) MONO_CFG_DIR=$(TOP) $(SYSTEM_SN) -q -R $@ $(PRODUCT_KEY_PATH)
$(WATCH_BUILD_DIR)/reference/System.Net.Http.pdb: $(WATCH_MONO_PATH)/mcs/class/lib/monotouch_watch/reference/System.Net.Http.pdb | $(WATCH_BUILD_DIR)/reference
$(WATCH_BUILD_DIR)/reference/System.Net.Http.pdb: $(MONO_PATH)/mcs/class/lib/monotouch_watch/reference/System.Net.Http.pdb | $(WATCH_BUILD_DIR)/reference
$(Q) cp $< $@
$(PROJECT_DIR)/xamwatch.csproj: xamwatch.tmpl.csproj Makefile $(wildcard $(TOP)/*.sources)

Просмотреть файл

@ -89,7 +89,6 @@ test.config: Makefile $(TOP)/Make.config
@echo "MONOTOUCH_PREFIX=$(abspath $(MONOTOUCH_PREFIX))" >> $@
@echo "IOS_DESTDIR=$(abspath $(IOS_DESTDIR))" >> $@
@echo "MAC_DESTDIR=$(abspath $(MAC_DESTDIR))" >> $@
@echo "WATCH_MONO_PATH=$(abspath $(WATCH_MONO_PATH))" >> $@
@echo "JENKINS_RESULTS_DIRECTORY=$(abspath $(JENKINS_RESULTS_DIRECTORY))" >> $@
@echo "INCLUDE_DEVICE=$(INCLUDE_DEVICE)" >> $@
@ -98,7 +97,6 @@ test-system.config:
@echo "MONOTOUCH_PREFIX=$(IOS_FRAMEWORK_DIR)/Versions/Current" >> $@
@echo "IOS_DESTDIR=/" >> $@
@echo "MAC_DESTDIR=/" >> $@
@echo "WATCH_MONO_PATH=$(abspath $(WATCH_MONO_PATH))" >> $@
@echo "JENKINS_RESULTS_DIRECTORY=$(abspath $(JENKINS_RESULTS_DIRECTORY))" >> $@
@echo "INCLUDE_DEVICE=$(INCLUDE_DEVICE)" >> $@

Просмотреть файл

@ -11,7 +11,6 @@ namespace xharness
{
public Harness Harness;
public string MonoPath { get { return Harness.MONO_PATH; } }
public string WatchMonoPath { get { return Harness.WATCH_MONO_PATH; } }
public string TestName;
static readonly Dictionary<string, string[]> ignored_tests = new Dictionary<string, string[]> {
@ -123,7 +122,7 @@ namespace xharness
var testName = TestName == "mscorlib" ? "corlib" : TestName;
var main_test_sources = Path.Combine (MonoPath, "mcs", "class", testName, testName + "_test.dll.sources");
var main_test_files = File.ReadAllLines (main_test_sources);
var watch_test_sources = Path.Combine (WatchMonoPath, "mcs", "class", testName, testName + "_test.dll.sources");
var watch_test_sources = Path.Combine (MonoPath, "mcs", "class", testName, testName + "_test.dll.sources");
var watch_test_files = File.ReadAllLines (watch_test_sources).Where ((arg) => !string.IsNullOrEmpty (arg));
var template_path = Path.Combine (Harness.RootDirectory, "bcl-test", TestName, TestName + ".csproj.template");
var csproj_input = File.ReadAllText (template_path);

Просмотреть файл

@ -73,7 +73,6 @@ namespace xharness
public string TodayContainerTemplate { get; set; }
public string TodayExtensionTemplate { get; set; }
public string MONO_PATH { get; set; } // Use same name as in Makefiles, so that a grep finds it.
public string WATCH_MONO_PATH { get; set; } // Use same name as in Makefiles, so that a grep finds it.
public string TVOS_MONO_PATH { get; set; } // Use same name as in Makefiles, so that a grep finds it.
public bool INCLUDE_IOS { get; set; }
public bool INCLUDE_TVOS { get; set; }
@ -209,7 +208,6 @@ namespace xharness
ParseConfigFiles ();
var src_root = Path.GetDirectoryName (Path.GetFullPath (RootDirectory));
MONO_PATH = Path.GetFullPath (Path.Combine (src_root, "external", "mono"));
WATCH_MONO_PATH = make_config ["WATCH_MONO_PATH"];
TVOS_MONO_PATH = MONO_PATH;
INCLUDE_IOS = make_config.ContainsKey ("INCLUDE_IOS") && !string.IsNullOrEmpty (make_config ["INCLUDE_IOS"]);
INCLUDE_TVOS = make_config.ContainsKey ("INCLUDE_TVOS") && !string.IsNullOrEmpty (make_config ["INCLUDE_TVOS"]);