1 (edited by derpepe 2008-02-12 11:55:42)

Topic: build problem under windows (v0.3.4)

Hello everybody,

I try to compile teewars for Windows from source.
I managed to go around a number of problems, but I hang at this error:

link e_system.obj : error LNK2019: unresolved external symbol '_SHGetFolderPath' referenced in function '_fs_storage_path'
C:/teewars/teewars-0.3.4-src/teewars_srv.exe : fatal error LNK1120: 1 unresolved external

I don't do programming under windows, so perhaps a win-geek can tell me how to correctly point on the shfolder.dll or whatever wents wrong here.

greetings

Peter


[edit: translated error-message from german]

2

Re: build problem under windows (v0.3.4)

What version of MSVC are you compiling with? MSDN says "shell32.dll version 5.0 or later" for SHGetFolderPath.

3

Re: build problem under windows (v0.3.4)

And and add the -v option to bam to see what commands it's running.

4 (edited by derpepe 2008-02-12 18:04:43)

Re: build problem under windows (v0.3.4)

I updated Windows XP with all available updates.
I downloaded Visual C/C++ Express and installed the newest available Python.

Here is the output of bam -v:

C:\teewars\teewars-0.3.4-src>..\bam\src\bam -v release
bam: reading internal base script
bam: reading script from 'default.bam'
bam: building 'release'
link link /nologo /incremental:no  gdi32.lib user32.lib ws2_32.lib ole32.lib shell32.lib  /out:C:/teewars/teewars-0.3.4-
src/tileset_borderfix.exe C:/teewars/teewars-0.3.4-src/objs/tileset_borderfix.obj C:/teewars/teewars-0.3.4-src/objs/e_co
mpression.obj C:/teewars/teewars-0.3.4-src/objs/e_config.obj C:/teewars/teewars-0.3.4-src/objs/e_datafile.obj C:/teewars
/teewars-0.3.4-src/objs/e_engine.obj C:/teewars/teewars-0.3.4-src/objs/e_keynames.obj C:/teewars/teewars-0.3.4-src/objs/
e_linereader.obj C:/teewars/teewars-0.3.4-src/objs/e_map.obj C:/teewars/teewars-0.3.4-src/objs/e_memheap.obj C:/teewars/
teewars-0.3.4-src/objs/e_msg.obj C:/teewars/teewars-0.3.4-src/objs/e_network.obj C:/teewars/teewars-0.3.4-src/objs/e_pac
ker.obj C:/teewars/teewars-0.3.4-src/objs/e_snapshot.obj C:/teewars/teewars-0.3.4-src/objs/e_system.obj C:/teewars/teewa
rs-0.3.4-src/objs/adler32.obj C:/teewars/teewars-0.3.4-src/objs/compress.obj C:/teewars/teewars-0.3.4-src/objs/crc32.obj
 C:/teewars/teewars-0.3.4-src/objs/deflate.obj C:/teewars/teewars-0.3.4-src/objs/gzio.obj C:/teewars/teewars-0.3.4-src/o
bjs/infback.obj C:/teewars/teewars-0.3.4-src/objs/inffast.obj C:/teewars/teewars-0.3.4-src/objs/inflate.obj C:/teewars/t
eewars-0.3.4-src/objs/inftrees.obj C:/teewars/teewars-0.3.4-src/objs/trees.obj C:/teewars/teewars-0.3.4-src/objs/uncompr
.obj C:/teewars/teewars-0.3.4-src/objs/zutil.obj
e_system.obj : error LNK2019: Verweis auf nicht aufgelöstes externes Symbol "_SHGetFolderPath" in Funktion "_fs_storage_
path".
C:/teewars/teewars-0.3.4-src/tileset_borderfix.exe : fatal error LNK1120: 1 nicht aufgelöste externe Verweise.
bam: link returned error number 1120
bam: error during build

C:\teewars\teewars-0.3.4-src>

This code divided in 3 lines:

link link /nologo /incremental:no  gdi32.lib user32.lib ws2_32.lib ole32.lib shell32.lib
  /out:C:/teewars/teewars-0.3.4-src/tileset_borderfix.exe
  C:/teewars/teewars-0.3.4-src/objs/tileset_borderfix.obj C:/teewars/teewars-0.3.4-src/objs/e_compression.obj C:/teewars/teewars-0.3.4-src/objs/e_config.obj C:/teewars/teewars-0.3.4-src/objs/e_datafile.obj C:/teewars/teewars-0.3.4-src/objs/e_engine.obj C:/teewars/teewars-0.3.4-src/objs/e_keynames.obj C:/teewars/teewars-0.3.4-src/objs/e_linereader.obj C:/teewars/teewars-0.3.4-src/objs/e_map.obj C:/teewars/teewars-0.3.4-src/objs/e_memheap.obj C:/teewars/teewars-0.3.4-src/objs/e_msg.obj C:/teewars/teewars-0.3.4-src/objs/e_network.obj C:/teewars/teewars-0.3.4-src/objs/e_packer.obj C:/teewars/teewars-0.3.4-src/objs/e_snapshot.obj C:/teewars/teewars-0.3.4-src/objs/e_system.obj C:/teewars/teewars-0.3.4-src/objs/adler32.obj C:/teewars/teewars-0.3.4-src/objs/compress.obj C:/teewars/teewars-0.3.4-src/objs/crc32.obj C:/teewars/teewars-0.3.4-src/objs/deflate.obj C:/teewars/teewars-0.3.4-src/objs/gzio.obj C:/teewars/teewars-0.3.4-src/objs/infback.obj C:/teewars/teewars-0.3.4-src/objs/inffast.obj C:/teewars/teewars-0.3.4-src/objs/inflate.obj C:/teewars/teewars-0.3.4-src/objs/inftrees.obj C:/teewars/teewars-0.3.4-src/objs/trees.obj C:/teewars/teewars-0.3.4-src/objs/uncompr.obj C:/teewars/teewars-0.3.4-src/objs/zutil.obj

