scope error on compile

Post Reply
Davenge
Posts: 32
Joined: Tue Sep 17, 2013 5:29 pm

scope error on compile

Post by Davenge » Thu Mar 26, 2015 11:20 am

getting error on compile with SqlHandle, I tried including "map.h" but still no luck.

g++ -std=gnu++0x -DHAVE_CONFIG_H -I. -I./src/common -DdsUDPSERV -I/usr//include/luajit-2.0 -I/usr/include/mysql -DBIG_JOINS=1 -fno-strict-aliasing -g -g -O2 -MT dsgame-ability.o -MD -MP -MF .deps/dsgame-ability.Tpo -c -o dsgame-ability.o `test -f 'src/map/ability.cpp' || echo './'`src/map/ability.cpp
In file included from src/map/lua/../entities/../party.h:27:0,
from src/map/lua/../entities/battleentity.h:35,
from src/map/lua/luautils.h:29,
from src/map/ability.cpp:24:
src/map/lua/../entities/../map.h:160:8: error: 'thread_local' does not name a type
src/map/ability.cpp: In function 'void ability::LoadAbilitiesList()':
src/map/ability.cpp:295:28: error: 'SqlHandle' was not declared in this scope
make: *** [dsgame-ability.o] Error 1

Davenge
Posts: 32
Joined: Tue Sep 17, 2013 5:29 pm

Re: scope error on compile

Post by Davenge » Thu Mar 26, 2015 5:07 pm

Nevermind, got it. Ubuntu 12.04 didn't use higher than gcc 4.6 and needed at least 4.8 so had to manually install higher version.

jaysudo
Posts: 1
Joined: Mon Mar 30, 2015 9:11 pm

Re: scope error on compile

Post by jaysudo » Fri Apr 03, 2015 11:38 pm

I installed gcc 4.8 on ubuntu 12.04 and I still get this exact error. Anyone know why?

User avatar
kjLotus
Special Guest
Posts: 1813
Joined: Sun Jul 22, 2012 2:16 pm

Re: scope error on compile

Post by kjLotus » Sun Apr 05, 2015 10:32 pm

jaysudo wrote:I installed gcc 4.8 on ubuntu 12.04 and I still get this exact error. Anyone know why?
you probably didn't install it correctly then, thread_local is a language keyword

Post Reply