mirror of
https://github.com/cyanfish/naps2.git
synced 2024-08-17 11:10:23 +03:00
Migrate to net8
This commit is contained in:
parent
3d9f8f4340
commit
61aebe6c8c
@ -1,7 +1,7 @@
|
|||||||
<Project Sdk="Microsoft.NET.Sdk">
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFrameworks>net6-windows;net462</TargetFrameworks>
|
<TargetFrameworks>net8-windows;net462</TargetFrameworks>
|
||||||
<EnableWindowsTargeting>true</EnableWindowsTargeting>
|
<EnableWindowsTargeting>true</EnableWindowsTargeting>
|
||||||
<OutputType>Exe</OutputType>
|
<OutputType>Exe</OutputType>
|
||||||
<AppConfig>app.config</AppConfig>
|
<AppConfig>app.config</AppConfig>
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
<Project Sdk="Microsoft.NET.Sdk">
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFramework>net6</TargetFramework>
|
<TargetFramework>net8</TargetFramework>
|
||||||
<OutputType>Exe</OutputType>
|
<OutputType>Exe</OutputType>
|
||||||
<RootNamespace>NAPS2</RootNamespace>
|
<RootNamespace>NAPS2</RootNamespace>
|
||||||
<AssemblyName>naps2</AssemblyName>
|
<AssemblyName>naps2</AssemblyName>
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
<Project Sdk="Microsoft.NET.Sdk">
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFramework>net7-macos10.15</TargetFramework>
|
<TargetFramework>net8-macos10.15</TargetFramework>
|
||||||
<OutputType>Exe</OutputType>
|
<OutputType>Exe</OutputType>
|
||||||
<RootNamespace>NAPS2</RootNamespace>
|
<RootNamespace>NAPS2</RootNamespace>
|
||||||
<AssemblyName>NAPS2</AssemblyName>
|
<AssemblyName>NAPS2</AssemblyName>
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
<Project Sdk="Microsoft.NET.Sdk">
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFrameworks>net6;net462</TargetFrameworks>
|
<TargetFrameworks>net8;net462</TargetFrameworks>
|
||||||
<OutputType>WinExe</OutputType>
|
<OutputType>WinExe</OutputType>
|
||||||
<RootNamespace>NAPS2.Portable</RootNamespace>
|
<RootNamespace>NAPS2.Portable</RootNamespace>
|
||||||
<AssemblyName>NAPS2.Portable</AssemblyName>
|
<AssemblyName>NAPS2.Portable</AssemblyName>
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
<Project Sdk="Microsoft.NET.Sdk">
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFramework>net6</TargetFramework>
|
<TargetFramework>net8</TargetFramework>
|
||||||
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
|
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
|
||||||
<ResolveAssemblyWarnOrErrorOnTargetArchitectureMismatch>None</ResolveAssemblyWarnOrErrorOnTargetArchitectureMismatch>
|
<ResolveAssemblyWarnOrErrorOnTargetArchitectureMismatch>None</ResolveAssemblyWarnOrErrorOnTargetArchitectureMismatch>
|
||||||
<Configurations>Debug;Release;DebugLang</Configurations>
|
<Configurations>Debug;Release;DebugLang</Configurations>
|
||||||
|
@ -12,7 +12,7 @@ public class LinuxAppTestTarget : IAppTestTarget
|
|||||||
{
|
{
|
||||||
var runtime = RuntimeInformation.OSArchitecture == Architecture.Arm64 ? "linux-arm64" : "linux-x64";
|
var runtime = RuntimeInformation.OSArchitecture == Architecture.Arm64 ? "linux-arm64" : "linux-x64";
|
||||||
return new AppTestExe(
|
return new AppTestExe(
|
||||||
Path.Combine(AppTestHelper.SolutionRoot, "NAPS2.App.Gtk", "bin", "Debug", "net6", runtime),
|
Path.Combine(AppTestHelper.SolutionRoot, "NAPS2.App.Gtk", "bin", "Debug", "net8", runtime),
|
||||||
"naps2",
|
"naps2",
|
||||||
argPrefix);
|
argPrefix);
|
||||||
}
|
}
|
||||||
|
@ -9,7 +9,7 @@ public class MacAppTestTarget : IAppTestTarget
|
|||||||
private AppTestExe GetAppTestExe(string argPrefix)
|
private AppTestExe GetAppTestExe(string argPrefix)
|
||||||
{
|
{
|
||||||
return new AppTestExe(
|
return new AppTestExe(
|
||||||
Path.Combine(AppTestHelper.SolutionRoot, "NAPS2.App.Mac", "bin", "Debug", "net7-macos10.15"),
|
Path.Combine(AppTestHelper.SolutionRoot, "NAPS2.App.Mac", "bin", "Debug", "net8-macos10.15"),
|
||||||
Path.Combine("NAPS2.app", "Contents", "MacOS", "NAPS2"),
|
Path.Combine("NAPS2.app", "Contents", "MacOS", "NAPS2"),
|
||||||
argPrefix);
|
argPrefix);
|
||||||
}
|
}
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
<Project Sdk="Microsoft.NET.Sdk">
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFrameworks>net6-windows;net462</TargetFrameworks>
|
<TargetFrameworks>net8-windows;net462</TargetFrameworks>
|
||||||
<EnableWindowsTargeting>true</EnableWindowsTargeting>
|
<EnableWindowsTargeting>true</EnableWindowsTargeting>
|
||||||
<OutputType>WinExe</OutputType>
|
<OutputType>WinExe</OutputType>
|
||||||
<AppConfig>app.config</AppConfig>
|
<AppConfig>app.config</AppConfig>
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
<Project Sdk="Microsoft.NET.Sdk">
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFrameworks>net6-windows;net462</TargetFrameworks>
|
<TargetFrameworks>net8-windows;net462</TargetFrameworks>
|
||||||
<EnableWindowsTargeting>true</EnableWindowsTargeting>
|
<EnableWindowsTargeting>true</EnableWindowsTargeting>
|
||||||
<OutputType>WinExe</OutputType>
|
<OutputType>WinExe</OutputType>
|
||||||
<LargeAddressAware>true</LargeAddressAware>
|
<LargeAddressAware>true</LargeAddressAware>
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
<Project Sdk="Microsoft.NET.Sdk">
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFrameworks>net6;net6-macos10.15</TargetFrameworks>
|
<TargetFrameworks>net6;net8-macos10.15</TargetFrameworks>
|
||||||
<Nullable>enable</Nullable>
|
<Nullable>enable</Nullable>
|
||||||
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
|
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
|
||||||
<CheckEolTargetFramework>false</CheckEolTargetFramework>
|
<CheckEolTargetFramework>false</CheckEolTargetFramework>
|
||||||
@ -32,7 +32,7 @@
|
|||||||
<Using Include="MonoMac.MobileCoreServices" />
|
<Using Include="MonoMac.MobileCoreServices" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<ItemGroup Condition="'$(TargetFramework)' == 'net6-macos10.15'">
|
<ItemGroup Condition="'$(TargetFramework)' == 'net8-macos10.15'">
|
||||||
<Using Include="AppKit" />
|
<Using Include="AppKit" />
|
||||||
<Using Include="CoreGraphics" />
|
<Using Include="CoreGraphics" />
|
||||||
<Using Include="Foundation" />
|
<Using Include="Foundation" />
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
<Project Sdk="Microsoft.NET.Sdk">
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFrameworks>net6</TargetFrameworks>
|
<TargetFrameworks>net8</TargetFrameworks>
|
||||||
<Nullable>enable</Nullable>
|
<Nullable>enable</Nullable>
|
||||||
<GenerateResourceUsePreserializedResources>true</GenerateResourceUsePreserializedResources>
|
<GenerateResourceUsePreserializedResources>true</GenerateResourceUsePreserializedResources>
|
||||||
<RootNamespace>NAPS2</RootNamespace>
|
<RootNamespace>NAPS2</RootNamespace>
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
<Project Sdk="Microsoft.NET.Sdk">
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFrameworks>net7-macos10.15</TargetFrameworks>
|
<TargetFrameworks>net8-macos10.15</TargetFrameworks>
|
||||||
<Nullable>enable</Nullable>
|
<Nullable>enable</Nullable>
|
||||||
<GenerateResourceUsePreserializedResources>true</GenerateResourceUsePreserializedResources>
|
<GenerateResourceUsePreserializedResources>true</GenerateResourceUsePreserializedResources>
|
||||||
<RootNamespace>NAPS2</RootNamespace>
|
<RootNamespace>NAPS2</RootNamespace>
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
<Project Sdk="Microsoft.NET.Sdk">
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFrameworks Condition="$([MSBuild]::IsOSPlatform('Windows'))">net6;net462</TargetFrameworks>
|
<TargetFrameworks Condition="$([MSBuild]::IsOSPlatform('Windows'))">net8;net462</TargetFrameworks>
|
||||||
<TargetFrameworks Condition="!$([MSBuild]::IsOSPlatform('Windows'))">net6</TargetFrameworks>
|
<TargetFrameworks Condition="!$([MSBuild]::IsOSPlatform('Windows'))">net8</TargetFrameworks>
|
||||||
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
|
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
|
||||||
<RootNamespace>NAPS2.Lib.Tests</RootNamespace>
|
<RootNamespace>NAPS2.Lib.Tests</RootNamespace>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
<Project Sdk="Microsoft.NET.Sdk">
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFrameworks>net6-windows;net462</TargetFrameworks>
|
<TargetFrameworks>net8-windows;net462</TargetFrameworks>
|
||||||
<Nullable>enable</Nullable>
|
<Nullable>enable</Nullable>
|
||||||
<GenerateResourceUsePreserializedResources>true</GenerateResourceUsePreserializedResources>
|
<GenerateResourceUsePreserializedResources>true</GenerateResourceUsePreserializedResources>
|
||||||
<RootNamespace>NAPS2</RootNamespace>
|
<RootNamespace>NAPS2</RootNamespace>
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
<Project Sdk="Microsoft.NET.Sdk">
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFrameworks Condition="$([MSBuild]::IsOSPlatform('Linux'))">net6;net462</TargetFrameworks>
|
<TargetFrameworks Condition="$([MSBuild]::IsOSPlatform('Linux'))">net8;net462</TargetFrameworks>
|
||||||
<TargetFrameworks Condition="!$([MSBuild]::IsOSPlatform('Linux'))">net6;net6-macos10.15;net462</TargetFrameworks>
|
<TargetFrameworks Condition="!$([MSBuild]::IsOSPlatform('Linux'))">net8;net8-macos10.15;net462</TargetFrameworks>
|
||||||
<Nullable>enable</Nullable>
|
<Nullable>enable</Nullable>
|
||||||
<GenerateResourceUsePreserializedResources>true</GenerateResourceUsePreserializedResources>
|
<GenerateResourceUsePreserializedResources>true</GenerateResourceUsePreserializedResources>
|
||||||
<RootNamespace>NAPS2</RootNamespace>
|
<RootNamespace>NAPS2</RootNamespace>
|
||||||
@ -15,7 +15,7 @@
|
|||||||
<Import Project="..\NAPS2.Setup\targets\CommonTargets.targets" />
|
<Import Project="..\NAPS2.Setup\targets\CommonTargets.targets" />
|
||||||
<Import Project="..\NAPS2.Setup\targets\LibUsers.targets" />
|
<Import Project="..\NAPS2.Setup\targets\LibUsers.targets" />
|
||||||
|
|
||||||
<PropertyGroup Condition="'$(TargetFramework)' == 'net6-macos10.15'">
|
<PropertyGroup Condition="'$(TargetFramework)' == 'net8-macos10.15'">
|
||||||
<DefineConstants>MAC</DefineConstants>
|
<DefineConstants>MAC</DefineConstants>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<PropertyGroup Condition="'$(Configuration)' == 'Release-Msi'">
|
<PropertyGroup Condition="'$(Configuration)' == 'Release-Msi'">
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
<Project Sdk="Microsoft.NET.Sdk">
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFrameworks>net6;net462</TargetFrameworks>
|
<TargetFrameworks>net8;net462</TargetFrameworks>
|
||||||
<!-- As these are just samples, no need for "windows only api" warnings for GdiImageContext -->
|
<!-- As these are just samples, no need for "windows only api" warnings for GdiImageContext -->
|
||||||
<NoWarn>CA1416</NoWarn>
|
<NoWarn>CA1416</NoWarn>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
<Project Sdk="Microsoft.NET.Sdk">
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFrameworks Condition="$([MSBuild]::IsOSPlatform('Windows'))">net6;net462</TargetFrameworks>
|
<TargetFrameworks Condition="$([MSBuild]::IsOSPlatform('Windows'))">net8;net462</TargetFrameworks>
|
||||||
<TargetFrameworks Condition="!$([MSBuild]::IsOSPlatform('Windows'))">net6</TargetFrameworks>
|
<TargetFrameworks Condition="!$([MSBuild]::IsOSPlatform('Windows'))">net8</TargetFrameworks>
|
||||||
<RootNamespace>NAPS2.Sdk.ScannerTests</RootNamespace>
|
<RootNamespace>NAPS2.Sdk.ScannerTests</RootNamespace>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
<Project Sdk="Microsoft.NET.Sdk">
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFrameworks Condition="$([MSBuild]::IsOSPlatform('Windows'))">net6;net462</TargetFrameworks>
|
<TargetFrameworks Condition="$([MSBuild]::IsOSPlatform('Windows'))">net8;net462</TargetFrameworks>
|
||||||
<TargetFrameworks Condition="!$([MSBuild]::IsOSPlatform('Windows'))">net6</TargetFrameworks>
|
<TargetFrameworks Condition="!$([MSBuild]::IsOSPlatform('Windows'))">net8</TargetFrameworks>
|
||||||
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
|
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
|
||||||
<GenerateResourceUsePreserializedResources>true</GenerateResourceUsePreserializedResources>
|
<GenerateResourceUsePreserializedResources>true</GenerateResourceUsePreserializedResources>
|
||||||
|
|
||||||
@ -27,7 +27,7 @@
|
|||||||
<ProjectReference Include="..\NAPS2.Images.Wpf\NAPS2.Images.Wpf.csproj" Condition="$([MSBuild]::IsOSPlatform('Windows'))" />
|
<ProjectReference Include="..\NAPS2.Images.Wpf\NAPS2.Images.Wpf.csproj" Condition="$([MSBuild]::IsOSPlatform('Windows'))" />
|
||||||
<ProjectReference Include="..\NAPS2.Images.Mac\NAPS2.Images.Mac.csproj" Condition="$([MSBuild]::IsOSPlatform('OSX'))" />
|
<ProjectReference Include="..\NAPS2.Images.Mac\NAPS2.Images.Mac.csproj" Condition="$([MSBuild]::IsOSPlatform('OSX'))" />
|
||||||
<ProjectReference Include="..\NAPS2.Images.Gtk\NAPS2.Images.Gtk.csproj" Condition="$([MSBuild]::IsOSPlatform('Linux'))" />
|
<ProjectReference Include="..\NAPS2.Images.Gtk\NAPS2.Images.Gtk.csproj" Condition="$([MSBuild]::IsOSPlatform('Linux'))" />
|
||||||
<ProjectReference Include="..\NAPS2.Images.ImageSharp\NAPS2.Images.ImageSharp.csproj" Condition="'$(TargetFramework)' == 'net6'" />
|
<ProjectReference Include="..\NAPS2.Images.ImageSharp\NAPS2.Images.ImageSharp.csproj" Condition="'$(TargetFramework)' == 'net8'" />
|
||||||
|
|
||||||
<PackageReference Include="NAPS2.Pdfium.Binaries" Version="1.0.1" />
|
<PackageReference Include="NAPS2.Pdfium.Binaries" Version="1.0.1" />
|
||||||
<PackageReference Include="NAPS2.Tesseract.Binaries" Version="1.1.0" />
|
<PackageReference Include="NAPS2.Tesseract.Binaries" Version="1.1.0" />
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
<Project Sdk="Microsoft.NET.Sdk">
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFramework>net6</TargetFramework>
|
<TargetFramework>net8</TargetFramework>
|
||||||
<OutputType>WinExe</OutputType>
|
<OutputType>WinExe</OutputType>
|
||||||
<LargeAddressAware>true</LargeAddressAware>
|
<LargeAddressAware>true</LargeAddressAware>
|
||||||
<RootNamespace>NAPS2.Sdk.Worker</RootNamespace>
|
<RootNamespace>NAPS2.Sdk.Worker</RootNamespace>
|
||||||
|
@ -18,7 +18,7 @@
|
|||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Compile Remove="*.*" />
|
<Compile Remove="*.*" />
|
||||||
<Content Include="NAPS2.Sdk.Worker.Win32.targets" PackagePath="build/NAPS2.Sdk.Worker.Win32.targets" />
|
<Content Include="NAPS2.Sdk.Worker.Win32.targets" PackagePath="build/NAPS2.Sdk.Worker.Win32.targets" />
|
||||||
<None Include="bin\Release\net6\win-x86\publish\NAPS2.Worker.exe">
|
<None Include="bin\Release\net8\win-x86\publish\NAPS2.Worker.exe">
|
||||||
<Link>lib/NAPS2.Worker.exe</Link>
|
<Link>lib/NAPS2.Worker.exe</Link>
|
||||||
<Pack>true</Pack>
|
<Pack>true</Pack>
|
||||||
<PackageCopyToOutput>true</PackageCopyToOutput>
|
<PackageCopyToOutput>true</PackageCopyToOutput>
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFrameworks>net6;net462</TargetFrameworks>
|
<TargetFrameworks>net6;net462</TargetFrameworks>
|
||||||
<TargetFrameworks Condition="!$([MSBuild]::IsOSPlatform('Linux')) and '$(Configuration)' != 'DebugNoMac'">
|
<TargetFrameworks Condition="!$([MSBuild]::IsOSPlatform('Linux')) and '$(Configuration)' != 'DebugNoMac'">
|
||||||
$(TargetFrameworks);net6-macos10.15
|
$(TargetFrameworks);net8-macos10.15
|
||||||
</TargetFrameworks>
|
</TargetFrameworks>
|
||||||
<Nullable>enable</Nullable>
|
<Nullable>enable</Nullable>
|
||||||
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
|
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
|
||||||
@ -22,7 +22,7 @@
|
|||||||
<Import Project="..\NAPS2.Setup\targets\SdkUsers.targets" />
|
<Import Project="..\NAPS2.Setup\targets\SdkUsers.targets" />
|
||||||
<Import Project="..\NAPS2.Setup\targets\SdkPackageTargets.targets" />
|
<Import Project="..\NAPS2.Setup\targets\SdkPackageTargets.targets" />
|
||||||
|
|
||||||
<PropertyGroup Condition="'$(TargetFramework)' == 'net6-macos10.15'">
|
<PropertyGroup Condition="'$(TargetFramework)' == 'net8-macos10.15'">
|
||||||
<DefineConstants>MAC</DefineConstants>
|
<DefineConstants>MAC</DefineConstants>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<PropertyGroup Condition="'$(AddDebugConstant)' == '1'">
|
<PropertyGroup Condition="'$(AddDebugConstant)' == '1'">
|
||||||
@ -37,14 +37,14 @@
|
|||||||
<HintPath>..\NAPS2.Setup\lib\PdfSharpCore.dll</HintPath>
|
<HintPath>..\NAPS2.Setup\lib\PdfSharpCore.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<!-- TODO: Switch back to the official nuget if https://github.com/soukoku/ntwain/pull/35 gets merged -->
|
<!-- TODO: Switch back to the official nuget if https://github.com/soukoku/ntwain/pull/35 gets merged -->
|
||||||
<Reference Include="NTwain" Condition="'$(TargetFramework)' != 'net6-macos10.15'">
|
<Reference Include="NTwain" Condition="'$(TargetFramework)' != 'net8-macos10.15'">
|
||||||
<HintPath>..\NAPS2.Setup\lib\NTwain.dll</HintPath>
|
<HintPath>..\NAPS2.Setup\lib\NTwain.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
|
|
||||||
<PackageReference Include="Grpc.Tools" Version="2.47.0" PrivateAssets="all" />
|
<PackageReference Include="Grpc.Tools" Version="2.47.0" PrivateAssets="all" />
|
||||||
<PackageReference Include="GrpcDotNetNamedPipes" Version="2.0.0" />
|
<PackageReference Include="GrpcDotNetNamedPipes" Version="2.0.0" />
|
||||||
<PackageReference Include="Microsoft.Win32.Registry" Version="5.0.0" Condition="'$(TargetFramework)' != 'net6-macos10.15'" />
|
<PackageReference Include="Microsoft.Win32.Registry" Version="5.0.0" Condition="'$(TargetFramework)' != 'net8-macos10.15'" />
|
||||||
<PackageReference Include="NAPS2.Wia" Version="2.0.3" Condition="'$(TargetFramework)' != 'net6-macos10.15'" />
|
<PackageReference Include="NAPS2.Wia" Version="2.0.3" Condition="'$(TargetFramework)' != 'net8-macos10.15'" />
|
||||||
<!-- Hide compatibility warnings for NTwain as it will only be actually used on Windows. -->
|
<!-- Hide compatibility warnings for NTwain as it will only be actually used on Windows. -->
|
||||||
<!-- TODO: Does this actually work if we build a net6 framework-dependent app and try to use Twain? -->
|
<!-- TODO: Does this actually work if we build a net6 framework-dependent app and try to use Twain? -->
|
||||||
<!-- <PackageReference Include="NTwain" Version="3.7.1" NoWarn="NU1701" Condition="'$(TargetFramework)' != 'net6-macos10.15'" />-->
|
<!-- <PackageReference Include="NTwain" Version="3.7.1" NoWarn="NU1701" Condition="'$(TargetFramework)' != 'net6-macos10.15'" />-->
|
||||||
@ -87,7 +87,7 @@
|
|||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ProjectReference Include="..\NAPS2.Escl\NAPS2.Escl.csproj" />
|
<ProjectReference Include="..\NAPS2.Escl\NAPS2.Escl.csproj" />
|
||||||
<ProjectReference Include="..\NAPS2.Escl.Server\NAPS2.Escl.Server.csproj" />
|
<ProjectReference Include="..\NAPS2.Escl.Server\NAPS2.Escl.Server.csproj" />
|
||||||
<ProjectReference Include="..\NAPS2.Images.Mac\NAPS2.Images.Mac.csproj" Condition="'$(TargetFramework)' == 'net6-macos10.15'" />
|
<ProjectReference Include="..\NAPS2.Images.Mac\NAPS2.Images.Mac.csproj" Condition="'$(TargetFramework)' == 'net8-macos10.15'" />
|
||||||
<ProjectReference Include="..\NAPS2.Images\NAPS2.Images.csproj" />
|
<ProjectReference Include="..\NAPS2.Images\NAPS2.Images.csproj" />
|
||||||
<ProjectReference Include="..\NAPS2.Internals\NAPS2.Internals.csproj" />
|
<ProjectReference Include="..\NAPS2.Internals\NAPS2.Internals.csproj" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
@ -24,7 +24,7 @@ public enum Driver
|
|||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Use an Apple ImageCaptureCore driver (Mac-only). You will also need to compile against a macOS framework target
|
/// Use an Apple ImageCaptureCore driver (Mac-only). You will also need to compile against a macOS framework target
|
||||||
/// (e.g net6-macos10.15) to use this driver type.
|
/// (e.g net8-macos10.15) to use this driver type.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
Apple,
|
Apple,
|
||||||
|
|
||||||
|
@ -37,7 +37,7 @@ internal class ScanDriverFactory : IScanDriverFactory
|
|||||||
default:
|
default:
|
||||||
throw new NotSupportedException(
|
throw new NotSupportedException(
|
||||||
$"Unsupported driver: {options.Driver}. " +
|
$"Unsupported driver: {options.Driver}. " +
|
||||||
"Make sure you're using the right framework target (e.g. net6-macos10.15 for the Apple driver).");
|
"Make sure you're using the right framework target (e.g. net8-macos10.15 for the Apple driver).");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -1,7 +1,7 @@
|
|||||||
<Project Sdk="Microsoft.NET.Sdk">
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFrameworks>net6;net462</TargetFrameworks>
|
<TargetFrameworks>net8;net462</TargetFrameworks>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<Import Project="..\NAPS2.Setup\targets\CommonTargets.targets" />
|
<Import Project="..\NAPS2.Setup\targets\CommonTargets.targets" />
|
||||||
|
@ -3,7 +3,7 @@ runtime: org.freedesktop.Platform
|
|||||||
runtime-version: '22.08'
|
runtime-version: '22.08'
|
||||||
sdk: org.freedesktop.Sdk
|
sdk: org.freedesktop.Sdk
|
||||||
sdk-extensions:
|
sdk-extensions:
|
||||||
- org.freedesktop.Sdk.Extension.dotnet6
|
- org.freedesktop.Sdk.Extension.dotnet8
|
||||||
command: naps2
|
command: naps2
|
||||||
copy-icon: true
|
copy-icon: true
|
||||||
cleanup:
|
cleanup:
|
||||||
@ -81,10 +81,10 @@ modules:
|
|||||||
- name: main
|
- name: main
|
||||||
buildsystem: simple
|
buildsystem: simple
|
||||||
build-options:
|
build-options:
|
||||||
append-path: /usr/lib/sdk/dotnet6/bin
|
append-path: /usr/lib/sdk/dotnet8/bin
|
||||||
append-ld-library-path: /usr/lib/sdk/dotnet6/lib
|
append-ld-library-path: /usr/lib/sdk/dotnet8/lib
|
||||||
env:
|
env:
|
||||||
PKG_CONFIG_PATH: /app/lib/pkgconfig:/app/share/pkgconfig:/usr/lib/pkgconfig:/usr/share/pkgconfig:/usr/lib/dotnet6/lib/pkgconfig
|
PKG_CONFIG_PATH: /app/lib/pkgconfig:/app/share/pkgconfig:/usr/lib/pkgconfig:/usr/share/pkgconfig:/usr/lib/dotnet8/lib/pkgconfig
|
||||||
DOTNET_CLI_TELEMETRY_OPTOUT: 'true'
|
DOTNET_CLI_TELEMETRY_OPTOUT: 'true'
|
||||||
DOTNET_SKIP_FIRST_TIME_EXPERIENCE: 'true'
|
DOTNET_SKIP_FIRST_TIME_EXPERIENCE: 'true'
|
||||||
arch:
|
arch:
|
||||||
@ -97,7 +97,7 @@ modules:
|
|||||||
build-commands:
|
build-commands:
|
||||||
- mkdir -p /app/bin
|
- mkdir -p /app/bin
|
||||||
- dotnet publish NAPS2.App.Gtk -c Release -r $RUNTIME --self-contained /p:DebugType=None /p:DebugSymbols=false --source ./nuget-sources
|
- dotnet publish NAPS2.App.Gtk -c Release -r $RUNTIME --self-contained /p:DebugType=None /p:DebugSymbols=false --source ./nuget-sources
|
||||||
- cp -r --remove-destination /run/build/main/NAPS2.App.Gtk/bin/Release/net6/$RUNTIME/publish/. /app/bin/
|
- cp -r --remove-destination /run/build/main/NAPS2.App.Gtk/bin/Release/net8/$RUNTIME/publish/. /app/bin/
|
||||||
- install -Dm644 com.naps2.Naps2.png /app/share/icons/hicolor/128x128/apps/com.naps2.Naps2.png
|
- install -Dm644 com.naps2.Naps2.png /app/share/icons/hicolor/128x128/apps/com.naps2.Naps2.png
|
||||||
- install -Dm644 com.naps2.Naps2.metainfo.xml /app/share/metainfo/com.naps2.Naps2.metainfo.xml
|
- install -Dm644 com.naps2.Naps2.metainfo.xml /app/share/metainfo/com.naps2.Naps2.metainfo.xml
|
||||||
- install -Dm644 com.naps2.Naps2.desktop /app/share/applications/com.naps2.Naps2.desktop
|
- install -Dm644 com.naps2.Naps2.desktop /app/share/applications/com.naps2.Naps2.desktop
|
||||||
|
@ -36,10 +36,10 @@ def main():
|
|||||||
'--env=DOTNET_CLI_TELEMETRY_OPTOUT=true',
|
'--env=DOTNET_CLI_TELEMETRY_OPTOUT=true',
|
||||||
'--env=DOTNET_SKIP_FIRST_TIME_EXPERIENCE=true',
|
'--env=DOTNET_SKIP_FIRST_TIME_EXPERIENCE=true',
|
||||||
'--command=sh', '--runtime=org.freedesktop.Sdk//22.08', '--share=network',
|
'--command=sh', '--runtime=org.freedesktop.Sdk//22.08', '--share=network',
|
||||||
'--filesystem=host', 'org.freedesktop.Sdk.Extension.dotnet6//22.08', '-c',
|
'--filesystem=host', 'org.freedesktop.Sdk.Extension.dotnet8//22.08', '-c',
|
||||||
'PATH="${PATH}:/usr/lib/sdk/dotnet6/bin" NUGET_PACKAGES="' +
|
'PATH="${PATH}:/usr/lib/sdk/dotnet8/bin" NUGET_PACKAGES="' +
|
||||||
str(Path(tmp).resolve()) +
|
str(Path(tmp).resolve()) +
|
||||||
'" LD_LIBRARY_PATH="$LD_LIBRARY_PATH:/usr/lib/sdk/dotnet6/lib" exec dotnet ' + cmd,
|
'" LD_LIBRARY_PATH="$LD_LIBRARY_PATH:/usr/lib/sdk/dotnet8/lib" exec dotnet ' + cmd,
|
||||||
'--', args.project] + runtime_args)
|
'--', args.project] + runtime_args)
|
||||||
|
|
||||||
runCommand('restore -r linux-x64 "$@"')
|
runCommand('restore -r linux-x64 "$@"')
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
<Project Sdk="Microsoft.NET.Sdk">
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFramework>net7</TargetFramework>
|
<TargetFramework>net8</TargetFramework>
|
||||||
<Nullable>enable</Nullable>
|
<Nullable>enable</Nullable>
|
||||||
<OutputType>Exe</OutputType>
|
<OutputType>Exe</OutputType>
|
||||||
<RootNamespace>NAPS2.Tools</RootNamespace>
|
<RootNamespace>NAPS2.Tools</RootNamespace>
|
||||||
|
@ -33,7 +33,7 @@ public static class DebPackager
|
|||||||
File.WriteAllText(Path.Combine(controlDir, "control"), template);
|
File.WriteAllText(Path.Combine(controlDir, "control"), template);
|
||||||
|
|
||||||
// Copy binary files
|
// Copy binary files
|
||||||
var publishDir = Path.Combine(Paths.SolutionRoot, "NAPS2.App.Gtk", "bin", "Release", "net6", runtimeId,
|
var publishDir = Path.Combine(Paths.SolutionRoot, "NAPS2.App.Gtk", "bin", "Release", "net8", runtimeId,
|
||||||
"publish");
|
"publish");
|
||||||
var targetDir = Path.Combine(workingDir, "usr/lib/naps2");
|
var targetDir = Path.Combine(workingDir, "usr/lib/naps2");
|
||||||
ProjectHelper.CopyDirectory(publishDir, targetDir);
|
ProjectHelper.CopyDirectory(publishDir, targetDir);
|
||||||
|
@ -14,7 +14,7 @@ public static class MacPackager
|
|||||||
Output.Info($"Packaging installer: {pkgPath}");
|
Output.Info($"Packaging installer: {pkgPath}");
|
||||||
|
|
||||||
Output.Verbose("Building bundle");
|
Output.Verbose("Building bundle");
|
||||||
var basePath = Path.Combine(Paths.SolutionRoot, "NAPS2.App.Mac", "bin", "Release", "net7-macos10.15");
|
var basePath = Path.Combine(Paths.SolutionRoot, "NAPS2.App.Mac", "bin", "Release", "net8-macos10.15");
|
||||||
string bundlePath = packageInfo.Platform switch
|
string bundlePath = packageInfo.Platform switch
|
||||||
{
|
{
|
||||||
Platform.Mac => Path.Combine(basePath, "NAPS2.app"),
|
Platform.Mac => Path.Combine(basePath, "NAPS2.app"),
|
||||||
|
@ -29,5 +29,5 @@ public class PackageOptions : OptionsBase
|
|||||||
[Option("debug", Required = false, HelpText = "Set DEBUG compile-time constant. Requires --build.")]
|
[Option("debug", Required = false, HelpText = "Set DEBUG compile-time constant. Requires --build.")]
|
||||||
public bool Debug { get; set; }
|
public bool Debug { get; set; }
|
||||||
|
|
||||||
// TODO: Add net target (net462/net6/net6-windows etc.)
|
// TODO: Add net target (net462/net8/net8-windows etc.)
|
||||||
}
|
}
|
@ -36,7 +36,7 @@ public static class RpmPackager
|
|||||||
File.WriteAllText(Path.Combine(workingDir, "SPECS/naps2.spec"), template);
|
File.WriteAllText(Path.Combine(workingDir, "SPECS/naps2.spec"), template);
|
||||||
|
|
||||||
// Copy binary files
|
// Copy binary files
|
||||||
var publishDir = Path.Combine(Paths.SolutionRoot, "NAPS2.App.Gtk", "bin", "Release", "net6", runtimeId,
|
var publishDir = Path.Combine(Paths.SolutionRoot, "NAPS2.App.Gtk", "bin", "Release", "net8", runtimeId,
|
||||||
"publish");
|
"publish");
|
||||||
var filesDir = Path.Combine(workingDir, $"naps2-{pkgInfo.VersionNumber}");
|
var filesDir = Path.Combine(workingDir, $"naps2-{pkgInfo.VersionNumber}");
|
||||||
var targetDir = Path.Combine(filesDir, "usr/lib/naps2");
|
var targetDir = Path.Combine(filesDir, "usr/lib/naps2");
|
||||||
|
@ -9,11 +9,11 @@ public class TestCommand : ICommand<TestOptions>
|
|||||||
// TODO: Framework options (e.g. "-f net462")
|
// TODO: Framework options (e.g. "-f net462")
|
||||||
var arch = RuntimeInformation.OSArchitecture.ToString().ToLowerInvariant();
|
var arch = RuntimeInformation.OSArchitecture.ToString().ToLowerInvariant();
|
||||||
var depsRootPath = OperatingSystem.IsMacOS()
|
var depsRootPath = OperatingSystem.IsMacOS()
|
||||||
? $"NAPS2.App.Mac/bin/Debug/net7-macos10.15/osx-{arch}"
|
? $"NAPS2.App.Mac/bin/Debug/net8-macos10.15/osx-{arch}"
|
||||||
: OperatingSystem.IsLinux()
|
: OperatingSystem.IsLinux()
|
||||||
? $"NAPS2.App.Gtk/bin/Debug/net6/linux-{arch}"
|
? $"NAPS2.App.Gtk/bin/Debug/net8/linux-{arch}"
|
||||||
: "NAPS2.App.WinForms/bin/Debug/net462";
|
: "NAPS2.App.WinForms/bin/Debug/net462";
|
||||||
var frameworkArg = OperatingSystem.IsWindows() ? "" : "-f net6";
|
var frameworkArg = OperatingSystem.IsWindows() ? "" : "-f net8";
|
||||||
|
|
||||||
void RunTests(string project, bool isRetry = false)
|
void RunTests(string project, bool isRetry = false)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user