Enable building distro agnostic runtime RPM packages
authordrneve <35274978+drneve@users.noreply.github.com>
Mon, 29 Jan 2018 19:50:39 +0000 (11:50 -0800)
committerDriele Neves Ribeiro <t-drneve@microsoft.com>
Thu, 8 Feb 2018 02:13:40 +0000 (18:13 -0800)
Commit migrated from https://github.com/dotnet/core-setup/commit/bdaf9ba3ada968edd3a3065591be4ff59a4d8f48

12 files changed:
src/installer/buildpipeline/Core-Setup-Linux-BT.json
src/installer/pkg/packaging/rpm/dotnet-runtime-deps-rpm_config_centos.7-x64.json [moved from src/installer/pkg/packaging/rpm/dotnet-sharedframework-opensuse-rpm_config.json with 58% similarity]
src/installer/pkg/packaging/rpm/dotnet-runtime-deps-rpm_config_fedora.26-x64.json [new file with mode: 0644]
src/installer/pkg/packaging/rpm/dotnet-runtime-deps-rpm_config_fedora.27-x64.json [new file with mode: 0644]
src/installer/pkg/packaging/rpm/dotnet-runtime-deps-rpm_config_opensuse.42-x64.json [new file with mode: 0644]
src/installer/pkg/packaging/rpm/dotnet-runtime-deps-rpm_config_oraclelinux.7-x64.json [new file with mode: 0644]
src/installer/pkg/packaging/rpm/dotnet-runtime-deps-rpm_config_sles.12-x64.json [new file with mode: 0644]
src/installer/pkg/packaging/rpm/dotnet-sharedframework-rpm_config.json
src/installer/pkg/packaging/rpm/dotnet-sharedhost-rpm_config.json
src/installer/pkg/packaging/rpm/package.props
src/installer/pkg/packaging/rpm/package.targets
src/installer/publish/dir.props

index 49873c6..4804ef8 100644 (file)
       "enabled": true,
       "continueOnError": false,
       "alwaysRun": false,
