Skip to content
Snippets Groups Projects
Commit 4d0ab27d authored by Adrien Béraud's avatar Adrien Béraud Committed by Adrien Béraud
Browse files

contrib/opendht: use cmake

Change-Id: Icba165348a97b18e11b461d2b515e3e41929e567
parent 32415a83
No related branches found
No related tags found
No related merge requests found
9c81a4077ac72297dde2f8183a05d1925b744b16dc68a7d7ce7204619754e3a30e54d1aaa5d45f38be70106a2380298c7e7a5cbe9ff3b607e9b5ee27a56fd9c0 opendht-2.5.4.tar.gz
9652843cdf5fa11bf3f436f920425efedc896a89bc6fe78c247f1b66201b44aac90350b67dfa25e06ec12dcc801f0a46c3a0503cc0e357d28416f7fd6dcab1b5 opendht-2.5.5.tar.gz
# OPENDHT
OPENDHT_VERSION := 2.5.4
OPENDHT_VERSION := 2.5.5
OPENDHT_URL := https://github.com/savoirfairelinux/opendht/archive/v$(OPENDHT_VERSION).tar.gz
PKGS += opendht
......@@ -8,27 +8,15 @@ PKGS_FOUND += opendht
endif
# Avoid building distro-provided dependencies in case opendht was built manually
ifneq ($(call need_pkg,"msgpack >= 1.2"),)
DEPS_opendht += msgpack
endif
ifneq ($(call need_pkg,"libargon2"),)
DEPS_opendht += argon2
endif
ifneq ($(and $(call need_pkg,"openssl >= 1.1.0"),$(call need_pkg,"libressl >= 1.12.2")),)
DEPS_opendht += libressl
endif
ifneq ($(call need_pkg,"restinio >= v.0.6.16"),)
DEPS_opendht += restinio
endif
ifneq ($(call need_pkg,"jsoncpp >= 1.7.2"),)
DEPS_opendht += jsoncpp
endif
ifneq ($(call need_pkg,"gnutls >= 3.3.0"),)
DEPS_opendht += gnutls
endif
DEPS_opendht += msgpack argon2 libressl restinio jsoncpp gnutls
# fmt 5.3.0 fix: https://github.com/fmtlib/fmt/issues/1267
OPENDHT_CONF = FMT_USE_USER_DEFINED_LITERALS=0
OPENDHT_CONF = -DBUILD_SHARED_LIBS=Off \
-DBUILD_TESTING=Off \
-DOPENDHT_DOCUMENTATION=Off \
-DOPENDHT_PROXY_CLIENT=On \
-DOPENDHT_PROXY_SERVER=On \
-DOPENDHT_PUSH_NOTIFICATIONS=On \
-DOPENDHT_TOOLS=Off
$(TARBALLS)/opendht-$(OPENDHT_VERSION).tar.gz:
$(call download,$(OPENDHT_URL))
......@@ -37,11 +25,10 @@ $(TARBALLS)/opendht-$(OPENDHT_VERSION).tar.gz:
opendht: opendht-$(OPENDHT_VERSION).tar.gz
$(UNPACK)
$(UPDATE_AUTOCONFIG) && cd $(UNPACK_DIR)
$(MOVE)
.opendht: opendht .sum-opendht
mkdir -p $</m4 && $(RECONF)
cd $< && $(HOSTVARS) $(OPENDHT_CONF) ./configure --enable-static --disable-shared --disable-c --disable-tools --disable-indexation --disable-python --disable-doc --enable-proxy-server --enable-proxy-client --enable-push-notifications $(HOSTCONF)
cd $< && $(MAKE) install
cd $< && mkdir -p build
cd $< && cd build && $(HOSTVARS) $(CMAKE) $(OPENDHT_CONF) ..
cd $< && cd build && $(MAKE) install
touch $@
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment