You've already forked linux-packaging-mono
Imported Upstream version 5.14.0.78
Former-commit-id: 3494343bcc9ddb42b36b82dd9ae7b69e85e0229f
This commit is contained in:
parent
74b74abd9f
commit
19234507ba
@@ -10,7 +10,6 @@ net_4_5_dirs := \
|
||||
mono-service \
|
||||
mono-xsd \
|
||||
resgen \
|
||||
gacutil \
|
||||
wsdl \
|
||||
xbuild \
|
||||
csharp \
|
||||
|
@@ -5,6 +5,14 @@ include ../../build/rules.make
|
||||
PROGRAM = cil-stringreplacer.exe
|
||||
NO_INSTALL = yes
|
||||
|
||||
ifeq ($(PROFILE),basic)
|
||||
# It can be run using system .net during boostrap
|
||||
TARGET_NET_REFERENCE = v4.6
|
||||
# Trick to make it work during boostrap where it has to run with system
|
||||
# assemblies not the ones in lib/basic folder
|
||||
PROGRAM_USE_INTERMEDIATE_FILE = 1
|
||||
endif
|
||||
|
||||
LIB_REFS = System Mono.Cecil
|
||||
|
||||
ifdef MCS_MODE
|
||||
|
@@ -1,6 +1,7 @@
|
||||
../../../external/linker/linker/Linker/Pipeline.cs
|
||||
../../../external/linker/linker/Linker/AssemblyInfo.cs
|
||||
../../../external/linker/linker/Linker/AssemblyResolver.cs
|
||||
../../../external/linker/linker/Linker/AssemblyUtilities.cs
|
||||
../../../external/linker/linker/Linker/TypePreserve.cs
|
||||
../../../external/linker/linker/Linker/TypeReferenceExtensions.cs
|
||||
../../../external/linker/linker/Linker/Annotations.cs
|
||||
|
@@ -24,6 +24,8 @@ LIB_REFS = monodoc System System.Xml System.Core Mono.Cecil ICSharpCode.SharpZip
|
||||
LOCAL_MCS_FLAGS = $(MDOC_RESOURCES_COMMAND) $(MONODOC_RESOURCES_COMMAND)
|
||||
PROGRAM = $(topdir)/class/lib/$(PROFILE)/mdoc.exe
|
||||
PROGRAM_DEPS = $(topdir)/class/lib/$(PROFILE)/monodoc.dll
|
||||
MSCORLIB = -r:$(topdir)/class/lib/$(PROFILE)/mscorlib.dll
|
||||
|
||||
|
||||
MDOC_TEST_FILES = \
|
||||
Test/CLILibraryTypes.dtd \
|
||||
@@ -77,51 +79,51 @@ cleanup:
|
||||
-rm -f monodocer1.exe*
|
||||
|
||||
Test/DocTest-addNonGeneric.dll:
|
||||
$(CSCOMPILE) $(TEST_CSCFLAGS) -unsafe -target:library -out:$@ Test/DocTest-addNonGeneric.cs
|
||||
$(CSCOMPILE) $(TEST_CSCFLAGS) $(MSCORLIB) -unsafe -target:library -out:$@ Test/DocTest-addNonGeneric.cs
|
||||
|
||||
Test/DocTest-addNonGeneric-v2.dll:
|
||||
$(CSCOMPILE) $(TEST_CSCFLAGS) -unsafe -target:library -out:$@ Test/DocTest-addNonGeneric.cs /define:V2
|
||||
$(CSCOMPILE) $(TEST_CSCFLAGS) $(MSCORLIB) -unsafe -target:library -out:$@ Test/DocTest-addNonGeneric.cs /define:V2
|
||||
|
||||
Test/DocTest-DropNS-classic-secondary.dll:
|
||||
@echo $(value @)
|
||||
$(CSCOMPILE) $(TEST_CSCFLAGS) -unsafe -target:library -out:$@ Test/DocTest-DropNS-classic-secondary.cs
|
||||
$(CSCOMPILE) $(TEST_CSCFLAGS) $(MSCORLIB) -unsafe -target:library -out:$@ Test/DocTest-DropNS-classic-secondary.cs
|
||||
|
||||
Test/DocTest-DropNS-classic.dll:
|
||||
@echo $(value @)
|
||||
$(CSCOMPILE) $(TEST_CSCFLAGS) -unsafe -target:library -out:$@ Test/DocTest-DropNS-classic.cs
|
||||
$(CSCOMPILE) $(TEST_CSCFLAGS) $(MSCORLIB) -unsafe -target:library -out:$@ Test/DocTest-DropNS-classic.cs
|
||||
|
||||
Test/DocTest-DropNS-unified.dll:
|
||||
$(CSCOMPILE) $(TEST_CSCFLAGS) -unsafe -target:library -out:$@ Test/DocTest-DropNS-unified.cs
|
||||
$(CSCOMPILE) $(TEST_CSCFLAGS) $(MSCORLIB) -unsafe -target:library -out:$@ Test/DocTest-DropNS-unified.cs
|
||||
|
||||
Test/DocTest-DropNS-unified-multitest.dll:
|
||||
rm -f $@
|
||||
$(CSCOMPILE) $(TEST_CSCFLAGS) -unsafe -target:library -out:$@ Test/DocTest-DropNS-unified.cs /define:MULTITEST
|
||||
$(CSCOMPILE) $(TEST_CSCFLAGS) $(MSCORLIB) -unsafe -target:library -out:$@ Test/DocTest-DropNS-unified.cs /define:MULTITEST
|
||||
|
||||
Test/DocTest-DropNS-classic-multitest.dll:
|
||||
rm -f $@
|
||||
$(CSCOMPILE) $(TEST_CSCFLAGS) -unsafe -target:library -out:$@ Test/DocTest-DropNS-classic.cs /define:MULTITEST
|
||||
$(CSCOMPILE) $(TEST_CSCFLAGS) $(MSCORLIB) -unsafe -target:library -out:$@ Test/DocTest-DropNS-classic.cs /define:MULTITEST
|
||||
|
||||
Test/DocTest-DropNS-unified-deletetest.dll:
|
||||
rm -f Test/DocTest-DropNS-unified-deletetest.dll
|
||||
$(CSCOMPILE) $(TEST_CSCFLAGS) -unsafe -target:library -out:$@ Test/DocTest-DropNS-unified.cs /define:DELETETEST
|
||||
$(CSCOMPILE) $(TEST_CSCFLAGS) $(MSCORLIB) -unsafe -target:library -out:$@ Test/DocTest-DropNS-unified.cs /define:DELETETEST
|
||||
|
||||
Test/DocTest-DropNS-unified-deletetest-V2.dll:
|
||||
rm -f Test/DocTest-DropNS-unified-deletetest.dll
|
||||
$(CSCOMPILE) $(TEST_CSCFLAGS) -unsafe -target:library -out:Test/DocTest-DropNS-unified-deletetest.dll Test/DocTest-DropNS-unified.cs /define:DELETETEST,V2
|
||||
$(CSCOMPILE) $(TEST_CSCFLAGS) $(MSCORLIB) -unsafe -target:library -out:Test/DocTest-DropNS-unified-deletetest.dll Test/DocTest-DropNS-unified.cs /define:DELETETEST,V2
|
||||
|
||||
Test/DocTest-DropNS-classic-deletetest.dll:
|
||||
rm -f Test/DocTest-DropNS-classic-deletetest.dll
|
||||
$(CSCOMPILE) $(TEST_CSCFLAGS) -unsafe -target:library -out:$@ Test/DocTest-DropNS-classic.cs /define:DELETETEST
|
||||
$(CSCOMPILE) $(TEST_CSCFLAGS) $(MSCORLIB) -unsafe -target:library -out:$@ Test/DocTest-DropNS-classic.cs /define:DELETETEST
|
||||
|
||||
Test/DocTest-DropNS-classic-deletetest-V2.dll:
|
||||
rm -f Test/DocTest-DropNS-classic-deletetest.dll
|
||||
$(CSCOMPILE) $(TEST_CSCFLAGS) -unsafe -target:library -out:Test/DocTest-DropNS-classic-deletetest.dll Test/DocTest-DropNS-classic.cs /define:DELETETEST,V2
|
||||
$(CSCOMPILE) $(TEST_CSCFLAGS) $(MSCORLIB) -unsafe -target:library -out:Test/DocTest-DropNS-classic-deletetest.dll Test/DocTest-DropNS-classic.cs /define:DELETETEST,V2
|
||||
|
||||
Test/DocTest.dll:
|
||||
$(CSCOMPILE) $(TEST_CSCFLAGS) -unsafe -target:library -out:$@ Test/DocTest.cs -r:$(topdir)/class/lib/$(PROFILE)/System.Core.dll -r:$(topdir)/class/lib/$(PROFILE)/Microsoft.CSharp.dll
|
||||
$(CSCOMPILE) $(TEST_CSCFLAGS) $(MSCORLIB) -unsafe -target:library -out:$@ Test/DocTest.cs -r:$(topdir)/class/lib/$(PROFILE)/System.Core.dll -r:$(topdir)/class/lib/$(PROFILE)/Microsoft.CSharp.dll
|
||||
|
||||
Test/DocTest-InternalInterface.dll:
|
||||
$(CSCOMPILE) $(TEST_CSCFLAGS) -unsafe -target:library -out:$@ Test/DocTest-InternalInterface.cs
|
||||
$(CSCOMPILE) $(TEST_CSCFLAGS) $(MSCORLIB) -unsafe -target:library -out:$@ Test/DocTest-InternalInterface.cs
|
||||
|
||||
Test/DocTest.dll-v1:
|
||||
-rm -f Test/DocTest.cs
|
||||
@@ -137,7 +139,7 @@ Test/DocTest.dll-v2:
|
||||
$(MAKE) TEST_CSCFLAGS=$(TEST_CSCFLAGS) Test/DocTest.dll
|
||||
|
||||
Test/DocTest-enumerations.dll:
|
||||
$(CSCOMPILE) $(TEST_CSCFLAGS) -unsafe -target:library -out:$@ Test/DocTest-enumerations.cs
|
||||
$(CSCOMPILE) $(TEST_CSCFLAGS) $(MSCORLIB) -unsafe -target:library -out:$@ Test/DocTest-enumerations.cs
|
||||
|
||||
check-monodocer-addNonGeneric: $(PROGRAM)
|
||||
-rm -Rf Test/en.actual
|
||||
|
@@ -48,8 +48,19 @@ class MakeBundle {
|
||||
static bool keeptemp = false;
|
||||
static bool compile_only = false;
|
||||
static bool static_link = false;
|
||||
static string config_file = null;
|
||||
|
||||
// Points to the $sysconfig/mono/4.5/machine.config, which contains System.Configuration settings
|
||||
static string machine_config_file = null;
|
||||
|
||||
// By default, we automatically bundle a machine-config, use this to turn off the behavior.
|
||||
static bool no_machine_config = false;
|
||||
|
||||
// Points to the $sysconfig/mono/config file, contains <dllmap> and others
|
||||
static string config_file = null;
|
||||
|
||||
// By default, we automatically bundle the above config file, use this to turn off the behavior.
|
||||
static bool no_config = false;
|
||||
|
||||
static string config_dir = null;
|
||||
static string style = "linux";
|
||||
static bool bundled_header = false;
|
||||
@@ -65,7 +76,7 @@ class MakeBundle {
|
||||
static string fetch_target = null;
|
||||
static bool custom_mode = true;
|
||||
static string embedded_options = null;
|
||||
|
||||
|
||||
static string runtime = null;
|
||||
|
||||
static bool aot_compile = false;
|
||||
@@ -148,7 +159,7 @@ class MakeBundle {
|
||||
return 1;
|
||||
}
|
||||
if (sdk_path != null || runtime != null)
|
||||
Error ("You can only specify one of --runtime, --sdk or --cross");
|
||||
Error ("You can only specify one of --runtime, --sdk or --cross {sdk_path}/{runtime}");
|
||||
custom_mode = false;
|
||||
autodeps = true;
|
||||
cross_target = args [++i];
|
||||
@@ -289,6 +300,12 @@ class MakeBundle {
|
||||
if (!quiet)
|
||||
Console.WriteLine ("WARNING:\n Check that the machine.config file you are bundling\n doesn't contain sensitive information specific to this machine.");
|
||||
break;
|
||||
case "--no-machine-config":
|
||||
no_machine_config = true;
|
||||
break;
|
||||
case "--no-config":
|
||||
no_config = true;
|
||||
break;
|
||||
case "--config-dir":
|
||||
if (i+1 == top) {
|
||||
Help ();
|
||||
@@ -523,6 +540,18 @@ class MakeBundle {
|
||||
if (!Directory.Exists (lib_path))
|
||||
Error ($"The SDK location does not contain a {path}/lib/mono/4.5 directory");
|
||||
link_paths.Add (lib_path);
|
||||
if (machine_config_file == null && !no_machine_config) {
|
||||
machine_config_file = Path.Combine (path, "etc", "mono", "4.5", "machine.config");
|
||||
if (!File.Exists (machine_config_file)){
|
||||
Error ($"Could not locate the file machine.config file at ${machine_config_file} use --machine-config FILE or --no-machine-config");
|
||||
}
|
||||
}
|
||||
if (config_file == null && !no_config) {
|
||||
config_file = Path.Combine (path, "etc", "mono", "config");
|
||||
if (!File.Exists (config_file)){
|
||||
Error ($"Could not locate the file config file at ${config_file} use --config FILE or --no-config");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static string targets_dir = Path.Combine (Environment.GetFolderPath (Environment.SpecialFolder.Personal), ".mono", "targets");
|
||||
@@ -2463,7 +2492,15 @@ void mono_register_config_for_assembly (const char* assembly_name, cons
|
||||
static bool Target64BitApplication ()
|
||||
{
|
||||
// Should probably handled the --cross and sdk parameters.
|
||||
return Environment.Is64BitProcess;
|
||||
string targetArchitecture = GetEnv ("VSCMD_ARG_TGT_ARCH", "");
|
||||
if (targetArchitecture.Length != 0) {
|
||||
if (string.Compare (targetArchitecture, "x64", StringComparison.OrdinalIgnoreCase) == 0)
|
||||
return true;
|
||||
else
|
||||
return false;
|
||||
} else {
|
||||
return Environment.Is64BitProcess;
|
||||
}
|
||||
}
|
||||
|
||||
static string GetMonoDir ()
|
||||
@@ -2560,6 +2597,13 @@ void mono_register_config_for_assembly (const char* assembly_name, cons
|
||||
linkerArgs.Add ("oldnames.lib");
|
||||
}
|
||||
|
||||
if (MakeBundle.compress) {
|
||||
if (staticLinkMono)
|
||||
linkerArgs.Add("zlibstatic.lib");
|
||||
else
|
||||
linkerArgs.Add("zlib.lib");
|
||||
}
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
|
@@ -6,11 +6,11 @@ PROGRAM = mono-service.exe
|
||||
|
||||
PROGRAM_SNK = ../../class/mono.snk
|
||||
|
||||
include ../../build/executable.make
|
||||
|
||||
LOCAL_MCS_FLAGS = -unsafe -publicsign -keyfile:../../class/mono.snk
|
||||
LIB_REFS = System.ServiceProcess Mono.Posix System
|
||||
|
||||
include ../../build/executable.make
|
||||
|
||||
# Copied from library.make
|
||||
|
||||
# -- begin --
|
||||
|
@@ -45,7 +45,7 @@ PREPARE_OUTDIR = @\
|
||||
mkdir -p $(MSYM_DIR);
|
||||
|
||||
COMPILE = \
|
||||
$(CSCOMPILE) $(TEST_CS) -out:$(TEST_EXE); \
|
||||
$(CSCOMPILE) $(TEST_CS) -r:$(LIB_PATH)/mscorlib.dll -out:$(TEST_EXE); \
|
||||
$(MONO) $(LIB_PATH)/$(PROGRAM) store-symbols $(MSYM_DIR) $(OUT_DIR); \
|
||||
$(MONO) $(LIB_PATH)/$(PROGRAM) store-symbols $(MSYM_DIR) $(LIB_PATH);
|
||||
|
||||
|
@@ -60,10 +60,10 @@ clean-local:
|
||||
dist-local: dist-default
|
||||
|
||||
sn.exe $(topdir)/class/lib/$(PROFILE)/sn.exe: $(SN_SOURCES)
|
||||
$(CSCOMPILE) -r:$(topdir)/class/lib/$(PROFILE)/Mono.Security.dll /out:$@ $(SN_SOURCES)
|
||||
$(CSCOMPILE) -r:$(topdir)/class/lib/$(PROFILE)/mscorlib.dll -r:$(topdir)/class/lib/$(PROFILE)/Mono.Security.dll /out:$@ $(SN_SOURCES)
|
||||
|
||||
permview.exe: permview.cs
|
||||
$(CSCOMPILE) $^ $(HELPER_SOURCES) -r:$(topdir)/class/lib/$(PROFILE)/Mono.Cecil.dll
|
||||
$(CSCOMPILE) $^ $(HELPER_SOURCES) -r:$(topdir)/class/lib/$(PROFILE)/mscorlib.dll -r:$(topdir)/class/lib/$(PROFILE)/Mono.Cecil.dll
|
||||
|
||||
%.exe: %.cs $(HELPER_SOURCES)
|
||||
$(CSCOMPILE) -r:$(topdir)/class/lib/$(PROFILE)/Mono.Security.dll -r:$(topdir)/class/lib/$(PROFILE)/System.dll $^
|
||||
$(CSCOMPILE) -r:$(topdir)/class/lib/$(PROFILE)/mscorlib.dll -r:$(topdir)/class/lib/$(PROFILE)/Mono.Security.dll -r:$(topdir)/class/lib/$(PROFILE)/System.dll $^
|
||||
|
Reference in New Issue
Block a user