mirror of
https://github.com/ading2210/libcurl.js.git
synced 2025-05-12 22:10:01 -04:00
initial commit
This commit is contained in:
commit
27aa9ff74c
8 changed files with 134 additions and 0 deletions
26
curl.sh
Executable file
26
curl.sh
Executable file
|
@ -0,0 +1,26 @@
|
|||
#!/bin/bash
|
||||
|
||||
#compile openssl for use with emscripten
|
||||
|
||||
CORE_COUNT=$(nproc --all)
|
||||
PREFIX=$(realpath curl-wasm)
|
||||
OPENSSL_PREFIX=$(realpath openssl-wasm)
|
||||
mkdir -p $PREFIX
|
||||
|
||||
rm -rf curl
|
||||
git clone -b master --depth=1 https://github.com/curl/curl
|
||||
cd curl
|
||||
|
||||
autoreconf -fi
|
||||
emconfigure ./configure --host i686-linux --prefix=$PREFIX --disable-shared --disable-threaded-resolver --without-libpsl --disable-netrc --disable-ipv6 --disable-tftp --disable-ntlm-wb --with-ssl=$OPENSSL_PREFIX
|
||||
emmake make -j$CORE_COUNT CFLAGS="-pthread"
|
||||
|
||||
rm -rf $PREFIX/include/*
|
||||
rm -rf $PREFIX/lib/*
|
||||
mkdir -p $PREFIX/include
|
||||
mkdir -p $PREFIX/lib
|
||||
cp -r include/curl $PREFIX/include
|
||||
cp lib/.libs/libcurl.a $PREFIX/lib
|
||||
cp -r $OPENSSL_PREFIX/* $PREFIX
|
||||
|
||||
cd ..
|
Loading…
Add table
Add a link
Reference in a new issue