Adding Fedora 23

This commit is contained in:
Livar Cunha 2016-05-26 23:16:18 -07:00
parent 84d1b60ffe
commit e634fedae8
50 changed files with 175 additions and 44 deletions

View file

@ -18,6 +18,7 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
}
}

View file

@ -18,6 +18,7 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
}
}

View file

@ -18,7 +18,8 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
},
"tools": {
"dotnet-portable": {

View file

@ -22,7 +22,8 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
},
"tools": {
"dotnet-portable": {

View file

@ -22,6 +22,7 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
}
}

View file

@ -18,6 +18,7 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
}
}

View file

@ -24,6 +24,7 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
}
}

View file

@ -18,6 +18,7 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
}
}

View file

@ -22,6 +22,7 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
}
}

View file

@ -25,6 +25,7 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
}
}

View file

@ -24,6 +24,7 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
}
}

View file

@ -37,6 +37,7 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
}
}

View file

@ -40,6 +40,7 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
}
}

View file

@ -41,6 +41,7 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
}
}

View file

@ -37,6 +37,7 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
}
}

View file

@ -33,6 +33,7 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
}
}

View file

@ -18,6 +18,7 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
}
}

View file

@ -18,7 +18,8 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
},
"runtimeOptions": {
"somethingString": "anything",

View file

@ -20,6 +20,7 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
}
}

View file

@ -18,6 +18,7 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
}
}

View file

@ -18,6 +18,7 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
}
}

View file

@ -25,6 +25,7 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
}
}

View file

@ -24,6 +24,7 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
}
}

View file

@ -23,6 +23,7 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
}
}

View file

@ -29,6 +29,7 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
}
}

View file

@ -18,7 +18,8 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
},
"scripts": {
"prepublish": [

View file

@ -23,7 +23,8 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
},
"scripts": {
"prepublish": [

View file

@ -17,6 +17,7 @@
"ubuntu.14.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
}
}

View file

@ -23,6 +23,7 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
}
}

View file

@ -23,6 +23,7 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
}
}

View file

@ -28,6 +28,7 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
}
}

View file

@ -22,6 +22,7 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
}
}

View file

@ -20,6 +20,7 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
}
}

View file

@ -18,6 +18,7 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
}
}

View file

@ -18,6 +18,7 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
}
}

View file

@ -19,6 +19,7 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
}
}

View file

@ -22,6 +22,7 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
}
}

View file

@ -22,6 +22,7 @@
"ubuntu.16.04-x64": {},
"centos.7-x64": {},
"rhel.7.2-x64": {},
"debian.8-x64": {}
"debian.8-x64": {},
"fedora.23-x64": {}
}
}

View file

@ -57,6 +57,15 @@ namespace Microsoft.DotNet.Cli.Build.Framework
}
}
public static bool IsFedora
{
get
{
var osname = RuntimeEnvironment.OperatingSystem;
return string.Equals(osname, "fedora", StringComparison.OrdinalIgnoreCase);
}
}
public static bool IsUnix
{
get
@ -78,7 +87,7 @@ namespace Microsoft.DotNet.Cli.Build.Framework
{
get
{
return IsUbuntu || IsCentOS || IsRHEL || IsDebian;
return IsUbuntu || IsCentOS || IsRHEL || IsDebian || IsFedora;
}
}
@ -103,6 +112,8 @@ namespace Microsoft.DotNet.Cli.Build.Framework
return IsRHEL;
case BuildPlatform.Debian:
return IsDebian;
case BuildPlatform.Fedora:
return IsFedora;
case BuildPlatform.Unix:
return IsUnix;
case BuildPlatform.Linux:
@ -143,6 +154,10 @@ namespace Microsoft.DotNet.Cli.Build.Framework
{
return BuildPlatform.Debian;
}
else if (IsFedora)
{
return BuildPlatform.Fedora;
}
else
{
return default(BuildPlatform);

View file

@ -9,6 +9,7 @@ namespace Microsoft.DotNet.Cli.Build.Framework
Ubuntu = 5,
CentOS = 6,
RHEL = 7,
Debian = 8
Debian = 8,
Fedora = 9
}
}

View file

@ -49,7 +49,8 @@ namespace Microsoft.DotNet.Cli.Build
{ "centos.7-x64", "rhel.7-x64" },
{ "rhel.7-x64", "rhel.7-x64" },
{ "rhel.7.2-x64", "rhel.7-x64" },
{ "debian.8-x64", "debian.8-x64" }
{ "debian.8-x64", "debian.8-x64" },
{ "fedora.23-x64", "fedora.23-x64" }
};
public const string SharedFrameworkName = "Microsoft.NETCore.App";

View file

@ -104,7 +104,8 @@ namespace Microsoft.DotNet.Cli.Build
"rhel.x64.version",
"osx.x64.version",
"debian.x64.version",
"centos.x64.version"
"centos.x64.version",
"fedora.23.x64.version"
};
string cliVersion = Utils.GetCliVersionFileContent(c);

View file

@ -106,6 +106,10 @@ namespace Microsoft.DotNet.Cli.Build
{
rid = "debian.8-x64";
}
else if (CurrentPlatform.IsFedora)
{
rid = "fedora.{RuntimeEnvironment.OperatingSystemVersion}-x64";
}
return rid;
}

View file

