Opt in for preview SDKs - visual-studio

I started playing around the the preview bits of the .NET 3.0 SDK. Now every .NET Core project I compile with VS Code, Visual Studio or the .NET CLI tries to use that preview version of the SDK.
How can I make this an opt in choice on my whole machine, i.e. always use the latest stable version of the SDK (whatever version that might be) and only use the preview SDK when I explicitly say so in the local global.json of the particular project.
Update: Maybe global.json is not the right approach? How could I play with preview SDKs in isolation without them affecting my whole machine?

Related

Is it safe to target the Bot Framework SDK to .NET 5?

We've recently started a project with the Virtual Assistant Template 1.0.1, and I wonder if it is safe to target the solution to net5.0 since we have some libraries that use this latest .NET GA release.
Currently, the VA template references the Bot Framework SDK 4.9.3. Any requirements on the SDK version?
I've done a couple of tests to confirm. The project compiles, and I can't see any errors. However, I'm looking for some confirmation from the community.
There are no obvious problems with targeting .NET 5. But if you'd like to be safe, you should go with the version the samples are using:
<TargetFramework>netcoreapp3.1</TargetFramework>

Need lower version of visual studio for mac

I just want to download a lower version of Visual Studio for Mac. The current version is 7.5.1 and I want to download 7.4.3.
Can anyone tell me where can I get that download file or link?
From some guesswork I found it by using this URL :
https://dl.xamarin.com/VsMac/VisualStudioForMac-7.4.2.12.dmg
Not installed it tho.
From this, comment on the 9th May link seems like you have to open a support ticket?!?!
As an update on this topic, all of the recent previous Xamarin.iOS,
Xamarin.Android, and Xamarin.Mac packages are available in the
archives on the open source continuous builds server (under the
Xamarin.Android and Xamarin.MaciOS tabs). And the Mono Framework MDK
is similarly available in the Mono Project download archive. I have
now updated the 15.7 Release Xamarin Release Blog post to provide the
links to those locations. In many cases, the latest version of Visual
Studio for Mac will be backwards compatible with previous versions of
the Xamarin SDKs, so you can in many cases just install those earlier
Xamarin SDK versions over the current versions and leave Visual Studio
for Mac and Mono Framework MDK at the latest.
If you do need to get an older version of Visual Studio for Mac
itself, the best option at this time is still to create a support
incident to request the version you'd like. The updated info for
creating a Visual Studio for Mac support incident is to go to
Technical Support > Product: Visual Studio > Assisted Support on
https://www.visualstudio.com/vs/support/ and then select Visual Studio
Community/Professional/Enterprise 2017 for Mac.
I used to download previous releases from my Xamarin account page
which now doesn't seem to exist anymore.
At the moment, the direct link to the old downloads page
(https://store.xamarin.com/account/my/subscription/downloads) is not
yet set to redirect, so it is still possible to access that page, but
indeed that page is considered deprecated in favor of the open source
continuous builds archive at this time, and the previous versions
provided on that page are from the earlier Xamarin 15.5 Release rather
than the Xamarin 15.6 Release.
Bunch of other versions in case someone needs them:
https://dl.xamarin.com/VsMac/VisualStudioForMac-7.3.0.797.dmg
https://dl.xamarin.com/VsMac/VisualStudioForMac-7.3.0.799.dmg
https://dl.xamarin.com/VsMac/VisualStudioForMac-7.3.3.5.dmg
https://dl.xamarin.com/VsMac/VisualStudioForMac-7.3.2.12.dmg
https://dl.xamarin.com/VsMac/VisualStudioForMac-7.4.0.1033.dmg
https://dl.xamarin.com/VsMac/VisualStudioForMac-Preview-7.4.0.839.dmg
https://dl.xamarin.com/VsMac/VisualStudioForMac-7.3.3.5.dmg
https://dl.xamarin.com/VsMac/VisualStudioForMac-Preview-7.4.0.884.dmg
https://dl.xamarin.com/VsMac/VisualStudioForMac-Preview-7.4.0.985.dmg
https://dl.xamarin.com/VsMac/VisualStudioForMac-Preview-7.4.0.1026.dmg
https://dl.xamarin.com/VsMac/VisualStudioForMac-Preview-7.5.0.933.dmg
https://dl.xamarin.com/VsMac/VisualStudioForMac-Preview-7.5.0.1062.dmg
https://dl.xamarin.com/VsMac/VisualStudioForMac-7.4.1.48.dmg
https://dl.xamarin.com/VsMac/VisualStudioForMac-Preview-7.5.0.1161.dmg
https://dl.xamarin.com/VsMac/VisualStudioForMac-Preview-7.5.0.1244.dmg
https://dl.xamarin.com/VsMac/VisualStudioForMac-Preview-7.5.0.1222.dmg
https://dl.xamarin.com/VsMac/VisualStudioForMac-Preview-7.6.0.711.dmg
https://dl.xamarin.com/VsMac/VisualStudioForMac-7.8.4.1.dmg
Note: These are from the index.xml files that VS4M downloads that includes all the matching packages for each release
You could also look for versions listed at the brew repository.
Use the url pattern https://dl.xamarin.com/VsMac/VisualStudioForMac-{version}.dmg.

Xamarin.Android version numbers seem inconsistent

To keep build tool version consistency, I want to manually upgrade Xamarin on my desktop as well as my CI build server (not to be confused with a Xamarin mac build host). Running auto-update only works if I upgrade all machines at the same time.
So I go to download, and I thin I need to download Xamarin.Android - latest version is 4.0.1. No revision number is given here.
The thing is, I did run an update from Visual Studio the other day, and according to the about dialog, I'm now running "Xamarin.Android 6.0.1.10":
Xamarin 4.0.1.89 (413372c)
Visual Studio extension to enable development for Xamarin.iOS and Xamarin.Android.
Xamarin.Android 6.0.1.10 (e98e962)
Visual Studio plugin to enable development for Xamarin.Android.
I've heard that the v4.0.1 relates to the Visual Studio plugin (I use VS on my desktop).
IN addition, I don't use Visual Studio on my CI build server; instead I have Xamarin Studio. When I look at pending updates for that, it's offering "Xamarin 4.0.1.93" - presumably not a Visual Studio plugin for Android Studio?
Is Xamarin telling me I'm downloading "Xamrin.Android 4.0.1" when really I'm downloading "Xamarin v4.0.1.?" which contains "Xamarin.Android v6.x.x.x".
My end-game is that I would like to be sure of what versions of Xamarin components are involved when building using MSBuild.
If I need to do a legacy build, I would like the legacy build tool to be used.
Update: I have started tracking versions myself here
Xamarin support got back to me. My understanding is:
The version number in the dropdown seems to be that of the installer that bundles both Xamarin.Android and Xamarin.iOS. It is not the version of Xamarin.Android.
Build tool version: "Xamarin.Android performs the build, so this is what you are looking for."
You can find out roughly what version of "Xamarin.Android" is bundled with "Xamarin" from the "Xamarin" Release Notes. The top line says something like Xamarin 4.0 updates Xamarin.iOS 9.4 and Xamarin.Android 6.0 releases.
More info from Xamarin:
On Windows you cannot download separate installers for Xamarin.iOS and
Xamarin.Android.
The Xamarin.VisualStudio package (also referred to as just "Xamarin")
includes Xamarin.iOS and Xamarin.Android.
E.g., Xamarin 4.0.1.93 contains Xamarin.iOS 9.4.1.24 and
Xamarin.Android 6.0.1.10
The version number you see on the download page refers to the version
number of "Xamarin" - which, as above, includes Xamarin.iOS and
Xamarin.Android. This is the same when you are updating and see
"Xamarin 4.0.1.93" for example.
You need to install "Xamarin" even if you are using Xamarin Studio on
Windows as this includes Xamarin.Android.
and
We do issue separate installers for Xamarin.Android on OS X, so if you are able to use a Mac for your CI (e.g., with something like Jenkins), then this may be more viable.

port an existing c++11 app which runs on Android and IOS to Windows Phone 8

currently I have to port an existing mobile application which runs on Android and IOS to Windows 8. Unfortunately it is using a lot of C++11 Stuff, which is not supported by Windows Phone 8.0. The project itself was written with cocos2d-x 2.0. It contains a C# Part which loads a C++ library with the major part of the application. Also it includes modules from "Project Angle", which is a library to convert OpenGL calls into DirectX calls.
The first thing I tried was to upgrade the project to Windows Phone 8.1 using the 'reassign project' option from Visual Studio. I still had to remove a bit of C++11 Code, but now at least the project itself compiles. After compiling I got some linker errors for functions like 'getenv'. The angle libraries don't even compile and gives me errors like 'Cant find include file vccorlib.h' for every single source file.
Since I'm completely new to Windows development, I don't know if something went wrong on upgrading the projects, or if I have to fix something within the projects. But I tried to upgrade an other project, which was already ported to WP8, and got the same errors.
Now I have to deceide if I have to fix the Windows Phone 8.1 version or if it's easier to remove C++11 Code for 8.0 (which means a few days of work and let my heart bleed)
I also found a compiler update for Visual Studio 2012, which has extended support for C++11, but it seems it's not compatible for Windows Phone.
I hope someone of you could give me a hint, what I have missed for WP 8.1 or has another idea. Thanks for your help!
Cocos2d-x should work on Windows Phone, but you have to get the right version. You can't use pre-built binaries for other platforms (even desktop Windows) and you need to make sure you're building correctly. See the download page.
Visual Studio 2013 Update 4 is the latest stable release of VS that supports Windows Phone projects; you can see the level of C++11 support listed here along with support in the not-yet-finished Visual Studio 2015 compiler.

Adding permanent Include directory

I'm trying to build a solution that contains dozens of projects, unfortunately I cannot find a way in VS2013 to add a "global" include directory to the solution since I need to include Directx.
Is there really no other way in VS2013 to add directories to a solution besides of adding them manually project by project?
Starting with VS 2010, the correct way to add the DirectX SDK to a project is to use VC++ Directories settings. See this old VC post for details.
You can also use custom .props through Property Manager. This is how you would use the Windows 8.x SDK with VS 2010 for example because the Windows SDK no longer creates Platform Toolsets for this combination of tools. See this post.
Historically the include path order has been the following because the DirectX SDK contained newer headers than the Windows SDK 7.x and prior:
$(DXSDK_DIR)Include;$(IncludePath)
$(DXSDK_DIR)Lib\x86 or x64;$(LibraryPath)
Now that the DirectX SDK is deprecated, the Windows 8.x SDK that comes with VS 2012 and VS 2013 contains newer headers than the legacy DirectX SDK. Therefore, if you still need to make use of old components that are only in the DirectX SDK (such as the deprecated D3DX library), you need to use:
$(IncludePath);$(DXSDK_DIR)Include
$(LibraryPath);$(DXSDK_DIR)Lib\x86 or x64
There are a few more minor details covered on MSDN
For Direct3D 11 development, you should remove use of the DirectX SDK in favor of the Windows 8.x SDK anyhow. See Living without D3DX and DirectXMath.
If using XInput 1.3 and you still need to target Windows 7 or earlier, one option is to use XInput 9.1.0 instead. See XINPUT and Windows 8. This is used by DirectX Tool Kit's GamePad when targeting down-level to avoid the need for the legacy DirectX SDK.
The only cases where it still makes sense to involve the DirectX SDK in newer Win32 desktop apps is when using XAudio2 and shipping on Windows 7 or earlier. See XAudio2 and Windows 8. This is used by DirectX Tool Kit for Audio when targeting down-level.
In both cases of using XInput 1.3 and XAudio 2.7 you actually need to use full paths to the DirectX SDK headers/libs and not rely on project search paths to pick up the right headers since they have name collisions with XInput 1.4 and XAudio 2.8 in the Windows SDK 8.x.

Resources