Page 1 of 1

Compile error vs2010

Posted: Tue Dec 20, 2011 4:33 pm
by xantier

Code: Select all

1>------ Build started: Project: UOX3_Official, Configuration: Debug Win32 ------
1>Build started 20.12.2011 17:25:18.
1>InitializeBuildStatus:
1>  Touching ".\Debug\UOX3_Official.unsuccessfulbuild".
1>ClCompile:
1>  CGump.cpp
1>  CJSEngine.cpp
1>  CJSMapping.cpp
1>  CPacketReceive.cpp
1>  c:\documents and settings\administrator\belgelerim\deniz\programming\uox3\projects\uox3\source\cpacketreceive.cpp(623) :  NOTE :   "Flush location"
1>  
1>  c:\documents and settings\administrator\belgelerim\deniz\programming\uox3\projects\uox3\source\cpacketreceive.cpp(750) :  NOTE :   "Flush location"
1>  
1>  CPacketSend.cpp
1>  c:\documents and settings\administrator\belgelerim\deniz\programming\uox3\projects\uox3\source\cpacketsend.cpp(248) :  NOTE :   "Function Warning: CPacketSpeech::Language(), does nothing"
1>  
1>  c:\documents and settings\administrator\belgelerim\deniz\programming\uox3\projects\uox3\source\cpacketsend.cpp(391) :  NOTE :   "we need to update this here to determine what goes on with elves too!"
1>  
1>  c:\documents and settings\administrator\belgelerim\deniz\programming\uox3\projects\uox3\source\cpacketsend.cpp(1628) :  NOTE :   "We need to check what the values are, OSI wise, for this value.  Are elfs 2/3?"
1>  
1>  CResponse.cpp
1>  Dictionary.cpp
1>  JSEncapsulate.cpp
1>  ObjectFactory.cpp
1>  PartySystem.cpp
1>  SEFunctions.cpp
1>  UOXJSMethods.cpp
1>  UOXJSPropertyFuncs.cpp
1>  ai.cpp
1>  archive.cpp
1>  boats.cpp
1>  books.cpp
1>  cAccountClass.cpp
1>  cBaseobject.cpp
1>  cChar.cpp
1>c:\documents and settings\administrator\belgelerim\deniz\programming\uox3\projects\uox3\source\cchar.cpp(236): error C2668: 'std::bitset<_Bits>::bitset' : ambiguous call to overloaded function
1>          with
1>          [
1>              _Bits=32
1>          ]
1>          c:\program files\microsoft visual studio 10.0\vc\include\bitset(174): could be 'std::bitset<_Bits>::bitset(const char *)'
1>          with
1>          [
1>              _Bits=32
1>          ]
1>          c:\program files\microsoft visual studio 10.0\vc\include\bitset(136): or       'std::bitset<_Bits>::bitset(_ULonglong)'
1>          with
1>          [
1>              _Bits=32
1>          ]
1>          c:\program files\microsoft visual studio 10.0\vc\include\bitset(127): or       'std::bitset<_Bits>::bitset(int)'
1>          with
1>          [
1>              _Bits=32
1>          ]
1>          while trying to match the argument list '(const UOX::UI32)'
1>  Generating Code...
1>  Compiling...
1>  cConsole.cpp
1>c:\documents and settings\administrator\belgelerim\deniz\programming\uox3\projects\uox3\source\cconsole.cpp(116): warning C4018: '>' : signed/unsigned mismatch
1>c:\documents and settings\administrator\belgelerim\deniz\programming\uox3\projects\uox3\source\cconsole.cpp(123): warning C4018: '>' : signed/unsigned mismatch
1>  cDice.cpp
1>  cGuild.cpp
1>  c:\documents and settings\administrator\belgelerim\deniz\programming\uox3\projects\uox3\source\cguild.cpp(1339) :  NOTE :   "Move guildstone functionality goes here"
1>  
1>  cHTMLSystem.cpp
1>  cItem.cpp
1>  cMultiObj.cpp
1>  cPlayerAction.cpp
1>  c:\documents and settings\administrator\belgelerim\deniz\programming\uox3\projects\uox3\source\cplayeraction.cpp(2481) :  TODO :   "We need to update this to use getTileName almost exclusively, for plurality"
1>  
1>  cRaces.cpp
1>  cScript.cpp
1>  cServerData.cpp
1>c:\documents and settings\administrator\belgelerim\deniz\programming\uox3\projects\uox3\source\cserverdata.cpp(1485): error C2679: binary '=' : no operator found which takes a right-hand operand of type 'size_t' (or there is no acceptable conversion)
1>          c:\program files\microsoft visual studio 10.0\vc\include\bitset(511): could be 'std::bitset<_Bits> &std::bitset<_Bits>::operator =(const std::bitset<_Bits> &)'
1>          with
1>          [
1>              _Bits=9
1>          ]
1>          while trying to match the argument list '(std::bitset<_Bits>, size_t)'
1>          with
1>          [
1>              _Bits=9
1>          ]
1>  cServerDefinitions.cpp
1>  cSocket.cpp
1>  cSpawnRegion.cpp
1>  cThreadQueue.cpp
1>  cVersionClass.cpp
1>  cWeather.cpp
1>  calcfuncs.cpp
1>  cmdtable.cpp
1>  combat.cpp
1>  commands.cpp
1>  Generating Code...
1>  Compiling...
1>  dist.cpp
1>  effect.cpp
1>  fileio.cpp
1>  findfuncs.cpp
1>  gumps.cpp
1>  house.cpp
1>  items.cpp
1>  jail.cpp
1>  lineofsight.cpp
1>  magic.cpp
1>  mapstuff.cpp
1>c:\documents and settings\administrator\belgelerim\deniz\programming\uox3\projects\uox3\source\mapstuff.cpp(1180): error C2679: binary '=' : no operator found which takes a right-hand operand of type 'UOX::UI32' (or there is no acceptable conversion)
1>          c:\program files\microsoft visual studio 10.0\vc\include\bitset(511): could be 'std::bitset<_Bits> &std::bitset<_Bits>::operator =(const std::bitset<_Bits> &)'
1>          with
1>          [
1>              _Bits=32
1>          ]
1>          while trying to match the argument list '(std::bitset<_Bits>, UOX::UI32)'
1>          with
1>          [
1>              _Bits=32
1>          ]
1>c:\documents and settings\administrator\belgelerim\deniz\programming\uox3\projects\uox3\source\mapstuff.cpp(1203): error C2679: binary '=' : no operator found which takes a right-hand operand of type 'UOX::UI32' (or there is no acceptable conversion)
1>          c:\program files\microsoft visual studio 10.0\vc\include\bitset(511): could be 'std::bitset<_Bits> &std::bitset<_Bits>::operator =(const std::bitset<_Bits> &)'
1>          with
1>          [
1>              _Bits=32
1>          ]
1>          while trying to match the argument list '(std::bitset<_Bits>, UOX::UI32)'
1>          with
1>          [
1>              _Bits=32
1>          ]
1>  movement.cpp
1>  msgboard.cpp
1>  network.cpp
1>  c:\documents and settings\administrator\belgelerim\deniz\programming\uox3\projects\uox3\source\network.cpp(583) :  NOTE :   "Flush location"
1>  
1>  c:\documents and settings\administrator\belgelerim\deniz\programming\uox3\projects\uox3\source\network.cpp(748) :  NOTE :   "Flush location"
1>  
1>  npcs.cpp
1>  pcmanage.cpp
1>  c:\documents and settings\administrator\belgelerim\deniz\programming\uox3\projects\uox3\source\pcmanage.cpp(836) :  NOTE :   "HTML Status for Players"
1>  
1>  quantityfuncs.cpp
1>  queue.cpp
1>  regions.cpp
1>  c:\documents and settings\administrator\belgelerim\deniz\programming\uox3\projects\uox3\source\regions.cpp(102) :  TODO :   "PlayerHTML Dumping needs to be reimplemented"
1>  
1>  scriptc.cpp
1>  Generating Code...
1>  Compiling...
1>  skills.cpp
1>  sound.cpp
1>  speech.cpp
1>  ssection.cpp
1>  targeting.cpp
1>  threadsafeobject.cpp
1>  townregion.cpp
1>  trade.cpp
1>  uox3.cpp
1>  ustring.cpp
1>  vendor.cpp
1>  weight.cpp
1>  wholist.cpp
1>  worldmain.cpp
1>  Generating Code...
1>
1>Build FAILED.
1>
1>Time Elapsed 00:06:08.57
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
latest svn.

