moparisthebest / static-curl

fully static builds of curl, runs anywhere
https://code.moparisthebest.com/moparisthebest/static-curl
MIT License
520 stars 30 forks source link

Exiting with 0, not doing anything #12

Open Slyke opened 1 year ago

Slyke commented 1 year ago
$ curl-amd64 -X GET "https://google.com"
$ echo $?
0
$ curl-amd64 "https://google.com"
$ echo $?
0
$ curl-amd64 "https://asdfaskfhaklshfkjsahflkjas.com"
$ echo $?
0
$ curl-amd64 "http://asdfaskfhaklshfkjsahflkjas.com"
$ echo $?
0
$ curl-amd64 "http://localhost.:8080"
$ echo $?
0
$ curl-amd64
$ echo $?
0
$ uname -a
FreeBSD router.xyz 12.3-STABLE FreeBSD 12.3-STABLE RELENG_2_6_0-n226742-1285d6d205f pfSense  amd64

I created a simple http listener and nothing is sent out.

moparisthebest commented 1 year ago

I tried the version you would have been using last week, 8.0.1, and it works fine for me... But I don't have access to a FreeBSD box right now, maybe run with strace or something and see what's going on?

Slyke commented 1 year ago

I think something else is going on:

$ ./curl-amd64  "http://W.X.Y.Z/test?"
ELF binary type "0" not known.
./curl-amd64: Exec format error. Binary file not executable.

System installed (Dynamically compiled cURL):

$ curl  "http://W.X.Y.Z/test?"
{}

Still investigating.

Slyke commented 1 year ago

I also tried

brandelf -t linux ./curl-amd64

And get a similar error:

ELF binary type "3" not known.
./curl-amd64: Exec format error. Binary file not executable.

I believe this is because the binaries are only 32bit? At least that's what I'm finding in Google.