• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

Solved when compiling otserv.cpp error under linux .

lkzone

New Member
Joined
Dec 22, 2012
Messages
9
Reaction score
1
the error when i do the make command

make all-am
make[1]: Entrando no diretório `/home/lkzone/Downloads/0.3b3.r102'
g++ -DHAVE_CONFIG_H -I. -I/usr/include/libxml2 -I/usr/include/lua5.1 -D__USE_MYSQL__ -D_THREAD_SAFE -D_REENTRANT -Wall -g -O1 -MT otserv.o -MD -MP -MF .deps/otserv.Tpo -c -o otserv.o otserv.cpp
otserv.cpp: Na função ‘void signalHandler(int32_t)’:
otserv.cpp:143:8: erro: ‘SIGHUP’ was not declared in this scope
otserv.cpp:148:8: erro: ‘SIGTRAP’ was not declared in this scope
otserv.cpp:153:8: erro: ‘SIGUSR1’ was not declared in this scope
otserv.cpp:157:8: erro: ‘SIGUSR2’ was not declared in this scope
otserv.cpp:160:8: erro: ‘SIGWINCH’ was not declared in this scope
otserv.cpp:163:8: erro: ‘SIGQUIT’ was not declared in this scope
otserv.cpp:167:8: erro: ‘SIGTERM’ was not declared in this scope
otserv.cpp: Na função ‘int main(int, char**)’:
otserv.cpp:212:19: erro: aggregate ‘main(int, char**)::sigaction sigh’ has incomplete type and cannot be defined
otserv.cpp:213:20: erro: ‘SIG_IGN’ was not declared in this scope
otserv.cpp:215:27: erro: ‘sigemptyset’ was not declared in this scope
otserv.cpp:216:12: erro: ‘SIGPIPE’ was not declared in this scope
otserv.cpp:216:32: erro: uso inválido do tipo incompleto ‘struct main(int, char**)::sigaction’
otserv.cpp:212:9: erro: forward declaration of ‘struct main(int, char**)::sigaction’
otserv.cpp:219:9: erro: ‘SIGHUP’ was not declared in this scope
otserv.cpp:219:30: erro: ‘signal’ was not declared in this scope
otserv.cpp:220:9: erro: ‘SIGTRAP’ was not declared in this scope
otserv.cpp:221:9: erro: ‘SIGUSR1’ was not declared in this scope
otserv.cpp:222:9: erro: ‘SIGUSR2’ was not declared in this scope
otserv.cpp:223:9: erro: ‘SIGWINCH’ was not declared in this scope
otserv.cpp:224:9: erro: ‘SIGQUIT’ was not declared in this scope
otserv.cpp:225:9: erro: ‘SIGTERM’ was not declared in this scope
make[1]: ** [otserv.o] Erro 1
make[1]: Saindo do diretório `/home/lkzone/Downloads/0.3b3.r102'
make: ** [all] Erro 2

somebody can help me?

- - - Updated - - -

solved
I add #include <sys/signal.h> in otserv.cpp :~)
 
Back
Top