summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2015-02-27 00:11:11 +0300
committerAndrei Karas <akaras@inbox.ru>2015-02-27 00:20:29 +0300
commit6a5aad6c537322ac5b54cde85271a560579d17ca (patch)
treec91643642ccff2e4f45e10b982cc512bc420bb1a /src
parentbf966d287a973ad9134c31d8c37cb471832088d2 (diff)
downloadmv-6a5aad6c537322ac5b54cde85271a560579d17ca.tar.gz
mv-6a5aad6c537322ac5b54cde85271a560579d17ca.tar.bz2
mv-6a5aad6c537322ac5b54cde85271a560579d17ca.tar.xz
mv-6a5aad6c537322ac5b54cde85271a560579d17ca.zip
Build auctionhandler only if eathena enabled.
Diffstat (limited to 'src')
-rw-r--r--src/CMakeLists.txt6
-rw-r--r--src/Makefile.am6
-rw-r--r--src/net/auctionhandler.h3
-rw-r--r--src/net/net.cpp4
-rw-r--r--src/net/tmwa/auctionhandler.h3
-rw-r--r--src/net/tmwa/generalhandler.cpp2
-rw-r--r--src/net/tmwa/generalhandler.h2
7 files changed, 20 insertions, 6 deletions
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index 78313af29..215d79a33 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -521,7 +521,6 @@ SET(SRCS
gui/windows/worldselectdialog.cpp
gui/windows/worldselectdialog.h
net/adminhandler.h
- net/auctionhandler.h
net/bankhandler.h
net/character.h
net/charserverhandler.cpp
@@ -1322,8 +1321,6 @@ SET(SRCS_TMWA
gui/windows/shopselldialog.h
net/tmwa/adminhandler.cpp
net/tmwa/adminhandler.h
- net/tmwa/auctionhandler.cpp
- net/tmwa/auctionhandler.h
net/tmwa/bankhandler.cpp
net/tmwa/bankhandler.h
net/tmwa/cashshophandler.cpp
@@ -1418,6 +1415,9 @@ SET(SRCS_EATHENA
listeners/vendingmodelistener.h
listeners/vendingslotslistener.cpp
listeners/vendingslotslistener.h
+ net/auctionhandler.h
+ net/tmwa/auctionhandler.cpp
+ net/tmwa/auctionhandler.h
net/eathena/adminhandler.cpp
net/eathena/adminhandler.h
net/eathena/auctionhandler.cpp
diff --git a/src/Makefile.am b/src/Makefile.am
index 195f2ba27..3578a0d11 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -645,7 +645,6 @@ manaplus_SOURCES += gui/widgets/avatarlistbox.cpp \
gui/windows/worldselectdialog.cpp \
gui/windows/worldselectdialog.h \
net/adminhandler.h \
- net/auctionhandler.h \
net/bankhandler.h \
net/cashshophandler.h \
net/beinghandler.h \
@@ -1257,8 +1256,6 @@ manaplus_SOURCES += \
gui/windows/shopselldialog.h \
net/tmwa/adminhandler.cpp \
net/tmwa/adminhandler.h \
- net/tmwa/auctionhandler.cpp \
- net/tmwa/auctionhandler.h \
net/tmwa/bankhandler.cpp \
net/tmwa/bankhandler.h \
net/tmwa/cashshophandler.cpp \
@@ -1354,6 +1351,9 @@ manaplus_SOURCES += gui/windows/bankwindow.cpp \
listeners/vendingmodelistener.h \
listeners/vendingslotslistener.cpp \
listeners/vendingslotslistener.h \
+ net/auctionhandler.h \
+ net/tmwa/auctionhandler.cpp \
+ net/tmwa/auctionhandler.h \
net/eathena/adminhandler.cpp \
net/eathena/adminhandler.h \
net/eathena/auctionhandler.cpp \
diff --git a/src/net/auctionhandler.h b/src/net/auctionhandler.h
index c1a3dc8a8..02d85da22 100644
--- a/src/net/auctionhandler.h
+++ b/src/net/auctionhandler.h
@@ -21,6 +21,8 @@
#ifndef NET_AUCTIONHANDLER_H
#define NET_AUCTIONHANDLER_H
+#ifdef EATHENA_SUPPORT
+
#include "enums/net/auctionsearchtype.h"
#include <string>
@@ -68,4 +70,5 @@ class AuctionHandler notfinal
extern Net::AuctionHandler *auctionHandler;
+#endif // EATHENA_SUPPORT
#endif // NET_AUCTIONHANDLER_H
diff --git a/src/net/net.cpp b/src/net/net.cpp
index 3dc095cef..527f3a34d 100644
--- a/src/net/net.cpp
+++ b/src/net/net.cpp
@@ -41,7 +41,9 @@
namespace Net
{
class AdminHandler;
+#ifdef EATHENA_SUPPORT
class AuctionHandler;
+#endif
class BankHandler;
class BeingHandler;
class BuyingStoreHandler;
@@ -91,7 +93,9 @@ Net::BuySellHandler *buySellHandler = nullptr;
Net::ServerFeatures *serverFeatures = nullptr;
Net::MailHandler *mailHandler = nullptr;
Net::MercenaryHandler *mercenaryHandler = nullptr;
+#ifdef EATHENA_SUPPORT
Net::AuctionHandler *auctionHandler = nullptr;
+#endif
Net::CashShopHandler *cashShopHandler = nullptr;
Net::FamilyHandler *familyHandler = nullptr;
Net::BankHandler *bankHandler = nullptr;
diff --git a/src/net/tmwa/auctionhandler.h b/src/net/tmwa/auctionhandler.h
index 5f793a78d..01e1428d7 100644
--- a/src/net/tmwa/auctionhandler.h
+++ b/src/net/tmwa/auctionhandler.h
@@ -21,6 +21,8 @@
#ifndef NET_TMWA_AUCTIONHANDLER_H
#define NET_TMWA_AUCTIONHANDLER_H
+#ifdef EATHENA_SUPPORT
+
#include "net/auctionhandler.h"
#include "net/tmwa/messagehandler.h"
@@ -65,4 +67,5 @@ class AuctionHandler final : public MessageHandler, public Net::AuctionHandler
} // namespace TmwAthena
+#endif // EATHENA_SUPPORT
#endif // NET_TMWA_AUCTIONHANDLER_H
diff --git a/src/net/tmwa/generalhandler.cpp b/src/net/tmwa/generalhandler.cpp
index 359cc5492..9a0ccd921 100644
--- a/src/net/tmwa/generalhandler.cpp
+++ b/src/net/tmwa/generalhandler.cpp
@@ -106,7 +106,9 @@ GeneralHandler::GeneralHandler() :
mQuestHandler(new QuestHandler),
mServerFeatures(new ServerFeatures),
mMailHandler(new MailHandler),
+#ifdef EATHENA_SUPPORT
mAuctionHandler(new AuctionHandler),
+#endif
mCashShopHandler(new CashShopHandler),
mFamilyHandler(new FamilyHandler),
mBankHandler(new BankHandler),
diff --git a/src/net/tmwa/generalhandler.h b/src/net/tmwa/generalhandler.h
index 01eda4145..1acc42a9e 100644
--- a/src/net/tmwa/generalhandler.h
+++ b/src/net/tmwa/generalhandler.h
@@ -82,7 +82,9 @@ class GeneralHandler final : public MessageHandler,
MessageHandlerPtr mQuestHandler;
ServerFeatures *mServerFeatures;
MessageHandlerPtr mMailHandler;
+#ifdef EATHENA_SUPPORT
MessageHandlerPtr mAuctionHandler;
+#endif
MessageHandlerPtr mCashShopHandler;
MessageHandlerPtr mFamilyHandler;
MessageHandlerPtr mBankHandler;