Tweaks for windows
This commit is contained in:
+1
-1
@@ -3,7 +3,7 @@ INCLUDES+=. client_utilities entities gameplay_scenes menu_scenes ../common/debu
|
||||
|
||||
#libraries
|
||||
#the order of the $(LIBS) is important, at least for MinGW
|
||||
LIBS+=client.a ../common/libcommon.a -lSDL_net
|
||||
LIBS+=client.a ../common/libcommon.a -lSDL2_net
|
||||
ifeq ($(OS),Windows_NT)
|
||||
LIBS+=-lwsock32 -liphlpapi -lmingw32
|
||||
endif
|
||||
|
||||
@@ -23,6 +23,7 @@
|
||||
|
||||
#include "channels.hpp"
|
||||
|
||||
#include <cstring>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
|
||||
@@ -307,7 +308,7 @@ void LobbyMenu::SendLoginRequest() {
|
||||
ClientPacket packet;
|
||||
packet.type = SerialPacketType::LOGIN_REQUEST;
|
||||
packet.clientIndex = clientIndex;
|
||||
strncpy(packet.username, config["client.username"].c_str(), PACKET_STRING_SIZE);
|
||||
strncpy(packet.username, config["client.username"].c_str(), PACKET_STRING_SIZE+1);
|
||||
|
||||
network.SendTo(Channels::SERVER, &packet);
|
||||
}
|
||||
|
||||
+3
-3
@@ -1,13 +1,13 @@
|
||||
#include directories
|
||||
INCLUDES+=SDL . accounts characters clients entities rooms server_utilities triggers ../common/debugging ../common/gameplay ../common/map ../common/network ../common/network/packet_types ../common/utilities
|
||||
INCLUDES+=. accounts characters clients entities rooms server_utilities triggers ../common/debugging ../common/gameplay ../common/map ../common/network ../common/network/packet_types ../common/utilities
|
||||
|
||||
#libraries
|
||||
#the order of the $(LIBS) is important, at least for MinGW
|
||||
LIBS+=server.a ../common/libcommon.a -lSDL_net
|
||||
LIBS+=server.a ../common/libcommon.a -lSDL2_net
|
||||
ifeq ($(OS),Windows_NT)
|
||||
LIBS+=-lwsock32 -liphlpapi -lmingw32
|
||||
endif
|
||||
LIBS+=-lSDLmain -lSDL -llua -lsqlite3
|
||||
LIBS+=-lSDL2main -lSDL2 -llua -lsqlite3
|
||||
ifeq ($(shell uname), Linux)
|
||||
#I don't know what this does, but Ubuntu needs it (dynamic linking for lua)
|
||||
LIBS+=-ldl
|
||||
|
||||
Reference in New Issue
Block a user