-      "displayName": "Package - Rhel7",
+      "displayName": "Package Runtime Dep - Rhel7",
       "timeoutInMinutes": 0,
       "refName": "Task38",
       "task": {
       "enabled": true,
       "continueOnError": false,
       "alwaysRun": false,
-      "displayName": "Publish - Rhel7",
+      "displayName": "Publish Runtime Dep - Rhel7",
       "timeoutInMinutes": 0,
       "refName": "Task39",
       "task": {
       "enabled": true,
       "continueOnError": false,
       "alwaysRun": false,
-      "displayName": "Package - OpenSuse",
+      "displayName": "Package Runtime Dep - OpenSuse",
       "timeoutInMinutes": 0,
       "refName": "Task38",
       "task": {
       "enabled": true,
       "continueOnError": false,
       "alwaysRun": false,
-      "displayName": "Publish - OpenSuse",
+      "displayName": "Publish Runtime Dep - OpenSuse",
       "timeoutInMinutes": 0,
       "refName": "Task39",
       "task": {
     {
       "environment": {},
       "enabled": true,
+      "continueOnError": false,
+      "alwaysRun": false,
+      "displayName": "Package Runtime Dep - Fedora 26",
+      "timeoutInMinutes": 0,
+      "refName": "Task43",
+      "task": {
+        "id": "d9bafed4-0b18-4f58-968d-86655b4d2ce9",
+        "versionSpec": "1.*",
+        "definitionType": "task"
+      },
+      "inputs": {
+        "filename": "docker",
+        "arguments": "run --rm $(DockerCommonRunArgs_Rhel7) $(PB_GitDirectory)/Tools/msbuild.sh $(PB_GitDirectory)/src/pkg/packaging/dir.proj $(AdditionalMSBuildPackagingArguments) $(DistroSpecificMSBuildArguments) /p:OutputRid=fedora.26-$(PB_TargetArchitecture)",
+        "workingFolder": "",
+        "failOnStandardError": "false"
+      }
+    },
+    {
+      "environment": {},
+      "enabled": true,
+      "continueOnError": false,
+      "alwaysRun": false,
+      "displayName": "Publish Runtime Dep - Fedora 26",
+      "timeoutInMinutes": 0,
+      "refName": "Task44",
+      "task": {
+        "id": "d9bafed4-0b18-4f58-968d-86655b4d2ce9",
+        "versionSpec": "1.*",
+        "definitionType": "task"
+      },
+      "inputs": {
+        "filename": "docker",
+        "arguments": "run --rm $(DockerCommonRunArgs_Rhel7) $(PB_GitDirectory)/Tools/msbuild.sh $(PB_GitDirectory)/publish/publish.proj /p:PublishType=$(PB_PublishType) $(DistroSpecificMSBuildArguments) $(DistroSpecificMSBuildPublishArgs) /p:OutputRid=fedora.26-$(PB_TargetArchitecture)",
+        "workingFolder": "",
+        "failOnStandardError": "false"
+      }
+    },
+    {
+      "environment": {},
+      "enabled": true,
+      "continueOnError": false,
+      "alwaysRun": false,
+      "displayName": "Package Runtime Dep - Fedora 27",
+      "timeoutInMinutes": 0,
+      "refName": "Task45",
+      "task": {
+        "id": "d9bafed4-0b18-4f58-968d-86655b4d2ce9",
+        "versionSpec": "1.*",
+        "definitionType": "task"
+      },
+      "inputs": {
+        "filename": "docker",
+        "arguments": "run --rm $(DockerCommonRunArgs_Rhel7) $(PB_GitDirectory)/Tools/msbuild.sh $(PB_GitDirectory)/src/pkg/packaging/dir.proj $(AdditionalMSBuildPackagingArguments) $(DistroSpecificMSBuildArguments) /p:OutputRid=fedora.27-$(PB_TargetArchitecture)",
+        "workingFolder": "",
+        "failOnStandardError": "false"
+      }
+    },
+    {
+      "environment": {},
+      "enabled": true,
+      "continueOnError": false,
+      "alwaysRun": false,
+      "displayName": "Publish Runtime Dep - Fedora 27",
+      "timeoutInMinutes": 0,
+      "refName": "Task46",
+      "task": {
+        "id": "d9bafed4-0b18-4f58-968d-86655b4d2ce9",
+        "versionSpec": "1.*",
+        "definitionType": "task"
+      },
+      "inputs": {
+        "filename": "docker",
+        "arguments": "run --rm $(DockerCommonRunArgs_Rhel7) $(PB_GitDirectory)/Tools/msbuild.sh $(PB_GitDirectory)/publish/publish.proj /p:PublishType=$(PB_PublishType) $(DistroSpecificMSBuildArguments) $(DistroSpecificMSBuildPublishArgs) /p:OutputRid=fedora.27-$(PB_TargetArchitecture)",
+        "workingFolder": "",
+        "failOnStandardError": "false"
+      }
+    },
+    {
+      "environment": {},
+      "enabled": true,
+      "continueOnError": false,
+      "alwaysRun": false,
+      "displayName": "Package Runtime Dep - Centos 7",
+      "timeoutInMinutes": 0,
+      "refName": "Task47",
+      "task": {
+        "id": "d9bafed4-0b18-4f58-968d-86655b4d2ce9",
+        "versionSpec": "1.*",
+        "definitionType": "task"
+      },
+      "inputs": {
+        "filename": "docker",
+        "arguments": "run --rm $(DockerCommonRunArgs_Rhel7) $(PB_GitDirectory)/Tools/msbuild.sh $(PB_GitDirectory)/src/pkg/packaging/dir.proj $(AdditionalMSBuildPackagingArguments) $(DistroSpecificMSBuildArguments) /p:OutputRid=centos.7-$(PB_TargetArchitecture)",
+        "workingFolder": "",
+        "failOnStandardError": "false"
+      }
+    },
+    {
+      "environment": {},
+      "enabled": true,
+      "continueOnError": false,
+      "alwaysRun": false,
+      "displayName": "Publish Runtime Dep - Centos 7",
+      "timeoutInMinutes": 0,
+      "refName": "Task48",
+      "task": {
+        "id": "d9bafed4-0b18-4f58-968d-86655b4d2ce9",
+        "versionSpec": "1.*",
+        "definitionType": "task"
+      },
+      "inputs": {
+        "filename": "docker",
+        "arguments": "run --rm $(DockerCommonRunArgs_Rhel7) $(PB_GitDirectory)/Tools/msbuild.sh $(PB_GitDirectory)/publish/publish.proj /p:PublishType=$(PB_PublishType) $(DistroSpecificMSBuildArguments) $(DistroSpecificMSBuildPublishArgs) /p:OutputRid=centos.7-$(PB_TargetArchitecture)",
+        "workingFolder": "",
+        "failOnStandardError": "false"
+      }
+    },
+    {
+      "environment": {},
+      "enabled": true,
+      "continueOnError": false,
+      "alwaysRun": false,
+      "displayName": "Package Runtime Dep - Oracle Linux 7",
+      "timeoutInMinutes": 0,
+      "refName": "Task49",
+      "task": {
+        "id": "d9bafed4-0b18-4f58-968d-86655b4d2ce9",
+        "versionSpec": "1.*",
+        "definitionType": "task"
+      },
+      "inputs": {
+        "filename": "docker",
+        "arguments": "run --rm $(DockerCommonRunArgs_Rhel7) $(PB_GitDirectory)/Tools/msbuild.sh $(PB_GitDirectory)/src/pkg/packaging/dir.proj $(AdditionalMSBuildPackagingArguments) $(DistroSpecificMSBuildArguments) /p:OutputRid=oraclelinux.7-$(PB_TargetArchitecture)",
+        "workingFolder": "",
+        "failOnStandardError": "false"
+      }
+    },
+    {
+      "environment": {},
+      "enabled": true,
+      "continueOnError": false,
+      "alwaysRun": false,
+      "displayName": "Publish Runtime Dep - Oracle Linux 7",
+      "timeoutInMinutes": 0,
+      "refName": "Task50",
+      "task": {
+        "id": "d9bafed4-0b18-4f58-968d-86655b4d2ce9",
+        "versionSpec": "1.*",
+        "definitionType": "task"
+      },
+      "inputs": {
+        "filename": "docker",
+        "arguments": "run --rm $(DockerCommonRunArgs_Rhel7) $(PB_GitDirectory)/Tools/msbuild.sh $(PB_GitDirectory)/publish/publish.proj /p:PublishType=$(PB_PublishType) $(DistroSpecificMSBuildArguments) $(DistroSpecificMSBuildPublishArgs) /p:OutputRid=oraclelinux.7-$(PB_TargetArchitecture)",
+        "workingFolder": "",
+        "failOnStandardError": "false"
+      }
+    },
+    {
+      "environment": {},
+      "enabled": true,
+      "continueOnError": false,
+      "alwaysRun": false,
+      "displayName": "Package Runtime Dep - SLES",
+      "timeoutInMinutes": 0,
+      "refName": "Task51",
+      "task": {
+        "id": "d9bafed4-0b18-4f58-968d-86655b4d2ce9",
+        "versionSpec": "1.*",
+        "definitionType": "task"
+      },
+      "inputs": {
+        "filename": "docker",
+        "arguments": "run --rm $(DockerCommonRunArgs_Rhel7) $(PB_GitDirectory)/Tools/msbuild.sh $(PB_GitDirectory)/src/pkg/packaging/dir.proj $(AdditionalMSBuildPackagingArguments) $(DistroSpecificMSBuildArguments) /p:OutputRid=sles.12-$(PB_TargetArchitecture)",
+        "workingFolder": "",
+        "failOnStandardError": "false"
+      }
+    },
+    {
+      "environment": {},
+      "enabled": true,
+      "continueOnError": false,
+      "alwaysRun": false,
+      "displayName": "Publish Runtime Dep - SLES",
+      "timeoutInMinutes": 0,
+      "refName": "Task52",
+      "task": {
+        "id": "d9bafed4-0b18-4f58-968d-86655b4d2ce9",
+        "versionSpec": "1.*",
+        "definitionType": "task"
+      },
+      "inputs": {
+        "filename": "docker",
+        "arguments": "run --rm $(DockerCommonRunArgs_Rhel7) $(PB_GitDirectory)/Tools/msbuild.sh $(PB_GitDirectory)/publish/publish.proj /p:PublishType=$(PB_PublishType) $(DistroSpecificMSBuildArguments) $(DistroSpecificMSBuildPublishArgs) /p:OutputRid=sles.12-$(PB_TargetArchitecture)",
+        "workingFolder": "",
+        "failOnStandardError": "false"
+      }
+    },
+    {
+      "environment": {},
+      "enabled": true,
       "continueOnError": true,
       "alwaysRun": false,
       "displayName": "Cleanup Docker",
     "revision": 418098432,
     "visibility": "organization"
   }
-}
\ No newline at end of file
+}
@@ -3,13 +3,12 @@
     "maintainer_email": "dotnetpackages@dotnetfoundation.org",
     "vendor": ".NET Foundation",
 
-    "package_name": "%SHARED_FRAMEWORK_RPM_PACKAGE_NAME%",
+    "package_name": "%RUNTIME_DEPS_RPM_PACKAGE_NAME%",
     "install_root": "/usr/share/dotnet",
-    "install_doc": "/usr/share/doc/%SHARED_FRAMEWORK_RPM_PACKAGE_NAME%/",
 
-    "short_description": "%SHARED_FRAMEWORK_BRAND_NAME% %SHARED_FRAMEWORK_NUGET_NAME%",
-    "long_description": ".NET Core is a development platform that you can use to build command-line\napplications, microservices and modern websites. It is open source,\ncross-platform and is supported by Microsoft. We hope you enjoy using it!\nIf you do, please consider joining the active community of developers that are\ncontributing to the project on GitHub (https://github.com/dotnet/core).\nWe happily accept issues and PRs.",
-    "homepage": "https://github.com/dotnet/core",
+    "short_description": "%RUNTIME_DEPS_RPM_PACKAGE_NAME% %RUNTIME_DEPS_VERSION%",
+    "long_description": ".NET Core is a development platform that you can use to build command-line applications, microservices and modern websites. This package installs all the system dependencies for Dotnet Core Runtime.",
+    "homepage": "https://dot.net/core",
 
     "release":{
         "package_version":"1.0.0.0",
@@ -17,7 +16,7 @@
         "urgency" : "low",
         "changelog_message" : "https://github.com/dotnet/core/tree/master/release-notes"
     },
-   
+
     "control": {
         "priority":"standard",
         "section":"libs",
     "copyright": "2017 Microsoft",
     "license": {
         "type": "MIT",
-        "full_text": "Copyright (c) 2015 Microsoft\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE."
+        "full_text": "Copyright (c) 2017 Microsoft\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE."
     },
     
-  "rpm_dependencies": [{
-      "package_name": "%HOSTFXR_RPM_PACKAGE_NAME%",
-      "package_version": ""
+    "rpm_dependencies":[{
+        "package_name": "openssl-libs",
+        "package_version": ""
     },
     {
-      "package_name": "libopenssl1_0_0",
-      "package_version": ""
+        "package_name": "libicu",
+        "package_version": ""
     },
     {
-      "package_name": "libicu52_1",
-      "package_version": ""
+        "package_name": "libunwind",
+        "package_version": ""
     },
     {
-      "package_name": "libunwind",
-      "package_version": ""
+        "package_name": "libcurl",
+        "package_version": ""
     },
     {
-      "package_name": "libcurl4",
-      "package_version": ""
-    }],
-   
-    "directories" : [
-        "/usr/share/dotnet/shared",
-        "/usr/share/doc/%SHARED_FRAMEWORK_RPM_PACKAGE_NAME%"
-    ]
-}
\ No newline at end of file
+        "package_name": "libuuid",
+        "package_version": ""
+    }]
+}
diff --git a/src/installer/pkg/packaging/rpm/dotnet-runtime-deps-rpm_config_fedora.26-x64.json b/src/installer/pkg/packaging/rpm/dotnet-runtime-deps-rpm_config_fedora.26-x64.json
new file mode 100644 (file)
index 0000000..908cb4c
--- /dev/null
@@ -0,0 +1,48 @@
+{
+    "maintainer_name": ".NET Core Team",
+    "maintainer_email": "dotnetpackages@dotnetfoundation.org",
+    "vendor": ".NET Foundation",
+
+    "package_name": "%RUNTIME_DEPS_RPM_PACKAGE_NAME%",
+    "install_root": "/usr/share/dotnet",
+
+    "short_description": "%RUNTIME_DEPS_RPM_PACKAGE_NAME% %RUNTIME_DEPS_VERSION%",
+    "long_description": ".NET Core is a development platform that you can use to build command-line applications, microservices and modern websites. This package installs all the system dependencies for Dotnet Core Runtime.",
+    "homepage": "https://dot.net/core",
+
+    "release":{
+        "package_version":"1.0.0.0",
+        "package_revision":"1",
+        "urgency" : "low",
+        "changelog_message" : "https://github.com/dotnet/core/tree/master/release-notes"
+    },
+
+    "control": {
+        "priority":"standard",
+        "section":"libs",
+        "architecture":"amd64"
+    },
+
+    "copyright": "2017 Microsoft",
+    "license": {
+        "type": "MIT",
+        "full_text": "Copyright (c) 2017 Microsoft\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE."
+    },
+    
+    "rpm_dependencies":[{
+        "package_name": "compat-openssl10",
+        "package_version": ""
+    },
+    {
+        "package_name": "libicu",
+        "package_version": ""
+    },
+    {
+        "package_name": "libunwind",
+        "package_version": ""
+    },
+    {
+        "package_name": "libcurl",
+        "package_version": ""
+    }]
+}
diff --git a/src/installer/pkg/packaging/rpm/dotnet-runtime-deps-rpm_config_fedora.27-x64.json b/src/installer/pkg/packaging/rpm/dotnet-runtime-deps-rpm_config_fedora.27-x64.json
new file mode 100644 (file)
index 0000000..908cb4c
--- /dev/null
@@ -0,0 +1,48 @@
+{
+    "maintainer_name": ".NET Core Team",
+    "maintainer_email": "dotnetpackages@dotnetfoundation.org",
+    "vendor": ".NET Foundation",
+
+    "package_name": "%RUNTIME_DEPS_RPM_PACKAGE_NAME%",
+    "install_root": "/usr/share/dotnet",
+
+    "short_description": "%RUNTIME_DEPS_RPM_PACKAGE_NAME% %RUNTIME_DEPS_VERSION%",
+    "long_description": ".NET Core is a development platform that you can use to build command-line applications, microservices and modern websites. This package installs all the system dependencies for Dotnet Core Runtime.",
+    "homepage": "https://dot.net/core",
+
+    "release":{
+        "package_version":"1.0.0.0",
+        "package_revision":"1",
+        "urgency" : "low",
+        "changelog_message" : "https://github.com/dotnet/core/tree/master/release-notes"
+    },
+
+    "control": {
+        "priority":"standard",
+        "section":"libs",
+        "architecture":"amd64"
+    },
+
+    "copyright": "2017 Microsoft",
+    "license": {
+        "type": "MIT",
+        "full_text": "Copyright (c) 2017 Microsoft\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE."
+    },
+    
+    "rpm_dependencies":[{
+        "package_name": "compat-openssl10",
+        "package_version": ""
+    },
+    {
+        "package_name": "libicu",
+        "package_version": ""
+    },
+    {
+        "package_name": "libunwind",
+        "package_version": ""
+    },
+    {
+        "package_name": "libcurl",
+        "package_version": ""
+    }]
+}
diff --git a/src/installer/pkg/packaging/rpm/dotnet-runtime-deps-rpm_config_opensuse.42-x64.json b/src/installer/pkg/packaging/rpm/dotnet-runtime-deps-rpm_config_opensuse.42-x64.json
new file mode 100644 (file)
index 0000000..879384d
--- /dev/null
@@ -0,0 +1,48 @@
+{
+    "maintainer_name": ".NET Core Team",
+    "maintainer_email": "dotnetpackages@dotnetfoundation.org",
+    "vendor": ".NET Foundation",
+
+    "package_name": "%RUNTIME_DEPS_RPM_PACKAGE_NAME%",
+    "install_root": "/usr/share/dotnet",
+
+    "short_description": "%RUNTIME_DEPS_RPM_PACKAGE_NAME% %RUNTIME_DEPS_VERSION%",
+    "long_description": ".NET Core is a development platform that you can use to build command-line applications, microservices and modern websites. This package installs all the system dependencies for Dotnet Core Runtime.",
+    "homepage": "https://dot.net/core",
+
+    "release":{
+        "package_version":"1.0.0.0",
+        "package_revision":"1",
+        "urgency" : "low",
+        "changelog_message" : "https://github.com/dotnet/core/tree/master/release-notes"
+    },
+
+    "control": {
+        "priority":"standard",
+        "section":"libs",
+        "architecture":"amd64"
+    },
+
+    "copyright": "2017 Microsoft",
+    "license": {
+        "type": "MIT",
+        "full_text": "Copyright (c) 2017 Microsoft\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE."
+    },
+    
+    "rpm_dependencies":[{
+        "package_name": "libopenssl1_0_0",
+        "package_version": ""
+    },
+    {
+        "package_name": "libicu52_1",
+        "package_version": ""
+    },
+    {
+        "package_name": "libunwind",
+        "package_version": ""
+    },
+    {
+        "package_name": "libcurl4",
+        "package_version": ""
+    }]
+}
diff --git a/src/installer/pkg/packaging/rpm/dotnet-runtime-deps-rpm_config_oraclelinux.7-x64.json b/src/installer/pkg/packaging/rpm/dotnet-runtime-deps-rpm_config_oraclelinux.7-x64.json
new file mode 100644 (file)
index 0000000..660191e
--- /dev/null
@@ -0,0 +1,48 @@
+{
+    "maintainer_name": ".NET Core Team",
+    "maintainer_email": "dotnetpackages@dotnetfoundation.org",
+    "vendor": ".NET Foundation",
+
+    "package_name": "%RUNTIME_DEPS_RPM_PACKAGE_NAME%",
+    "install_root": "/usr/share/dotnet",
+
+    "short_description": "%RUNTIME_DEPS_RPM_PACKAGE_NAME% %RUNTIME_DEPS_VERSION%",
+    "long_description": ".NET Core is a development platform that you can use to build command-line applications, microservices and modern websites. This package installs all the system dependencies for Dotnet Core Runtime.",
+    "homepage": "https://dot.net/core",
+
+    "release":{
+        "package_version":"1.0.0.0",
+        "package_revision":"1",
+        "urgency" : "low",
+        "changelog_message" : "https://github.com/dotnet/core/tree/master/release-notes"
+    },
+
+    "control": {
+        "priority":"standard",
+        "section":"libs",
+        "architecture":"amd64"
+    },
+
+    "copyright": "2017 Microsoft",
+    "license": {
+        "type": "MIT",
+        "full_text": "Copyright (c) 2017 Microsoft\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE."
+    },
+    
+    "rpm_dependencies":[{
+        "package_name": "openssl-libs",
+        "package_version": ""
+    },
+    {
+        "package_name": "libicu",
+        "package_version": ""
+    },
+    {
+        "package_name": "libunwind",
+        "package_version": ""
+    },
+    {
+        "package_name": "libcurl",
+        "package_version": ""
+    }]
+}
diff --git a/src/installer/pkg/packaging/rpm/dotnet-runtime-deps-rpm_config_sles.12-x64.json b/src/installer/pkg/packaging/rpm/dotnet-runtime-deps-rpm_config_sles.12-x64.json
new file mode 100644 (file)
index 0000000..896e97b
--- /dev/null
@@ -0,0 +1,40 @@
+{
+    "maintainer_name": ".NET Core Team",
+    "maintainer_email": "dotnetpackages@dotnetfoundation.org",
+    "vendor": ".NET Foundation",
+
+    "package_name": "%RUNTIME_DEPS_RPM_PACKAGE_NAME%",
+    "install_root": "/usr/share/dotnet",
+
+    "short_description": "%RUNTIME_DEPS_RPM_PACKAGE_NAME% %RUNTIME_DEPS_VERSION%",
+    "long_description": ".NET Core is a development platform that you can use to build command-line applications, microservices and modern websites. This package installs all the system dependencies for Dotnet Core Runtime.",
+    "homepage": "https://dot.net/core",
+
+    "release":{
+        "package_version":"1.0.0.0",
+        "package_revision":"1",
+        "urgency" : "low",
+        "changelog_message" : "https://github.com/dotnet/core/tree/master/release-notes"
+    },
+
+    "control": {
+        "priority":"standard",
+        "section":"libs",
+        "architecture":"amd64"
+    },
+
+    "copyright": "2017 Microsoft",
+    "license": {
+        "type": "MIT",
+        "full_text": "Copyright (c) 2017 Microsoft\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE."
+    },
+    
+    "rpm_dependencies":[{
+        "package_name": "libopenssl1_0_0",
+        "package_version": ""
+    },
+    {
+        "package_name": "libcurl4",
+        "package_version": ""
+    }]
+}
index 3a6a8e8..ba0b4d0 100644 (file)
   "rpm_dependencies": [{
       "package_name": "%HOSTFXR_RPM_PACKAGE_NAME%",
       "package_version": ""
-    },
-    {
-      "package_name": "openssl-libs",
-      "package_version": ""
-    },   
-    {
-      "package_name": "libcurl",
-      "package_version": ""
     }],
    
     "directories" : [
         "/usr/share/dotnet/shared",
         "/usr/share/doc/%SHARED_FRAMEWORK_RPM_PACKAGE_NAME%"
     ]
-}
\ No newline at end of file
+}
index cfe050f..7f95e65 100644 (file)
         "dotnet",
         "dotnet-nightly"
     ],
+    
+    "rpm_dependencies": [{
+        "package_name": "%RUNTIME_DEPS_RPM_PACKAGE_NAME%",
+        "package_version": "%RUNTIME_DEPS_VERSION%"
+    }],
 
     "directories" : [
         "/usr/share/dotnet",
@@ -43,4 +48,4 @@
 
     "after_install_source": "scripts/after_install_host.sh",
     "after_remove_source": "scripts/after_remove_host.sh"
-}
\ No newline at end of file
+}
index 77b10da..8bb7a15 100644 (file)
@@ -9,7 +9,9 @@
     <HostFxrRpmPkgName>$(HostFxrRpmPkgName.ToLower())</HostFxrRpmPkgName>
     <SharedFxRpmPkgName>dotnet-runtime-$(SharedFrameworkNugetVersion)</SharedFxRpmPkgName>
     <SharedFxRpmPkgName>$(SharedFxRpmPkgName.ToLower())</SharedFxRpmPkgName>
+    <RuntimeDependenciesRpmPkgName>$(DotnetRuntimeDependenciesPackageString)$(ProductVersion)</RuntimeDependenciesRpmPkgName>
+    <RuntimeDependenciesRpmPkgName>$(RuntimeDependenciesRpmPkgName.ToLower())</RuntimeDependenciesRpmPkgName>
     <TemplatesDir>$(MSBuildThisFileDirectory)/templates</TemplatesDir>
     <ScriptsDir>$(MSBuildThisFileDirectory)/scripts</ScriptsDir>
   </PropertyGroup>
