diff options
Diffstat (limited to 'dev-util')
-rw-r--r-- | dev-util/tartool/files/Tools.CommandLine.csproj | 64 | ||||
-rw-r--r-- | dev-util/tartool/tartool-1.0.0.0.ebuild | 22 |
2 files changed, 81 insertions, 5 deletions
diff --git a/dev-util/tartool/files/Tools.CommandLine.csproj b/dev-util/tartool/files/Tools.CommandLine.csproj new file mode 100644 index 0000000..81961d3 --- /dev/null +++ b/dev-util/tartool/files/Tools.CommandLine.csproj @@ -0,0 +1,64 @@ +<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+ <PropertyGroup>
+ <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
+ <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
+ <ProjectGuid>{AF77CC00-FE07-46A7-9960-A71671BC5934}</ProjectGuid>
+ <OutputType>Exe</OutputType>
+ <AppDesignerFolder>Properties</AppDesignerFolder>
+ <RootNamespace>Tools.CommandLine</RootNamespace>
+ <AssemblyName>TarTool</AssemblyName>
+ <TargetFrameworkVersion>v4.6</TargetFrameworkVersion>
+ <FileAlignment>512</FileAlignment>
+ <StartupObject>Tools.CommandLine.TarTool</StartupObject>
+ </PropertyGroup>
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
+ <DebugSymbols>true</DebugSymbols>
+ <DebugType>full</DebugType>
+ <Optimize>false</Optimize>
+ <OutputPath>bin\Debug\</OutputPath>
+ <DefineConstants>DEBUG;TRACE</DefineConstants>
+ <ErrorReport>prompt</ErrorReport>
+ <WarningLevel>4</WarningLevel>
+ </PropertyGroup>
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
+ <DebugType>pdbonly</DebugType>
+ <Optimize>true</Optimize>
+ <OutputPath>bin\Release\</OutputPath>
+ <DefineConstants>TRACE</DefineConstants>
+ <ErrorReport>prompt</ErrorReport>
+ <WarningLevel>4</WarningLevel>
+ </PropertyGroup>
+ <PropertyGroup>
+ <NoWin32Manifest>true</NoWin32Manifest>
+ </PropertyGroup>
+ <ItemGroup>
+ <Reference Include="System" />
+ <Reference Include="System.Data" />
+ <Reference Include="System.Xml" />
+ <Reference Include="ICSharpCode.SharpZLib" />
+ </ItemGroup>
+ <ItemGroup>
+ <Compile Include="Properties\AssemblyInfo.cs" />
+ <Compile Include="Properties\AssemblyVersion.cs" />
+ <Compile Include="TarTool.cs" />
+ </ItemGroup>
+ <ItemGroup>
+ <None Include="app.config" />
+ </ItemGroup>
+ <ItemGroup>
+ <Content Include="Readme.txt" />
+ </ItemGroup>
+ <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
+ <Import Project="$(MSBuildExtensionsPath)\MSBuild.Community.Tasks.Targets" />
+ <Target Name="BeforeBuild">
+ <PropertyGroup Condition=" '$(VersionNumber)' == '' ">
+ <VersionNumber>1.0.0.0</VersionNumber>
+ </PropertyGroup>
+ <AssemblyInfo CodeLanguage="C#"
+ OutputFile="Properties/AssemblyVersion.cs"
+ AssemblyVersion="$(VersionNumber)"
+ AssemblyFileVersion="$(VersionNumber)"
+ />
+ </Target>
+</Project>
diff --git a/dev-util/tartool/tartool-1.0.0.0.ebuild b/dev-util/tartool/tartool-1.0.0.0.ebuild index ead3d6a..dc13578 100644 --- a/dev-util/tartool/tartool-1.0.0.0.ebuild +++ b/dev-util/tartool/tartool-1.0.0.0.ebuild @@ -11,7 +11,8 @@ SLOT="0" USE_DOTNET="net45" IUSE="+${USE_DOTNET} developer debug nupkg gac doc" -inherit msbuild +# eutils - for "make_wrapper" +inherit msbuild eutils NAME="tartool" HOMEPAGE="https://github.com/senthilrajasek/${NAME}" @@ -30,13 +31,14 @@ RDEPEND="${CDEPEND} " DEPEND="${CDEPEND} + >=dev-dotnet/msbuildtasks-1.5.0.240 " PATH_TO_PROJ="Tools.CommandLine/trunk/Tools.CommandLine.TarTool" METAFILE_TO_BUILD=Tools.CommandLine ASSEMBLY_NAME="TarTool" -#ASSEMBLY_VERSION="${PV}" +ASSEMBLY_VERSION="${PV}" function output_filename ( ) { local DIR="" @@ -49,22 +51,32 @@ function output_filename ( ) { } src_prepare() { + cp "${FILESDIR}/${METAFILE_TO_BUILD}.csproj" "${S}/${PATH_TO_PROJ}/${METAFILE_TO_BUILD}.csproj" || die + sed -i "/Version/d" "${PATH_TO_PROJ}/Properties/AssemblyInfo.cs" || die eapply_user } src_compile() { - emsbuild /p:TargetFrameworkVersion=v4.6 "/p:SignAssembly=true" "/p:PublicSign=true" "/p:AssemblyOriginatorKeyFile=${KEY2}" /p:VersionNumber="${ASSEMBLY_VERSION}" "${S}/${PATH_TO_PROJ}/${METAFILE_TO_BUILD}.csproj" + emsbuild /p:TargetFrameworkVersion=v4.6 /p:VersionNumber="${ASSEMBLY_VERSION}" "${S}/${PATH_TO_PROJ}/${METAFILE_TO_BUILD}.csproj" } src_install() { - if [ "${SLOT}" eq "0"] + if [ "${SLOT}" == "0" ] ; then SLOTTEDDIR="/usr/share/${PN}/" else SLOTTEDDIR="/usr/share/${PN}-${SLOT}/" fi insinto "${SLOTTEDDIR}" - doins "${PATH_TO_PROJ}/bin/${DIR}/${ASSEMBLY_NAME}.{config,dll,exe}" + + local DIR="" + if use debug; then + DIR="Debug" + else + DIR="Release" + fi + doins "${PATH_TO_PROJ}/bin/${DIR}/${ASSEMBLY_NAME}.exe" + doins "${PATH_TO_PROJ}/bin/${DIR}/${ASSEMBLY_NAME}.exe.config" if use developer; then doins "${PATH_TO_PROJ}/bin/${DIR}/${ASSEMBLY_NAME}.pdb" fi |