Posted: Tue Dec 20, 2011 7:24 pm
by Xuri
Hm. I'm using VS6 and VS2008 Express, and I'm not seeing those compiling errors. Not sure what's up there. Maybe giwo knows.

Posted: Wed Dec 21, 2011 1:27 am
by giwo
This is a bug in VS2010, the work-around is to cast the unsigned long to an unsigned long long.

I would recommend you try changing line 31 in typedefs.h from

Code: Select all

	typedef unsigned long int UI32;
to

Code: Select all

	typedef unsigned long long UI32;
Note this may have other negative effects and potentially increase the memory footprint of UOX3, so the best solution would be to only change the instances that are throwing errors or compile in VS2008

http://stackoverflow.com/questions/6947 ... ing-vs2010

Posted: Wed Dec 21, 2011 5:24 am
by xantier
giwo wrote:This is a bug in VS2010, the work-around is to cast the unsigned long to an unsigned long long.

I would recommend you try changing line 31 in typedefs.h from

Code: Select all

	typedef unsigned long int UI32;
to

Code: Select all

	typedef unsigned long long UI32;
Note this may have other negative effects and potentially increase the memory footprint of UOX3, so the best solution would be to only change the instances that are throwing errors or compile in VS2008

http://stackoverflow.com/questions/6947 ... ing-vs2010
unfortunately, i got more errors. i will simply install vs2008, i hope it fixes this.