-</Project>
\ No newline at end of file
+</Project>
index 491c7da..6855b6b 100644 (file)
@@ -8,14 +8,19 @@
   <PropertyGroup>
     <IsRPMBasedDistro Condition="'$(InstallerExtension)' == '.rpm'">true</IsRPMBasedDistro>
     <BuildRpmPackage Condition="'$(IsRPMBasedDistro)' == true and '$(TargetArchitecture)' == 'x64'">true</BuildRpmPackage>
+    <BuildRuntimeRpms>true</BuildRuntimeRpms>
   </PropertyGroup>
 
   <Target Name="GenerateRpms"
           DependsOnTargets="TestFPMTool;BuildRpms;"
           Condition="'$(BuildRpmPackage)'=='true'" />
+  
+  <Target Name="GenerateRuntimeRpms" 
+          DependsOnTargets="GenerateSharedHostRpm;GenerateHostFxrRpm;GenerateSharedFrameworkRpm"
+          Condition="'$(BuildRuntimeRpms)' == 'true'" />
 
   <Target Name="BuildRpms"
-          DependsOnTargets="GenerateSharedHostRpm;GenerateHostFxrRpm;GenerateSharedFrameworkRpm"
+          DependsOnTargets="GenerateRuntimeRpms; GenerateRuntimeDependenciesRpm"
           Condition="'$(BuildRpmPackage)'=='true' and '$(FPMPresent)'=='true'" />
 
   <Target Name="GenerateSharedHostRpm">
       <SharedHostTokenValue Include="%SHARED_HOST_BRAND_NAME%">
         <ReplacementString>$(SharedHostBrandName)</ReplacementString>
       </SharedHostTokenValue>
