Sunday, October 28, 2012

A temporary solution for the Profile1 only bug in MonoDevelop MonoTouch PCL support

Update: install the patch -

Thanks especially to "Jonathan Peppers"...

There is a solution to the problem that MonoDevelop can only build Profile1 for MonoTouch PCL libraries.

The solution is to use Conditional MSBuild attributes.

So... replace:

    <TargetFrameworkProfile Condition="'$(OS)' != 'Windows_NT'">Profile1</TargetFrameworkProfile>      <TargetFrameworkProfile Condition="'$(OS)' == 'Windows_NT'">Profile104</TargetFrameworkProfile>
This can be done using Replace In Files :)

Afterwards it seems to work perfectly in both Visual Studio and in MonoDevelop :)



  1. where can I change that? which file is that?

  2. You have to do that in each and every one of your portable projects

  3. I'm still receiving 'Assembly not available for .NETPortable 4.0 Profile1 Profile (in Mono 2.10.9)' on MonoDevelop/osx

  4. If that's a clean install of MonoDevelop for MonoToch then you can also try the fix from (see

  5. Hi Slodge, it is a clean install indeed, and the fix suggested on stackoverflow does not fix my problem unfortunately.

    The problem gets stranger and stranger. I'd really like to get this going, but man, what a hassle.

    If I download your project from github and compile it on the mac: i get no errors. If I then do a REBUILD of the project, I get lots of errors.
    My guess is that still the 'Assembly not available for .NETportable 4.0 profile1' is the problem.
    On the first build (the working one) the references are yellow, with a warning sign and the message "'Assembly not available for .NETportable 4.0 profile1'"... after the rebuild they've turned red (same message still) and I get build errors on stuff like Dictionary not found

  6. Maybe move this over to - someone from Xamarin can help work it out.

    That bug has been logged since last Summer - it shouldn't still be in NEW State.