@ -9,7 +9,7 @@ def project = GithubProject
def branch = GithubBranchName
def isPR = true
def platformList = ['Debian8.2:x64:Debug', 'Ubuntu:x64:Release', 'Ubuntu16.04:x64:Release', 'OSX:x64:Release', 'Windows_NT:x64:Release', 'Windows_NT:x86:Debug', 'RHEL7.2:x64:Release', 'CentOS7.1:x64:Debug']
def platformList = ['Debian8.2:x64:Debug', 'Ubuntu:x64:Release', 'Ubuntu16.04:x64:Release', 'OSX:x64:Release', 'Windows_NT:x64:Release', 'Windows_NT:x86:Debug', 'RHEL7.2:x64:Release', 'CentOS7.1:x64:Debug', 'Fedora23:x64:Debug']
def static getBuildJobName(def configuration, def os, def architecture) {
return configuration.toLowerCase() + '_' + os.toLowerCase() + '_' + architecture.toLowerCase()

View file

@ -0,0 +1,52 @@
#
# Copyright (c) .NET Foundation and contributors. All rights reserved.
# Licensed under the MIT license. See LICENSE file in the project root for full license information.
#
# Dockerfile that creates a container suitable to build dotnet-cli
FROM chcosta/dotnetcore:fedora23_prereqs
# Install the base toolchain we need to build anything (clang, cmake, make and the like)
# this does not include libraries that we need to compile different projects, we'd like
# them in a different layer.
RUN dnf install -y cmake \
clang \
lldb-devel \
make \
which && \
dnf clean all
# Install tools used by the VSO build automation.
RUN dnf install -y git \
zip \
tar \
nodejs \
npm && \
findutils && \
dnf clean all && \
npm install -g azure-cli && \
npm cache clean
# Dependencies of CoreCLR and CoreFX.
RUN dnf install -y libicu-devel \
libuuid-devel \
libcurl-devel \
openssl-devel \
libunwind-devel \
lttng-ust-devel && \
dnf clean all
# Setup User to match Host User, and give superuser permissions
ARG USER_ID=0
RUN useradd -m code_executor -u ${USER_ID} -g wheel
RUN echo 'code_executor ALL=(ALL) NOPASSWD:ALL' >> /etc/sudoers
# With the User Change, we need to change permissions on these directories
RUN chmod -R a+rwx /usr/local
RUN chmod -R a+rwx /home
# Set user to the one we just created
USER ${USER_ID}
# Set working directory
WORKDIR /opt/code

View file

@ -70,6 +70,12 @@ if [ -z "$DOCKERFILE" ]; then
elif [ "$(cat /etc/*-release | grep -cim1 debian)" -eq 1 ]; then
echo "Detected current OS as Debian, using 'debian' image"
export DOCKERFILE=scripts/docker/debian
elif [ "$(cat /etc/*-release | grep -cim1 fedora)" -eq 1 ]; then
echo "Detected current OS as Fedora, determining fedora version to use..."
if [ "$(cat /etc/*-release | grep -cim1 23)" -eq 1 ]; then
echo "using 'fedora.23' image"
export DOCKERFILE=scripts/docker/fedora.23
fi
else
echo "Unknown Linux Distro. Using 'ubuntu' image"
export DOCKERFILE=scripts/docker/ubuntu

View file

@ -82,6 +82,11 @@ get_current_os_name() {
elif [ "$(cat /etc/*-release | grep -cim1 debian)" -eq 1 ]; then
echo "debian"
return 0
if [ "$(cat /etc/*-release | grep -cim1 fedora)" -eq 1 ]; then
if [ "$(cat /etc/*-release | grep -cim1 23)" -eq 1 ]; then
echo "fedora.23"
return 0
fi
fi
fi

View file

@ -231,7 +231,8 @@ namespace Microsoft.DotNet.Tests.EndToEnd
{
case "centos":
case "rhel":
Console.WriteLine("Skipping native compilation tests on CentOS/RHEL - https://github.com/dotnet/cli/issues/453");
case "fedora"
Console.WriteLine("Skipping native compilation tests on Fedora/CentOS/RHEL - https://github.com/dotnet/cli/issues/453");
isSupported = false;
break;
case "debian":

View file

@ -129,6 +129,7 @@ namespace Microsoft.Extensions.DependencyModel.Tests
new RuntimeFallbacks("ubuntu-x64", "ubuntu", "linux-x64", "linux", "unix", "any", "base"),
new RuntimeFallbacks("ubuntu.16.04-x64", "ubuntu", "linux-x64", "linux", "unix", "any", "base"),
new RuntimeFallbacks("rhel-x64", "rhel", "linux-x64", "linux", "unix", "any", "base"),
new RuntimeFallbacks("fedora.23-x64", "fedora", "linux-x64", "linux", "unix", "any", "base"),
new RuntimeFallbacks("osx-x64", "osx", "unix", "any", "base"),
});
}

View file

@ -59,6 +59,12 @@ namespace Microsoft.DotNet.Tools.Publish.Tests
Rid="osx.10.11-x64",
HostExtension="",
ExpectedArtifacts=new string[] { "libhostfxr.dylib", "libcoreclr.dylib", "libhostpolicy.dylib" }
},
new
{
Rid="fedora.23-x64",
HostExtension="",
ExpectedArtifacts=new string[] { "libhostfxr.so", "libcoreclr.so", "libhostpolicy.so" }
}
};