+      <SharedHostTokenValue Include="%RUNTIME_DEPS_RPM_PACKAGE_NAME%">
+        <ReplacementString>$(RuntimeDependenciesRpmPkgName)</ReplacementString>
+      </SharedHostTokenValue>
+      <SharedHostTokenValue Include="%RUNTIME_DEPS_VERSION%">
+        <ReplacementString>$(RuntimeDepsRpmVersion)</ReplacementString> 
+      </SharedHostTokenValue>
     </ItemGroup>
 
     <ReplaceFileContents InputFile="$(ConfigJsonFile)"
       <InputRoot>$(SharedFrameworkPublishRoot)</InputRoot>
       <RpmFile>$(SharedFrameworkInstallerFile)</RpmFile>
       <ConfigJsonName>dotnet-sharedframework-rpm_config.json</ConfigJsonName>
-      <ConfigJsonName Condition="$(PackageTargetRid.StartsWith('opensuse'))">dotnet-sharedframework-opensuse-rpm_config.json</ConfigJsonName>
       <ConfigJsonFile>$(rpmPackagingConfigPath)$(ConfigJsonName)</ConfigJsonFile>
       <RpmIntermediatesDir>$(PackagesIntermediateDir)$(RpmPackageName)/$(RpmPackageVersion)</RpmIntermediatesDir>
     </PropertyGroup>
           UseHardlinksIfPossible="False" />
 
   </Target>
