cgit build on riscv64 machine
Bo YU
tsu.yubo at gmail.com
Tue Jul 19 08:02:30 UTC 2022
Hi,
Thank you for quick reply.
>[...]
>> not ok 10 - do not access $HOME: foo/snapshot/master.tar.gz
>> #
>> # test_no_home_access 'foo/snapshot/master.tar.gz'
>> #
>> # failed 10 among 10 test(s)
>> 1..10
>> make[1]: *** [Makefile:12: t0109-gitconfig.sh] Error 1
>> make: *** [Makefile:83: test] Error 2
>
>
>Are you using qemu-user?
It is interesting. In fact, I build it on real riscv64
hardware(Unmatched boards).
```
vimer at unmatched:~/build/07/31_cgit/cgit-master/tests$ uname -a
Linux unmatched 5.18.0-2-riscv64 #1 SMP Debian 5.18.5-1 (2022-06-16) riscv64 GNU/Linux
```
>
>That test uses strace, which in turn uses the ptrace() system call.
>qemu-user does not support ptrace(). At least it didn't when I tried a couple of years ago.
I just test strace cmd after see your hint, but it looks ok(If I do
wrong please conrect me)
```
vimer at unmatched:~/build/07/31_cgit/cgit-master/tests$ strace -o strace.out ls
Makefile t0001-validate-git-versions.sh t0102-summary.sh t0106-diff.sh t0110-rawdiff.sh valgrind
filters t0010-validate-html.sh t0103-log.sh t0107-snapshot.sh t0111-filter.sh
setup.sh t0020-validate-cache.sh t0104-tree.sh t0108-patch.sh test-results
strace.out t0101-index.sh t0105-commit.sh t0109-gitconfig.sh 'trash directory.t0109-gitconfig'
vimer at unmatched:~/build/07/31_cgit/cgit-master/tests$ cat strace.out
execve("/usr/bin/ls", ["ls"], 0x3fcc1ab530 /* 22 vars */) = 0
brk(NULL) = 0x2abe9aa000
faccessat(AT_FDCWD, "/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/etc/ld.so.cache", O_RDONLY|O_CLOEXEC) = 3
newfstatat(3, "", {st_mode=S_IFREG|0644, st_size=67387, ...}, AT_EMPTY_PATH) = 0
mmap(NULL, 67387, PROT_READ, MAP_PRIVATE, 3, 0) = 0x3f92a36000
close(3) = 0
openat(AT_FDCWD, "/lib/riscv64-linux-gnu/libselinux.so.1", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0\363\0\1\0\0\0\0\0\0\0\0\0\0\0"..., 832) = 832
newfstatat(3, "", {st_mode=S_IFREG|0644, st_size=131280, ...}, AT_EMPTY_PATH) = 0
mmap(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x3f92a34000
mmap(NULL, 142984, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x3f92a11000
mmap(0x3f92a30000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x1e000) = 0x3f92a30000
mmap(0x3f92a32000, 7816, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x3f92a32000
close(3) = 0
openat(AT_FDCWD, "/lib/riscv64-linux-gnu/libc.so.6", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\3\0\0\0\0\0\0\0\0\3\0\363\0\1\0\0\0\370\10\2\0\0\0\0\0"..., 832) = 832
newfstatat(3, "", {st_mode=S_IFREG|0755, st_size=1086160, ...}, AT_EMPTY_PATH) = 0
mmap(NULL, 1117952, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x3f92900000
mmap(0x3f92a03000, 24576, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x102000) = 0x3f92a03000
mmap(0x3f92a09000, 32512, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x3f92a09000
close(3) = 0
openat(AT_FDCWD, "/lib/riscv64-linux-gnu/libpcre2-8.so.0", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0\363\0\1\0\0\0\0\0\0\0\0\0\0\0"..., 832) = 832
newfstatat(3, "", {st_mode=S_IFREG|0644, st_size=342600, ...}, AT_EMPTY_PATH) = 0
mmap(NULL, 344904, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x3f928ab000
mmap(0x3f928fe000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x52000) = 0x3f928fe000
close(3) = 0
openat(AT_FDCWD, "/lib/riscv64-linux-gnu/libdl.so.2", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0\363\0\1\0\0\0\0\0\0\0\0\0\0\0"..., 832) = 832
newfstatat(3, "", {st_mode=S_IFREG|0644, st_size=10376, ...}, AT_EMPTY_PATH) = 0
mmap(NULL, 12616, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x3f928a7000
mmap(0x3f928a9000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x1000) = 0x3f928a9000
close(3) = 0
mmap(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x3f928a5000
mprotect(0x3f92a03000, 16384, PROT_READ) = 0
[...]
mprotect(0x3f928a9000, 4096, PROT_READ) = 0
munmap(0x3f92a36000, 67387) = 0
statfs("/sys/fs/selinux", 0x3fcf981390) = -1 ENOENT (No such file or directory)
statfs("/selinux", 0x3fcf981390) = -1 ENOENT (No such file or directory)
brk(NULL) = 0x2abe9aa000
brk(0x2abe9cb000) = 0x2abe9cb000
openat(AT_FDCWD, "/proc/filesystems", O_RDONLY|O_CLOEXEC) = 3
newfstatat(3, "", {st_mode=S_IFREG|0444, st_size=0, ...}, AT_EMPTY_PATH) = 0
read(3, "nodev\tsysfs\nnodev\ttmpfs\nnodev\tbd"..., 1024) = 340
read(3, "", 1024) = 0
close(3) = 0
faccessat(AT_FDCWD, "/etc/selinux/config", F_OK) = -1 ENOENT (No such file or directory)
ioctl(1, TCGETS, {B38400 opost isig icanon echo ...}) = 0
ioctl(1, TIOCGWINSZ, {ws_row=38, ws_col=137, ws_xpixel=0, ws_ypixel=0}) = 0
openat(AT_FDCWD, ".", O_RDONLY|O_NONBLOCK|O_CLOEXEC|O_DIRECTORY) = 3
newfstatat(3, "", {st_mode=S_IFDIR|0755, st_size=4096, ...}, AT_EMPTY_PATH) = 0
getdents64(3, 0x2abe9af2e0 /* 24 entries */, 32768) = 912
getdents64(3, 0x2abe9af2e0 /* 0 entries */, 32768) = 0
close(3) = 0
newfstatat(1, "", {st_mode=S_IFCHR|0620, st_rdev=makedev(0x88, 0x2), ...}, AT_EMPTY_PATH) = 0
write(1, " Makefile t0001-validate-git"..., 117) = 117
write(1, " filters t0010-validate-htm"..., 96) = 96
write(1, " setup.sh t0020-validate-cac"..., 95) = 95
write(1, " strace.out t0101-index.sh\t\t "..., 109) = 109
close(1) = 0
close(2) = 0
exit_group(0) = ?
+++ exited with 0 +++
```
Or the test cmd does not cover the cases?
Bo
--
Best Regards
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <http://lists.zx2c4.com/pipermail/cgit/attachments/20220719/aeebaf3f/attachment.sig>
More information about the CGit
mailing list