aboutsummaryrefslogtreecommitdiff
path: root/contrib
diff options
context:
space:
mode:
authorRiccardo Spagni <ric@spagni.net>2018-09-25 12:06:20 +0200
committerRiccardo Spagni <ric@spagni.net>2018-09-25 12:06:20 +0200
commitd2f9a4c584cfd072487dbd2503954049f6e0959c (patch)
treefbf375eb60b664d32360e716d72151cfc90f1f0f /contrib
parentMerge pull request #4419 (diff)
parentFix Darwin Sodium build (diff)
downloadmonero-d2f9a4c584cfd072487dbd2503954049f6e0959c.tar.xz
Merge pull request #4420
0f4f873b Fix Darwin Sodium build (TheCharlatan) bf1e1d97 A Travis to monero (TheCharlatan)
Diffstat (limited to 'contrib')
-rw-r--r--contrib/depends/hosts/darwin.mk6
-rw-r--r--contrib/depends/packages/packages.mk6
-rw-r--r--contrib/depends/packages/sodium-darwin.mk24
-rw-r--r--contrib/depends/packages/sodium.mk8
-rw-r--r--contrib/depends/toolchain.cmake.in6
5 files changed, 38 insertions, 12 deletions
diff --git a/contrib/depends/hosts/darwin.mk b/contrib/depends/hosts/darwin.mk
index 4e58bec74..6f8f2ffe2 100644
--- a/contrib/depends/hosts/darwin.mk
+++ b/contrib/depends/hosts/darwin.mk
@@ -2,13 +2,13 @@ OSX_MIN_VERSION=10.8
OSX_SDK_VERSION=10.11
OSX_SDK=$(SDK_PATH)/MacOSX$(OSX_SDK_VERSION).sdk
LD64_VERSION=253.9
-darwin_CC=clang -target $(host) -mmacosx-version-min=$(OSX_MIN_VERSION) --sysroot $(OSX_SDK) -mlinker-version=$(LD64_VERSION)
-darwin_CXX=clang++ -target $(host) -mmacosx-version-min=$(OSX_MIN_VERSION) --sysroot $(OSX_SDK) -mlinker-version=$(LD64_VERSION) -stdlib=libc++
+darwin_CC=clang -target $(host) -mmacosx-version-min=$(OSX_MIN_VERSION) --sysroot $(OSX_SDK) -mlinker-version=$(LD64_VERSION) -B $(host_prefix)/native/bin
+darwin_CXX=clang++ -target $(host) -mmacosx-version-min=$(OSX_MIN_VERSION) --sysroot $(OSX_SDK) -mlinker-version=$(LD64_VERSION) -stdlib=libc++ -B $(host_prefix)/native/bin
darwin_CFLAGS=-pipe
darwin_CXXFLAGS=$(darwin_CFLAGS)
-darwin_release_CFLAGS=-O2
+darwin_release_CFLAGS=-O1
darwin_release_CXXFLAGS=$(darwin_release_CFLAGS)
darwin_debug_CFLAGS=-O1
diff --git a/contrib/depends/packages/packages.mk b/contrib/depends/packages/packages.mk
index 28eaf34c5..114f8e9c0 100644
--- a/contrib/depends/packages/packages.mk
+++ b/contrib/depends/packages/packages.mk
@@ -1,16 +1,19 @@
-packages:=boost openssl libevent zeromq cppzmq zlib expat ldns cppzmq readline libiconv qt sodium
+packages:=boost openssl libevent zeromq cppzmq zlib expat ldns cppzmq readline libiconv qt
native_packages := native_ccache
wallet_packages=bdb
darwin_native_packages = native_biplist native_ds_store native_mac_alias
+darwin_packages += sodium-darwin
ifeq ($(host_os),linux)
packages += pcsc-lite
packages += unwind
+packages += sodium
endif
ifeq ($(host_os),mingw32)
packages += icu4c
+packages += sodium
endif
ifneq ($(build_os),darwin)
@@ -18,4 +21,3 @@ darwin_native_packages += native_cctools native_cdrkit native_libdmg-hfsplus
packages += readline
endif
-
diff --git a/contrib/depends/packages/sodium-darwin.mk b/contrib/depends/packages/sodium-darwin.mk
new file mode 100644
index 000000000..796bead16
--- /dev/null
+++ b/contrib/depends/packages/sodium-darwin.mk
@@ -0,0 +1,24 @@
+package=sodium-darwin
+$(package)_version=1.0.15
+$(package)_download_path=https://download.libsodium.org/libsodium/releases/
+$(package)_file_name=libsodium-$($(package)_version).tar.gz
+$(package)_sha256_hash=fb6a9e879a2f674592e4328c5d9f79f082405ee4bb05cb6e679b90afe9e178f4
+
+define $(package)_set_vars
+$(package)_config_opts=--enable-static
+$(package)_config_opts+=--prefix=$(host_prefix)
+endef
+
+define $(package)_config_cmds
+ ./autogen.sh &&\
+ $($(package)_autoconf) $($(package)_config_opts) RANLIB="$(host_prefix)/native/bin/x86_64-apple-darwin11-ranlib" AR="$(host_prefix)/native/bin/x86_64-apple-darwin11-ar"
+endef
+
+define $(package)_build_cmds
+ echo "path is problematic here" &&\
+ make
+endef
+
+define $(package)_stage_cmds
+ $(MAKE) DESTDIR=$($(package)_staging_dir) install
+endef
diff --git a/contrib/depends/packages/sodium.mk b/contrib/depends/packages/sodium.mk
index 885b1ea19..0e6668062 100644
--- a/contrib/depends/packages/sodium.mk
+++ b/contrib/depends/packages/sodium.mk
@@ -1,8 +1,8 @@
package=sodium
-$(package)_version=1.0.16
-$(package)_download_path=https://github.com/jedisct1/libsodium/archive
-$(package)_file_name=$($(package)_version).tar.gz
-$(package)_sha256_hash=0c14604bbeab2e82a803215d65c3b6e74bb28291aaee6236d65c699ccfe1a98c
+$(package)_version=1.0.15
+$(package)_download_path=https://download.libsodium.org/libsodium/releases/
+$(package)_file_name=libsodium-$($(package)_version).tar.gz
+$(package)_sha256_hash=fb6a9e879a2f674592e4328c5d9f79f082405ee4bb05cb6e679b90afe9e178f4
define $(package)_set_vars
$(package)_config_opts=--enable-static
diff --git a/contrib/depends/toolchain.cmake.in b/contrib/depends/toolchain.cmake.in
index b594ddd62..375533557 100644
--- a/contrib/depends/toolchain.cmake.in
+++ b/contrib/depends/toolchain.cmake.in
@@ -26,9 +26,9 @@ SET(BOOST_IGNORE_SYSTEM_PATH ON)
SET(BOOST_ROOT @prefix@)
SET(BOOST_LIBRARYDIR @prefix@/lib)
SET(BOOST_IGNORE_SYSTEM_PATHS_DEFAULT OFF)
-SET(Boost_NO_SYSTEM_PATHS TRUE)
-SET(Boost_USE_STATIC_LIBS TRUE)
-SET(Boost_USE_STATIC_RUNTIME TRUE)
+SET(BOOST_NO_SYSTEM_PATHS TRUE)
+SET(BOOST_USE_STATIC_LIBS TRUE)
+SET(BOOST_USE_STATIC_RUNTIME TRUE)
SET(OpenSSL_DIR @prefix@/lib)
SET(ARCHITECTURE @arch@)