+  
+  <Target Name="GenerateRuntimeDependenciesRpm">
+    <PropertyGroup>
+      <RpmPackageName>$(RuntimeDependenciesRpmPkgName)</RpmPackageName>
+      <RpmPackageVersion>$(SharedFrameworkNugetVersion)</RpmPackageVersion>
+      <RpmFile>$(DotnetRuntimeDependenciesPackageInstallerFile)</RpmFile>
+      <ConfigJsonName>dotnet-runtime-deps-rpm_config_$(OutputRid).json</ConfigJsonName>
+      <ConfigJsonFile>$(rpmPackagingConfigPath)$(ConfigJsonName)</ConfigJsonFile>
+      <RpmIntermediatesDir>$(PackagesIntermediateDir)$(RpmPackageName)/$(RpmPackageVersion)</RpmIntermediatesDir>
+    </PropertyGroup>
+
+    <PropertyGroup>
+      <rpmLayoutDirectory>$(RpmIntermediatesDir)/rpmLayoutDirectory/</rpmLayoutDirectory>
+      <rpmLayoutPackageRoot>$(rpmLayoutDirectory)package_root</rpmLayoutPackageRoot>
+      <rpmLayoutDocs>$(rpmLayoutDirectory)docs</rpmLayoutDocs>
+      <rpmLayoutTemplates>$(rpmLayoutDirectory)templates</rpmLayoutTemplates> <!-- Copyright, Changelog -->
+    </PropertyGroup>
+
+    <!-- Error out if the configuration file doesn't exist -->
+    <Error Condition="!Exists('$(ConfigJsonFile)')" Text="Config file does not exist : '$(ConfigJsonFile)'" />
+
+    <RemoveDir Condition="Exists('$(RpmIntermediatesDir)')" Directories="$(RpmIntermediatesDir)" />
+    <MakeDir Directories="$(RpmIntermediatesDir)" />
+
+    <!-- Create empty rpm layout -->
+    <RemoveDir Condition="Exists('$(rpmLayoutDirectory)')" Directories="$(rpmLayoutDirectory)" />
+    <MakeDir Directories="$(rpmLayoutDirectory)" />
+    <MakeDir Directories="$(rpmLayoutPackageRoot)" />
+    <MakeDir Directories="$(rpmLayoutDocs)" />
+    <MakeDir Directories="$(rpmLayoutTemplates)" />
+    
+     <!-- Copy files to rpm layout -->
+    <ItemGroup>
+        <HFFiles Include="$(InputRoot)/**/*" />
+        <HFTemplatesFiles Include="$(TemplatesDir)/**/*" />
+    </ItemGroup>
+
+    <Copy SourceFiles="@(HFFiles)" DestinationFiles="@(HFFiles->'$(rpmLayoutPackageRoot)/%(RecursiveDir)%(Filename)%(Extension)')" />
+    <Copy SourceFiles="@(HFTemplatesFiles)" DestinationFiles="@(HFTemplatesFiles->'$(rpmLayoutTemplates)/%(RecursiveDir)%(Filename)%(Extension)')" />
+
+    <!-- Replace config json variables -->
+    <ItemGroup>
+      <SharedFrameworkTokenValue Include="%RUNTIME_DEPS_RPM_PACKAGE_NAME%">
+        <ReplacementString>$(RuntimeDependenciesRpmPkgName)</ReplacementString>
+      </SharedFrameworkTokenValue>
+      <SharedFrameworkTokenValue Include="%RUNTIME_DEPS_VERSION%">
+        <ReplacementString>$(RuntimeDepsRpmVersion)</ReplacementString> 
+      </SharedFrameworkTokenValue>
+    </ItemGroup>
+
+    <ReplaceFileContents InputFile="$(ConfigJsonFile)"
+                         DestinationFile="$(rpmLayoutDirectory)$(rpmConfigJsonName)"
+                         ReplacementItems="@(SharedFrameworkTokenValue)" />
+
+    <!-- Call the task to build the pre-reqs (parameters, copyright, changelog) for calling the FPM tool -->
+    <BuildFPMToolPreReqs  InputDir="$(rpmLayoutDirectory)"
+                          OutputDir="$(RpmIntermediatesDir)"
+                          PackageVersion="$(RpmPackageVersion)"
+                          ConfigJsonFile="$(rpmLayoutDirectory)$(rpmConfigJsonName)">
+                          <Output TaskParameter="FPMParameters" PropertyName="FPMCmdParameters" />
+    </BuildFPMToolPreReqs>
+
+    <!-- Build the RPM package by calling the FPM tool and passing the parameter list -->
+    <Exec Command="fpm $(FPMCmdParameters)"  WorkingDirectory="$(RpmIntermediatesDir)" />
+
+    <!-- Copy package to output -->
+    <ItemGroup>
+      <GeneratedRpmFiles Remove="@(GeneratedRpmFiles)" />
+      <GeneratedRpmFiles Include="$(RpmIntermediatesDir)/*.rpm" />
+    </ItemGroup>
+
+    <Error Text="@(GeneratedRpmFiles->Count()) .rpm files generated." Condition="'@(GeneratedRpmFiles->Count())' != 1" />
+
+    <Copy SourceFiles="@(GeneratedRpmFiles)"
+          DestinationFiles="$(RpmFile)"
+          OverwriteReadOnlyFiles="True"
+          SkipUnchangedFiles="False"
+          UseHardlinksIfPossible="False" />
+
+  </Target>
 
   <Target Name="TestFPMTool">
 
              Text="FPM tool Not found, RPM packages will not be built."
              Importance="High" />
   </Target>
-</Project>
\ No newline at end of file
+</Project>
index 904cda1..4e46280 100644 (file)
     <PublishRid Include="linux-arm" />
     <PublishRid Include="rhel.7-x64" />
     <PublishRid Include="opensuse.42-x64" />
+    <PublishRid Include="centos.7-x64" />
+    <PublishRid Include="fedora.26-x64" />
+    <PublishRid Include="fedora.27-x64" />
+    <PublishRid Include="oraclelinux.7-x64" />
+    <PublishRid Include="sles.12-x64" />
   </ItemGroup>
 </Project>