5

Re: build problem under windows (v0.3.4)

I finally managed to get it to work.
So here is a short tutorial how to compile Teewars from source under Windows XP (Vista should work the same way):

1. Download and install Visual C/C++ Express.
( http://www.microsoft.com/germany/expres … fault.aspx )

2. Download and install Windows Server 2003 Platform SDK. It suits also for Windows XP.
( http://www.microsoft.com/downloads/deta … laylang=en )

3. Download and install the DirectX SDK.
( http://www.microsoft.com/downloads/deta … laylang=en )

4. Run the "Visual Studio 2008-Console", you can find it in the start menu under "All Programs\Visual C++ 9.0 Express Edition\Visual Studio Tools".

5. Run the following commands, they will set up your environment:

cd "C:\Program Files\Microsoft DirectX SDK (November 2007)\Utilities\Bin"
call dx_setenv.cmd
cd "C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2"
call SetEnv.Cmd

In this console, you can now compile BAM ( http://teewars.com/files/bam.zip ) and use it to compile Teewars from source.

6

Re: build problem under windows (v0.3.4)

matricks wrote:

And and add the -v option to bam to see what commands it's running.

First of all, use the Edit Button! lol

@Topic:

A friend of me has got the same problem.... I going to ask him tomorrow what he did!

ima charhgin ma lazerz!!1
SHOOP DA WHOOOOP!!!!!!11

7

Re: build problem under windows (v0.3.4)

I already posted the solution, so you can ask your friend if he wants to try to install the two SDKs.

8

Re: build problem under windows (v0.3.4)

derpepe wrote:

I finally managed to get it to work.
So here is a short tutorial how to compile Teewars from source under Windows XP (Vista should work the same way):

1. Download and install Visual C/C++ Express.
( http://www.microsoft.com/germany/expres … fault.aspx )

2. Download and install Windows Server 2003 Platform SDK. It suits also for Windows XP.
( http://www.microsoft.com/downloads/deta … laylang=en )

3. Download and install the DirectX SDK.
( http://www.microsoft.com/downloads/deta … laylang=en )

4. Run the "Visual Studio 2008-Console", you can find it in the start menu under "All Programs\Visual C++ 9.0 Express Edition\Visual Studio Tools".

5. Run the following commands, they will set up your environment:

cd "C:\Program Files\Microsoft DirectX SDK (November 2007)\Utilities\Bin"
call dx_setenv.cmd
cd "C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2"
call SetEnv.Cmd

In this console, you can now compile BAM ( http://teewars.com/files/bam.zip ) and use it to compile Teewars from source.

Ok so I did all of this, but now I don't understand how to compile BAM...Can someone direct me in the right direction? or is there an easier way?

<JB4> hehe <3 matricks (not in a gay way though) <matricks> awww sad <JB4> thats wrong I'm friggen 15... <matricks> thats legal here in sweden big_smile

9

Re: build problem under windows (v0.3.4)

run steps 4,5 then change directory to your bam folder and type:
make_win32_msvc2005

that should comiple bam.

then change directory to teewars source and type:
path to bam folder\src\bam release

10

Re: build problem under windows (v0.3.4)

this is what happens when i try to compile the teewars source:

http://img297.imageshack.us/img297/2826/compilinghelpdp0.png

any suggestions?

<JB4> hehe <3 matricks (not in a gay way though) <matricks> awww sad <JB4> thats wrong I'm friggen 15... <matricks> thats legal here in sweden big_smile

11

Re: build problem under windows (v0.3.4)

Wrong or no version of python installed?

Languages shapes the way we think, or don't.

12 (edited by JB4 2008-02-27 00:20:01)

Re: build problem under windows (v0.3.4)

Never mind I fixed it! I got it to compile smile

[EDIT]

crap now i get an error that it can't access include files or something, it was something.h but IDK how to fix that. I'll look it up when i try again.

<JB4> hehe <3 matricks (not in a gay way though) <matricks> awww sad <JB4> thats wrong I'm friggen 15... <matricks> thats legal here in sweden big_smile