Mercurial > mxe-octave
changeset 5639:ae36e8c35157
Add linsodium
* src/libsodium.mk: new file
* dist-files.mk, index.html: add ref to libsodium
author | John Donoghue <john.donoghue@ieee.org> |
---|---|
date | Sun, 17 Jan 2021 08:00:21 -0500 |
parents | 3c303f9b5a36 |
children | e09d430e2f76 |
files | dist-files.mk index.html src/libsodium.mk |
diffstat | 3 files changed, 39 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/dist-files.mk Sun Jan 17 08:00:16 2021 -0500 +++ b/dist-files.mk Sun Jan 17 08:00:21 2021 -0500 @@ -309,6 +309,7 @@ libsndfile.mk \ libssh2-test.c \ libssh2.mk \ + libsodium.mk \ libtasn1.mk \ libtool.mk \ libunistring.mk \
--- a/index.html Sun Jan 17 08:00:16 2021 -0500 +++ b/index.html Sun Jan 17 08:00:21 2021 -0500 @@ -1714,6 +1714,10 @@ <td class="website"><a href="http://www.libssh2.org">libssh2</a></td> </tr> <tr> + <td class="package">libsodium</td> + <td class="website"><a href="https://doc.libsodium.org/">libsodium</a></td> + </tr> + <tr> <td class="package">libtasn1</td> <td class="website"><a href="https://www.gnu.org/software/libtasn1/">libtasn1</a></td> </tr>
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/src/libsodium.mk Sun Jan 17 08:00:21 2021 -0500 @@ -0,0 +1,34 @@ +# This file is part of MXE. +# See index.html for further information. + +PKG := libsodium +$(PKG)_IGNORE := +$(PKG)_VERSION := 1.0.18 +$(PKG)_CHECKSUM := cd8a76b79aeb077e8d3eea478ea6241972593dfd +$(PKG)_SUBDIR := $(PKG)-$($(PKG)_VERSION) +$(PKG)_FILE := $($(PKG)_SUBDIR).tar.gz +$(PKG)_URL := https://github.com/jedisct1/$(PKG)/archive/$($(PKG)_VERSION).tar.gz +$(PKG)_DEPS := + +define $(PKG)_UPDATE + $(WGET) -q -O- 'https://github.com/jedisct1/libsodium/tags' | \ + $(SED) -n 's|.*releases/tag/\([^"]*\).*|\1|p' | $(SORT) -V | \ + tail -1 +endef + +$(PKG)_EXTRA_CONFIGURE_OPTIONS := +ifneq ($(filter mingw msvc,$(MXE_SYSTEM)),) + $(PKG)_EXTRA_CONFIGURE_OPTIONS += CFLAGS="-O2 -g -fstack-protector" +endif + +define $(PKG)_BUILD + cd '$(1)' && ./autogen.sh \ + cd '$(1)' && ./configure \ + $(HOST_AND_BUILD_CONFIGURE_OPTIONS) \ + --prefix='$(HOST_PREFIX)' \ + $($(PKG)_EXTRA_CONFIGURE_OPTIONS) \ + $(ENABLE_SHARED_OR_STATIC) + + $(MAKE) -C '$(1)' -j '$(JOBS)' + $(MAKE) -C '$(1)' -j 1 install DESTDIR='$(3)' $(MXE_DISABLE_PROGS) $(MXE_DISABLE_DOCS) +endef