Unity Windows Phone 8 Build Error in Smartfox

Post here your questions about the Unity / .Net / Mono / Windows 8 / Windows Phone 8 API for SFS2X

Moderators: Lapo, Bax

Post Reply
Eser Telekom
Posts: 25
Joined: 16 Oct 2014, 07:28
Location: Istanbul
Contact:

Unity Windows Phone 8 Build Error in Smartfox

Post by Eser Telekom »

Unity v. : 4.6.0f3
Smartfox client v. :1.5.6.0

When i try to build ,its return error :

Error building Player: Exception: Error: type `Windows.Security.Cryptography.Core.HashAlgorithmProvider` doesn't exist in target framework. It is referenced from SmartFox2X.dll at System.String Sfs2X.Util.PasswordUtil::MD5Password(System.String).
Error: type `Windows.Security.Cryptography.CryptographicBuffer` doesn't exist in target framework. It is referenced from SmartFox2X.dll at System.String Sfs2X.Util.PasswordUtil::MD5Password(System.String).
Error: type `Windows.Security.Cryptography.BinaryStringEncoding` doesn't exist in target framework. It is referenced from SmartFox2X.dll at System.String Sfs2X.Util.PasswordUtil::MD5Password(System.String).
Error: method `Windows.Storage.Streams.IBuffer Windows.Security.Cryptography.CryptographicBuffer::ConvertStringToBinary(System.String,Windows.Security.Cryptography.BinaryStringEncoding)` doesn't exist in target framework. It is referenced from SmartFox2X.dll at System.String Sfs2X.Util.PasswordUtil::MD5Password(System.String).
Error: type `Windows.Security.Cryptography.Core.HashAlgorithmNames` doesn't exist in target framework. It is referenced from SmartFox2X.dll at System.String Sfs2X.Util.PasswordUtil::MD5Password(System.String).
Error: method `System.String Windows.Security.Cryptography.Core.HashAlgorithmNames::get_Md5()` doesn't exist in target framework. It is referenced from SmartFox2X.dll at System.String Sfs2X.Util.PasswordUtil::MD5Password(System.String).
Error: type `Windows.Security.Cryptography.Core.HashAlgorithmProvider` doesn't exist in target framework. It is referenced from SmartFox2X.dll at System.String Sfs2X.Util.PasswordUtil::MD5Password(System.String).
Error: type `Windows.Security.Cryptography.Core.HashAlgorithmProvider` doesn't exist in target framework. It is referenced from SmartFox2X.dll at System.String Sfs2X.Util.PasswordUtil::MD5Password(System.String).
Error: method `Windows.Security.Cryptography.Core.HashAlgorithmProvider Windows.Security.Cryptography.Core.HashAlgorithmProvider::OpenAlgorithm(System.String)` doesn't exist in target framework. It is referenced from SmartFox2X.dll at System.String Sfs2X.Util.PasswordUtil::MD5Password(System.String).
Error: type `Windows.Security.Cryptography.Core.HashAlgorithmProvider` doesn't exist in target framework. It is referenced from SmartFox2X.dll at System.String Sfs2X.Util.PasswordUtil::MD5Password(System.String).
Error: method `Windows.Storage.Streams.IBuffer Windows.Security.Cryptography.Core.HashAlgorithmProvider::HashData(Windows.Storage.Streams.IBuffer)` doesn't exist in target framework. It is referenced from SmartFox2X.dll at System.String Sfs2X.Util.PasswordUtil::MD5Password(System.String).
Error: type `Windows.Security.Cryptography.CryptographicBuffer` doesn't exist in target framework. It is referenced from SmartFox2X.dll at System.String Sfs2X.Util.PasswordUtil::MD5Password(System.String).
Error: method `System.String Windows.Security.Cryptography.CryptographicBuffer::EncodeToHexString(Windows.Storage.Streams.IBuffer)` doesn't exist in target framework. It is referenced from SmartFox2X.dll at System.String Sfs2X.Util.PasswordUtil::MD5Password(System.String).
User avatar
Bax
Site Admin
Posts: 4626
Joined: 29 Mar 2005, 09:50
Location: Italy
Contact:

Re: Unity Windows Phone 8 Build Error in Smartfox

Post by Bax »

This error was reported previously by another customer. He was using Unity v4.5.0f6, which had a bug when building Win Store apps.
I don't think this is your case. Maybe you are just using the wrong DLL? Please make sure you follow the instructions provided here: http://docs.unity3d.com/Manual/wp8-plugins.html
The two DLL are part of our C# API distribution.
Paolo Bax
The SmartFoxServer Team
Eser Telekom
Posts: 25
Joined: 16 Oct 2014, 07:28
Location: Istanbul
Contact:

Re: Unity Windows Phone 8 Build Error in Smartfox

Post by Eser Telekom »

I known this process , Check this topic : http://forums.smartfoxserver.com/viewto ... 20&t=17551 .
No problem 1.5.5.0 version of smartfox. After I uptaded smartfox wp dll and smartfox unity dll , I got error.
Put fake and real dlls in your Unity project and try to build .
User avatar
Bax
Site Admin
Posts: 4626
Joined: 29 Mar 2005, 09:50
Location: Italy
Contact:

Re: Unity Windows Phone 8 Build Error in Smartfox

Post by Bax »

For some reason Visual Studio didn't respect the conditional compilation used in the class mentioned in the error you reported.
After building the solution a few more times, now it seems it works as expected.
We just re-uploaded the API package. Can you please test it?
Thank you.
Paolo Bax
The SmartFoxServer Team
Eser Telekom
Posts: 25
Joined: 16 Oct 2014, 07:28
Location: Istanbul
Contact:

Re: Unity Windows Phone 8 Build Error in Smartfox

Post by Eser Telekom »

I tested new dlls (v1.5.6.0 Client dlls) and I can confirm that it is fixed.


Thank you.
Post Reply