IPB

Welcome Guest ( Log In | Register )

2 Pages V  1 2 >  
Reply to this topicStart new topic
> RC2BOTS, rc2bots for linux
luc19707
post Feb 26 2007, 09:33 PM
Post #1


Newbie
*

Group: Members
Posts: 2
Joined: 12-February 07
Member No.: 1,031



Hi Everidody ,,

I just want to know if it is possible to run the RC2BOT source on a linux machine?If yes can sommeone give me the link for the plugin?Because i think .dll are for windows only.......thanks you .....
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
terminator_2
post Feb 26 2007, 10:23 PM
Post #2


Member
**

Group: Members
Posts: 13
Joined: 26-February 07
Member No.: 1,057



I would be able to provide a test server if a linux variant could be compiled. We're running the Windows32 version at work during lunchtimes and I have been working on some waypoints.
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
luc19707
post Feb 27 2007, 12:16 AM
Post #3


Newbie
*

Group: Members
Posts: 2
Joined: 12-February 07
Member No.: 1,031



ty terminator your da man
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
Salvax
post Feb 27 2007, 04:53 AM
Post #4


Advanced Member
***

Group: Members
Posts: 75
Joined: 14-February 07
Member No.: 1,034



not yet, but i hope there would be . smile.gif
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
Cheeseh
post Feb 27 2007, 11:50 AM
Post #5


Admin
*****

Group: Admin
Posts: 3,066
Joined: 11-September 03
From: uk
Member No.: 1



The source is available for anyone who wants to compile in linux, although I have no idea what is needed to compile in linux so they would have to do a little research on the Source developer sdk in linux before hand.
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
Fusionhead
post Mar 19 2007, 04:24 AM
Post #6


Member
**

Group: Members
Posts: 11
Joined: 18-March 07
Member No.: 1,075



QUOTE(Cheeseh @ Feb 27 2007, 11:50 AM) *

The source is available for anyone who wants to compile in linux, although I have no idea what is needed to compile in linux so they would have to do a little research on the Source developer sdk in linux before hand.


Hi Cheeseh, nice mod.

I have an AMD 64 Ubuntu 64 Linux server as well a 32 bit verity. I'll look into getting a compile completed. As with you, my time is limited but I'll see what I can do. If others want to take a crack at it, Info can be found at the following link:

http://developer.valvesoftware.com/wiki/Co...ing_under_Linux

-Fusionhead

User is offlineProfile CardPM
Go to the top of the page
+Quote Post
Salvax
post Mar 31 2007, 02:02 PM
Post #7


Advanced Member
***

Group: Members
Posts: 75
Joined: 14-February 07
Member No.: 1,034



there r lots of versions of Linux, for Red Hat , i think GCC is better smile.gif
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
Fusionhead
post Apr 14 2007, 07:16 AM
Post #8


Member
**

Group: Members
Posts: 11
Joined: 18-March 07
Member No.: 1,075



QUOTE(Salvax @ Mar 31 2007, 02:02 PM) *

there r lots of versions of Linux, for Red Hat , i think GCC is better smile.gif


I use gcc smile.gif

OK, I'm taking a look at this now. Anyone know how to convert the Microsoft Visual Studio file HPB_Bot2.vcproj to a gcc Makefile?

I've got my gcc/g++ environment working. I really want to get this Linux port working so I can use my Linux box for games only. There's a big difference of how many people join the bot server versus no bots. Right now, I'm hosting my game server on my desktop. Not ideal!

-Fusionhead
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
terminator_2
post Oct 9 2007, 10:07 PM
Post #9


Member
**

Group: Members
Posts: 13
Joined: 26-February 07
Member No.: 1,057



QUOTE(Fusionhead @ Apr 14 2007, 08:16 AM) *

I use gcc smile.gif

OK, I'm taking a look at this now. Anyone know how to convert the Microsoft Visual Studio file HPB_Bot2.vcproj to a gcc Makefile?

I've got my gcc/g++ environment working. I really want to get this Linux port working so I can use my Linux box for games only. There's a big difference of how many people join the bot server versus no bots. Right now, I'm hosting my game server on my desktop. Not ideal!

-Fusionhead


Fusionhead,

I have probably made a breakthrough with the complie for linux, however I'm running 64bit and when I perform a "make", then it comes back saying that the "CPU you selected does not support x86-64 instruction set"!

What I have done so far is to install the HLSDK onto my linux machine and then gone to the HLSDK's linux_sdk directory and had a look at their makefile. I then installed a bit of code called xerces (as stated in the makefile) and apparently this will enable the gcc compiler to read Visual studio proj files!

I am even considering building a temporary linux 32bit machine just to compile the code!!

Regards,

T2
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
Fusionhead
post Nov 13 2007, 08:11 PM
Post #10


Member
**

Group: Members
Posts: 11
Joined: 18-March 07
Member No.: 1,075



QUOTE(terminator_2 @ Oct 9 2007, 10:07 PM) *

Fusionhead,

I have probably made a breakthrough with the complie for linux, however I'm running 64bit and when I perform a "make", then it comes back saying that the "CPU you selected does not support x86-64 instruction set"!

What I have done so far is to install the HLSDK onto my linux machine and then gone to the HLSDK's linux_sdk directory and had a look at their makefile. I then installed a bit of code called xerces (as stated in the makefile) and apparently this will enable the gcc compiler to read Visual studio proj files!

I am even considering building a temporary linux 32bit machine just to compile the code!!

Regards,

T2



Hey T2, nice work. smile.gif Did you get a clean compile? That would be great. I haven't had the time to work on this. A 32 bit compile should work on your 64 bit machine.

-Fusionhead
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
terminator_2
post Nov 19 2007, 09:26 PM
Post #11


Member
**

Group: Members
Posts: 13
Joined: 26-February 07
Member No.: 1,057



QUOTE(Fusionhead @ Nov 13 2007, 08:11 PM) *

Hey T2, nice work. smile.gif Did you get a clean compile? That would be great. I haven't had the time to work on this. A 32 bit compile should work on your 64 bit machine.

-Fusionhead


Hey Fusionhead,

Still trying to get the mod to compile...... can get a sample server plugin provided by valve to compiles OK, but the RCBot code fails in some areas. I'm no c++ programmer (can post the failures). I am trying various versions of Linux to get a decent compile environment. Have tried Mandriva, Unbuntu and have now moved on fedora core 6.
Have had best results with gcc4.1.1 but I have seen in some forums that I should be using gcc3.4.6 which gives the best results.
Am still working on it, but I can't spend too mush time on it at the moment myself.
Xerces does convert from a vcproj file to a make file... it's just getting the copiler to work with the RCBot2 code.

T2
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
terminator_2
post Mar 4 2008, 10:16 PM
Post #12


Member
**

Group: Members
Posts: 13
Joined: 26-February 07
Member No.: 1,057



Cheeseh,

Firstly, I can't thank you enough for coding the bots for HL2DM...... we play during our lunch break at work. We used to able to get 5 humans deathmatch, but were told off because of all the peronal pc's on site and therefore we looked to using the bots and now have 3 humans and 11 bots team dethmatch - 30 miunte frag fest!

