瀏覽代碼

added AOT compilation to demo

vpenades 1 年之前
父節點
當前提交
9cd7903c9c

+ 1 - 0
examples/InfiniteSkinnedTentacle/InfiniteSkinnedTentacle.csproj

@@ -3,6 +3,7 @@
   <PropertyGroup>
     <OutputType>Exe</OutputType>
     <TargetFramework>net8.0</TargetFramework>
+    <PublishAot>true</PublishAot>
   </PropertyGroup>
 
   <ItemGroup>

+ 18 - 0
examples/InfiniteSkinnedTentacle/Properties/PublishProfiles/FolderProfile.pubxml

@@ -0,0 +1,18 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+https://go.microsoft.com/fwlink/?LinkID=208121.
+-->
+<Project>
+  <PropertyGroup>
+    <Configuration>Release</Configuration>
+    <Platform>Any CPU</Platform>
+    <PublishDir>bin\Release\net8.0\publish\win-x64\</PublishDir>
+    <PublishProtocol>FileSystem</PublishProtocol>
+    <_TargetId>Folder</_TargetId>
+    <TargetFramework>net8.0</TargetFramework>
+    <RuntimeIdentifier>win-x64</RuntimeIdentifier>
+    <SelfContained>true</SelfContained>
+    <PublishSingleFile>false</PublishSingleFile>
+    <PublishReadyToRun>false</PublishReadyToRun>
+  </PropertyGroup>
+</Project>

+ 4 - 3
tests/SharpGLTF.Trimmed.App/Properties/PublishProfiles/FolderProfile.pubxml

@@ -6,12 +6,13 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
   <PropertyGroup>
     <Configuration>Release</Configuration>
     <Platform>Any CPU</Platform>
-    <PublishDir>bin\publish\</PublishDir>
+    <PublishDir>bin\Release\net8.0\publish\win-x64\</PublishDir>
     <PublishProtocol>FileSystem</PublishProtocol>
-    <TargetFramework>net7.0</TargetFramework>
+    <_TargetId>Folder</_TargetId>
+    <TargetFramework>net8.0</TargetFramework>
     <RuntimeIdentifier>win-x64</RuntimeIdentifier>
     <SelfContained>true</SelfContained>
-    <PublishSingleFile>true</PublishSingleFile>
+    <PublishSingleFile>false</PublishSingleFile>
     <PublishReadyToRun>false</PublishReadyToRun>
   </PropertyGroup>
 </Project>

+ 2 - 7
tests/SharpGLTF.Trimmed.App/SharpGLTF.Trimmed.App.csproj

@@ -2,13 +2,8 @@
 
   <PropertyGroup>
     <OutputType>Exe</OutputType>
-    <TargetFramework>net8.0</TargetFramework>    
-  </PropertyGroup>  
-
-  <PropertyGroup>
-    <PublishTrimmed>true</PublishTrimmed>
-    <!-- Prevent warnings from unused code in dependencies -->
-    <TrimmerDefaultAction>link</TrimmerDefaultAction>
+    <TargetFramework>net8.0</TargetFramework>
+    <PublishAot>true</PublishAot>
     <RootNamespace>SharpGLTF</RootNamespace>
   </PropertyGroup>