fix paths, also build main library automatically for C# binding
This commit is contained in:
		
							parent
							
								
									18aa87da92
								
							
						
					
					
						commit
						51685f038c
					
				
					 4 changed files with 21 additions and 10 deletions
				
			
		
							
								
								
									
										70
									
								
								servicepoint2-binding-cs/src/ServicePoint2.csproj
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										70
									
								
								servicepoint2-binding-cs/src/ServicePoint2.csproj
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,70 @@
 | 
			
		|||
<Project Sdk="Microsoft.NET.Sdk">
 | 
			
		||||
 | 
			
		||||
    <PropertyGroup>
 | 
			
		||||
        <TargetFramework>net8.0</TargetFramework>
 | 
			
		||||
        <ImplicitUsings>disable</ImplicitUsings>
 | 
			
		||||
        <Nullable>enable</Nullable>
 | 
			
		||||
        <AllowUnsafeBlocks>true</AllowUnsafeBlocks>
 | 
			
		||||
 | 
			
		||||
        <DisableFastUpToDateCheck>true</DisableFastUpToDateCheck>
 | 
			
		||||
        <GeneratePackageOnBuild>true</GeneratePackageOnBuild>
 | 
			
		||||
    </PropertyGroup>
 | 
			
		||||
 | 
			
		||||
    <PropertyGroup>
 | 
			
		||||
        <PackageId>ServicePoint2</PackageId>
 | 
			
		||||
        <Version>0.2.0</Version>
 | 
			
		||||
        <Authors>Repository Authors</Authors>
 | 
			
		||||
        <Company>None</Company>
 | 
			
		||||
        <Product>ServicePoint2</Product>
 | 
			
		||||
        <PackageTags>CCCB</PackageTags>
 | 
			
		||||
        <Description>
 | 
			
		||||
            C# bindings for the rust crate servicepoint2. You will need a suitable native shared library to use this.
 | 
			
		||||
            For documentation, see the rust documentation: https://docs.rs/servicepoint2/latest/servicepoint2/.
 | 
			
		||||
            Note that this library is still in early development. Breaking changes are expected before 1.0 is released.
 | 
			
		||||
        </Description>
 | 
			
		||||
        <PackageReadmeFile>README.md</PackageReadmeFile>
 | 
			
		||||
        <PublishRepositoryUrl>true</PublishRepositoryUrl>
 | 
			
		||||
    </PropertyGroup>
 | 
			
		||||
 | 
			
		||||
    <Target Name="BuildLibrary" Condition="'$(Configuration)'=='Release'" BeforeTargets="PrepareForBuild">
 | 
			
		||||
        <Exec Command="cargo build --manifest-path ../../servicepoint2/Cargo.toml --all-features --release"/>
 | 
			
		||||
    </Target>
 | 
			
		||||
 | 
			
		||||
    <Target Name="BuildLibrary" Condition="'$(Configuration)'=='Debug'" BeforeTargets="PrepareForBuild">
 | 
			
		||||
        <Exec Command="cargo build --manifest-path ../../servicepoint2/Cargo.toml --all-features"/>
 | 
			
		||||
    </Target>
 | 
			
		||||
 | 
			
		||||
    <Target Name="BuildBindings" Condition="'$(Configuration)'=='Release'" BeforeTargets="PrepareForBuild">
 | 
			
		||||
        <Exec Command="cargo build --release"/>
 | 
			
		||||
    </Target>
 | 
			
		||||
 | 
			
		||||
    <Target Name="BuildBindings" Condition="'$(Configuration)'=='Debug'" BeforeTargets="PrepareForBuild">
 | 
			
		||||
        <Exec Command="cargo build"/>
 | 
			
		||||
    </Target>
 | 
			
		||||
 | 
			
		||||
    <ItemGroup Condition="'$(Configuration)'=='Debug'">
 | 
			
		||||
        <Content Include="../../servicepoint2/target/debug/libservicepoint2.so" CopyToOutputDirectory="Always">
 | 
			
		||||
            <Link>libservicepoint2.so</Link>
 | 
			
		||||
        </Content>
 | 
			
		||||
    </ItemGroup>
 | 
			
		||||
 | 
			
		||||
    <ItemGroup Condition="'$(Configuration)'=='Release'">
 | 
			
		||||
        <Content Include="../../servicepoint2/target/release/libservicepoint2.so" CopyToOutputDirectory="Always">
 | 
			
		||||
            <Link>libservicepoint2.so</Link>
 | 
			
		||||
        </Content>
 | 
			
		||||
    </ItemGroup>
 | 
			
		||||
 | 
			
		||||
    <ItemGroup>
 | 
			
		||||
        <!-- include link to source code at revision -->
 | 
			
		||||
        <None Include="../../README.md" Pack="true" PackagePath="\"/>
 | 
			
		||||
        <!-- add README.md to package -->
 | 
			
		||||
        <PackageReference Include="Microsoft.SourceLink.GitHub" Version="8.0.0" PrivateAssets="All"/>
 | 
			
		||||
    </ItemGroup>
 | 
			
		||||
 | 
			
		||||
    <ItemGroup>
 | 
			
		||||
      <Content Include="..\build.rs">
 | 
			
		||||
        <Link>build.rs</Link>
 | 
			
		||||
      </Content>
 | 
			
		||||
    </ItemGroup>
 | 
			
		||||
 | 
			
		||||
</Project>
 | 
			
		||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue