2
2
# On the Windows side, most of this is just unzipping and sorting pre-built binaries
3
3
# On the Linux side, we're only compiling CURL and installing Debian packages
4
4
5
+ if command -v apt > /dev/null; then
6
+
7
+ echo " Checking for necessary -dev packages..."
8
+ sudo apt install \
9
+ libarchive-dev \
10
+ libxml2-dev \
11
+ liblzma-dev \
12
+ libacl1-dev \
13
+ libgl1-mesa-dev \
14
+ libxcb* -dev \
15
+ libfontconfig1-dev \
16
+ libxkbcommon-x11-dev \
17
+ libnghttp2-dev \
18
+ libidn2-dev
19
+
20
+ echo " Checking for MinGW for cross-compilation..."
21
+ sudo apt install \
22
+ mingw-w64 \
23
+ mingw-w64-tools \
24
+ gcc-mingw-w64-x86-64 \
25
+ g++-mingw-w64-x86-64
26
+
27
+ echo " Switching to POSIX threads..."
28
+ sudo update-alternatives --set x86_64-w64-mingw32-gcc /usr/bin/x86_64-w64-mingw32-gcc-posix
29
+ sudo update-alternatives --set x86_64-w64-mingw32-g++ /usr/bin/x86_64-w64-mingw32-g++-posix
30
+
31
+ fi
32
+
5
33
rm -rf ./deps
6
34
mkdir deps
7
35
cd deps
@@ -57,12 +85,14 @@ mkdir shared
57
85
cd ..; rm -rf openssl
58
86
59
87
mkdir curl; cd curl
60
- wget https://curl.se/windows/dl-8.10.1_2/curl-8.10.1_2-win64-mingw.zip
61
- unzip curl-8.10.1_2-win64-mingw.zip
62
- mv curl-8.10.1_2-win64-mingw curl
63
- mv ./curl/bin/* .exe ../bin
64
- mv ./curl/bin/* .dll ../lib
65
- mv ./curl/lib/* ../lib
88
+ wget https://curl.se/download/curl-8.10.1.zip
89
+ unzip curl-8.10.1.zip
90
+ mv curl-8.10.1 curl; cd curl
91
+ ./configure --host=x86_64-w64-mingw32 --target=x86_64-w64-mingw32 --with-sysroot=/usr/x86_64-w64-mingw32 --enable-optimize --with-schannel --disable-dependency-tracking --disable-static --enable-shared --disable-ftp --disable-file --disable-ldap --disable-ldaps --disable-rtsp --disable-dict --disable-telnet --disable-tftp --disable-pop3 --disable-imap --disable-smb --disable-smtp --disable-gopher --disable-mqtt --disable-manual --disable-docs --disable-sspi --disable-aws --disable-ntlm --disable-unix-sockets --disable-socketpair --disable-dateparse --disable-progress-meter --enable-websockets --without-brotli --without-libssh2 --without-libssh --without-wolfssh --without-librtmp --without-libpsl
92
+ make
93
+ cd ..
94
+ mv ./curl/src/curl.exe ../bin
95
+ mv ./curl/lib/.libs/libcurl-4.dll ../lib
66
96
mv ./curl/include/* ../include
67
97
cd ..; rm -rf curl
68
98
@@ -79,7 +109,7 @@ mkdir shared
79
109
wget https://curl.se/download/curl-8.10.1.zip
80
110
unzip curl-8.10.1.zip
81
111
mv curl-8.10.1 curl; cd curl
82
- ./configure --enable-optimize --with-openssl --disable-dependency-tracking --disable-shared --disable-ftp --disable-file --disable-ldap --disable-ldaps --disable-rtsp --disable-dict --disable-telnet --disable-tftp --disable-pop3 --disable-imap --disable-smb --disable-smtp --disable-gopher --disable-mqtt --disable-manual --disable-docs --disable-sspi --disable-aws --disable-ntlm --disable-unix-sockets --disable-socketpair --disable-dateparse --disable-progress-meter --enable-websockets --without-brotli --without-libssh2 --without-libssh --without-wolfssh --without-librtmp
112
+ ./configure --enable-optimize --with-openssl --disable-dependency-tracking --disable-shared --disable-ftp --disable-file --disable-ldap --disable-ldaps --disable-rtsp --disable-dict --disable-telnet --disable-tftp --disable-pop3 --disable-imap --disable-smb --disable-smtp --disable-gopher --disable-mqtt --disable-manual --disable-docs --disable-sspi --disable-aws --disable-ntlm --disable-unix-sockets --disable-socketpair --disable-dateparse --disable-progress-meter --enable-websockets --without-brotli --without-libssh2 --without-libssh --without-wolfssh --without-librtmp --without-libpsl
83
113
make
84
114
cd ..
85
115
mv ./curl/src/curl ../bin
@@ -88,32 +118,3 @@ mkdir shared
88
118
cd ..; rm -rf curl
89
119
90
120
cd ..
91
-
92
- if command -v apt > /dev/null; then
93
-
94
- echo " Checking for necessary -dev packages..."
95
- sudo apt install \
96
- libarchive-dev \
97
- libxml2-dev \
98
- liblzma-dev \
99
- libacl1-dev \
100
- libgl1-mesa-dev \
101
- libxcb* -dev \
102
- libfontconfig1-dev \
103
- libxkbcommon-x11-dev \
104
- libpsl-dev \
105
- libnghttp2-dev \
106
- libidn2-dev
107
-
108
- echo " Checking for MinGW for cross-compilation..."
109
- sudo apt install \
110
- mingw-w64 \
111
- mingw-w64-tools \
112
- gcc-mingw-w64-x86-64 \
113
- g++-mingw-w64-x86-64
114
-
115
- echo " Switching to POSIX threads..."
116
- sudo update-alternatives --set x86_64-w64-mingw32-gcc /usr/bin/x86_64-w64-mingw32-gcc-posix
117
- sudo update-alternatives --set x86_64-w64-mingw32-g++ /usr/bin/x86_64-w64-mingw32-g++-posix
118
-
119
- fi
0 commit comments