VGOEmulator.net

A Development Project for the Vanguard:Saga of Heroes MMO

Skip to content

Advanced search
  • Quick links
    • Unanswered topics
    • Active topics
    • Search
  • Portal
  • Project Manager
  • Bug Tracker
  • Server List
  • Wiki
  • Donate
  • Login
  • Register
  • Board index Support Linux
  • Search

Compile error: Rev 766

Help with the Linux x86/x64 versions of the VGOEmulator Server

Moderator: Community Managers

Post Reply
  • Print view
Advanced search
7 posts • Page 1 of 1
User avatar
Blackstorm
Retired
Posts: 354
Joined: Thu Sep 04, 2014 11:11 am
Location: Paris, FRANCE
Contact:
Contact Blackstorm
Website
Compile error: Rev 766
  • Quote

Post by Blackstorm » Tue Nov 04, 2014 5:28 pm

Actually i have an error on the rev766

Code: Select all

root@sd-56056:/vgoemu/src/world# make
g++ -c `mysql_config --cflags` -march=native -pipe -O -pthread -std=c++0x -Wall -g -DVG_WORLD -DVG_DEBUG -D_GNU_SOURCE WorldDatabase.cpp -o WorldDatabase.o
WorldDatabase.cpp:424:2: warning: multi-line comment [-Wcomment]
  // Load the character's titles\
  ^
WorldDatabase.cpp: In member function 'uint32_t WorldDatabase::LoadSpawnPlacements(uint32_t)':
WorldDatabase.cpp:1221:63: error: invalid initialization of non-const reference of type 'std::__detail::_Node_iterator<std::pair<const unsigned int, SpawnPlacement>, false, false>&' from an rvalue of type 'std::unordered_map<unsigned int, SpawnPlacement>::iterator {aka std::__detail::_Node_iterator<
std::pair<const unsigned int, SpawnPlacement>, false, false>}'
     for (auto &itr = master_spawn_list.spawn_placements.begin(); itr != master_spawn_list.spawn_placements.end();) {
                                                               ^
Makefile:136: recipe for target 'WorldDatabase.o' failed
make: *** [WorldDatabase.o] Error 1
working on ^^
Last edited by Blackstorm on Tue Nov 04, 2014 5:31 pm, edited 1 time in total.
Top

shargash
Team Member
Team Member
Posts: 338
Joined: Tue Apr 15, 2014 10:16 pm
Re: Compile error: Rev 766
  • Quote

Post by shargash » Tue Nov 04, 2014 5:31 pm

I did not recompile, but I get an error during WorldServer startup:

19:26:09.714 E LUA Error reading lua script file at samples/generic.lua!
19:26:09.714 E LUA Error reading lua script file at samples/TanFenGreatcloud.lua!

The lua files are there. I know squat about lua, so I have no idea how to go about figuring out what's missing.
Top

Lokked
Principle Developer
Principle Developer
Posts: 600
Joined: Wed Aug 06, 2014 3:15 pm
Re: Compile error: Rev 766
  • Quote

Post by Lokked » Tue Nov 04, 2014 5:37 pm

Blackstorm, make it a for (const auto &itr : ....).

I'll try and remember to put this in a commit tonight. I'm surprised this hasn't come up before, though, as I don't recall changing that.
Top

User avatar
Blackstorm
Retired
Posts: 354
Joined: Thu Sep 04, 2014 11:11 am
Location: Paris, FRANCE
Contact:
Contact Blackstorm
Website
Re: Compile error: Rev 766
  • Quote

Post by Blackstorm » Tue Nov 04, 2014 5:40 pm

ok for the first error :

In WorldDatabase.cpp : line 1221

Code: Select all

for (auto &itr = master_spawn_list.spawn_placements.begin(); itr != master_spawn_list.spawn_placements.end();) {
change it by :

Code: Select all

for (auto itr = master_spawn_list.spawn_placements.begin(); itr != master_spawn_list.spawn_placements.end();) {

after that you have another error for the MasterSpawnList.cpp line 267 : do the same thing, remove the "&" before "itr"

edit : arf, thanks Looked should be better to add the "const" declaration ^^
Last edited by Blackstorm on Tue Nov 04, 2014 5:53 pm, edited 1 time in total.
Top

shargash
Team Member
Team Member
Posts: 338
Joined: Tue Apr 15, 2014 10:16 pm
Re: Compile error: Rev 766
  • Quote

Post by shargash » Tue Nov 04, 2014 5:42 pm

[quote="shargash"]I did not recompile, but I get an error during WorldServer startup:[/quote]

Never mind. I figured it out. I have been copying world server to a run-time directory, and I didn't realize I had to copy the samples subdirectory as well as WorldServer.exe. It started fine after I did the copy.
Top

User avatar
Blackstorm
Retired
Posts: 354
Joined: Thu Sep 04, 2014 11:11 am
Location: Paris, FRANCE
Contact:
Contact Blackstorm
Website
Re: Compile error: Rev 766
  • Quote

Post by Blackstorm » Tue Nov 04, 2014 5:50 pm

In addition, the Linux binary require always the generic.lua in the same directory... (in 744 too)

Code: Select all

root@sd-56056:/vgoemu/src/world# service vgoemu_init restart
Error, The file generic.lua is not in the daemon directory, exit
Top

User avatar
John Adams
Retired
Posts: 4582
Joined: Wed Aug 28, 2013 9:40 am
Location: Phoenix, AZ.
Contact:
Contact John Adams
Website
Re: Compile error: Rev 766
  • Quote

Post by John Adams » Tue Nov 04, 2014 6:43 pm

[quote="Lokked"]Blackstorm, make it a for (const auto &itr : ....).

I'll try and remember to put this in a commit tonight. I'm surprised this hasn't come up before, though, as I don't recall changing that.[/quote]
We need to not use auto &itr, as the & breaks linux compile. I keep removing them after every commit. That was how I was told to fix it. There's probably some other reason the & doesn't work, so we need to figure out one or the other so we're on the same page.

Rev 766 compiles and runs perfectly for me on both Windows 7 x64 and Ubuntu Linux 14.04 x64. be sure you do a make clean each time.



[quote="shargash"]Never mind. I figured it out. I have been copying world server to a run-time directory, and I didn't realize I had to copy the samples subdirectory as well as WorldServer.exe. It started fine after I did the copy.[/quote]
Your LUA scripts can exist anywhere, you just have to point to them in the `lua_scripts` table. I have never tried fully-qualified paths, but have always used relative. Can't say D:\lua\stuff.lua will work if world is outside D:\lua, for example.
Top


Post Reply
  • Print view

7 posts • Page 1 of 1

Return to “Linux”

Jump to
  • Information
  • ↳   Announcements
  • ↳   Dev Chats
  • ↳   Events
  • Community
  • ↳   General Discussions
  • ↳   VGO Team Help Requests
  • ↳   Introductions
  • ↳   Game Features
  • ↳   Wish List
  • ↳   Off-Topic
  • Support
  • ↳   How-To's
  • ↳   General Support
  • ↳   Windows
  • ↳   Linux
  • Bugs
  • ↳   Server Bugs
  • ↳   Server Bugs (Closed)
  • ↳   Content Bugs
  • ↳   Content Bugs (Closed)
  • ↳   Database Bugs
  • ↳   Tools Bugs
  • Board index
  • All times are UTC-07:00
  • Delete cookies
  • Contact us
Powered by phpBB® Forum Software © phpBB Limited
*Original Author: Brad Veryard
*Updated to 3.2 by MannixMD