I have been extremely busy over the past year waypointing loads of maps (some aren't fully optimised, some are not finished.) but I was wondering if you would like them...... (if you can give me the ability to upload them somewhere then I will!). I have been using Salvax's ladder code, so some of the maps have areas for ladders.

I posted some entries on the forum regarding my attempts at compiling for Linux (so I can run the bots at home), but have really now come to a stop. I can get a sample plugin to compile (from valve) using gcc and also a tool called xerces (which can convert a vcproj file). However, when I try a rcbot2 compile it fails with some errors (This is the first): -

[nick@localhost linux_sdk]$ make

if [ -z "/usr/bin/gcc34" ]; then echo "Compiler not defined."; exit; fi

if [ ! -d . ];then mkdir .;fi

cd .

if [ ! -f "tier0_i486.so" ]; then ln -s ../../hl2mp/bin/tier0_i486.so .; fi

if [ ! -f "vstdlib_i486.so" ]; then ln -s ../../hl2mp/bin/vstdlib_i486.so .; fi

./vcpm ../utils/HPB_Bot2/HPB_Bot2.vcproj

Valve Software - vcprojtomake.exe (Feb 24 2008)

make -f Makefile.mod CC=/usr/bin/gcc34 CPLUS=/usr/bin/g++34 CPP_LIB="/usr/lib/gcc/i386-redhat-linux/3.4.6/libstdc++.a /usr/lib/gcc/i386-redhat-linux/3.4.6/libgcc_eh.a" BUILD_DIR=. BUILD_OBJ_DIR=./obj SOURCE_DIR=.. SHLIBLDFLAGS=-shared -Wl,-Map,mod_map.txt -Wl SHLIBEXT=so CLINK=/usr/bin/gcc34 CFLAGS=" -mtune=i686 -march=pentium3 -mmmx -O3 -fpermissive -D_LINUX -DNDEBUG -Dstricmp=strcasecmp -D_stricmp=strcasecmp -D_strnicmp=strncasecmp -Dstrnicmp=strncasecmp -D_snprintf=snprintf -D_vsnprintf=vsnprintf -D_alloca=alloca -Dstrcmpi=strcasecmp -Usprintf=use_Q_snprintf_instead_of_sprintf -Ustrncpy=use_Q_strncpy_instead -UPROTECTED_THINGS_ENABLE" LDFLAGS="-lm -ldl ../../hl2mp/bin/tier0_i486.so ../../hl2mp/bin/vstdlib_i486.so mathlib_i486.a choreoobjects_i486.a tier1_i486.a" ARCH=i486 GAME_DIR=../../hl2mp MOD_CONFIG=HPB_bot2_ReleaseWin32 NAME=hpb_bot2 XERCES_INC_DIR=/usr/local/src/xerces-c_2_6_0/include XERCES_LIB_DIR=/usr/local/src/xerces-c_2_6_0/lib

make[1]: Entering directory `/hl2sdk/linux_sdk'

mkdir -p obj/hpb_bot2_i486/utils/HPB_Bot2

mkdir -p obj/hpb_bot2_i486/utils/HPB_Bot2/public

mkdir -p obj/hpb_bot2_i486/utils/HPB_Bot2/public/tier0

mkdir -p obj/hpb_bot2_i486/utils/HPB_Bot2/tier1

/usr/bin/g++34 -w -I../utils/HPB_Bot2/../../public -I../utils/HPB_Bot2/../../public/engine -I../utils/HPB_Bot2/../../public/tier0 -I../utils/HPB_Bot2/../../public/tier1 -I../utils/HPB_Bot2/../../dlls -I../utils/HPB_Bot2/../../game_shared -DNDEBUG -mtune=i686 -march=pentium3 -mmmx -O3 -fpermissive -D_LINUX -DNDEBUG -Dstricmp=strcasecmp -D_stricmp=strcasecmp -D_strnicmp=strncasecmp -Dstrnicmp=strncasecmp -D_snprintf=snprintf -D_vsnprintf=vsnprintf -D_alloca=alloca -Dstrcmpi=strcasecmp -Usprintf=use_Q_snprintf_instead_of_sprintf -Ustrncpy=use_Q_strncpy_instead -UPROTECTED_THINGS_ENABLE -o obj/hpb_bot2_i486/utils/HPB_Bot2/bot.o -c ../utils/HPB_Bot2/bot.cpp

In file included from ../utils/HPB_Bot2/../../game_shared/usercmd.h:16,

from ../utils/HPB_Bot2/bot.cpp:44:

../utils/HPB_Bot2/../../game_shared/imovehelper.h:20: error: use of enum `PLAYER_ANIM' without previous declaration

../utils/HPB_Bot2/../../game_shared/imovehelper.h:81: error: `PLAYER_ANIM' has not been declared

In file included from ../utils/HPB_Bot2/bot.h:47,

from ../utils/HPB_Bot2/bot.cpp:54:

../utils/HPB_Bot2/../../game_shared/IEffects.h:23: error: use of enum `ShakeCommand_t' without previous declaration

In file included from ../utils/HPB_Bot2/bot_schedule.h:36,

from ../utils/HPB_Bot2/bot.cpp:55:

../utils/HPB_Bot2/bot_genclass.h: In member function `void dataUnconstArray<T>::Remove(T)':

../utils/HPB_Bot2/bot_genclass.h:645: error: expected `;' before "it"

../utils/HPB_Bot2/bot_genclass.h:647: error: `it' was not declared in this scope

make[1]: *** [obj/hpb_bot2_i486/utils/HPB_Bot2/bot.o] Error 1

make[1]: Leaving directory `/hl2sdk/linux_sdk'

make: *** [mod] Error 2

It's the last few lines that I don't understand..... these are valve standard files! ..... any ideas? If you do, then we're nearer a linux compile!

Any help would be appreciated!

t_2
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
Fusionhead
post Mar 6 2008, 09:54 PM
Post #13


Member
**

Group: Members
Posts: 11
Joined: 18-March 07
Member No.: 1,075



Hey T2, nice work again. Have you checked the steam developer forums?

http://forums.steampowered.com/forums/forumdisplay.php?f=191

I shut down all of my servers a few months ago so I no longer have a need but I may crank them up again at some point. I wish that I could help. Just no time. Another place to ask is some of the modders sites. Like you could try asking on.

http://www.mani-admin-plugin.com/index.php...6&board=1.0

http://www.sourcemm.net/?go=plugins

They should be able to steer you in the right direction if not answer directly.

Good luck!

~Fusionhead





User is offlineProfile CardPM
Go to the top of the page
+Quote Post
terminator_2
post Apr 18 2008, 08:43 PM
Post #14


Member
**

Group: Members
Posts: 13
Joined: 26-February 07
Member No.: 1,057



QUOTE(Fusionhead @ Mar 6 2008, 10:54 PM) *

Hey T2, nice work again. Have you checked the steam developer forums?

http://forums.steampowered.com/forums/forumdisplay.php?f=191

I shut down all of my servers a few months ago so I no longer have a need but I may crank them up again at some point. I wish that I could help. Just no time. Another place to ask is some of the modders sites. Like you could try asking on.

http://www.mani-admin-plugin.com/index.php...6&board=1.0

http://www.sourcemm.net/?go=plugins

They should be able to steer you in the right direction if not answer directly.

Good luck!

~Fusionhead


Fusionhead.... thanks for the info. I had searched the suggested forums and i had not found the answers that I wanted.

The news is that I have started to get a compile. It has now processed 13 of the 29 C++ files. The compile now fails in bot_main.cpp at lines 530 - static ConVar empty_cvar(BOT_VER_CVAR, BOT_VER, FCVAR_PLUGIN, BOT_NAME_VER);
It then fails at lines 604, 612, 613, 615, 616, 617, 632, 633, 634, 636 and then finally falls over!

I'm no C++ programmer, so I'm slow at running through the code, but at least we now have an environment that will compile the code (on fedora core and unbuntu).
Have had some luck with cygwin, but it seems to get further on Fedora core and Unbuntu.
Anyone able to to look at a dump of the latest failure?

terminator_2
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
terminator_2
post May 3 2008, 08:24 PM
Post #15


Member
**

Group: Members
Posts: 13
Joined: 26-February 07
Member No.: 1,057



Update!!!

I've sat through each c++ file and found most of the fixable errors and I now get something that compiles, however, I can't get it to load in the Linux Dedicated Server.
I have tried various ways of compiling the code on various platforms and I still get the same. The complile goes ahead without any error messages using Valves own Makefiles (which converts a VCProj file to something that can be used in Linux).
When I issue an ldd -d on the resulting file(in this case HPB_bot2_i486.so) it says something about an undefined symbol in the HPB_bot2_i486.so and quoting _ZN17CNavMeshNavigator6beliefE6VectorS0_ff9BotBelief
We're so near now to the Linux Compile.

Cheeseh, can you confirm all the bot*.cpp and bot*.h files are needed for the compile. I have edited the vcproj file to exclude bot_memory etc, but just wondering if I have missed something?

t_2
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
Fusionhead
post Dec 3 2008, 11:46 PM
Post #16


Member
**

Group: Members
Posts: 11
Joined: 18-March 07
Member No.: 1,075



T2, I thought I'd check back here. You probably gave up on this by now.
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
terminator_2
post Dec 4 2008, 09:46 PM
Post #17


Member
**

Group: Members
Posts: 13
Joined: 26-February 07
Member No.: 1,057



QUOTE(Fusionhead @ Dec 4 2008, 12:46 AM) *

T2, I thought I'd check back here. You probably gave up on this by now.



I've not given up.... I have now got the code to compile via two methods (using valves Makefile + cross compilier xerces) and I have also used Sourcemm's version of copiling and a moddified version of their Makefile. Unfortunately, the resulting plugin fails to load. I have also got the code to compile in two variants of Linux - both Fedora core 6 and Unbuntu (can't remeber what version number).

The failure is somewhere in bot.navmesh.cpp I think, but I haven't been able to track down the error just yet. It's still WIP, but I don't understand why it is not working.

performing an ldd -d -r on HPB_Bot2_mm_i486.so results in: -

[nick@localhost Linux]$ ldd -d -r HPB_Bot2_mm_i486.so
linux-gate.so.1 => (0x00110000)
libm.so.6 => /lib/libm.so.6 (0x00498000)
libdl.so.2 => /lib/libdl.so.2 (0x004bf000)
/hl2mp/bin/tier0_i486.so (0x004c3000)
/hl2mp/bin/vstdlib_i486.so (0x004f9000)
libc.so.6 => /lib/libc.so.6 (0x0050d000)
/lib/ld-linux.so.2 (0x80000000)
libpthread.so.0 => /lib/libpthread.so.0 (0x0064d000)
tier0_i486.so => not found
undefined symbol: _ZN17CNavMeshNavigator6beliefE6VectorS0_ff9BotBelief (./HPB_Bot2_mm_i486.so)
undefined symbol: _ZSt20__throw_length_errorPKc (./HPB_Bot2_mm_i486.so)
undefined symbol: __cxa_guard_release (./HPB_Bot2_mm_i486.so)
undefined symbol: _ZSt17__throw_bad_allocv (./HPB_Bot2_mm_i486.so)
undefined symbol: __cxa_guard_acquire (./HPB_Bot2_mm_i486.so)


Thanks for the interest, t_2.

QUOTE(Fusionhead @ Dec 4 2008, 12:46 AM) *

T2, I thought I'd check back here. You probably gave up on this by now.



I've not given up.... I have now got the code to compile via two methods (using valve's Makefile + cross compilier xerces) and I have also used Sourcemm's version of copiling and a modified version of their Makefile. Unfortunately, the resulting plugin fails to load. I have also got the code to compile in two variants of Linux - both Fedora core 6 and Unbuntu (can't remeber what version number).

