commit:     90d9561ee1566b33cfdad8223a7d3586decb7a55
Author:     ArsenShnurkov <Arsen.Shnurkov <AT> gmail <DOT> com>
AuthorDate: Sun Jul 17 03:06:19 2016 +0000
Commit:     Heather Cynede <cynede <AT> gentoo <DOT> org>
CommitDate: Sun Jul 17 03:06:19 2016 +0000
URL:        https://gitweb.gentoo.org/proj/dotnet.git/commit/?id=90d9561e

NUnit.Runners package is now created

 .../nunit/files/removing-2.0-compatibiility.patch  | 29 +++++++
 .../nunit/files/removing-tests-from-nproj.patch    | 12 +++
 dev-util/nunit/metadata.xml                        | 12 +++
 dev-util/nunit/nunit-2.6.4_p2015011102-r1.ebuild   | 99 ++++++++++++++++++++++
 4 files changed, 152 insertions(+)

diff --git a/dev-util/nunit/files/removing-2.0-compatibiility.patch 
b/dev-util/nunit/files/removing-2.0-compatibiility.patch
new file mode 100644
index 0000000..56ff347
--- /dev/null
+++ b/dev-util/nunit/files/removing-2.0-compatibiility.patch
@@ -0,0 +1,29 @@
+diff --git a/src/NUnitEngine/mono-addins/Mono.Addins.csproj 
b/src/NUnitEngine/mono-addins/Mono.Addins.csproj
+index cb09546..7536d46 100644
+--- a/src/NUnitEngine/mono-addins/Mono.Addins.csproj
++++ b/src/NUnitEngine/mono-addins/Mono.Addins.csproj
+@@ -43,24 +41,6 @@
+   </ItemGroup>
+   <ItemGroup>
+     <Compile Include="AssemblyInfo.cs" />
+-    <Compile Include="Compatibility\Check.cs" />
+-    <Compile Include="Compatibility\Enumerable.cs" />
+-    <Compile Include="Compatibility\ExtensionAttribute.cs" />
+-    <Compile Include="Compatibility\Funcs.cs" />
+-    <Compile Include="Compatibility\Grouping.cs" />
+-    <Compile Include="Compatibility\HashPrimeNumbers.cs" />
+-    <Compile Include="Compatibility\HashSet.cs" />
+-    <Compile Include="Compatibility\IGrouping.cs" />
+-    <Compile Include="Compatibility\ILookup_T.cs" />
+-    <Compile Include="Compatibility\IOrderedEnumerable_T.cs" />
+-    <Compile Include="Compatibility\Lookup.cs" />
+-    <Compile Include="Compatibility\OrderedEnumerable.cs" />
+-    <Compile Include="Compatibility\OrderedSequence.cs" />
+-    <Compile Include="Compatibility\QuickSort.cs" />
+-    <Compile Include="Compatibility\SortContext.cs" />
+-    <Compile Include="Compatibility\SortDirection.cs" />
+-    <Compile Include="Compatibility\SortSequenceContext.cs" />
+-    <Compile Include="Compatibility\Tuple.cs" />
+     <Compile Include="Mono.Addins\ExtensionNode.cs" />
+     <Compile Include="Mono.Addins\ExtensionTree.cs" />
+     <Compile Include="Mono.Addins\TreeNode.cs" />

diff --git a/dev-util/nunit/files/removing-tests-from-nproj.patch 
b/dev-util/nunit/files/removing-tests-from-nproj.patch
new file mode 100644
index 0000000..8c117eb
--- /dev/null
+++ b/dev-util/nunit/files/removing-tests-from-nproj.patch
@@ -0,0 +1,12 @@
+diff --git a/NUnit.proj b/NUnit.proj
+index 31e4dab..a964b88 100644
+--- a/NUnit.proj
++++ b/NUnit.proj
+@@ -659,7 +659,6 @@
+ 
+     <!-- Addin tests -->
+     <EngineProjects Include="$(AddinSrcDir)\addin-tests\addin-tests.csproj" />
+-    <EngineProjects 
Include="$(AddinSrcDir)\nunit.v2.driver.tests\nunit.v2.driver.tests.csproj" />
+ 
+   </ItemGroup>
+ 

diff --git a/dev-util/nunit/metadata.xml b/dev-util/nunit/metadata.xml
new file mode 100644
index 0000000..b855da0
--- /dev/null
+++ b/dev-util/nunit/metadata.xml
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd";>
+<pkgmetadata>
+       <maintainer type="project">
+               <email>dot...@gentoo.org</email>
+               <description>Gentoo Dotnet Project</description>
+       </maintainer>
+       <use>
+               <flag name='developer'>enables debug information for any of 
debug and release builds</flag>
+               <flag name='nupkg'>creates local nuget package</flag>
+       </use>
+</pkgmetadata>

