Page 1 of 2

Compilin Server

Posted: 14 Dec 2006, 01:24
by Av3nger (Offline)
Sorry again but i need a help =/
This is the error when i try to compile the server which i've download in the svn directory/tmwserver/branch/enet

Code: Select all

Compilador: Default compiler
Building Makefile: "D:\tmw\server\Makefile.win"
Executando  make...
make.exe -f "D:\tmw\server\Makefile.win" all
g++.exe -D__DEBUG__ -c src/dal/dataproviderfactory.cpp -o src/obj/dataproviderfactory.o -I"C:/Dev-Cpp/lib/gcc/mingw32/3.4.2/include"  -I"C:/Dev-Cpp/include/c++/3.4.2/backward"  -I"C:/Dev-Cpp/include/c++/3.4.2/mingw32"  -I"C:/Dev-Cpp/include/c++/3.4.2"  -I"C:/Dev-Cpp/include"  -I"C:/Dev-Cpp/mingw/include/SDL"  -I"C:/Dev-Cpp/mingw/include/DLL"  -DSQLITE_SUPPORT   -O3 -g3

In file included from src/dal/dataproviderfactory.cpp:31:
src/dal/sqlitedataprovider.h:27:21: sqlite3.h: No such file or directory
In file included from src/dal/dataproviderfactory.cpp:31:

src/dal/sqlitedataprovider.h:109: error: ISO C++ forbids declaration of `sqlite3' with no type

src/dal/sqlitedataprovider.h:109: error: expected `;' before '*' token

make.exe: *** [src/obj/dataproviderfactory.o] Error 1

Execução terminada

Thanks For all support

//Av3nger

Posted: 14 Dec 2006, 08:55
by ElvenProgrammer
You need sqlite. You can get a devpak here http://devpaks.org/category.php?category=Database

