Buy commercial curl support from WolfSSL. We help you work
out your issues, debug your libcurl applications, use the API, port to new
platforms, add new features and more. With a team lead by the curl founder
himself.
Building cURL for Apple Silicon
- Contemporary messages sorted: [ by date ] [ by thread ] [ by subject ] [ by author ] [ by messages with attachments ]
From: Taw via curl-library <curl-library_at_cool.haxx.se>
Date: Thu, 12 Nov 2020 17:48:34 +0200
Hi,
This is my first mail in a mailing-list so I hope I do this properly.
I am trying to build cURL for Apple Silicon ARM (cross-compilation) using a
macOS Intel host.
How is done with other libraries (zlib, cjson, etc): just add "-target
arm64-apple-macos11" to CFLAGS and that's it.
I am using this command
"CFLAGS=" -fPIC -DPIC -m64 -target arm64-apple-macos11 " ./configure
--without-libssh2 --without-zlib --without-gnutls --without-nss
--without-libidn --without-libidn2 --without-nghttp2 --without-librtmp
--without-brotli --without-libpsl
--prefix="/Users/test/work/curl-7.73.0/prefix"
--with-ssl="/Users/test/work/openssl-1.1.1h/prefix/"
I get this error
"configure:4488: gcc -o conftest -fPIC -DPIC -m64 -target
arm64-apple-macos11 conftest.c >&5
configure:4492: $? = 0
configure:4499: ./conftest
./configure: line 4501: ./conftest: Bad CPU type in executable
configure:4503: $? = 126
configure:4510: error: in `/Users/test/work/curl-7.73.0':
configure:4512: error: cannot run C compiled programs.
If you meant to cross compile, use `--host'."
But I don't know what "--host" to use. So I put a dummy "--host=arm" and it
seems to work.
On configure I get "Host setup: arm-unknown-none", but after "make
install" the binary seems ok.
"prefix/bin/curl: Mach-O 64-bit executable arm64"
Am I doing this in a correct manner? Does it matter what I put to "host"?
Thank you
-------------------------------------------------------------------
Unsubscribe: https://cool.haxx.se/list/listinfo/curl-library
Etiquette: https://curl.haxx.se/mail/etiquette.html
Received on 2020-11-12
Date: Thu, 12 Nov 2020 17:48:34 +0200
Hi,
This is my first mail in a mailing-list so I hope I do this properly.
I am trying to build cURL for Apple Silicon ARM (cross-compilation) using a
macOS Intel host.
How is done with other libraries (zlib, cjson, etc): just add "-target
arm64-apple-macos11" to CFLAGS and that's it.
I am using this command
"CFLAGS=" -fPIC -DPIC -m64 -target arm64-apple-macos11 " ./configure
--without-libssh2 --without-zlib --without-gnutls --without-nss
--without-libidn --without-libidn2 --without-nghttp2 --without-librtmp
--without-brotli --without-libpsl
--prefix="/Users/test/work/curl-7.73.0/prefix"
--with-ssl="/Users/test/work/openssl-1.1.1h/prefix/"
I get this error
"configure:4488: gcc -o conftest -fPIC -DPIC -m64 -target
arm64-apple-macos11 conftest.c >&5
configure:4492: $? = 0
configure:4499: ./conftest
./configure: line 4501: ./conftest: Bad CPU type in executable
configure:4503: $? = 126
configure:4510: error: in `/Users/test/work/curl-7.73.0':
configure:4512: error: cannot run C compiled programs.
If you meant to cross compile, use `--host'."
But I don't know what "--host" to use. So I put a dummy "--host=arm" and it
seems to work.
On configure I get "Host setup: arm-unknown-none", but after "make
install" the binary seems ok.
"prefix/bin/curl: Mach-O 64-bit executable arm64"
Am I doing this in a correct manner? Does it matter what I put to "host"?
Thank you
-------------------------------------------------------------------
Unsubscribe: https://cool.haxx.se/list/listinfo/curl-library
Etiquette: https://curl.haxx.se/mail/etiquette.html
Received on 2020-11-12