feat(Deps/ACE): remove ACE library (part 1/2) (#6980)

This commit is contained in:
Kargatum 2021-07-16 20:05:39 +07:00 committed by GitHub
parent c17ce009dd
commit 96c51317f5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
10 changed files with 16 additions and 110 deletions

View File

@ -100,10 +100,6 @@ CU_RUN_HOOK("AFTER_LOAD_CMAKE_MODULES")
set(ACE_EXPECTED_VERSION 6.0.3)
find_package(PCHSupport)
find_package(ACE REQUIRED)
if(CMAKE_SYSTEM_NAME MATCHES "Darwin")
add_definitions(-DACE_LACKS_AUTO_PTR=1)
endif()
find_package(MySQL REQUIRED)
if(UNIX AND WITH_PERFTOOLS)

View File

@ -27,7 +27,7 @@ ENV DEBIAN_FRONTEND=noninteractive
# Do not use acore dashboard to install
# since it's not cacheable by docker
RUN apt-get update && apt-get install -y gdb gdbserver git dos2unix lsb-core sudo curl unzip \
make cmake clang libmysqlclient-dev libace-dev \
make cmake clang libmysqlclient-dev \
libboost-system1.7*-dev libboost-filesystem1.7*-dev libboost-program-options1.7*-dev libboost-iostreams1.7*-dev \
build-essential libtool cmake-data openssl libgoogle-perftools-dev google-perftools \
libssl-dev libmysql++-dev libreadline6-dev zlib1g-dev libbz2-dev mysql-client \
@ -109,7 +109,7 @@ RUN addgroup --gid $GROUP_ID acore && \
# install the required dependencies to run the server
RUN apt-get update && apt-get install -y dos2unix gdb gdbserver google-perftools libgoogle-perftools-dev net-tools \
libboost-system1.7*-dev libboost-filesystem1.7*-dev libboost-program-options1.7*-dev libboost-iostreams1.7*-dev \
tzdata libmysqlclient-dev libace-dev mysql-client curl unzip && rm -rf /var/lib/apt/lists/* ;
tzdata libmysqlclient-dev mysql-client curl unzip && rm -rf /var/lib/apt/lists/* ;
# change timezone in container
RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone && dpkg-reconfigure --frontend noninteractive tzdata
@ -281,7 +281,7 @@ ENV TZ=Etc/UTC
# set noninteractive mode so tzdata doesn't ask to set timezone on install
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install -y libmysqlclient-dev libace-dev libssl-dev libbz2-dev \
RUN apt-get update && apt-get install -y libmysqlclient-dev libssl-dev libbz2-dev \
libboost-system1.7*-dev libboost-filesystem1.7*-dev libboost-program-options1.7*-dev libboost-iostreams1.7*-dev \
sudo && rm -rf /var/lib/apt/lists/* ;

View File

@ -6,7 +6,7 @@ DEBIAN_VERSION=$(lsb_release -sr)
sudo apt-get update -y
sudo apt-get install -y gdbserver gdb unzip curl libace-6.* libace-dev \
sudo apt-get install -y gdbserver gdb unzip curl \
libncurses-dev libreadline-dev clang g++ \
gcc git cmake make ccache

View File

@ -13,4 +13,4 @@ if ! command -v cmake &>/dev/null ; then
fi
##########################################
brew install openssl readline ace boost bash-completion curl unzip mysql ccache
brew install openssl readline boost bash-completion curl unzip mysql ccache

View File

@ -7,7 +7,7 @@ UBUNTU_VERSION=$(lsb_release -sr);
sudo apt update
# shared deps
sudo apt-get -y install ccache clang cmake curl google-perftools libace-dev libmysqlclient-dev make unzip
sudo apt-get -y install ccache clang cmake curl google-perftools libmysqlclient-dev make unzip
if [[ $CONTINUOUS_INTEGRATION || $DOCKER ]]; then
sudo add-apt-repository -y ppa:mhier/libboost-latest && sudo apt update && sudo apt-get -y install build-essential cmake-data \
@ -17,13 +17,13 @@ else
case $UBUNTU_VERSION in
"20.04")
sudo apt-get install -y g++ gdb gdbserver gcc git \
libace-6.* libboost-all-dev libbz2-dev libncurses-dev libreadline-dev \
libssl-dev mysql-server
libboost-all-dev libbz2-dev libncurses-dev libreadline-dev \
libssl-dev mysql-server
;;
*)
sudo add-apt-repository -y ppa:mhier/libboost-latest && sudo apt update && sudo apt-get install -y g++ gdb gdbserver gcc git \
libace-6.* libboost-all-dev libbz2-dev libncurses-dev libreadline-dev \
libssl-dev mysql-server
libboost-all-dev libbz2-dev libncurses-dev libreadline-dev \
libssl-dev mysql-server
;;
esac
fi

1
deps/CMakeLists.txt vendored
View File

@ -19,7 +19,6 @@ endif()
add_subdirectory(threads)
if(SERVERS OR TOOLS)
add_subdirectory(acelite)
add_subdirectory(boost)
add_subdirectory(zlib)
add_subdirectory(g3dlite)

View File

@ -1,9 +1,5 @@
AzerothCore uses (parts of or in whole) the following opensource software:
ACE (ADAPTIVE Communication Environment)
http://www.cs.wustl.edu/~schmidt/ACE.html
Version: 6.1.4
argon2
https://github.com/P-H-C/phc-winner-argon2
Version: 62358ba

View File

@ -1,84 +0,0 @@
#
# Find the ACE client includes and library
#
# This module defines
# ACE_INCLUDE_DIR, where to find ace.h
# ACE_LIBRARIES, the libraries to link against
# ACE_FOUND, if false, you cannot build anything that requires ACE
# also defined, but not for general use are
# ACE_LIBRARY, where to find the ACE library.
set( ACE_FOUND 0 )
if ( UNIX )
if (NOT ACE_INCLUDE_DIR)
FIND_PATH( ACE_INCLUDE_DIR
NAMES
ace/ACE.h
PATHS
/usr/include
/usr/include/ace
/usr/local/include
/usr/local/include/ace
$ENV{ACE_ROOT}
$ENV{ACE_ROOT}/ace
$ENV{ACE_ROOT}/include
${CMAKE_SOURCE_DIR}/externals/ace
DOC
"Specify include-directories that might contain ace.h here."
)
endif()
if (NOT ACE_LIBRARY)
FIND_LIBRARY( ACE_LIBRARY
NAMES
ace ACE
PATHS
/usr/lib
/usr/lib/ace
/usr/local/lib
/usr/local/lib/ace
/usr/local/ace/lib
$ENV{ACE_ROOT}/lib
$ENV{ACE_ROOT}
DOC "Specify library-locations that might contain the ACE library here."
)
# FIND_LIBRARY( ACE_EXTRA_LIBRARIES
# NAMES
# z zlib
# PATHS
# /usr/lib
# /usr/local/lib
# DOC
# "if more libraries are necessary to link into ACE, specify them here."
# )
endif()
if ( ACE_LIBRARY )
if ( ACE_INCLUDE_DIR )
if (_ACE_VERSION)
set(ACE_VERSION "${_ACE_VERSION}")
else (_ACE_VERSION)
file(STRINGS "${ACE_INCLUDE_DIR}/ace/Version.h" ACE_VERSION_STR REGEX "^#define ACE_VERSION \".*\"")
string(REGEX REPLACE "^.*ACE_VERSION \"([0-9].[0-9].[0-9a-z]).*$"
"\\1" ACE_VERSION "${ACE_VERSION_STR}")
endif (_ACE_VERSION)
include(EnsureVersion)
ENSURE_VERSION( "${ACE_EXPECTED_VERSION}" "${ACE_VERSION}" ACE_FOUND)
if (NOT ACE_FOUND)
message(FATAL_ERROR "AzerothCore needs ACE version ${ACE_EXPECTED_VERSION} but found version ${ACE_VERSION}")
endif()
message( STATUS "Found ACE library: ${ACE_LIBRARY}")
message( STATUS "Found ACE headers: ${ACE_INCLUDE_DIR}")
else ( ACE_INCLUDE_DIR )
message(FATAL_ERROR "Could not find ACE headers! Please install ACE libraries and headers")
endif ( ACE_INCLUDE_DIR )
endif ( ACE_LIBRARY )
mark_as_advanced( ACE_FOUND ACE_LIBRARY ACE_EXTRA_LIBRARIES ACE_INCLUDE_DIR )
endif (UNIX)

View File

@ -1,10 +1,6 @@
# Platform-specfic options
option(USE_MYSQL_SOURCES "Use included MySQL-sources to build libraries" 0)
# Package overloads
set(ACE_INCLUDE_DIR ${CMAKE_SOURCE_DIR}/deps/acelite)
set(ACE_LIBRARY "ace")
if( USE_MYSQL_SOURCES )
set(MYSQL_INCLUDE_DIR ${CMAKE_SOURCE_DIR}/deps/mysqllite/include)
set(MYSQL_LIBRARY "libmysql")

View File

@ -1,8 +1,11 @@
#include "WorldSocket.h" // must be first to make ACE happy with ACE includes in it
/*
* Copyright (C) 2016+ AzerothCore <www.azerothcore.org>, released under GNU AGPL v3 license: https://github.com/azerothcore/azerothcore-wotlk/blob/master/LICENSE-AGPL3
*/
#include "Common.h"
#include "Configuration/Config.h"
#include "Database/DatabaseEnv.h"
#include "Config.h"
#include "DatabaseEnv.h"
#include "Log.h"
#include "Util.h"
#include "World.h"
#include "WorldSocket.h"