The failure is somewhere in bot.navmesh.cpp I think, but I haven't been able to track down the error just yet. It's still WIP, but I don't understand why it is not working.

performing an ldd -d -r on HPB_Bot2_mm_i486.so results in: -

[nick@localhost Linux]$ ldd -d -r HPB_Bot2_mm_i486.so
linux-gate.so.1 => (0x00110000)
libm.so.6 => /lib/libm.so.6 (0x00498000)
libdl.so.2 => /lib/libdl.so.2 (0x004bf000)
/hl2mp/bin/tier0_i486.so (0x004c3000)
/hl2mp/bin/vstdlib_i486.so (0x004f9000)
libc.so.6 => /lib/libc.so.6 (0x0050d000)
/lib/ld-linux.so.2 (0x80000000)
libpthread.so.0 => /lib/libpthread.so.0 (0x0064d000)
tier0_i486.so => not found
undefined symbol: _ZN17CNavMeshNavigator6beliefE6VectorS0_ff9BotBelief (./HPB_Bot2_mm_i486.so)
undefined symbol: _ZSt20__throw_length_errorPKc (./HPB_Bot2_mm_i486.so)
undefined symbol: __cxa_guard_release (./HPB_Bot2_mm_i486.so)
undefined symbol: _ZSt17__throw_bad_allocv (./HPB_Bot2_mm_i486.so)
undefined symbol: __cxa_guard_acquire (./HPB_Bot2_mm_i486.so)