Posted: Wed Dec 21, 2011 8:51 pm
by Tom
I'm having trouble with spidermonkey compiling, I have several compilers installed, and my nmake wont work. Also having no luck finding a way to manually set my enviroment paths. Reinstalling isnt an option, and my vcvars is from a different pc installation. Does anyone know how to set the path manually? This my last obstacle to compiling. Even better, a download of the js32.dll and js32.lib from the current build pre-compiled?

Posted: Wed Dec 21, 2011 9:09 pm
by xantier
okay i installed vs2008 and compiled it successfully. you must compile js32.lib and .dll and set library path for these. otherwise, you will get link error with js32.lib

Posted: Wed Dec 21, 2011 11:46 pm
by Tom
If you could check your system/advanced/enviroment variables.. and post the value and path it added, I could manually enter them.

Other than that I'm stuck without the js32.lib, the dll is included in the UOX3 folder.

Posted: Wed Dec 21, 2011 11:59 pm
by Xuri
Not sure if it will help you, as you're using VS2008/2010, but the following archive contains two versions (one from 2006 and the other from 2007) of the release/debug js32.lib files that I compiled in VS6 back in the day, and have been using since:
js32_lib.7z (RAR-version)

I'd upload the ones I have for 2008 Express, but that computer is on a different continent at the moment, and I won't have access to it again until after New Year.

Posted: Thu Dec 22, 2011 12:18 am
by Tom
Thank you so much, I have 6 pro and 2008 installed actually, along with a few others :)

I have a good feeling it will work! I'll post back to let you know.

Posted: Thu Dec 22, 2011 12:31 am
by Tom
Worked like a charm, thanks Xuri!

I'll try to assist xantier with the client version issues. Dragon had a good question about why though, Id like to see the reply. A somewhat newer client could be made to behave like an older one, unless there is something I am missing.