Will Xamarin 15.2.2 roll out this weekend, and will it fix SDK-style csproj?

Oops, of course.

Having done that, I’m now back to those same errors:

1096) CS0518: System/SubscribeSafeExtensions.cs(14,54): Predefined type 'System.Int32' is not defined or imported
1097) CS0518: System/SubscribeSafeExtensions.cs(33,14): Predefined type 'System.Object' is not defined or imported

By the way, the FAKE build is triggered by a script step in my workflow (which just runs build.sh). Executing that same script on my Mac works fine.

Did you try to build the project on another Mac?

Not sure what this might be, but we prepare the VS4Mac stack the same way we do the Xamarin one: we pick a base Xcode stack, which doesn’t have Xamarin nor VS4Mac installed, and then we install Xamarin Studio or VS4Mac on top of it, using the official installer, and then we preinstall a couple of Android packages (https://github.com/bitrise-io/osx-box-bootstrap/blob/master/xamarin-playbook.yml) and that’s all.

No customization, we install XS or VS4Mac using the same installer you can download from their website.

From this I’d say you have something custom on your Mac installed/configured, something that’s not installed by the XS/VS4Mac installer.

I’ll ask a couple of colleagues to build that branch on their Macs tomorrow.

Let us know how it goes! :wink:

OK, colleague gets the same errors when building on his Mac. Any ideas where to start looking for answers here? I’m kinda baffled.

Most likely some tool version diff

these looks similar:

Or just google for Predefined type 'System.Int32' is not defined or imported, quite a few things what might cause this.

Been trying to figure out which tool, exactly, would be different. Not having much luck.

I tried getting my colleague to install the same .NET Core SDK that I have (on the theory that perhaps only the runtime was being installed by the Bitrise step). That didn’t work. As further proof it has nothing to do with .NET Core, I uninstalled .NET Core from my Mac and it continues to build fine.

OK, I know what the frigging problem is.

VS4M does an automatic package restore when you open a solution whereas msbuild does not. I had been testing msbuild after opening the solution in VS4M, so all packages were restored.

So I need a manual package restore step ahead of the build. I thought this might be just a dotnet restore call, but I already have that in my build script, so there must be something else I need to do. Looking into it…

I had to dotnet restore per solution, since I had multiple solutions in place.

And now, after all that, IT WORKS!

Thanks so much for the assistance along the way @viktorbenei.

1 Like

Wow, kudos @ch_kent! :slight_smile:

If you have the time, can you share your script(s) / config (parts) you needed for this to work? Might help others as well as if there’s anything we could integrate in a clever way we’d definitely be open :wink: