Comments (9)
@vkacherov just to check, you are using the latest on the main
branch?
We had someone else hit an error like this, and SourceTree didn't clone the Github "default" branch.
from maui-samples.
@rolfbjarne I think @mdh1418 is having the same problem, so there might be an issue with -t:Run
for iOS?
from maui-samples.
I tried running the sample using sdk 5.0.100-rc.1.20466.16
, 5.0.100-rc.1.20452.5
, 5.0.100-rc.2.20459.1
(as expected by the repository) and still ran into that error with dotnet build HelloiOS/HelloiOS.csproj -t:Run
. (Also had tried it with 6.0.100-alpha.1.20479.7`
I believe dotnet build
itself succeeded for 5.0.1xx
, but failed on 6.0.100-alpha.1.20479.7
with
/usr/local/share/dotnet/sdk/6.0.100-alpha.1.20479.7/Sdks/Microsoft.NET.Sdk/targets/Microsoft.NET.TargetFrameworkInference.targets(213,5): error NETSDK1140: 13.6 is not a valid TargetPlatformVersion for iOS. Valid versions include: [/Users/mdhwang/net6-samples/HelloiOS/HelloiOS.csproj]
/usr/local/share/dotnet/sdk/6.0.100-alpha.1.20479.7/Sdks/Microsoft.NET.Sdk/targets/Microsoft.NET.TargetFrameworkInference.targets(213,5): error NETSDK1140: None [/Users/mdhwang/net6-samples/HelloiOS/HelloiOS.csproj]
from maui-samples.
The known good version of .NET for this repo is here:
Depending on the build, an MSBuild property was renamed recently, which can cause the NETSDK1140
error:
from maui-samples.
Using the known good version works for me:
$ git clean -xfd
$ git diff global.json
diff --git a/global.json b/global.json
index 0f80674..b5ac7f9 100644
--- a/global.json
+++ b/global.json
@@ -1,4 +1,5 @@
{
+ "sdk": { "version": "5.0.100-rc.2.20459.1" },
"msbuild-sdks": {
"Microsoft.iOS.Sdk": "13.6.100-ci.main.379",
"Microsoft.Android.Sdk": "11.0.100-ci.master.127"
$ dotnet build HelloiOS/HelloiOS.csproj
Microsoft (R) Build Engine version 16.8.0-preview-20454-01+b33e5486f for .NET
Copyright (C) Microsoft Corporation. All rights reserved.
Determining projects to restore...
Restored /Users/rolf/work/net6-samples/HelloiOS/HelloiOS.csproj (in 1.77 sec).
You are using a preview version of .NET. See: https://aka.ms/dotnet-core-preview
HelloiOS -> /Users/rolf/work/net6-samples/HelloiOS/bin/Debug/net5.0-ios/ios-x64/HelloiOS.dll
Detected signing identity:
Bundle Id: com.microsoft.net5.helloios
App Id: com.microsoft.net5.helloios
Optimizing assemblies for size, which may change the behavior of the app. Be sure to test after publishing. See: https://aka.ms/dotnet-illink
Build succeeded.
0 Warning(s)
0 Error(s)
Time Elapsed 00:00:19.94
other versions don't work (with the error reported here).
from maui-samples.
@jonathanpeppers maybe we should bump to 5.0.100-rc.2.20480.7
here (and use updated packages, our main packages (version14.0.100-ci.main.558
for instance) support the new msbuild variable name)
from maui-samples.
I'll work on a PR that will give specific download URLs in the instructions and update our packages.
I think the original problem is the Run
target may not be working:
$ dotnet build HelloiOS/HelloiOS.csproj -t:Run
...
/usr/local/share/dotnet/sdk/6.0.100-alpha.1.20479.7/Sdks/Microsoft.NET.Sdk/targets/Microsoft.NET.Sdk.targets(814,5): error MSB3073: The command "dotnet exec "/Users/vadim/projects/net6-samples/HelloiOS/bin/Debug/net5.0-ios/ios-x64/HelloiOS.dll"" exited with code 129. [/Users/vadim/projects/net6-samples/HelloiOS/HelloiOS.csproj]
But I'll test this and see if it works for me.
from maui-samples.
@rolfbjarne even using Microsoft.iOS.Sdk 14.0.100-ci.main.559, I'm hitting the issue using -t:Run
for the iOS app:
/usr/local/share/dotnet/sdk/5.0.100-rc.2.20480.7/Sdks/Microsoft.NET.Sdk/targets/Microsoft.NET.Sdk.targets(814,5): error MSB3073: The command "dotnet exec "/Users/jopepper/src/net5-samples/HelloiOS/bin/Debug/net5.0-ios/ios-x64/HelloiOS.dll"" exited with code 131. [/Users/jopepper/src/net5-samples/HelloiOS/HelloiOS.csproj]
It's like it is using the built-in Run
target, and maybe the iOS SDK needs to replace it? Android is using it's own Run
target now:
from maui-samples.
Yes, I can reproduce that, I'll have a look.
from maui-samples.
Related Issues (20)
- Please read before opening an issue! - .NET MAUI samples support
- Fundamentals\Shell\Xaminals - Search bug
- Fundamentals\Shell\Xaminals - Selected ShellItem issue
- Setting BackgroundColor of AnimalTemplate, disables the backgroundColor style of the grid element
- Monkey testing the bottom TabBar crashes the app HOT 1
- In Control Gallery Sample, iOS Displaying Incorrect Text in TableView
- In Control Gallery, Windows Host Stops Navigating After One Click / Back Sequence HOT 4
- Dynamic change of `ControlTemplates` at runtime doesn't work.
- Install QUEST
- WordPuzzle sample
- Weathertwentyone app example GitHub action pipelines
- why are all sample codes not running because of packages? HOT 3
- BugSweeper
- WebAuthenticator in PlatformIntegrationDemo ends (crashes?) App HOT 1
- Native embedding sample
- NativeEmbeddingDemo doesn't work. HOT 2
- DatePicker crashes app HOT 3
- Point of Sale will not even Compile... HOT 4
- WEATHER APP DOES NOT RUN!! HOT 2
- Update quest.config
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from maui-samples.