Thanks for the interest, t_2.
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
Enra
post Apr 27 2009, 08:18 PM
Post #18


Newbie
*

Group: Members
Posts: 6
Joined: 26-April 09
Member No.: 1,530



Any updates on the Linux build?

I have run into the first batch of problems discussed here.
CODE
../utils/RCBot2/../../game/shared/imovehelper.h:20: error: use of enum ‘PLAYER_ANIM’ without previous declaration
../utils/RCBot2/../../game/shared/imovehelper.h:81: error: ‘PLAYER_ANIM’ has not been declared
../utils/RCBot2/../../game/shared/IEffects.h:23: error: use of enum ‘ShakeCommand_t’ without previous declaration
../utils/RCBot2/bot_genclass.h: In member function ‘void dataUnconstArray<T>::Remove(T)’:
../utils/RCBot2/bot_genclass.h:647: error: expected `;' before ‘it’
../utils/RCBot2/bot_genclass.h:649: error: ‘it’ was not declared in this scope


I am using GCC 4.1.3 with the same options that I use to build my mod so I didn't expect errors in the Valve standard headers. What was the solution to this problem?
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
Enra
post Apr 29 2009, 06:08 PM
Post #19


Newbie
*

Group: Members
Posts: 6
Joined: 26-April 09
Member No.: 1,530



OK, tracked down and fixed all Linux related problems. Now the bots loads fine on a dedicated Linux server.
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
rcweed
post May 2 2009, 12:16 PM
Post #20


Newbie
*

Group: Members
Posts: 2
Joined: 2-May 09
Member No.: 1,533



QUOTE(Enra @ Apr 29 2009, 06:08 PM) *

OK, tracked down and fixed all Linux related problems. Now the bots loads fine on a dedicated Linux server.


hi enra,

can you please share your files? thx
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

2 Pages V  1 2 >
Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 



- Lo-Fi Version Time is now: 4th November 2024 - 04:32 AM