diff --git a/dev-util/nunit/nunit-2.6.4_p2015011102-r1.ebuild 
b/dev-util/nunit/nunit-2.6.4_p2015011102-r1.ebuild
new file mode 100644
index 0000000..b08be2b
--- /dev/null
+++ b/dev-util/nunit/nunit-2.6.4_p2015011102-r1.ebuild
@@ -0,0 +1,99 @@
+# Copyright 1999-2016 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=6
+inherit mono-env nuget dotnet
+
+NAME="nunitv2"
+HOMEPAGE="https://github.com/nunit/${NAME}";
+
+EGIT_COMMIT="1b549f4f8b067518c7b54a5b263679adb83ccda4"
+SRC_URI="${HOMEPAGE}/archive/${EGIT_COMMIT}.zip -> ${PF}.zip"
+S="${WORKDIR}/${NAME}-${EGIT_COMMIT}"
+
+SLOT="2" # NUnit V2 IS NO LONGER MAINTAINED OR UPDATED.
+
+DESCRIPTION="NUnit test suite for mono applications"
+LICENSE="NUnit-License" # http://nunit.org/nuget/license.html
+KEYWORDS="~amd64 ~x86"
+USE_DOTNET="net45"
+IUSE="net45 developer debug gac nupkg doc"
+
+RDEPEND=">=dev-lang/mono-4.0.2.5
+       dev-util/nant[nupkg]
+"
+DEPEND="${RDEPEND}
+"
+
+S="${WORKDIR}/${NAME}-${EGIT_COMMIT}"
+FILE_TO_BUILD=nunit.sln
+METAFILETOBUILD="${S}/${FILE_TO_BUILD}"
+
+# PN = Package name, for example vim.
+# PV = Package version (excluding revision, if any), for example 6.3.
+
+src_prepare() {
+       chmod -R +rw "${S}" || die
+       enuget_restore "${METAFILETOBUILD}"
+
+       if use debug; then
+               DIR="Debug"
+       else
+               DIR="Release"
+       fi
+       sed -i '/x86/d' "${S}/nuget/"*.nuspec || die
+       sed -i '/log4net/d' "${S}/nuget/"*.nuspec || die
+       sed -i 's#\\#/#g' "${S}/nuget/"*.nuspec || die
+       sed -i "s#\${package.version}#$(get_version_component_range 1-3)#g" 
"${S}/nuget/"*.nuspec || die
+       sed -i "s#\${project.base.dir}##g" "${S}/nuget/"*.nuspec || die
+       sed -i "s#\${current.build.dir}#bin/${DIR}#g" "${S}/nuget/"*.nuspec || 
die
+       default
+}
+
+src_compile() {
+       exbuild "${METAFILETOBUILD}"
+       enuspec "${S}/nuget/nunit.nuspec"
+       enuspec "${S}/nuget/nunit.runners.nuspec"
+}
+
+src_install() {
+       if use debug; then
+               DIR="Debug"
+       else
+               DIR="Release"
+       fi
+
+       SLOTTEDDIR="/usr/share/nunit-${SLOT}/"
+       insinto "${SLOTTEDDIR}"
+       doins bin/${DIR}/*.{config,dll,exe}
+       # install: cannot stat 'bin/Release/*.mdb': No such file or directory
+       if use developer; then
+               doins bin/${DIR}/*.mdb
+       fi
+
+#      into /usr
+#      dobin ${FILESDIR}/nunit-console
+       make_wrapper nunit264 "mono ${SLOTTEDDIR}/nunit-console.exe"
+
+       if use gac; then
+               if use debug; then
+                       DIR="Debug"
+               else
+                       DIR="Release"
+               fi
+
+               egacinstall "${S}/bin/${DIR}/lib/nunit-console-runner.dll"
+       fi
+
+       if use doc; then
+#              dodoc ${WORKDIR}/doc/*.txt
+#              dohtml ${WORKDIR}/doc/*.html
+#              insinto /usr/share/${P}/samples
+#              doins -r ${WORKDIR}/samples/*
+               doins license.txt
+       fi
+
+       enupkg "${WORKDIR}/NUnit.$(get_version_component_range 1-3).nupkg"
+       enupkg "${WORKDIR}/NUnit.Runners.$(get_version_component_range 
1-3).nupkg"
+}

Reply via email to