Import rpm: c8s
This commit is contained in:
commit
3f493f6700
2
.gitignore
vendored
Normal file
2
.gitignore
vendored
Normal file
@ -0,0 +1,2 @@
|
||||
SOURCES/dotnet-v2.1.524-SDK.tar.gz
|
||||
/dotnet-v2.1.524-SDK.tar.gz
|
12
build-corefx-disable-werror.patch
Normal file
12
build-corefx-disable-werror.patch
Normal file
@ -0,0 +1,12 @@
|
||||
diff --git a/src/Native/Unix/CMakeLists.txt b/src/Native/Unix/CMakeLists.txt
|
||||
index 7d804a1e54..717c2718d7 100644
|
||||
--- a/src/Native/Unix/CMakeLists.txt
|
||||
+++ b/src/Native/Unix/CMakeLists.txt
|
||||
@@ -25,7 +25,6 @@ add_compile_options(-fPIC)
|
||||
add_compile_options(-I${CMAKE_CURRENT_SOURCE_DIR}/Common)
|
||||
add_compile_options(-I${CMAKE_CURRENT_BINARY_DIR}/Common)
|
||||
add_compile_options(-g)
|
||||
-add_compile_options(-Werror)
|
||||
if (CMAKE_CXX_COMPILER_VERSION VERSION_LESS 3.5)
|
||||
add_compile_options(-Wno-unreachable-code)
|
||||
endif ()
|
136
check-debug-symbols.py
Executable file
136
check-debug-symbols.py
Executable file
@ -0,0 +1,136 @@
|
||||
#!/usr/bin/python3
|
||||
|
||||
"""
|
||||
Check debug symbols are present in shared object and can identify
|
||||
code.
|
||||
|
||||
It starts scanning from a directory and recursively scans all ELF
|
||||
files found in it for various symbols to ensure all debuginfo is
|
||||
present and nothing has been stripped.
|
||||
|
||||
Usage:
|
||||
|
||||
./check-debug-symbols /path/of/dir/to/scan/
|
||||
|
||||
|
||||
Example:
|
||||
|
||||
./check-debug-symbols /usr/lib64
|
||||
"""
|
||||
|
||||
# This technique was explained to me by Mark Wielaard (mjw).
|
||||
|
||||
import collections
|
||||
import os
|
||||
import re
|
||||
import subprocess
|
||||
import sys
|
||||
|
||||
ScanResult = collections.namedtuple('ScanResult',
|
||||
'file_name debug_info debug_abbrev file_symbols gnu_debuglink')
|
||||
|
||||
|
||||
def scan_file(file):
|
||||
"Scan the provided file and return a ScanResult containing results of the scan."
|
||||
|
||||
# Test for .debug_* sections in the shared object. This is the main test.
|
||||
# Stripped objects will not contain these.
|
||||
readelf_S_result = subprocess.run(['eu-readelf', '-S', file],
|
||||
stdout=subprocess.PIPE, encoding='utf-8', check=True)
|
||||
has_debug_info = any(line for line in readelf_S_result.stdout.split('\n') if '] .debug_info' in line)
|
||||
|
||||
has_debug_abbrev = any(line for line in readelf_S_result.stdout.split('\n') if '] .debug_abbrev' in line)
|
||||
|
||||
# Test FILE symbols. These will most likely be removed by anyting that
|
||||
# manipulates symbol tables because it's generally useless. So a nice test
|
||||
# that nothing has messed with symbols.
|
||||
def contains_file_symbols(line):
|
||||
parts = line.split()
|
||||
if len(parts) < 8:
|
||||
return False
|
||||
return \
|
||||
parts[2] == '0' and parts[3] == 'FILE' and parts[4] == 'LOCAL' and parts[5] == 'DEFAULT' and \
|
||||
parts[6] == 'ABS' and re.match(r'((.*/)?[-_a-zA-Z0-9]+\.(c|cc|cpp|cxx))?', parts[7])
|
||||
|
||||
readelf_s_result = subprocess.run(["eu-readelf", '-s', file],
|
||||
stdout=subprocess.PIPE, encoding='utf-8', check=True)
|
||||
has_file_symbols = any(line for line in readelf_s_result.stdout.split('\n') if contains_file_symbols(line))
|
||||
|
||||
# Test that there are no .gnu_debuglink sections pointing to another
|
||||
# debuginfo file. There shouldn't be any debuginfo files, so the link makes
|
||||
# no sense either.
|
||||
has_gnu_debuglink = any(line for line in readelf_s_result.stdout.split('\n') if '] .gnu_debuglink' in line)
|
||||
|
||||
return ScanResult(file, has_debug_info, has_debug_abbrev, has_file_symbols, has_gnu_debuglink)
|
||||
|
||||
def is_elf(file):
|
||||
result = subprocess.run(['file', file], stdout=subprocess.PIPE, encoding='utf-8', check=True)
|
||||
return re.search('ELF 64-bit LSB (?:executable|shared object)', result.stdout)
|
||||
|
||||
def scan_file_if_sensible(file):
|
||||
if is_elf(file):
|
||||
# print(file)
|
||||
return scan_file(file)
|
||||
return None
|
||||
|
||||
def scan_dir(dir):
|
||||
results = []
|
||||
for root, _, files in os.walk(dir):
|
||||
for name in files:
|
||||
result = scan_file_if_sensible(os.path.join(root, name))
|
||||
if result:
|
||||
results.append(result)
|
||||
return results
|
||||
|
||||
def scan(file):
|
||||
file = os.path.abspath(file)
|
||||
if os.path.isdir(file):
|
||||
return scan_dir(file)
|
||||
elif os.path.isfile(file):
|
||||
return scan_file_if_sensible(file)
|
||||
|
||||
def is_bad_result(result):
|
||||
return not result.debug_info or not result.debug_abbrev or not result.file_symbols or result.gnu_debuglink
|
||||
|
||||
def print_scan_results(results, verbose):
|
||||
# print(results)
|
||||
for result in results:
|
||||
file_name = result.file_name
|
||||
found_issue = False
|
||||
if not result.debug_info:
|
||||
found_issue = True
|
||||
print('error: missing .debug_info section in', file_name)
|
||||
if not result.debug_abbrev:
|
||||
found_issue = True
|
||||
print('error: missing .debug_abbrev section in', file_name)
|
||||
if not result.file_symbols:
|
||||
found_issue = True
|
||||
print('error: missing FILE symbols in', file_name)
|
||||
if result.gnu_debuglink:
|
||||
found_issue = True
|
||||
print('error: unexpected .gnu_debuglink section in', file_name)
|
||||
if verbose and not found_issue:
|
||||
print('OK: ', file_name)
|
||||
|
||||
def main(args):
|
||||
verbose = False
|
||||
files = []
|
||||
for arg in args:
|
||||
if arg == '--verbose' or arg == '-v':
|
||||
verbose = True
|
||||
else:
|
||||
files.append(arg)
|
||||
|
||||
results = []
|
||||
for file in files:
|
||||
results.extend(scan(file))
|
||||
|
||||
print_scan_results(results, verbose)
|
||||
|
||||
if any(is_bad_result(result) for result in results):
|
||||
return 1
|
||||
return 0
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
sys.exit(main(sys.argv[1:]))
|
18
cli-telemetry-optout.patch
Normal file
18
cli-telemetry-optout.patch
Normal file
@ -0,0 +1,18 @@
|
||||
diff --git a/src/dotnet/Program.cs b/src/dotnet/Program.cs
|
||||
index de1ebb9e6..6bbf479de 100644
|
||||
--- a/src/dotnet/Program.cs
|
||||
+++ b/src/dotnet/Program.cs
|
||||
@@ -28,6 +28,13 @@ public class Program
|
||||
|
||||
public static int Main(string[] args)
|
||||
{
|
||||
+ // opt out of telemetry by default if the env var is unset
|
||||
+ string telemetryValue = Environment.GetEnvironmentVariable("DOTNET_CLI_TELEMETRY_OPTOUT");
|
||||
+ if (String.IsNullOrEmpty(telemetryValue))
|
||||
+ {
|
||||
+ Environment.SetEnvironmentVariable("DOTNET_CLI_TELEMETRY_OPTOUT", "1");
|
||||
+ }
|
||||
+
|
||||
DebugHelper.HandleDebugSwitch(ref args);
|
||||
|
||||
new MulticoreJitActivator().TryActivateMulticoreJit();
|
48
core-setup-4510-commit-id.patch
Normal file
48
core-setup-4510-commit-id.patch
Normal file
@ -0,0 +1,48 @@
|
||||
From e02ee86364b9db3edc298a6a081004aa07473d09 Mon Sep 17 00:00:00 2001
|
||||
From: Omair Majid <omajid@redhat.com>
|
||||
Date: Wed, 29 Aug 2018 17:03:25 -0400
|
||||
Subject: [PATCH] Allow setting the commit id using /p:LatestCommit
|
||||
|
||||
This is similar to how CommitCount is already supported.
|
||||
|
||||
This lets consumers who are building outside a git repo, such as
|
||||
source-build, set a commit id which is displayed by `dotnet --info`
|
||||
and `strings dotnet | grep '@(#)'`.
|
||||
|
||||
See: https://github.com/dotnet/source-build/issues/651
|
||||
See: https://github.com/dotnet/cli/pull/5945
|
||||
---
|
||||
dir.targets | 9 +++++----
|
||||
1 file changed, 5 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/dir.targets b/dir.targets
|
||||
index 8d34872c6..59dc1ebde 100644
|
||||
--- a/dir.targets
|
||||
+++ b/dir.targets
|
||||
@@ -17,7 +17,8 @@
|
||||
<Exec Command="$(DotnetToolCommand) build $(MSBuildThisFileDirectory)tools-local/tasks/core-setup.tasks.csproj" />
|
||||
</Target>
|
||||
|
||||
- <Target Name="GetLatestCommitHash">
|
||||
+ <Target Name="GetLatestCommitHash"
|
||||
+ Condition="'$(LatestCommit)' == ''">
|
||||
<!-- Get the latest commit hash -->
|
||||
<Exec Command="git rev-parse HEAD 2>&1" StandardOutputImportance="Low" IgnoreExitCode="true" IgnoreStandardErrorWarningFormat="true" ConsoleToMSBuild="true">
|
||||
<Output TaskParameter="ConsoleOutput" PropertyName="LatestCommit" />
|
||||
@@ -29,13 +30,13 @@
|
||||
</PropertyGroup>
|
||||
</Target>
|
||||
|
||||
- <Target Name="GetCommitCount">
|
||||
+ <Target Name="GetCommitCount"
|
||||
+ Condition="'$(CommitCount)' == ''">
|
||||
<Exec Command="git rev-list --count HEAD"
|
||||
StandardOutputImportance="Low"
|
||||
IgnoreExitCode="true"
|
||||
IgnoreStandardErrorWarningFormat="true"
|
||||
- ConsoleToMSBuild="true"
|
||||
- Condition="'$(CommitCount)' == ''">
|
||||
+ ConsoleToMSBuild="true">
|
||||
<Output TaskParameter="ConsoleOutput" PropertyName="CommitCount" />
|
||||
<Output TaskParameter="ExitCode" PropertyName="CommitCountExitCode" />
|
||||
</Exec>
|
11
core-setup-pie.patch
Normal file
11
core-setup-pie.patch
Normal file
@ -0,0 +1,11 @@
|
||||
--- a/src/corehost/cli/exe/exe.cmake
|
||||
+++ b/src/corehost/cli/exe/exe.cmake
|
||||
@@ -44,6 +44,8 @@
|
||||
|
||||
add_executable(${DOTNET_HOST_EXE_NAME} ${SOURCES} ${RESOURCES})
|
||||
|
||||
+SET_TARGET_PROPERTIES(${DOTNET_HOST_EXE_NAME} PROPERTIES LINK_FLAGS -pie)
|
||||
+
|
||||
if(NOT WIN32)
|
||||
disable_pax_mprotect(${DOTNET_HOST_EXE_NAME})
|
||||
endif()
|
402
coreclr-libunwind-fno-common.patch
Normal file
402
coreclr-libunwind-fno-common.patch
Normal file
@ -0,0 +1,402 @@
|
||||
From 29e17d8d2ccbca07c423e3089a6d5ae8a1c9cb6e Mon Sep 17 00:00:00 2001
|
||||
From: Yichao Yu <yyc1992@gmail.com>
|
||||
Date: Tue, 31 Mar 2020 00:43:32 -0400
|
||||
Subject: [PATCH] Fix compilation with -fno-common.
|
||||
|
||||
Making all other archs consistent with IA64 which should not have this problem.
|
||||
Also move the FIXME to the correct place.
|
||||
|
||||
Also add some minimum comments about this...
|
||||
---
|
||||
src/aarch64/Ginit.c | 15 +++++++--------
|
||||
src/arm/Ginit.c | 15 +++++++--------
|
||||
src/coredump/_UPT_get_dyn_info_list_addr.c | 5 +++++
|
||||
src/hppa/Ginit.c | 15 +++++++--------
|
||||
src/ia64/Ginit.c | 1 +
|
||||
src/mi/Gfind_dynamic_proc_info.c | 1 +
|
||||
src/mips/Ginit.c | 15 +++++++--------
|
||||
src/ppc32/Ginit.c | 11 +++++++----
|
||||
src/ppc64/Ginit.c | 11 +++++++----
|
||||
src/ptrace/_UPT_get_dyn_info_list_addr.c | 5 +++++
|
||||
src/s390x/Ginit.c | 15 +++++++--------
|
||||
src/sh/Ginit.c | 15 +++++++--------
|
||||
src/tilegx/Ginit.c | 15 +++++++--------
|
||||
src/x86/Ginit.c | 15 +++++++--------
|
||||
src/x86_64/Ginit.c | 15 +++++++--------
|
||||
15 files changed, 89 insertions(+), 80 deletions(-)
|
||||
|
||||
diff --git a/src/pal/src/libunwind/src/aarch64/Ginit.c b/src/pal/src/libunwind/src/aarch64/Ginit.c
|
||||
index dec235c82..35389762f 100644
|
||||
--- a/src/pal/src/libunwind/src/aarch64/Ginit.c
|
||||
+++ b/src/pal/src/libunwind/src/aarch64/Ginit.c
|
||||
@@ -61,13 +61,6 @@ tdep_uc_addr (unw_tdep_context_t *uc, int reg)
|
||||
|
||||
# endif /* UNW_LOCAL_ONLY */
|
||||
|
||||
-HIDDEN unw_dyn_info_list_t _U_dyn_info_list;
|
||||
-
|
||||
-/* XXX fix me: there is currently no way to locate the dyn-info list
|
||||
- by a remote unwinder. On ia64, this is done via a special
|
||||
- unwind-table entry. Perhaps something similar can be done with
|
||||
- DWARF2 unwind info. */
|
||||
-
|
||||
static void
|
||||
put_unwind_info (unw_addr_space_t as, unw_proc_info_t *proc_info, void *arg)
|
||||
{
|
||||
@@ -78,7 +71,13 @@ static int
|
||||
get_dyn_info_list_addr (unw_addr_space_t as, unw_word_t *dyn_info_list_addr,
|
||||
void *arg)
|
||||
{
|
||||
- *dyn_info_list_addr = (unw_word_t) &_U_dyn_info_list;
|
||||
+#ifndef UNW_LOCAL_ONLY
|
||||
+# pragma weak _U_dyn_info_list_addr
|
||||
+ if (!_U_dyn_info_list_addr)
|
||||
+ return -UNW_ENOINFO;
|
||||
+#endif
|
||||
+ // Access the `_U_dyn_info_list` from `LOCAL_ONLY` library, i.e. libunwind.so.
|
||||
+ *dyn_info_list_addr = _U_dyn_info_list_addr ();
|
||||
return 0;
|
||||
}
|
||||
|
||||
diff --git a/src/pal/src/libunwind/src/arm/Ginit.c b/ssrc/pal/src/libunwind/src/arm/Ginit.c
|
||||
index 2720d063a..0bac0d72d 100644
|
||||
--- a/src/pal/src/libunwind/src/arm/Ginit.c
|
||||
+++ b/src/pal/src/libunwind/src/arm/Ginit.c
|
||||
@@ -57,18 +57,17 @@ tdep_uc_addr (unw_tdep_context_t *uc, int reg)
|
||||
|
||||
# endif /* UNW_LOCAL_ONLY */
|
||||
|
||||
-HIDDEN unw_dyn_info_list_t _U_dyn_info_list;
|
||||
-
|
||||
-/* XXX fix me: there is currently no way to locate the dyn-info list
|
||||
- by a remote unwinder. On ia64, this is done via a special
|
||||
- unwind-table entry. Perhaps something similar can be done with
|
||||
- DWARF2 unwind info. */
|
||||
-
|
||||
static int
|
||||
get_dyn_info_list_addr (unw_addr_space_t as, unw_word_t *dyn_info_list_addr,
|
||||
void *arg)
|
||||
{
|
||||
- *dyn_info_list_addr = (unw_word_t) &_U_dyn_info_list;
|
||||
+#ifndef UNW_LOCAL_ONLY
|
||||
+# pragma weak _U_dyn_info_list_addr
|
||||
+ if (!_U_dyn_info_list_addr)
|
||||
+ return -UNW_ENOINFO;
|
||||
+#endif
|
||||
+ // Access the `_U_dyn_info_list` from `LOCAL_ONLY` library, i.e. libunwind.so.
|
||||
+ *dyn_info_list_addr = _U_dyn_info_list_addr ();
|
||||
return 0;
|
||||
}
|
||||
|
||||
diff --git a/src/pal/src/libunwind/src/coredump/_UPT_get_dyn_info_list_addr.c b/src/pal/src/libunwind/src/coredump/_UPT_get_dyn_info_list_addr.c
|
||||
index 0d1190556..739ed0569 100644
|
||||
--- a/src/pal/src/libunwind/src/coredump/_UPT_get_dyn_info_list_addr.c
|
||||
+++ b/src/pal/src/libunwind/src/coredump/_UPT_get_dyn_info_list_addr.c
|
||||
@@ -74,6 +74,11 @@ get_list_addr (unw_addr_space_t as, unw_word_t *dil_addr, void *arg,
|
||||
|
||||
#else
|
||||
|
||||
+/* XXX fix me: there is currently no way to locate the dyn-info list
|
||||
+ by a remote unwinder. On ia64, this is done via a special
|
||||
+ unwind-table entry. Perhaps something similar can be done with
|
||||
+ DWARF2 unwind info. */
|
||||
+
|
||||
static inline int
|
||||
get_list_addr (unw_addr_space_t as, unw_word_t *dil_addr, void *arg,
|
||||
int *countp)
|
||||
diff --git a/src/pal/src/libunwind/src/hppa/Ginit.c b/src/pal/src/libunwind/src/hppa/Ginit.c
|
||||
index 461e4b93d..265455a68 100644
|
||||
--- a/src/pal/src/libunwind/src/hppa/Ginit.c
|
||||
+++ b/src/pal/src/libunwind/src/hppa/Ginit.c
|
||||
@@ -64,13 +64,6 @@ _Uhppa_uc_addr (ucontext_t *uc, int reg)
|
||||
|
||||
# endif /* UNW_LOCAL_ONLY */
|
||||
|
||||
-HIDDEN unw_dyn_info_list_t _U_dyn_info_list;
|
||||
-
|
||||
-/* XXX fix me: there is currently no way to locate the dyn-info list
|
||||
- by a remote unwinder. On ia64, this is done via a special
|
||||
- unwind-table entry. Perhaps something similar can be done with
|
||||
- DWARF2 unwind info. */
|
||||
-
|
||||
static void
|
||||
put_unwind_info (unw_addr_space_t as, unw_proc_info_t *proc_info, void *arg)
|
||||
{
|
||||
@@ -81,7 +74,13 @@ static int
|
||||
get_dyn_info_list_addr (unw_addr_space_t as, unw_word_t *dyn_info_list_addr,
|
||||
void *arg)
|
||||
{
|
||||
- *dyn_info_list_addr = (unw_word_t) &_U_dyn_info_list;
|
||||
+#ifndef UNW_LOCAL_ONLY
|
||||
+# pragma weak _U_dyn_info_list_addr
|
||||
+ if (!_U_dyn_info_list_addr)
|
||||
+ return -UNW_ENOINFO;
|
||||
+#endif
|
||||
+ // Access the `_U_dyn_info_list` from `LOCAL_ONLY` library, i.e. libunwind.so.
|
||||
+ *dyn_info_list_addr = _U_dyn_info_list_addr ();
|
||||
return 0;
|
||||
}
|
||||
|
||||
diff --git a/src/pal/src/libunwind/src/ia64/Ginit.c b/src/pal/src/libunwind/src/ia64/Ginit.c
|
||||
index b09a2ad57..8601bb3ca 100644
|
||||
--- a/src/pal/src/libunwind/src/ia64/Ginit.c
|
||||
+++ b/src/pal/src/libunwind/src/ia64/Ginit.c
|
||||
@@ -68,6 +68,7 @@ get_dyn_info_list_addr (unw_addr_space_t as, unw_word_t *dyn_info_list_addr,
|
||||
if (!_U_dyn_info_list_addr)
|
||||
return -UNW_ENOINFO;
|
||||
#endif
|
||||
+ // Access the `_U_dyn_info_list` from `LOCAL_ONLY` library, i.e. libunwind.so.
|
||||
*dyn_info_list_addr = _U_dyn_info_list_addr ();
|
||||
return 0;
|
||||
}
|
||||
diff --git a/src/pal/src/libunwind/src/mi/Gfind_dynamic_proc_info.c b/src/pal/src/libunwind/src/mi/Gfind_dynamic_proc_info.c
|
||||
index 98d350128..2e7c62e5e 100644
|
||||
--- a/src/pal/src/libunwind/src/mi/Gfind_dynamic_proc_info.c
|
||||
+++ b/src/pal/src/libunwind/src/mi/Gfind_dynamic_proc_info.c
|
||||
@@ -49,6 +49,7 @@ local_find_proc_info (unw_addr_space_t as, unw_word_t ip, unw_proc_info_t *pi,
|
||||
return -UNW_ENOINFO;
|
||||
#endif
|
||||
|
||||
+ // Access the `_U_dyn_info_list` from `LOCAL_ONLY` library, i.e. libunwind.so.
|
||||
list = (unw_dyn_info_list_t *) (uintptr_t) _U_dyn_info_list_addr ();
|
||||
for (di = list->first; di; di = di->next)
|
||||
if (ip >= di->start_ip && ip < di->end_ip)
|
||||
diff --git a/src/pal/src/libunwind/src/mips/Ginit.c b/src/pal/src/libunwind/src/mips/Ginit.c
|
||||
index 3df170c75..bf7a8f5a8 100644
|
||||
--- a/src/pal/src/libunwind/src/mips/Ginit.c
|
||||
+++ b/src/pal/src/libunwind/src/mips/Ginit.c
|
||||
@@ -69,13 +69,6 @@ tdep_uc_addr (ucontext_t *uc, int reg)
|
||||
|
||||
# endif /* UNW_LOCAL_ONLY */
|
||||
|
||||
-HIDDEN unw_dyn_info_list_t _U_dyn_info_list;
|
||||
-
|
||||
-/* XXX fix me: there is currently no way to locate the dyn-info list
|
||||
- by a remote unwinder. On ia64, this is done via a special
|
||||
- unwind-table entry. Perhaps something similar can be done with
|
||||
- DWARF2 unwind info. */
|
||||
-
|
||||
static void
|
||||
put_unwind_info (unw_addr_space_t as, unw_proc_info_t *proc_info, void *arg)
|
||||
{
|
||||
@@ -86,7 +79,13 @@ static int
|
||||
get_dyn_info_list_addr (unw_addr_space_t as, unw_word_t *dyn_info_list_addr,
|
||||
void *arg)
|
||||
{
|
||||
- *dyn_info_list_addr = (unw_word_t) (intptr_t) &_U_dyn_info_list;
|
||||
+#ifndef UNW_LOCAL_ONLY
|
||||
+# pragma weak _U_dyn_info_list_addr
|
||||
+ if (!_U_dyn_info_list_addr)
|
||||
+ return -UNW_ENOINFO;
|
||||
+#endif
|
||||
+ // Access the `_U_dyn_info_list` from `LOCAL_ONLY` library, i.e. libunwind.so.
|
||||
+ *dyn_info_list_addr = _U_dyn_info_list_addr ();
|
||||
return 0;
|
||||
}
|
||||
|
||||
diff --git a/src/pal/src/libunwind/src/ppc32/Ginit.c b/src/pal/src/libunwind/src/ppc32/Ginit.c
|
||||
index ba302448a..7b4545580 100644
|
||||
--- a/src/pal/src/libunwind/src/ppc32/Ginit.c
|
||||
+++ b/src/pal/src/libunwind/src/ppc32/Ginit.c
|
||||
@@ -91,9 +91,6 @@ tdep_uc_addr (ucontext_t *uc, int reg)
|
||||
|
||||
# endif /* UNW_LOCAL_ONLY */
|
||||
|
||||
-HIDDEN unw_dyn_info_list_t _U_dyn_info_list;
|
||||
-
|
||||
-
|
||||
static void
|
||||
put_unwind_info (unw_addr_space_t as, unw_proc_info_t *proc_info, void *arg)
|
||||
{
|
||||
@@ -104,7 +101,13 @@ static int
|
||||
get_dyn_info_list_addr (unw_addr_space_t as, unw_word_t *dyn_info_list_addr,
|
||||
void *arg)
|
||||
{
|
||||
- *dyn_info_list_addr = (unw_word_t) &_U_dyn_info_list;
|
||||
+#ifndef UNW_LOCAL_ONLY
|
||||
+# pragma weak _U_dyn_info_list_addr
|
||||
+ if (!_U_dyn_info_list_addr)
|
||||
+ return -UNW_ENOINFO;
|
||||
+#endif
|
||||
+ // Access the `_U_dyn_info_list` from `LOCAL_ONLY` library, i.e. libunwind.so.
|
||||
+ *dyn_info_list_addr = _U_dyn_info_list_addr ();
|
||||
return 0;
|
||||
}
|
||||
|
||||
diff --git a/src/pal/src/libunwind/src/ppc64/Ginit.c b/src/pal/src/libunwind/src/ppc64/Ginit.c
|
||||
index 4c88cd6e7..7bfb395a7 100644
|
||||
--- a/src/pal/src/libunwind/src/ppc64/Ginit.c
|
||||
+++ b/src/pal/src/libunwind/src/ppc64/Ginit.c
|
||||
@@ -95,9 +95,6 @@ tdep_uc_addr (ucontext_t *uc, int reg)
|
||||
|
||||
# endif /* UNW_LOCAL_ONLY */
|
||||
|
||||
-HIDDEN unw_dyn_info_list_t _U_dyn_info_list;
|
||||
-
|
||||
-
|
||||
static void
|
||||
put_unwind_info (unw_addr_space_t as, unw_proc_info_t *proc_info, void *arg)
|
||||
{
|
||||
@@ -108,7 +105,13 @@ static int
|
||||
get_dyn_info_list_addr (unw_addr_space_t as, unw_word_t *dyn_info_list_addr,
|
||||
void *arg)
|
||||
{
|
||||
- *dyn_info_list_addr = (unw_word_t) &_U_dyn_info_list;
|
||||
+#ifndef UNW_LOCAL_ONLY
|
||||
+# pragma weak _U_dyn_info_list_addr
|
||||
+ if (!_U_dyn_info_list_addr)
|
||||
+ return -UNW_ENOINFO;
|
||||
+#endif
|
||||
+ // Access the `_U_dyn_info_list` from `LOCAL_ONLY` library, i.e. libunwind.so.
|
||||
+ *dyn_info_list_addr = _U_dyn_info_list_addr ();
|
||||
return 0;
|
||||
}
|
||||
|
||||
diff --git a/src/pal/src/libunwind/src/ptrace/_UPT_get_dyn_info_list_addr.c b/src/pal/src/libunwind/src/ptrace/_UPT_get_dyn_info_list_addr.c
|
||||
index cc5ed0441..16671d453 100644
|
||||
--- a/src/pal/src/libunwind/src/ptrace/_UPT_get_dyn_info_list_addr.c
|
||||
+++ b/src/pal/src/libunwind/src/ptrace/_UPT_get_dyn_info_list_addr.c
|
||||
@@ -71,6 +71,11 @@ get_list_addr (unw_addr_space_t as, unw_word_t *dil_addr, void *arg,
|
||||
|
||||
#else
|
||||
|
||||
+/* XXX fix me: there is currently no way to locate the dyn-info list
|
||||
+ by a remote unwinder. On ia64, this is done via a special
|
||||
+ unwind-table entry. Perhaps something similar can be done with
|
||||
+ DWARF2 unwind info. */
|
||||
+
|
||||
static inline int
|
||||
get_list_addr (unw_addr_space_t as, unw_word_t *dil_addr, void *arg,
|
||||
int *countp)
|
||||
diff --git a/src/pal/src/libunwind/src/sh/Ginit.c b/src/pal/src/libunwind/src/sh/Ginit.c
|
||||
index 52988a721..9fe96d2bd 100644
|
||||
--- a/src/pal/src/libunwind/src/sh/Ginit.c
|
||||
+++ b/src/pal/src/libunwind/src/sh/Ginit.c
|
||||
@@ -58,13 +58,6 @@ tdep_uc_addr (ucontext_t *uc, int reg)
|
||||
|
||||
# endif /* UNW_LOCAL_ONLY */
|
||||
|
||||
-HIDDEN unw_dyn_info_list_t _U_dyn_info_list;
|
||||
-
|
||||
-/* XXX fix me: there is currently no way to locate the dyn-info list
|
||||
- by a remote unwinder. On ia64, this is done via a special
|
||||
- unwind-table entry. Perhaps something similar can be done with
|
||||
- DWARF2 unwind info. */
|
||||
-
|
||||
static void
|
||||
put_unwind_info (unw_addr_space_t as, unw_proc_info_t *proc_info, void *arg)
|
||||
{
|
||||
@@ -75,7 +68,13 @@ static int
|
||||
get_dyn_info_list_addr (unw_addr_space_t as, unw_word_t *dyn_info_list_addr,
|
||||
void *arg)
|
||||
{
|
||||
- *dyn_info_list_addr = (unw_word_t) &_U_dyn_info_list;
|
||||
+#ifndef UNW_LOCAL_ONLY
|
||||
+# pragma weak _U_dyn_info_list_addr
|
||||
+ if (!_U_dyn_info_list_addr)
|
||||
+ return -UNW_ENOINFO;
|
||||
+#endif
|
||||
+ // Access the `_U_dyn_info_list` from `LOCAL_ONLY` library, i.e. libunwind.so.
|
||||
+ *dyn_info_list_addr = _U_dyn_info_list_addr ();
|
||||
return 0;
|
||||
}
|
||||
|
||||
diff --git a/src/pal/src/libunwind/src/tilegx/Ginit.c b/src/pal/src/libunwind/src/tilegx/Ginit.c
|
||||
index 7564a558b..925e64132 100644
|
||||
--- a/src/pal/src/libunwind/src/tilegx/Ginit.c
|
||||
+++ b/src/pal/src/libunwind/src/tilegx/Ginit.c
|
||||
@@ -64,13 +64,6 @@ tdep_uc_addr (ucontext_t *uc, int reg)
|
||||
|
||||
# endif /* UNW_LOCAL_ONLY */
|
||||
|
||||
-HIDDEN unw_dyn_info_list_t _U_dyn_info_list;
|
||||
-
|
||||
-/* XXX fix me: there is currently no way to locate the dyn-info list
|
||||
- by a remote unwinder. On ia64, this is done via a special
|
||||
- unwind-table entry. Perhaps something similar can be done with
|
||||
- DWARF2 unwind info. */
|
||||
-
|
||||
static void
|
||||
put_unwind_info (unw_addr_space_t as, unw_proc_info_t *proc_info, void *arg)
|
||||
{
|
||||
@@ -81,7 +74,13 @@ static int
|
||||
get_dyn_info_list_addr (unw_addr_space_t as, unw_word_t *dyn_info_list_addr,
|
||||
void *arg)
|
||||
{
|
||||
- *dyn_info_list_addr = (unw_word_t) (intptr_t) &_U_dyn_info_list;
|
||||
+#ifndef UNW_LOCAL_ONLY
|
||||
+# pragma weak _U_dyn_info_list_addr
|
||||
+ if (!_U_dyn_info_list_addr)
|
||||
+ return -UNW_ENOINFO;
|
||||
+#endif
|
||||
+ // Access the `_U_dyn_info_list` from `LOCAL_ONLY` library, i.e. libunwind.so.
|
||||
+ *dyn_info_list_addr = _U_dyn_info_list_addr ();
|
||||
return 0;
|
||||
}
|
||||
|
||||
diff --git a/src/pal/src/libunwind/src/x86/Ginit.c b/src/pal/src/libunwind/src/x86/Ginit.c
|
||||
index f6b8dc27d..3cec74a21 100644
|
||||
--- a/src/pal/src/libunwind/src/x86/Ginit.c
|
||||
+++ b/src/pal/src/libunwind/src/x86/Ginit.c
|
||||
@@ -54,13 +54,6 @@ tdep_uc_addr (ucontext_t *uc, int reg)
|
||||
|
||||
# endif /* UNW_LOCAL_ONLY */
|
||||
|
||||
-HIDDEN unw_dyn_info_list_t _U_dyn_info_list;
|
||||
-
|
||||
-/* XXX fix me: there is currently no way to locate the dyn-info list
|
||||
- by a remote unwinder. On ia64, this is done via a special
|
||||
- unwind-table entry. Perhaps something similar can be done with
|
||||
- DWARF2 unwind info. */
|
||||
-
|
||||
static void
|
||||
put_unwind_info (unw_addr_space_t as, unw_proc_info_t *proc_info, void *arg)
|
||||
{
|
||||
@@ -71,7 +64,13 @@ static int
|
||||
get_dyn_info_list_addr (unw_addr_space_t as, unw_word_t *dyn_info_list_addr,
|
||||
void *arg)
|
||||
{
|
||||
- *dyn_info_list_addr = (unw_word_t) &_U_dyn_info_list;
|
||||
+#ifndef UNW_LOCAL_ONLY
|
||||
+# pragma weak _U_dyn_info_list_addr
|
||||
+ if (!_U_dyn_info_list_addr)
|
||||
+ return -UNW_ENOINFO;
|
||||
+#endif
|
||||
+ // Access the `_U_dyn_info_list` from `LOCAL_ONLY` library, i.e. libunwind.so.
|
||||
+ *dyn_info_list_addr = _U_dyn_info_list_addr ();
|
||||
return 0;
|
||||
}
|
||||
|
||||
diff --git a/src/pal/src/libunwind/src/x86_64/Ginit.c b/src/pal/src/libunwind/src/x86_64/Ginit.c
|
||||
index a865d3385..fd8d418b1 100644
|
||||
--- a/src/pal/src/libunwind/src/x86_64/Ginit.c
|
||||
+++ b/src/pal/src/libunwind/src/x86_64/Ginit.c
|
||||
@@ -49,13 +49,6 @@ static struct unw_addr_space local_addr_space;
|
||||
|
||||
unw_addr_space_t unw_local_addr_space = &local_addr_space;
|
||||
|
||||
-HIDDEN unw_dyn_info_list_t _U_dyn_info_list;
|
||||
-
|
||||
-/* XXX fix me: there is currently no way to locate the dyn-info list
|
||||
- by a remote unwinder. On ia64, this is done via a special
|
||||
- unwind-table entry. Perhaps something similar can be done with
|
||||
- DWARF2 unwind info. */
|
||||
-
|
||||
static void
|
||||
put_unwind_info (unw_addr_space_t as, unw_proc_info_t *proc_info, void *arg)
|
||||
{
|
||||
@@ -66,7 +59,13 @@ static int
|
||||
get_dyn_info_list_addr (unw_addr_space_t as, unw_word_t *dyn_info_list_addr,
|
||||
void *arg)
|
||||
{
|
||||
- *dyn_info_list_addr = (unw_word_t) &_U_dyn_info_list;
|
||||
+#ifndef UNW_LOCAL_ONLY
|
||||
+# pragma weak _U_dyn_info_list_addr
|
||||
+ if (!_U_dyn_info_list_addr)
|
||||
+ return -UNW_ENOINFO;
|
||||
+#endif
|
||||
+ // Access the `_U_dyn_info_list` from `LOCAL_ONLY` library, i.e. libunwind.so.
|
||||
+ *dyn_info_list_addr = _U_dyn_info_list_addr ();
|
||||
return 0;
|
||||
}
|
||||
|
11
coreclr-pie.patch
Normal file
11
coreclr-pie.patch
Normal file
@ -0,0 +1,11 @@
|
||||
--- a/src/debug/createdump/CMakeLists.txt
|
||||
+++ b/src/debug/createdump/CMakeLists.txt
|
||||
@@ -38,6 +38,8 @@
|
||||
main.cpp
|
||||
)
|
||||
|
||||
+SET_TARGET_PROPERTIES(createdump PROPERTIES LINK_FLAGS -pie)
|
||||
+
|
||||
target_link_libraries(createdump
|
||||
createdump_lib
|
||||
# share the PAL in the dac module
|
22
corefx-32956-alpn.patch
Normal file
22
corefx-32956-alpn.patch
Normal file
@ -0,0 +1,22 @@
|
||||
From 9b9697318e9990655ea878a28a00eda44fb615c2 Mon Sep 17 00:00:00 2001
|
||||
From: Jeremy Barton <jbarton@microsoft.com>
|
||||
Date: Mon, 22 Oct 2018 11:54:52 -0700
|
||||
Subject: [PATCH] Fix ALPN detection logic (for non-portable shim builds)
|
||||
|
||||
---
|
||||
.../Unix/System.Security.Cryptography.Native/configure.cmake | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/src/Native/Unix/System.Security.Cryptography.Native/configure.cmake b/src/Native/Unix/System.Security.Cryptography.Native/configure.cmake
|
||||
index cdc9f50f3c33..fac8c16343df 100644
|
||||
--- a/src/Native/Unix/System.Security.Cryptography.Native/configure.cmake
|
||||
+++ b/src/Native/Unix/System.Security.Cryptography.Native/configure.cmake
|
||||
@@ -2,7 +2,7 @@ include(CheckLibraryExists)
|
||||
include(CheckFunctionExists)
|
||||
|
||||
set(CMAKE_REQUIRED_INCLUDES ${OPENSSL_INCLUDE_DIR})
|
||||
-set(CMAKE_REQUIRED_LIBRARIES ${OPENSSL_CRYPTO_LIBRARY})
|
||||
+set(CMAKE_REQUIRED_LIBRARIES ${OPENSSL_CRYPTO_LIBRARY} ${OPENSSL_SSL_LIBRARY})
|
||||
|
||||
check_function_exists(
|
||||
EC_GF2m_simple_method
|
27
corefx-optflags-support.patch
Normal file
27
corefx-optflags-support.patch
Normal file
@ -0,0 +1,27 @@
|
||||
diff --git a/src/Native/Unix/configure.cmake b/src/Native/Unix/configure.cmake
|
||||
index f4a30ad6cb..f2db68402a 100644
|
||||
--- a/src/Native/Unix/configure.cmake
|
||||
+++ b/src/Native/Unix/configure.cmake
|
||||
@@ -27,6 +27,12 @@ else ()
|
||||
message(FATAL_ERROR "Unknown platform. Cannot define PAL_UNIX_NAME, used by RuntimeInformation.")
|
||||
endif ()
|
||||
|
||||
+
|
||||
+set (PREVIOUS_CMAKE_CXX_FLAGS ${CMAKE_CXX_FLAGS})
|
||||
+set (CMAKE_CXX_FLAGS "-D_GNU_SOURCE")
|
||||
+set (PREVIOUS_CMAKE_C_FLAGS ${CMAKE_C_FLAGS})
|
||||
+set (CMAKE_C_FLAGS "-D_GNU_SOURCE")
|
||||
+
|
||||
# We compile with -Werror, so we need to make sure these code fragments compile without warnings.
|
||||
# Older CMake versions (3.8) do not assign the result of their tests, causing unused-value errors
|
||||
# which are not distinguished from the test failing. So no error for that one.
|
||||
@@ -698,6 +704,9 @@ endif()
|
||||
|
||||
set (CMAKE_REQUIRED_LIBRARIES)
|
||||
|
||||
+set (CMAKE_CXX_FLAGS "${PREVIOUS_CMAKE_CXX_FLAGS}")
|
||||
+set (CMAKE_C_FLAGS "${PREVIOUS_CMAKE_C_FLAGS}")
|
||||
+
|
||||
check_c_source_compiles(
|
||||
"
|
||||
#include <sys/inotify.h>
|
7
dotnet.sh
Normal file
7
dotnet.sh
Normal file
@ -0,0 +1,7 @@
|
||||
|
||||
# Add dotnet tools directory to PATH
|
||||
DOTNET_TOOLS_PATH="$HOME/.dotnet/tools"
|
||||
case "$PATH" in
|
||||
*"$DOTNET_TOOLS_PATH"* ) true ;;
|
||||
* ) PATH="$PATH:$DOTNET_TOOLS_PATH" ;;
|
||||
esac
|
502
dotnet.spec
Normal file
502
dotnet.spec
Normal file
@ -0,0 +1,502 @@
|
||||
# Avoid provides/requires from private libraries
|
||||
%global privlibs libhostfxr
|
||||
%global privlibs %{privlibs}|libclrjit
|
||||
%global privlibs %{privlibs}|libcoreclr
|
||||
%global privlibs %{privlibs}|libcoreclrtraceptprovider
|
||||
%global privlibs %{privlibs}|libdbgshim
|
||||
%global privlibs %{privlibs}|libhostpolicy
|
||||
%global privlibs %{privlibs}|libmscordaccore
|
||||
%global privlibs %{privlibs}|libmscordbi
|
||||
%global privlibs %{privlibs}|libsos
|
||||
%global privlibs %{privlibs}|libsosplugin
|
||||
%global __provides_exclude ^(%{privlibs})\\.so
|
||||
%global __requires_exclude ^(%{privlibs})\\.so
|
||||
|
||||
# Filter flags not supported by clang/dotnet:
|
||||
# -fcf-protection is not supported by clang
|
||||
# -fstack-clash-protection is not supported by clang
|
||||
# -specs= is not supported by clang
|
||||
# -fpie is added manually instead of via -specs
|
||||
%global dotnet_cflags %(echo %optflags | sed -e 's/-fcf-protection//' | sed -e 's/-fstack-clash-protection//' | sed -re 's/-specs=[^ ]*//g')
|
||||
%global dotnet_ldflags %(echo %{__global_ldflags} | sed -re 's/-specs=[^ ]*//g')
|
||||
|
||||
%if 0%{?fedora}
|
||||
%global use_bundled_libunwind 0
|
||||
%else
|
||||
%global use_bundled_libunwind 1
|
||||
%endif
|
||||
|
||||
%global simple_name dotnet
|
||||
|
||||
%global host_version 2.1.28
|
||||
%global runtime_version 2.1.28
|
||||
%global sdk_version 2.1.524
|
||||
|
||||
Name: dotnet
|
||||
Version: %{sdk_version}
|
||||
Release: 1%{?dist}
|
||||
Summary: .NET Core CLI tools and runtime
|
||||
License: MIT and ASL 2.0 and BSD
|
||||
URL: https://github.com/dotnet/
|
||||
|
||||
# The source is generated on a RHEL box via:
|
||||
# ./build-dotnet-tarball v%%{sdk_version}-SDK
|
||||
|
||||
Source0: dotnet-v%{sdk_version}-SDK.tar.gz
|
||||
Source1: check-debug-symbols.py
|
||||
Source2: dotnet.sh
|
||||
|
||||
Patch10: corefx-optflags-support.patch
|
||||
Patch11: corefx-32956-alpn.patch
|
||||
# This patch is generally applied at tarball-build time, except when we dont build the tarball
|
||||
Patch12: build-corefx-disable-werror.patch
|
||||
|
||||
Patch100: coreclr-pie.patch
|
||||
Patch101: coreclr-libunwind-fno-common.patch
|
||||
|
||||
Patch300: core-setup-4510-commit-id.patch
|
||||
Patch301: core-setup-pie.patch
|
||||
|
||||
Patch400: cli-telemetry-optout.patch
|
||||
|
||||
ExclusiveArch: x86_64
|
||||
|
||||
BuildRequires: clang
|
||||
BuildRequires: cmake
|
||||
# Bootstrap SDK needs OpenSSL 1.0 to run, but we can build and then
|
||||
# run with either OpenSSL 1.0 or 1.1
|
||||
%if 0%{?fedora} >= 26 || 0%{?rhel} >= 8
|
||||
BuildRequires: compat-openssl10
|
||||
%endif
|
||||
BuildRequires: git
|
||||
BuildRequires: glibc-langpack-en
|
||||
BuildRequires: hostname
|
||||
BuildRequires: krb5-devel
|
||||
BuildRequires: libcurl-devel
|
||||
BuildRequires: libicu-devel
|
||||
%if ! %{use_bundled_libunwind}
|
||||
BuildRequires: libunwind-devel
|
||||
%endif
|
||||
BuildRequires: lldb-devel
|
||||
BuildRequires: llvm
|
||||
BuildRequires: lttng-ust-devel
|
||||
BuildRequires: make
|
||||
BuildRequires: openssl-devel
|
||||
BuildRequires: python3
|
||||
BuildRequires: strace
|
||||
BuildRequires: zlib-devel
|
||||
|
||||
Requires: %{simple_name}-sdk-2.1%{?_isa} >= %{sdk_version}-%{release}
|
||||
|
||||
%description
|
||||
.NET Core is a fast, lightweight and modular platform for creating
|
||||
cross platform applications that work on Linux, macOS and Windows.
|
||||
|
||||
It particularly focuses on creating console applications, web
|
||||
applications and micro-services.
|
||||
|
||||
.NET Core contains a runtime conforming to .NET Standards a set of
|
||||
framework libraries, an SDK containing compilers and a 'dotnet'
|
||||
application to drive everything.
|
||||
|
||||
|
||||
%package -n %{simple_name}-host
|
||||
|
||||
Version: %{host_version}
|
||||
Summary: .NET command line launcher
|
||||
|
||||
%description -n %{simple_name}-host
|
||||
The .NET Core host is a command line program that runs a standalone
|
||||
.NET core application or launches the SDK.
|
||||
|
||||
.NET Core is a fast, lightweight and modular platform for creating
|
||||
cross platform applications that work on Linux, Mac and Windows.
|
||||
|
||||
It particularly focuses on creating console applications, web
|
||||
applications and micro-services.
|
||||
|
||||
|
||||
%package -n %{simple_name}-host-fxr-2.1
|
||||
|
||||
Version: %{host_version}
|
||||
Summary: .NET Core command line host resolver
|
||||
|
||||
# Theoretically any version of the host should work. But lets aim for the one
|
||||
# provided by this package, or from a newer version of .NET Core
|
||||
Requires: %{simple_name}-host%{?_isa} >= %{host_version}-%{release}
|
||||
|
||||
%description -n %{simple_name}-host-fxr-2.1
|
||||
The .NET Core host resolver contains logic to resolve and select the
|
||||
right version of the .NET Core SDK or runtime to use.
|
||||
|
||||
.NET Core is a fast, lightweight and modular platform for creating
|
||||
cross platform applications that work on Linux, Mac and Windows.
|
||||
|
||||
It particularly focuses on creating console applications, web
|
||||
applications and micro-services.
|
||||
|
||||
%package -n %{simple_name}-runtime-2.1
|
||||
|
||||
Version: %{runtime_version}
|
||||
Summary: NET Core 2.1 runtime
|
||||
|
||||
Requires: %{simple_name}-host-fxr-2.1%{?_isa} >= %{host_version}-%{release}
|
||||
|
||||
# libicu is dlopen()ed
|
||||
Requires: libicu
|
||||
|
||||
%description -n %{simple_name}-runtime-2.1
|
||||
The .NET Core runtime contains everything needed to run .NET Core applications.
|
||||
It includes a high performance Virtual Machine as well as the framework
|
||||
libraries used by .NET Core applications.
|
||||
|
||||
.NET Core is a fast, lightweight and modular platform for creating
|
||||
cross platform applications that work on Linux, Mac and Windows.
|
||||
|
||||
It particularly focuses on creating console applications, web
|
||||
applications and micro-services.
|
||||
|
||||
%package -n %{simple_name}-sdk-2.1
|
||||
|
||||
Version: %{sdk_version}
|
||||
Summary: .NET Core 2.1 Software Development Kit
|
||||
|
||||
Requires: %{simple_name}-sdk-2.1.5xx%{?_isa} >= %{sdk_version}-%{release}
|
||||
|
||||
%description -n %{simple_name}-sdk-2.1
|
||||
The .NET Core SDK is a collection of command line applications to
|
||||
create, build, publish and run .NET Core applications.
|
||||
|
||||
.NET Core is a fast, lightweight and modular platform for creating
|
||||
cross platform applications that work on Linux, Mac and Windows.
|
||||
|
||||
It particularly focuses on creating console applications, web
|
||||
applications and micro-services.
|
||||
|
||||
%package -n %{simple_name}-sdk-2.1.5xx
|
||||
|
||||
Version: %{sdk_version}
|
||||
Summary: .NET Core 2.1.5xx Software Development Kit
|
||||
|
||||
Requires: %{simple_name}-runtime-2.1%{?_isa} >= %{runtime_version}-%{release}
|
||||
|
||||
%description -n %{simple_name}-sdk-2.1.5xx
|
||||
The .NET Core SDK is a collection of command line applications to
|
||||
create, build, publish and run .NET Core applications.
|
||||
|
||||
.NET Core is a fast, lightweight and modular platform for creating
|
||||
cross platform applications that work on Linux, Mac and Windows.
|
||||
|
||||
It particularly focuses on creating console applications, web
|
||||
applications and micro-services.
|
||||
|
||||
|
||||
%prep
|
||||
%setup -q -n %{simple_name}-v%{sdk_version}-SDK
|
||||
|
||||
pushd src/corefx
|
||||
%patch10 -p1
|
||||
%patch11 -p1
|
||||
%patch12 -p1
|
||||
popd
|
||||
|
||||
pushd src/coreclr
|
||||
%patch100 -p1
|
||||
%patch101 -p1
|
||||
popd
|
||||
|
||||
pushd src/core-setup
|
||||
%patch300 -p1
|
||||
%patch301 -p1
|
||||
popd
|
||||
|
||||
pushd src/cli
|
||||
%patch400 -p1
|
||||
popd
|
||||
|
||||
# Fix bad hardcoded path in build
|
||||
sed -i 's|/usr/share/dotnet|%{_libdir}/%{simple_name}|' src/core-setup/src/corehost/common/pal.unix.cpp
|
||||
|
||||
# Disable warnings
|
||||
sed -i 's|skiptests|skiptests ignorewarnings|' repos/coreclr.proj
|
||||
|
||||
# If CLR_CMAKE_USE_SYSTEM_LIBUNWIND=TRUE is missing, add it back
|
||||
grep CLR_CMAKE_USE_SYSTEM_LIBUNWIND repos/coreclr.proj || \
|
||||
sed -i 's|\$(BuildArguments) </BuildArguments>|$(BuildArguments) cmakeargs -DCLR_CMAKE_USE_SYSTEM_LIBUNWIND=TRUE</BuildArguments>|' repos/coreclr.proj
|
||||
|
||||
%if %{use_bundled_libunwind}
|
||||
# Use bundled libunwind
|
||||
sed -i 's|-DCLR_CMAKE_USE_SYSTEM_LIBUNWIND=TRUE|-DCLR_CMAKE_USE_SYSTEM_LIBUNWIND=FALSE|' repos/coreclr.proj
|
||||
%endif
|
||||
|
||||
cat source-build-info.txt
|
||||
|
||||
|
||||
%build
|
||||
export DOTNET_CLI_TELEMETRY_OPTOUT=1
|
||||
|
||||
export LLVM_HOME=/opt/rh/llvm-toolset-6.0/root/usr
|
||||
export CMAKE_INCLUDE_PATH="/opt/rh/llvm-toolset-6.0/root/usr/include"
|
||||
|
||||
export CFLAGS="%{dotnet_cflags}"
|
||||
export CXXFLAGS="%{dotnet_cflags}"
|
||||
export LDFLAGS="%{dotnet_ldflags}"
|
||||
|
||||
test -f Tools/ilasm/ilasm
|
||||
|
||||
Tools/dotnetcli/dotnet --info
|
||||
|
||||
VERBOSE=1 ./build.sh \
|
||||
/v:n \
|
||||
/p:MinimalConsoleLogOutput=false \
|
||||
/p:ContinueOnPrebuiltBaselineError=true
|
||||
|
||||
|
||||
%install
|
||||
install -d -m 0755 %{buildroot}%{_libdir}/%{simple_name}/
|
||||
ls bin/x64/Release
|
||||
tar xf bin/x64/Release/dotnet-sdk-%{sdk_version}-*.tar.gz -C %{buildroot}%{_libdir}/%{simple_name}/
|
||||
|
||||
# Fix permissions on files
|
||||
find %{buildroot}%{_libdir}/%{simple_name}/ -type f -name '*.props' -exec chmod -x {} \;
|
||||
find %{buildroot}%{_libdir}/%{simple_name}/ -type f -name '*.targets' -exec chmod -x {} \;
|
||||
find %{buildroot}%{_libdir}/%{simple_name}/ -type f -name '*.dll' -exec chmod -x {} \;
|
||||
find %{buildroot}%{_libdir}/%{simple_name}/ -type f -name '*.pubxml' -exec chmod -x {} \;
|
||||
|
||||
# Provided by dotnet-host from another SRPM
|
||||
# Add ~/.dotnet/tools to $PATH for all users
|
||||
#install -dm 0755 %%{buildroot}%%{_sysconfdir}/profile.d/
|
||||
#install %%{SOURCE2} %%{buildroot}%%{_sysconfdir}/profile.d/
|
||||
|
||||
# Provided by dotnet-host from another SRPM
|
||||
#install -dm 755 %%{buildroot}/%%{_datadir}/bash-completion/completions
|
||||
# dynamic completion needs the file to be named the same as the base command
|
||||
#install src/cli/scripts/register-completions.bash %%{buildroot}/%%{_datadir}/bash-completion/completions/dotnet
|
||||
|
||||
# TODO: the zsh completion script needs to be ported to use #compdef
|
||||
#install -dm 755 %%{buildroot}/%%{_datadir}/zsh/site-functions
|
||||
#install src/cli/scripts/register-completions.zsh %%{buildroot}/%%{_datadir}/zsh/site-functions/_dotnet
|
||||
|
||||
# Provided by dotnet-host from another SRPM
|
||||
#install -d -m 0755 %%{buildroot}%%{_bindir}
|
||||
#ln -s %%{_libdir}/%%{simple_name}/dotnet %%{buildroot}%%{_bindir}/
|
||||
|
||||
# Provided by dotnet-host from another SRPM
|
||||
#install -d -m 0755 %%{buildroot}%%{_mandir}/man1/
|
||||
#find -iname 'dotnet*.1' -type f -exec cp {} %%{buildroot}%%{_mandir}/man1/ \;
|
||||
|
||||
# Check debug symbols in all elf objects. This is not in %%check
|
||||
# because native binaries are stripped by rpm-build after %%install.
|
||||
# So we need to do this check earlier.
|
||||
echo "Testing build results for debug symbols..."
|
||||
%{SOURCE1} -v %{buildroot}%{_libdir}/%{simple_name}/
|
||||
|
||||
# Self-check
|
||||
%{buildroot}%{_libdir}/%{simple_name}/dotnet --info
|
||||
|
||||
# Provided by dotnet-host from another SRPM
|
||||
rm %{buildroot}%{_libdir}/%{simple_name}/LICENSE.txt
|
||||
rm %{buildroot}%{_libdir}/%{simple_name}/ThirdPartyNotices.txt
|
||||
rm %{buildroot}%{_libdir}/%{simple_name}/dotnet
|
||||
|
||||
|
||||
%files -n %{simple_name}-host-fxr-2.1
|
||||
%dir %{_libdir}/%{simple_name}/host/fxr
|
||||
%{_libdir}/%{simple_name}/host/fxr/%{host_version}
|
||||
|
||||
%files -n %{simple_name}-runtime-2.1
|
||||
%dir %{_libdir}/%{simple_name}/shared
|
||||
%dir %{_libdir}/%{simple_name}/shared/Microsoft.NETCore.App
|
||||
%{_libdir}/%{simple_name}/shared/Microsoft.NETCore.App/%{runtime_version}
|
||||
|
||||
%files -n %{simple_name}-sdk-2.1
|
||||
# empty package useful for dependencies
|
||||
|
||||
%files -n %{simple_name}-sdk-2.1.5xx
|
||||
%dir %{_libdir}/%{simple_name}/sdk
|
||||
%{_libdir}/%{simple_name}/sdk/%{sdk_version}
|
||||
|
||||
%changelog
|
||||
* Mon May 17 2021 Omair Majid <omajid@redhat.com> - 2.1.524-1
|
||||
- Update to .NET SDK 2.1.524 and Runtime 2.1.28
|
||||
- Resolves: RHBZ#1953763
|
||||
|
||||
* Wed Apr 21 2021 Omair Majid <omajid@redhat.com> - 2.1.523-2
|
||||
- Update to .NET SDK 2.1.523 and Runtime 2.1.27
|
||||
- Resolves: RHBZ#1946718
|
||||
|
||||
* Wed Feb 10 2021 Omair Majid <omajid@redhat.com> - 2.1.521-2
|
||||
- Update to .NET Core SDK 2.1.521 and Runtime 2.1.25
|
||||
- Resolves: RHBZ#1921939
|
||||
|
||||
* Tue Jan 12 14:41:40 EST 2021 Omair Majid <omajid@redhat.com> - 2.1.520-1
|
||||
- Update to .NET Core SDK 2.1.520 and Runtime 2.1.24
|
||||
- Resolves: RHBZ#1905575
|
||||
|
||||
* Tue Oct 06 2020 Omair Majid <omajid@redhat.com> - 2.1.519-2
|
||||
- Bump release
|
||||
- Resolves: RHBZ#1884080
|
||||
|
||||
* Thu Oct 01 2020 Omair Majid <omajid@redhat.com> - 2.1.519-1
|
||||
- Update to .NET Core SDK 2.1.519 and Runtime 2.1.23
|
||||
- Drop patches merged upstream
|
||||
- Resolves: RHBZ#1884080
|
||||
|
||||
* Fri Sep 04 2020 Omair Majid <omajid@redhat.com> - 2.1.518-1
|
||||
- Update to .NET Core SDK 2.1.518 and Runtime 2.1.22
|
||||
- Resolves: RHBZ#1874064
|
||||
|
||||
* Mon Aug 17 2020 Omair Majid <omajid@redhat.com> - 2.1.517-1
|
||||
- Update to .NET Core SDK 2.1.517 and Runtime 2.1.21
|
||||
- Resolves: RHBZ#1866119
|
||||
|
||||
* Fri Jul 17 2020 Omair Majid <omajid@redhat.com> - 2.1.516-1
|
||||
- Update to .NET Core SDK 2.1.516 and Runtime 2.1.20
|
||||
- Resolves: RHBZ#1851971
|
||||
- Resolves: RHBZ#1856937
|
||||
|
||||
* Thu Jun 11 2020 Omair Majid <omajid@redhat.com> - 2.1.515-2
|
||||
- Update to .NET Core SDK 2.1.515 and Runtime 2.1.19
|
||||
- Resolves: RHBZ#1843672
|
||||
|
||||
* Mon Jun 01 2020 Omair Majid <omajid@redhat.com> - 2.1.514-3
|
||||
- Update to .NET Core SDK 2.1.514 and Runtime 2.1.18
|
||||
- Resolves: RHBZ#1828392
|
||||
|
||||
* Mon Mar 23 2020 Omair Majid <omajid@redhat.com> - 2.1.513-2
|
||||
- Update to .NET Core SDK 2.1.513 and Runtime 2.1.17
|
||||
- Resolves: RHBZ#1815640
|
||||
|
||||
* Sat Mar 07 2020 Omair Majid <omajid@redhat.com> - 2.1.512-1
|
||||
- Update to .NET Core Runtime 2.1.16 and SDK 2.1.512
|
||||
- Resolves: RHBZ#1799068
|
||||
|
||||
* Fri Jan 17 2020 Omair Majid <omajid@redhat.com> - 2.1.511-2
|
||||
- Update to .NET Core Runtime 2.1.15 and SDK 2.1.511
|
||||
- Resolves: RHBZ#1786190
|
||||
|
||||
* Thu Aug 29 2019 Omair Majid <omajid@redhat.com> - 2.1.509-2
|
||||
- Update to .NET Core Runtime 2.1.13 and SDK 2.1.509
|
||||
- Resolves: RHBZ#1742959
|
||||
|
||||
* Thu Aug 15 2019 Omair Majid <omajid@redhat.com> - 2.1.508-3
|
||||
- Remove dotnet and dotnet host packages
|
||||
- Resolves: RHBZ#1740879
|
||||
|
||||
* Tue Aug 13 2019 Omair Majid <omajid@redhat.com> - 2.1.508-2
|
||||
- Bump release
|
||||
- Resolves: RHBZ#1740308
|
||||
|
||||
* Thu Jul 11 2019 Omair Majid <omajid@redhat.com> - 2.1.508-1
|
||||
- Update to .NET Core Runtime 2.1.12 and SDK 2.1.508
|
||||
- Resolves: RHBZ#1728823
|
||||
|
||||
* Wed Jun 12 2019 Omair Majid <omajid@redhat.com> - 2.1.507-4
|
||||
- Bump version
|
||||
- Related: RHBZ#1712158
|
||||
|
||||
* Mon May 20 2019 Omair Majid <omajid@redhat.com> - 2.1.507-2
|
||||
- Link against strerror_r correctly
|
||||
- Resolves: RHBZ#1712158
|
||||
|
||||
* Thu May 02 2019 Omair Majid <omajid@redhat.com> - 2.1.507-1
|
||||
- Update to .NET Core Runtime 2.1.11 and SDK 2.1.507
|
||||
- Resolves: RHBZ#1705284
|
||||
|
||||
* Wed Apr 17 2019 Omair Majid <omajid@redhat.com> - 2.1.506-2
|
||||
- Switch away from SCL dependencies for clang/llvm/lldb
|
||||
- Resolves: RHBZ#1700908
|
||||
|
||||
* Tue Apr 09 2019 Omair Majid <omajid@redhat.com> - 2.1.506-1
|
||||
- Update to .NET Core Runtime 2.1.10 and SDK 2.1.506
|
||||
- Resolves: RHBZ#1696371
|
||||
|
||||
* Fri Feb 22 2019 Omair Majid <omajid@redhat.com> - 2.1.504-1
|
||||
- Update to .NET Core Runtime 2.1.8 and SDK 2.1.504
|
||||
- Sync with Fedora copr spec file
|
||||
- Resolves: RHBZ#1646713
|
||||
|
||||
* Fri Oct 12 2018 Omair Majid <omajid@redhat.com> - 2.1.403-4
|
||||
- Disable telemetry via code, not just environment variable
|
||||
- Resolves: rhbz#1638093
|
||||
|
||||
* Thu Oct 11 2018 Omair Majid <omajid@redhat.com> - 2.1.403-3
|
||||
- Disable telemetry by default
|
||||
- Resolves: rhbz#1638093
|
||||
|
||||
* Wed Oct 10 2018 Omair Majid <omajid@redhat.com> - 2.1.403-2
|
||||
- Target the latest ASP.NET Core version instead of 2.1.1
|
||||
- Resolves: rhbz#1636585
|
||||
|
||||
* Thu Oct 04 2018 Omair Majid <omajid@redhat.com> - 2.1.403-1
|
||||
- Update to .NET Core Runtime 2.1.5 and SDK 2.1.403
|
||||
- Resolves: rhbz#1634182
|
||||
|
||||
* Mon Oct 01 2018 Omair Majid <omajid@redhat.com> - 2.1.402-5
|
||||
- Backport fix to correct order of SSL_CERT_FILE and SSL_CERT_DIR lookup
|
||||
- Resolves: rhbz#1633742
|
||||
|
||||
* Thu Sep 27 2018 Omair Majid <omajid@redhat.com> - 2.1.402-4
|
||||
- Add ~/.dotnet/tools to $PATH to make it easier to use dotnet tools
|
||||
- Resolves: rhbz#1630439
|
||||
|
||||
* Tue Sep 25 2018 Omair Majid <omajid@redhat.com> - 2.1.402-3
|
||||
- Update .NET Core Runtime 2.1.4 and SDK 2.1.402
|
||||
- Resolves: rhbz#1628997
|
||||
|
||||
* Tue Sep 11 2018 Omair Majid <omajid@redhat.com> - 2.1.401-3
|
||||
- Use standard flags to build .NET Core
|
||||
- Resolves: rhbz#1624105
|
||||
|
||||
* Tue Sep 11 2018 Omair Majid <omajid@redhat.com> - 2.1.401-2
|
||||
- Bundle libunwind
|
||||
- Resolves: rhbz#1626285
|
||||
|
||||
* Fri Aug 17 2018 Omair Majid <omajid@redhat.com> - 2.1.401-1
|
||||
- Update .NET Core Runtime 2.1.3 and SDK 2.1.401
|
||||
- Drop upstreamed patches
|
||||
|
||||
* Mon Aug 06 2018 Omair Majid <omajid@redhat.com> - 2.1.302-1
|
||||
- Initial build.
|
||||
- Un-SCLized the package.
|
||||
|
||||
* Wed Jul 4 2018 Omair Majid <omajid@redhat.com> - 2.1.302-1
|
||||
- Update to .NET Core Runtime 2.1.2 and SDK 2.1.302
|
||||
|
||||
* Wed Jun 20 2018 Omair Majid <omajid@redhat.com> - 2.1.301-5
|
||||
- Add sdk-2.1.3xx subpackage
|
||||
|
||||
* Tue Jun 19 2018 Omair Majid <omajid@redhat.com> - 2.1.301-4
|
||||
- Rebuild to pick up new lttng-ust
|
||||
|
||||
* Tue Jun 19 2018 Omair Majid <omajid@redhat.com> - 2.1.301-3
|
||||
- Add workaround for unreadable system certificates
|
||||
- Resolves: rhbz#1588099
|
||||
|
||||
* Tue Jun 19 2018 Omair Majid <omajid@redhat.com> - 2.1.301-2
|
||||
- Add updated man pages
|
||||
- Resolves: rhbz#1584790
|
||||
|
||||
* Thu Jun 14 2018 Omair Majid <omajid@redhat.com> - 2.1.301-1
|
||||
- Update to .NET Core SDK 2.1.301
|
||||
|
||||
* Wed May 30 2018 Omair Majid <omajid@redhat.com> - 2.1.300-7
|
||||
- Explicitly require a modified libcurl
|
||||
|
||||
* Tue May 29 2018 Omair Majid <omajid@redhat.com> - 2.1.300-6
|
||||
- Install bash completions in %%{_root_datadir}
|
||||
|
||||
* Mon May 28 2018 Omair Majid <omajid@redhat.com> - 2.1.300-5
|
||||
- Add provides for dotnet-sdk-2.1.3xx
|
||||
|
||||
* Mon May 28 2018 Omair Majid <omajid@redhat.com> - 2.1.300-4
|
||||
- Remove patch for ASP.NET Core templates. No longer needed for 2.1.
|
||||
|
||||
* Fri May 25 2018 Omair Majid <omajid@redhat.com> - 2.1.300-3
|
||||
- Remove net46 symlink
|
||||
|
||||
* Thu May 24 2018 Omair Majid <omajid@redhat.com> - 2.1.300-2
|
||||
- Rebuild to pick up updated dependencies
|
||||
|
||||
* Thu May 24 2018 Omair Majid <omajid@redhat.com> - 2.1.300-1
|
||||
- New package. Import from Fedora (DotNet SIG package).
|
Loading…
Reference in New Issue
Block a user