aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorArsenShnurkov <ArsenShnurkov@users.noreply.github.com>2017-04-28 11:44:40 +0300
committerArsenShnurkov <ArsenShnurkov@users.noreply.github.com>2017-04-28 11:44:40 +0300
commit010eb4ed29fb941490c189e93dc42cc7a8caeb56 (patch)
tree881aa705d3532291b9d28e6ebe373fe6fda0993a
parentnew versions of build (diff)
downloaddotnet-010eb4ed29fb941490c189e93dc42cc7a8caeb56.tar.gz
dotnet-010eb4ed29fb941490c189e93dc42cc7a8caeb56.tar.bz2
dotnet-010eb4ed29fb941490c189e93dc42cc7a8caeb56.zip
GAC installing moved to pkg_postinst/pkg_prerm
-rw-r--r--dev-dotnet/msbuildtasks/files/csproj.patch35
-rw-r--r--dev-dotnet/msbuildtasks/files/location.patch2
-rw-r--r--dev-dotnet/msbuildtasks/files/references-2016052301.patch21
-rw-r--r--dev-dotnet/msbuildtasks/msbuildtasks-1.5.0.235.ebuild17
-rw-r--r--dev-dotnet/msbuildtasks/msbuildtasks-1.5.0.240.ebuild20
-rw-r--r--eclass/gac.eclass24
6 files changed, 80 insertions, 39 deletions
diff --git a/dev-dotnet/msbuildtasks/files/csproj.patch b/dev-dotnet/msbuildtasks/files/csproj.patch
new file mode 100644
index 0000000..2df14cf
--- /dev/null
+++ b/dev-dotnet/msbuildtasks/files/csproj.patch
@@ -0,0 +1,35 @@
+--- a/Source/MSBuild.Community.Tasks/MSBuild.Community.Tasks.csproj
++++ b/Source/MSBuild.Community.Tasks/MSBuild.Community.Tasks.csproj
+@@ -31,21 +31,18 @@
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
+ <DebugType>pdbonly</DebugType>
+ <Optimize>true</Optimize>
+- <OutputPath>..\..\Build\</OutputPath>
++ <OutputPath>bin\Release\</OutputPath>
+ <DefineConstants>
+ </DefineConstants>
+ <ErrorReport>prompt</ErrorReport>
+ <WarningLevel>4</WarningLevel>
+- <DocumentationFile>..\..\Build\MSBuild.Community.Tasks.xml</DocumentationFile>
++ <DocumentationFile>bin\Release\MSBuild.Community.Tasks.xml</DocumentationFile>
+ <TreatWarningsAsErrors>false</TreatWarningsAsErrors>
+ <CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
+ <Prefer32Bit>false</Prefer32Bit>
+ </PropertyGroup>
+ <ItemGroup>
+- <Reference Include="DotNetZip, Version=1.10.1.0, Culture=neutral, PublicKeyToken=6583c7c814667745, processorArchitecture=MSIL">
+- <HintPath>..\packages\DotNetZip.1.10.1\lib\net20\DotNetZip.dll</HintPath>
+- <Private>True</Private>
+- </Reference>
++ <Reference Include="Ionic.Zip.Reduced" />
+ <Reference Include="Microsoft.Build.Framework" />
+ <Reference Include="Microsoft.Build.Utilities.v4.0" />
+ <Reference Include="System" />
+@@ -270,7 +267,6 @@
+ <Content Include="NUnitReport.xsl">
+ <CopyToOutputDirectory>Always</CopyToOutputDirectory>
+ </Content>
+- <None Include="packages.config" />
+ </ItemGroup>
+ <ItemGroup>
+ <EmbeddedResource Include="Properties\Resources.resx">
diff --git a/dev-dotnet/msbuildtasks/files/location.patch b/dev-dotnet/msbuildtasks/files/location.patch
index 21800b1..6333c4e 100644
--- a/dev-dotnet/msbuildtasks/files/location.patch
+++ b/dev-dotnet/msbuildtasks/files/location.patch
@@ -8,7 +8,7 @@
- <MSBuildCommunityTasksPath Condition="'$(MSBuildCommunityTasksPath)' == '' and '$(MSBuildThisFile)' == 'MSBuild.Community.Tasks.Targets'">$(MSBuildThisFileDirectory)</MSBuildCommunityTasksPath>
- <MSBuildCommunityTasksPath Condition="'$(MSBuildCommunityTasksPath)' == '' and '$(MSBuildThisFile)' == 'MSBuildTasks.targets'">$(MSBuildThisFileDirectory)\..\tools</MSBuildCommunityTasksPath>
- <MSBuildCommunityTasksLib Condition="'$(OS)' == 'Windows_NT'">$([MSBUILD]::Unescape($(MSBuildCommunityTasksPath)\MSBuild.Community.Tasks.dll))</MSBuildCommunityTasksLib>
-- <MSBuildCommunityTasksLib Condition="'$(OS)' != 'Windows_NT'">$(MSBuildCommunityTasksPath)\MSBuild.Community.Tasks.dll)</MSBuildCommunityTasksLib>
+- <MSBuildCommunityTasksLib Condition="'$(OS)' != 'Windows_NT'">$(MSBuildCommunityTasksPath)\MSBuild.Community.Tasks.dll</MSBuildCommunityTasksLib>
- <MSBuildCommunityTasksLib Condition="!Exists('$(MSBuildCommunityTasksLib)')">MSBuild.Community.Tasks.dll</MSBuildCommunityTasksLib>
+ <PropertyGroup Condition="Exists('/usr/lib64/mono/msbuildtasks/MSBuild.Community.Tasks.dll')">
+ <MSBuildCommunityTasksPath>/usr/lib64/mono/msbuildtasks</MSBuildCommunityTasksPath>
diff --git a/dev-dotnet/msbuildtasks/files/references-2016052301.patch b/dev-dotnet/msbuildtasks/files/references-2016052301.patch
deleted file mode 100644
index b087397..0000000
--- a/dev-dotnet/msbuildtasks/files/references-2016052301.patch
+++ /dev/null
@@ -1,21 +0,0 @@
---- a/Source/MSBuild.Community.Tasks/MSBuild.Community.Tasks.csproj
-+++ b/Source/MSBuild.Community.Tasks/MSBuild.Community.Tasks.csproj
-@@ -42,9 +42,7 @@
- <Prefer32Bit>false</Prefer32Bit>
- </PropertyGroup>
- <ItemGroup>
-- <Reference Include="Ionic.Zip.Reduced, Version=1.9.1.8, Culture=neutral, PublicKeyToken=edbe51ad942a3f5c, processorArchitecture=MSIL">
-- <HintPath>..\packages\DotNetZip.Reduced.1.9.1.8\lib\net20\Ionic.Zip.Reduced.dll</HintPath>
-- </Reference>
-+ <Reference Include="Ionic.Zip.Reduced" />
- <Reference Include="Microsoft.Build.Framework" />
- <Reference Include="Microsoft.Build.Utilities.v4.0" />
- <Reference Include="System" />
-@@ -269,7 +266,6 @@
- <Content Include="NUnitReport.xsl">
- <CopyToOutputDirectory>Always</CopyToOutputDirectory>
- </Content>
-- <None Include="packages.config" />
- </ItemGroup>
- <ItemGroup>
- <EmbeddedResource Include="Properties\Resources.resx"> \ No newline at end of file
diff --git a/dev-dotnet/msbuildtasks/msbuildtasks-1.5.0.235.ebuild b/dev-dotnet/msbuildtasks/msbuildtasks-1.5.0.235.ebuild
index 5ac1ef0..2d9a651 100644
--- a/dev-dotnet/msbuildtasks/msbuildtasks-1.5.0.235.ebuild
+++ b/dev-dotnet/msbuildtasks/msbuildtasks-1.5.0.235.ebuild
@@ -29,7 +29,7 @@ DEPEND="${COMMON_DEPEND}
"
src_prepare() {
- eapply "${FILESDIR}/references-2016052301.patch"
+ eapply "${FILESDIR}/csproj.patch"
eapply "${FILESDIR}/location.patch"
eapply_user
}
@@ -44,8 +44,19 @@ src_install() {
else
DIR="Release"
fi
- egacinstall "Source/MSBuild.Community.Tasks/bin/${DIR}/MSBuild.Community.Tasks.dll"
+ insinto "/usr/lib/mono/${EBUILD_FRAMEWORK}"
+ doins "Source/MSBuild.Community.Tasks/bin/${DIR}/MSBuild.Community.Tasks.dll"
einstall_pc_file "${PN}" "${PV}" "MSBuild.Community.Tasks"
- insinto "/usr/lib/mono/4.5"
+ insinto "/usr/lib/mono/xbuild"
doins "Source/MSBuild.Community.Tasks/MSBuild.Community.Tasks.Targets"
}
+
+pkg_postinst()
+{
+ egacadd "${PREFIX}/usr/lib/mono/${EBUILD_FRAMEWORK}/MSBuild.Community.Tasks.dll"
+}
+
+pkg_prerm()
+{
+ egacdel "MSBuild.Community.Tasks"
+}
diff --git a/dev-dotnet/msbuildtasks/msbuildtasks-1.5.0.240.ebuild b/dev-dotnet/msbuildtasks/msbuildtasks-1.5.0.240.ebuild
index 95d9383..71467ad 100644
--- a/dev-dotnet/msbuildtasks/msbuildtasks-1.5.0.240.ebuild
+++ b/dev-dotnet/msbuildtasks/msbuildtasks-1.5.0.240.ebuild
@@ -14,7 +14,8 @@ HOMEPAGE="https://github.com/loresoft/msbuildtasks"
EGIT_COMMIT="014ed0f7a69f4936d7b3b438a5ceca78f902e0ef"
SRC_URI="${HOMEPAGE}/archive/${EGIT_COMMIT}.tar.gz -> ${PN}-${PV}.tar.gz"
RESTRICT="mirror"
-S="${WORKDIR}/${PN}-${PV}"
+NAME="msbuildtasks"
+S="${WORKDIR}/${NAME}-${EGIT_COMMIT}"
DESCRIPTION="The MSBuild Community Tasks Project is an open source project for MSBuild tasks."
LICENSE="BSD" # https://github.com/loresoft/msbuildtasks/blob/master/LICENSE
@@ -30,7 +31,7 @@ DEPEND="${COMMON_DEPEND}
"
src_prepare() {
- eapply "${FILESDIR}/references-2016052301.patch"
+ eapply "${FILESDIR}/csproj.patch"
eapply "${FILESDIR}/location.patch"
eapply_user
}
@@ -45,8 +46,19 @@ src_install() {
else
DIR="Release"
fi
- egacinstall "Source/MSBuild.Community.Tasks/bin/${DIR}/MSBuild.Community.Tasks.dll"
+ insinto "/usr/lib/mono/${EBUILD_FRAMEWORK}"
+ doins "Source/MSBuild.Community.Tasks/bin/${DIR}/MSBuild.Community.Tasks.dll"
einstall_pc_file "${PN}" "${PV}" "MSBuild.Community.Tasks"
- insinto "/usr/lib/mono/4.5"
+ insinto "/usr/lib/mono/xbuild"
doins "Source/MSBuild.Community.Tasks/MSBuild.Community.Tasks.Targets"
}
+
+pkg_postinst()
+{
+ egacadd "${PREFIX}/usr/lib/mono/${EBUILD_FRAMEWORK}/MSBuild.Community.Tasks.dll"
+}
+
+pkg_prerm()
+{
+ egacdel "MSBuild.Community.Tasks"
+}
diff --git a/eclass/gac.eclass b/eclass/gac.eclass
index 7830c0c..aed7d6b 100644
--- a/eclass/gac.eclass
+++ b/eclass/gac.eclass
@@ -35,27 +35,31 @@ egacinstall() {
}
# @FUNCTION: egacadd
-# @DESCRIPTION: install package to GAC
+# @DESCRIPTION: install package to GAC in pkg_postinst phase
+# the idea is to allow registration in GAC for binary packages for different PREFIX-es
+# see http://arsenshnurkov.github.io/gentoo-mono-handbook/gac.htm
egacadd() {
if use gac; then
- use !prefix && has "${EAPI:-0}" 0 1 2 && ED="${D}"
+ GACROOT="${PREFIX}/usr/$(get_libdir)"
+ GACDIR="/usr/$(get_libdir)/mono/gac"
+ einfo egacadd: GACROOT="${GACROOT}", GACDIR="${GACDIR}"
gacutil -i "${1}" \
- -root "${ED}"/usr/$(get_libdir) \
- -gacdir /usr/$(get_libdir) \
+ -root ${GACROOT} \
+ -gacdir "${GACDIR}" \
-package ${2:-${GACPN:-${PN}}} \
|| die "installing ${1} into the Global Assembly Cache failed"
fi
}
# @FUNCTION: egacdel
-# @DESCRIPTION: remove package from GAC
+# @DESCRIPTION: remove package from GAC in pkg_prerm phase
+# see notes for egacadd()
egacdel() {
if use gac; then
- use !prefix && has "${EAPI:-0}" 0 1 2 && ED="${D}"
- gacutil -u "${1}" \
- -root "${ED}"/usr/$(get_libdir) \
- -gacdir /usr/$(get_libdir) \
- -package ${2:-${GACPN:-${PN}}}
+ GACROOT="${PREFIX}/usr/$(get_libdir)"
+ GACDIR="/usr/$(get_libdir)/mono/gac"
+ einfo gacutil -u "${1}" -root "${GACROOT}" -gacdir "${GACDIR}"
+ gacutil -u "${1}" -root "${GACROOT}" -gacdir "${GACDIR}"
# don't die
fi
}