Add configure and make script
This commit is contained in:
1 parent
55007cb911
commit
1a4c07b961
3 files changed
+32
-2
No files matched your search
+2
-2
@@ -13,5 +13,5 @@ build/
|
||||
/package.json
|
||||
/multiplatform-crypto/src/jsMain/npm/node_modules
|
||||
/multiplatform-crypto/src/jsMain/npm/package-lock.json
|
||||
./sodiumWrapper/include
|
||||
./sodiumWrapper/lib
|
||||
/sodiumWrapper/include/
|
||||
/sodiumWrapper/lib/
|
||||
+27
@@ -0,0 +1,27 @@
|
||||
#!/bin/bash
|
||||
## and then borrowed and slightly modified from https://github.com/datkt/sodium/configure
|
||||
## borrowed from https://github.com/sodium-friends/sodium-native/blob/master/configure
|
||||
PREFIX="${PREFIX:-$PWD}"
|
||||
KONAN="${KONAN:-$HOME/.konan}"
|
||||
ARCH=${ARCH:-$(uname -m)}
|
||||
|
||||
cd libsodium
|
||||
|
||||
./autogen.sh -s -f
|
||||
|
||||
if [ -z "$SYSROOT" ]; then
|
||||
case $(uname -a) in
|
||||
**Linux*x86_64**)
|
||||
GCC=${GCC:-gcc}
|
||||
GCC=gcc
|
||||
;;
|
||||
|
||||
**Darwin*x86_64**)
|
||||
GCC=${GCC:-clang}
|
||||
;;
|
||||
esac
|
||||
|
||||
export CC=$(find $KONAN/dependencies -wholename *${ARCH/_/-}/bin/*$GCC | head -n1)
|
||||
fi
|
||||
|
||||
./configure --prefix=$PREFIX "$@"
|
||||
Executable
+3
@@ -0,0 +1,3 @@
|
||||
./configure
|
||||
make -j32 -C libsodium
|
||||
make -j32 -C libsodium install
|
||||
Reference in new issue
Block a user