Posted: 14 Dec 2006, 20:19
by Av3nger (Offline)
Ok i will try but do not close yet i will check if is this the problem(no that i don't believe in you..)

--Edited

New problem...

Code: Select all

Compilador: Default compiler
Building Makefile: "D:\tmw\server\Makefile.win"
Executando  make...
make.exe -f "D:\tmw\server\Makefile.win" all
g++.exe -D__DEBUG__ -c src/dal/dataproviderfactory.cpp -o src/obj/dataproviderfactory.o -I"C:/Dev-Cpp/lib/gcc/mingw32/3.4.2/include"  -I"C:/Dev-Cpp/include/c++/3.4.2/backward"  -I"C:/Dev-Cpp/include/c++/3.4.2/mingw32"  -I"C:/Dev-Cpp/include/c++/3.4.2"  -I"C:/Dev-Cpp/include"  -I"C:/Dev-Cpp/mingw/include/SDL"  -I"C:/Dev-Cpp/mingw/include/DLL"  -DSQLITE_SUPPORT   -O3 -g3

g++.exe -D__DEBUG__ -c src/dal/recordset.cpp -o src/obj/recordset.o -I"C:/Dev-Cpp/lib/gcc/mingw32/3.4.2/include"  -I"C:/Dev-Cpp/include/c++/3.4.2/backward"  -I"C:/Dev-Cpp/include/c++/3.4.2/mingw32"  -I"C:/Dev-Cpp/include/c++/3.4.2"  -I"C:/Dev-Cpp/include"  -I"C:/Dev-Cpp/mingw/include/SDL"  -I"C:/Dev-Cpp/mingw/include/DLL"  -DSQLITE_SUPPORT   -O3 -g3

g++.exe -D__DEBUG__ -c src/dal/sqlitedataprovider.cpp -o src/obj/sqlitedataprovider.o -I"C:/Dev-Cpp/lib/gcc/mingw32/3.4.2/include"  -I"C:/Dev-Cpp/include/c++/3.4.2/backward"  -I"C:/Dev-Cpp/include/c++/3.4.2/mingw32"  -I"C:/Dev-Cpp/include/c++/3.4.2"  -I"C:/Dev-Cpp/include"  -I"C:/Dev-Cpp/mingw/include/SDL"  -I"C:/Dev-Cpp/mingw/include/DLL"  -DSQLITE_SUPPORT   -O3 -g3

g++.exe -D__DEBUG__ -c src/utils/logger.cpp -o src/obj/logger.o -I"C:/Dev-Cpp/lib/gcc/mingw32/3.4.2/include"  -I"C:/Dev-Cpp/include/c++/3.4.2/backward"  -I"C:/Dev-Cpp/include/c++/3.4.2/mingw32"  -I"C:/Dev-Cpp/include/c++/3.4.2"  -I"C:/Dev-Cpp/include"  -I"C:/Dev-Cpp/mingw/include/SDL"  -I"C:/Dev-Cpp/mingw/include/DLL"  -DSQLITE_SUPPORT   -O3 -g3

g++.exe -D__DEBUG__ -c src/accounthandler.cpp -o src/obj/accounthandler.o -I"C:/Dev-Cpp/lib/gcc/mingw32/3.4.2/include"  -I"C:/Dev-Cpp/include/c++/3.4.2/backward"  -I"C:/Dev-Cpp/include/c++/3.4.2/mingw32"  -I"C:/Dev-Cpp/include/c++/3.4.2"  -I"C:/Dev-Cpp/include"  -I"C:/Dev-Cpp/mingw/include/SDL"  -I"C:/Dev-Cpp/mingw/include/DLL"  -DSQLITE_SUPPORT   -O3 -g3

In file included from src/accounthandler.cpp:33:
src/netcomputer.h:30:23: enet/enet.h: No such file or directory
In file included from src/accounthandler.cpp:33:
src/netcomputer.h:49: error: `ENetPeer' has not been declared
src/netcomputer.h:49: error: ISO C++ forbids declaration of `peer' with no type

src/netcomputer.h:79: error: ISO C++ forbids declaration of `ENetPeer' with no type
src/netcomputer.h:79: error: expected `;' before '*' token
src/netcomputer.h:84: error: expected `;' before "void"

src/netcomputer.h:116: error: ISO C++ forbids declaration of `ENetPeer' with no type
src/netcomputer.h:116: error: expected `;' before '*' token

make.exe: *** [src/obj/accounthandler.o] Error 1

Execução terminada

//Av3nger

Posted: 14 Dec 2006, 22:21
by Bjørn
You need to learn how to read these errors, they're really not so difficult, as I'll show you. In the first error, the key problem was this:
src/dal/sqlitedataprovider.h:27:21: sqlite3.h: No such file or directory
What you needed was sqlite3. Now in your next error, the key problem was this:
src/netcomputer.h:30:23: enet/enet.h: No such file or directory
Guess what? You need ENet, which you can get at http://enet.bespin.org/. However I can't help you with getting it to work on Windows (probably Elven can, if you can't figure it out).

In both cases, the cause of the problem was the first reported error. You'll find that this is usually the case.

Posted: 14 Dec 2006, 22:59
by Av3nger (Offline)
Ok,

I knew what was the problems but i did not know where i download them..
But Thanks for help =]

//Av3nger

Posted: 15 Dec 2006, 03:32
by Platyna
I don't want to put your on the ground brutally but if you can't read these errors, I dare to be in doubt, that you will have any use of TMW server - which is under development.

Regards.

Posted: 15 Dec 2006, 17:07
by Av3nger (Offline)
Sry but like i said i know what is the problem but i can't find the needed programs...

and where can i find enet in a .zip file?

Posted: 15 Dec 2006, 18:16
by Crush
Nowhere, you have to compile enet to a static library from source.

Posted: 16 Dec 2006, 14:26
by Av3nger (Offline)
Ok thanks a lot i gonna try...

//Av3nger

--Edited


New Problem...

Code: Select all

Compilador: Default compiler
Building Makefile: "D:\tmw\server\Makefile.win"
Executando  make...
make.exe -f "D:\tmw\server\Makefile.win" all
g++.exe -D__DEBUG__ src/obj/dataprovider.o src/obj/dataproviderfactory.o src/obj/recordset.o src/obj/sqlitedataprovider.o src/obj/logger.o src/obj/accounthandler.o src/obj/connectionhandler.o src/obj/dalstorage.o src/obj/debug.o src/obj/main.o src/obj/messagehandler.o src/obj/messagein.o src/obj/messageout.o src/obj/netcomputer.o src/obj/netsession.o src/obj/object.o src/obj/packet.o src/obj/script.o src/obj/skill.o src/obj/storage.o src/obj/account.o src/obj/being.o src/obj/configuration.o src/obj/SDL_win32_main.o src/obj/chathandler.o src/obj/map.o src/obj/resourcemanager.o src/obj/base64.o src/obj/state.o src/obj/items.o src/obj/gamehandler.o src/obj/mapmanager.o src/obj/mapreader.o src/obj/stringfilter.o src/obj/chatchannelmanager.o src/obj/chatchannel.o src/obj/tmwserv_private.res -o "tmwserv.exe" -L"C:/Dev-Cpp/lib" -L"C:/Dev-Cpp/mingw/include/enet-1.0/include/enet" -L"C:/Dev-Cpp/include/enet-1.0/include/enet" -lmingw32 -lSDL -lenet -lws2_32 -lsqlite3 -lxml2 -lphysfs -lz -mconsole -mwindows -lwinmm  -g3 -s 

C:\Dev-Cpp\Bin\..\lib\gcc\mingw32\3.4.2\..\..\..\..\mingw32\bin\ld.exe: cannot find -lenet
collect2: ld returned 1 exit status

make.exe: *** [tmwserv.exe] Error 1

Execução terminada

Posted: 16 Dec 2006, 15:31
by Matt
You need enet.

Posted: 16 Dec 2006, 16:20
by Av3nger (Offline)
i've download it.. and it didn't works..
which files are needed in this problem i mean *.h files

//Av3nger

New Problem
Compilador: Default compiler
Building Makefile: "D:\tmw\server\Makefile.win"
Executando make...
make.exe -f "D:\tmw\server\Makefile.win" all
g++.exe -D__DEBUG__ -c src/main.cpp -o src/obj/main.o -I"C:/Dev-Cpp/mingw/include/SDL" -I"C:/Dev-Cpp/mingw/include/DLL" -I"C:/Dev-Cpp/bin" -I"lib/gcc/mingw32/3.4.2/include" -I"include/c++/3.4.2/backward" -I"include/c++/3.4.2/mingw32" -I"include/c++/3.4.2" -I"include" -I"C:/Dev-Cpp/mingw/include/enet" -I"C:/Dev-Cpp/mingw/include/enet/include" -I"C:/Dev-Cpp/mingw/include" -I"C:/Dev-Cpp/mingw/include/enet/include" -I"C:/Dev-Cpp/mingw/include/enet/include/enet" -DSQLITE_SUPPORT -O3 -g3

In file included from C:/Dev-Cpp/Bin/../lib/gcc/mingw32/3.4.2/../../../../include/c++/3.4.2/cwchar:51,
from C:/Dev-Cpp/Bin/../lib/gcc/mingw32/3.4.2/../../../../include/c++/3.4.2/bits/postypes.h:46,
from C:/Dev-Cpp/Bin/../lib/gcc/mingw32/3.4.2/../../../../include/c++/3.4.2/iosfwd:50,
from C:/Dev-Cpp/Bin/../lib/gcc/mingw32/3.4.2/../../../../include/c++/3.4.2/ios:44,
from C:/Dev-Cpp/Bin/../lib/gcc/mingw32/3.4.2/../../../../include/c++/3.4.2/ostream:45,
from C:/Dev-Cpp/Bin/../lib/gcc/mingw32/3.4.2/../../../../include/c++/3.4.2/iostream:45,
from src/main.cpp:26:
C:/Dev-Cpp/Bin/../lib/gcc/mingw32/3.4.2/../../../../include/c++/3.4.2/ctime:66: error: `::clock_t' has not been declared
C:/Dev-Cpp/Bin/../lib/gcc/mingw32/3.4.2/../../../../include/c++/3.4.2/ctime:68: error: `::tm' has not been declared

C:/Dev-Cpp/Bin/../lib/gcc/mingw32/3.4.2/../../../../include/c++/3.4.2/ctime:70: error: `::clock' has not been declared
C:/Dev-Cpp/Bin/../lib/gcc/mingw32/3.4.2/../../../../include/c++/3.4.2/ctime:71: error: `::difftime' has not been declared
C:/Dev-Cpp/Bin/../lib/gcc/mingw32/3.4.2/../../../../include/c++/3.4.2/ctime:72: error: `::mktime' has not been declared
C:/Dev-Cpp/Bin/../lib/gcc/mingw32/3.4.2/../../../../include/c++/3.4.2/ctime:73: error: `::time' has not been declared
C:/Dev-Cpp/Bin/../lib/gcc/mingw32/3.4.2/../../../../include/c++/3.4.2/ctime:74: error: `::asctime' has not been declared
C:/Dev-Cpp/Bin/../lib/gcc/mingw32/3.4.2/../../../../include/c++/3.4.2/ctime:75: error: `::ctime' has not been declared
C:/Dev-Cpp/Bin/../lib/gcc/mingw32/3.4.2/../../../../include/c++/3.4.2/ctime:76: error: `::gmtime' has not been declared
C:/Dev-Cpp/Bin/../lib/gcc/mingw32/3.4.2/../../../../include/c++/3.4.2/ctime:77: error: `::localtime' has not been declared
C:/Dev-Cpp/Bin/../lib/gcc/mingw32/3.4.2/../../../../include/c++/3.4.2/ctime:78: error: `::strftime' has not been declared

make.exe: *** [src/obj/main.o] Error 1

Execução terminada

Posted: 18 Dec 2006, 10:58
by Bjørn
You seem now to have gotten to the point where you have totally messed up your compiler environment. At least, according to the error, main.cpp is failing to properly include the standard iostream header.

Your earlier issue with ENet was because you had only installed the headers, but not the compiled library.

Posted: 28 Dec 2006, 15:04
by Av3nger (Offline)
Bjørn wrote:Your earlier issue with ENet was because you had only installed the headers, but not the compiled library.
But where can i find the compiled library?

Posted: 28 Dec 2006, 16:16
by Rotonen
Av3nger wrote:But where can i find the compiled library?
How about compiling it yourself?

http://enet.bespin.org/Installation.html

There are good and simple instructions on how to do it that can be applied to just about any IDE (Dev-C++, Code::Blocks) besides the MSVC6 mentioned there.

Then again someone could already have done it so you could try to google for one.

Posted: 28 Dec 2006, 16:33
by Av3nger (Offline)
The problem is that the tutorial is in msvc 6 and i use dev-c++...
where i get ws2_32.lib??
still with the same problem... could someone do this for me??
Then again someone could already have done it so you could try to google for one.
Like he said "someone could" the problem is anybody have donw it i think...


//Av3nger