diff options
author | luigi1111 <luigi1111w@gmail.com> | 2023-10-25 21:38:32 -0400 |
---|---|---|
committer | luigi1111 <luigi1111w@gmail.com> | 2023-10-25 21:38:32 -0400 |
commit | e946315627c22ec5c83505c9c72b9db64b7e67c7 (patch) | |
tree | 37482e0ea097f37afbdb5ffc52ab3ea2680277c6 | |
parent | Merge pull request #8989 (diff) | |
parent | depends: remove libiconv: unused (diff) | |
download | monero-e946315627c22ec5c83505c9c72b9db64b7e67c7.tar.xz |
Merge pull request #9002
932bba3 depends: remove libiconv: unused (tobtoht)
-rw-r--r-- | CMakeLists.txt | 11 | ||||
-rw-r--r-- | contrib/depends/packages/boost.mk | 6 | ||||
-rw-r--r-- | contrib/depends/packages/libiconv.mk | 35 | ||||
-rw-r--r-- | contrib/depends/packages/packages.mk | 2 | ||||
-rw-r--r-- | contrib/depends/patches/libiconv/fix-whitespace.patch | 13 | ||||
-rw-r--r-- | src/wallet/api/wallet.cpp | 3 |
6 files changed, 14 insertions, 56 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 6c1fca051..7f96017c6 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1070,7 +1070,12 @@ if(STATIC) set(Boost_USE_STATIC_LIBS ON) set(Boost_USE_STATIC_RUNTIME ON) endif() -find_package(Boost 1.58 QUIET REQUIRED COMPONENTS system filesystem thread date_time chrono regex serialization program_options locale) + +set(BOOST_COMPONENTS system filesystem thread date_time chrono regex serialization program_options) +if (WIN32) + list(APPEND BOOST_COMPONENTS locale) +endif() +find_package(Boost 1.58 QUIET REQUIRED COMPONENTS ${BOOST_COMPONENTS}) add_definitions(-DBOOST_ASIO_ENABLE_SEQUENTIAL_STRAND_ALLOCATION) set(CMAKE_FIND_LIBRARY_SUFFIXES ${OLD_LIB_SUFFIXES}) @@ -1095,9 +1100,7 @@ include_directories(SYSTEM ${Boost_INCLUDE_DIRS}) if(MINGW) set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -Wa,-mbig-obj") set(EXTRA_LIBRARIES mswsock;ws2_32;iphlpapi;crypt32;bcrypt) - if(DEPENDS) - set(ICU_LIBRARIES iconv) - else() + if(NOT DEPENDS) set(ICU_LIBRARIES icuio icuin icuuc icudt icutu iconv) endif() elseif(APPLE OR OPENBSD OR ANDROID) diff --git a/contrib/depends/packages/boost.mk b/contrib/depends/packages/boost.mk index fd06c5393..d81bca973 100644 --- a/contrib/depends/packages/boost.mk +++ b/contrib/depends/packages/boost.mk @@ -3,7 +3,6 @@ $(package)_version=1_64_0 $(package)_download_path=https://downloads.sourceforge.net/project/boost/boost/1.64.0/ $(package)_file_name=$(package)_$($(package)_version).tar.bz2 $(package)_sha256_hash=7bcc5caace97baa948931d712ea5f37038dbb1c5d89b43ad4def4ed7cb683332 -$(package)_dependencies=libiconv $(package)_patches=fix_aroptions.patch fix_arm_arch.patch define $(package)_set_vars @@ -22,7 +21,8 @@ $(package)_toolset_$(host_os)=gcc $(package)_archiver_$(host_os)=$($(package)_ar) $(package)_toolset_darwin=darwin $(package)_archiver_darwin=$($(package)_libtool) -$(package)_config_libraries=chrono,filesystem,program_options,system,thread,test,date_time,regex,serialization,locale +$(package)_config_libraries_$(host_os)="chrono,filesystem,program_options,system,thread,test,date_time,regex,serialization" +$(package)_config_libraries_mingw32="chrono,filesystem,program_options,system,thread,test,date_time,regex,serialization,locale" $(package)_cxxflags=-std=c++11 $(package)_cxxflags_linux=-fPIC $(package)_cxxflags_freebsd=-fPIC @@ -35,7 +35,7 @@ define $(package)_preprocess_cmds endef define $(package)_config_cmds - ./bootstrap.sh --without-icu --with-libraries=$(boost_config_libraries) + ./bootstrap.sh --without-icu --with-libraries=$(boost_config_libraries_$(host_os)) endef define $(package)_build_cmds diff --git a/contrib/depends/packages/libiconv.mk b/contrib/depends/packages/libiconv.mk deleted file mode 100644 index eac8b4331..000000000 --- a/contrib/depends/packages/libiconv.mk +++ /dev/null @@ -1,35 +0,0 @@ -package=libiconv -$(package)_version=1.15 -$(package)_download_path=https://ftp.gnu.org/gnu/libiconv -$(package)_file_name=libiconv-$($(package)_version).tar.gz -$(package)_sha256_hash=ccf536620a45458d26ba83887a983b96827001e92a13847b45e4925cc8913178 -$(package)_patches=fix-whitespace.patch - -define $(package)_set_vars - $(package)_config_opts=--disable-nls - $(package)_config_opts=--enable-static - $(package)_config_opts=--disable-shared - $(package)_config_opts_linux=--with-pic - $(package)_config_opts_freebsd=--with-pic -endef - -define $(package)_preprocess_cmds - cp -f $(BASEDIR)/config.guess $(BASEDIR)/config.sub build-aux/ &&\ - patch -p1 < $($(package)_patch_dir)/fix-whitespace.patch -endef - -define $(package)_config_cmds - $($(package)_autoconf) AR_FLAGS=$($(package)_arflags) -endef - -define $(package)_build_cmds - $(MAKE) -endef - -define $(package)_stage_cmds - $(MAKE) DESTDIR=$($(package)_staging_dir) install -endef - -define $(package)_postprocess_cmds - rm lib/*.la -endef diff --git a/contrib/depends/packages/packages.mk b/contrib/depends/packages/packages.mk index 35dc2abc7..280b699d8 100644 --- a/contrib/depends/packages/packages.mk +++ b/contrib/depends/packages/packages.mk @@ -1,4 +1,4 @@ -packages:=boost openssl zeromq libiconv expat unbound +packages:=boost openssl zeromq expat unbound # ccache is useless in gitian builds ifneq ($(GITIAN),1) diff --git a/contrib/depends/patches/libiconv/fix-whitespace.patch b/contrib/depends/patches/libiconv/fix-whitespace.patch deleted file mode 100644 index 531364b45..000000000 --- a/contrib/depends/patches/libiconv/fix-whitespace.patch +++ /dev/null @@ -1,13 +0,0 @@ -diff --git a/preload/configure b/preload/configure -index aab5c77..e20b8f0 100755 ---- a/preload/configure -+++ b/preload/configure -@@ -588,7 +588,7 @@ MAKEFLAGS= - PACKAGE_NAME='libiconv' - PACKAGE_TARNAME='libiconv' - PACKAGE_VERSION='0' --PACKAGE_STRING='libiconv 0' -+PACKAGE_STRING='libiconv0' - PACKAGE_BUGREPORT='' - PACKAGE_URL='' - diff --git a/src/wallet/api/wallet.cpp b/src/wallet/api/wallet.cpp index 0c3aaf853..7f4dbbc79 100644 --- a/src/wallet/api/wallet.cpp +++ b/src/wallet/api/wallet.cpp @@ -45,7 +45,10 @@ #include <sstream> #include <unordered_map> +#ifdef WIN32 #include <boost/locale.hpp> +#endif + #include <boost/filesystem.hpp> using namespace std; |