1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
|
GNU Hello
I'm reviewing the PR for a Nix package (https://github.com/NixOS/nixpkgs/pull/173987).
I want to try to run box64 with the most simple program before any game, so i tried GNU **hello**, but that fails already. Is that program not supported or is there an issue with the packaging?
```
[nix-shell:~/.cache/nixpkgs-review/pr-173987-4]$ box64 -v
Dynarec for ARM64, with extension: ASIMD AES CRC32 PMULL PageSize:4096
Box64 with Dynarec v0.1.8 nogit built on Jan 1 1980 00:00:00
# get x86_64-linux hello on aarch64-linux system
[root@pinephone:~]# nix-build 'https://github.com/NixOS/nixpkgs/archive/17c252aab1772d36acd6d3f57f6512f25b6f9e9c.tar.gz' --arg crossSystem '{ config = "x86_64-unknown-linux-gnu"; }' -A hello
these 2 paths will be fetched (6.15 MiB download, 29.72 MiB unpacked):
/nix/store/bq5fvsivbfxn3gpqa4mbh318xlx64b86-glibc-x86_64-unknown-linux-gnu-2.34-115
/nix/store/j3g94knvy76wzravskmzr4m3xfa5ghy5-hello-x86_64-unknown-linux-gnu-2.12
copying path '/nix/store/bq5fvsivbfxn3gpqa4mbh318xlx64b86-glibc-x86_64-unknown-linux-gnu-2.34-115' from 'https://cache.nixos.org'...
copying path '/nix/store/j3g94knvy76wzravskmzr4m3xfa5ghy5-hello-x86_64-unknown-linux-gnu-2.12' from 'https://cache.nixos.org'...
/nix/store/j3g94knvy76wzravskmzr4m3xfa5ghy5-hello-x86_64-unknown-linux-gnu-2.12
[nix-shell:~/.cache/nixpkgs-review/pr-173987-4]$ box64 /nix/store/j3g94knvy76wzravskmzr4m3xfa5ghy5-hello-x86_64-unknown-linux-gnu-2.12/bin/hello
Dynarec for ARM64, with extension: ASIMD AES CRC32 PMULL PageSize:4096
Box64 with Dynarec v0.1.8 nogit built on Jan 1 1980 00:00:00
Using default BOX64_LD_LIBRARY_PATH: ./:lib/:lib64/:x86_64/:bin64/:libs64/
Using default BOX64_PATH: ./:bin/
Counted 109 Env var
Looking for /nix/store/j3g94knvy76wzravskmzr4m3xfa5ghy5-hello-x86_64-unknown-linux-gnu-2.12/bin/hello
Using native(wrapped) libc.so.6
Using native(wrapped) ld-linux-x86-64.so.2
Using native(wrapped) libpthread.so.0
Using native(wrapped) librt.so.1
Error: PltResolver: Symbol __wprintf_chk(ver 4: __wprintf_chk@GLIBC_2.4) not found, cannot apply R_X86_64_JUMP_SLOT 0x40cf78 (0x4022f6) in /nix/store/j3g94knvy76wzravskmzr4m3xfa5ghy5-hello-x86_64-unknown-linux-gnu-2.12/bin/hello
```
```
[nix-shell:~/.cache/nixpkgs-review/pr-173987-4]$ box64 /nix/store/zagsmdwhrmnbnp23vgrzg1nq0w5mvmmc-coreutils-x86_64-unknown-linux-gnu-9.0/bin/uptime
Dynarec for ARM64, with extension: ASIMD AES CRC32 PMULL PageSize:4096
Box64 with Dynarec v0.1.8 nogit built on Jan 1 1980 00:00:00
Using default BOX64_LD_LIBRARY_PATH: ./:lib/:lib64/:x86_64/:bin64/:libs64/
Using default BOX64_PATH: ./:bin/
Counted 109 Env var
Looking for /nix/store/zagsmdwhrmnbnp23vgrzg1nq0w5mvmmc-coreutils-x86_64-unknown-linux-gnu-9.0/bin/uptime
Using emulated /nix/store/b0sshs1b8qvrvjijy4q7br48x8d0mkwq-acl-x86_64-unknown-linux-gnu-2.3.1/lib/libacl.so.1
Using emulated /nix/store/3r50lcc6dmfvcs9z5w1744jf55wdr0lf-attr-x86_64-unknown-linux-gnu-2.5.1/lib/libattr.so.1
Error initializing native libgmp.so.10 (last dlerror is libgmp.so.10: cannot open shared object file: No such file or directory)
Using emulated /nix/store/y2wbpqwhzjiihbs0ls0j9x8zx7yym1zk-gmp-with-cxx-x86_64-unknown-linux-gnu-6.2.1/lib/libgmp.so.10
Using native(wrapped) libc.so.6
Using native(wrapped) ld-linux-x86-64.so.2
Using native(wrapped) libpthread.so.0
Using native(wrapped) librt.so.1
Error: PltResolver: Symbol error(ver 2: error@GLIBC_2.2.5) not found, cannot apply R_X86_64_JUMP_SLOT 0x552c40 (0x408096) in /nix/store/zagsmdwhrmnbnp23vgrzg1nq0w5mvmmc-coreutils-x86_64-unknown-linux-gnu-9.0/bin/uptime
```
```
[nix-shell:~/.cache/nixpkgs-review/pr-173987-4]$ box64 /nix/store/zagsmdwhrmnbnp23vgrzg1nq0w5mvmmc-coreutils-x86_64-unknown-linux-gnu-9.0/bin/who
Dynarec for ARM64, with extension: ASIMD AES CRC32 PMULL PageSize:4096
Box64 with Dynarec v0.1.8 nogit built on Jan 1 1980 00:00:00
Using default BOX64_LD_LIBRARY_PATH: ./:lib/:lib64/:x86_64/:bin64/:libs64/
Using default BOX64_PATH: ./:bin/
Counted 109 Env var
Looking for /nix/store/zagsmdwhrmnbnp23vgrzg1nq0w5mvmmc-coreutils-x86_64-unknown-linux-gnu-9.0/bin/who
Using emulated /nix/store/b0sshs1b8qvrvjijy4q7br48x8d0mkwq-acl-x86_64-unknown-linux-gnu-2.3.1/lib/libacl.so.1
Using emulated /nix/store/3r50lcc6dmfvcs9z5w1744jf55wdr0lf-attr-x86_64-unknown-linux-gnu-2.5.1/lib/libattr.so.1
Error initializing native libgmp.so.10 (last dlerror is libgmp.so.10: cannot open shared object file: No such file or directory)
Using emulated /nix/store/y2wbpqwhzjiihbs0ls0j9x8zx7yym1zk-gmp-with-cxx-x86_64-unknown-linux-gnu-6.2.1/lib/libgmp.so.10
Using native(wrapped) libc.so.6
Using native(wrapped) ld-linux-x86-64.so.2
Using native(wrapped) libpthread.so.0
Using native(wrapped) librt.so.1
Error: PltResolver: Symbol stat(ver 16: stat@GLIBC_2.33) not found, cannot apply R_X86_64_JUMP_SLOT 0x552980 (0x407b16) in /nix/store/zagsmdwhrmnbnp23vgrzg1nq0w5mvmmc-coreutils-x86_64-unknown-linux-gnu-9.0/bin/who
```
These work:
```
[nix-shell:~/.cache/nixpkgs-review/pr-173987-4]$ box64 /nix/store/zagsmdwhrmnbnp23vgrzg1nq0w5mvmmc-coreutils-x86_64-unknown-linux-gnu-9.0/bin/echo test
Dynarec for ARM64, with extension: ASIMD AES CRC32 PMULL PageSize:4096
Box64 with Dynarec v0.1.8 nogit built on Jan 1 1980 00:00:00
Using default BOX64_LD_LIBRARY_PATH: ./:lib/:lib64/:x86_64/:bin64/:libs64/
Using default BOX64_PATH: ./:bin/
Counted 109 Env var
Looking for /nix/store/zagsmdwhrmnbnp23vgrzg1nq0w5mvmmc-coreutils-x86_64-unknown-linux-gnu-9.0/bin/echo
argv[1]="test"
Using emulated /nix/store/b0sshs1b8qvrvjijy4q7br48x8d0mkwq-acl-x86_64-unknown-linux-gnu-2.3.1/lib/libacl.so.1
Using emulated /nix/store/3r50lcc6dmfvcs9z5w1744jf55wdr0lf-attr-x86_64-unknown-linux-gnu-2.5.1/lib/libattr.so.1
Error initializing native libgmp.so.10 (last dlerror is libgmp.so.10: cannot open shared object file: No such file or directory)
Using emulated /nix/store/y2wbpqwhzjiihbs0ls0j9x8zx7yym1zk-gmp-with-cxx-x86_64-unknown-linux-gnu-6.2.1/lib/libgmp.so.10
Using native(wrapped) libc.so.6
Using native(wrapped) ld-linux-x86-64.so.2
Using native(wrapped) libpthread.so.0
Using native(wrapped) librt.so.1
test
```
```
[nix-shell:~/.cache/nixpkgs-review/pr-173987-4]$ box64 /nix/store/zagsmdwhrmnbnp23vgrzg1nq0w5mvmmc-coreutils-x86_64-unknown-linux-gnu-9.0/bin/mktemp
Dynarec for ARM64, with extension: ASIMD AES CRC32 PMULL PageSize:4096
Box64 with Dynarec v0.1.8 nogit built on Jan 1 1980 00:00:00
Using default BOX64_LD_LIBRARY_PATH: ./:lib/:lib64/:x86_64/:bin64/:libs64/
Using default BOX64_PATH: ./:bin/
Counted 109 Env var
Looking for /nix/store/zagsmdwhrmnbnp23vgrzg1nq0w5mvmmc-coreutils-x86_64-unknown-linux-gnu-9.0/bin/mktemp
Using emulated /nix/store/b0sshs1b8qvrvjijy4q7br48x8d0mkwq-acl-x86_64-unknown-linux-gnu-2.3.1/lib/libacl.so.1
Using emulated /nix/store/3r50lcc6dmfvcs9z5w1744jf55wdr0lf-attr-x86_64-unknown-linux-gnu-2.5.1/lib/libattr.so.1
Error initializing native libgmp.so.10 (last dlerror is libgmp.so.10: cannot open shared object file: No such file or directory)
Using emulated /nix/store/y2wbpqwhzjiihbs0ls0j9x8zx7yym1zk-gmp-with-cxx-x86_64-unknown-linux-gnu-6.2.1/lib/libgmp.so.10
Using native(wrapped) libc.so.6
Using native(wrapped) ld-linux-x86-64.so.2
Using native(wrapped) libpthread.so.0
Using native(wrapped) librt.so.1
/tmp/tmp.701c0tWJp8
```
```
[nix-shell:~/.cache/nixpkgs-review/pr-173987-4]$ box64 /nix/store/zagsmdwhrmnbnp23vgrzg1nq0w5mvmmc-coreutils-x86_64-unknown-linux-gnu-9.0/bin/uname -a
Dynarec for ARM64, with extension: ASIMD AES CRC32 PMULL PageSize:4096
Box64 with Dynarec v0.1.8 nogit built on Jan 1 1980 00:00:00
Using default BOX64_LD_LIBRARY_PATH: ./:lib/:lib64/:x86_64/:bin64/:libs64/
Using default BOX64_PATH: ./:bin/
Counted 109 Env var
Looking for /nix/store/zagsmdwhrmnbnp23vgrzg1nq0w5mvmmc-coreutils-x86_64-unknown-linux-gnu-9.0/bin/uname
argv[1]="-a"
Using emulated /nix/store/b0sshs1b8qvrvjijy4q7br48x8d0mkwq-acl-x86_64-unknown-linux-gnu-2.3.1/lib/libacl.so.1
Using emulated /nix/store/3r50lcc6dmfvcs9z5w1744jf55wdr0lf-attr-x86_64-unknown-linux-gnu-2.5.1/lib/libattr.so.1
Error initializing native libgmp.so.10 (last dlerror is libgmp.so.10: cannot open shared object file: No such file or directory)
Using emulated /nix/store/y2wbpqwhzjiihbs0ls0j9x8zx7yym1zk-gmp-with-cxx-x86_64-unknown-linux-gnu-6.2.1/lib/libgmp.so.10
Using native(wrapped) libc.so.6
Using native(wrapped) ld-linux-x86-64.so.2
Using native(wrapped) libpthread.so.0
Using native(wrapped) librt.so.1
Linux pinephone 5.17.5 #1-mobile-nixos SMP Tue Jan 1 00:00:00 UTC 1980 x86_64 GNU/Linux
```
```
[nix-shell:~/.cache/nixpkgs-review/pr-173987-4]$ box64 /nix/store/zagsmdwhrmnbnp23vgrzg1nq0w5mvmmc-coreutils-x86_64-unknown-linux-gnu-9.0/bin/whoami
Dynarec for ARM64, with extension: ASIMD AES CRC32 PMULL PageSize:4096
Box64 with Dynarec v0.1.8 nogit built on Jan 1 1980 00:00:00
Using default BOX64_LD_LIBRARY_PATH: ./:lib/:lib64/:x86_64/:bin64/:libs64/
Using default BOX64_PATH: ./:bin/
Counted 109 Env var
Looking for /nix/store/zagsmdwhrmnbnp23vgrzg1nq0w5mvmmc-coreutils-x86_64-unknown-linux-gnu-9.0/bin/whoami
Using emulated /nix/store/b0sshs1b8qvrvjijy4q7br48x8d0mkwq-acl-x86_64-unknown-linux-gnu-2.3.1/lib/libacl.so.1
Using emulated /nix/store/3r50lcc6dmfvcs9z5w1744jf55wdr0lf-attr-x86_64-unknown-linux-gnu-2.5.1/lib/libattr.so.1
Error initializing native libgmp.so.10 (last dlerror is libgmp.so.10: cannot open shared object file: No such file or directory)
Using emulated /nix/store/y2wbpqwhzjiihbs0ls0j9x8zx7yym1zk-gmp-with-cxx-x86_64-unknown-linux-gnu-6.2.1/lib/libgmp.so.10
Using native(wrapped) libc.so.6
Using native(wrapped) ld-linux-x86-64.so.2
Using native(wrapped) libpthread.so.0
Using native(wrapped) librt.so.1
davidak
```
|