blakemcbride/LISPF4

Runtime execution failure of SYSATOMS.

Opened this issue · 10 comments

The downstream bug describing the exact situation can be found here.
This bug is 100% reproducible across all systems I tried so far, and can be reproduced if you install Guix or GuixSD on some form of a system including just a VM (see Guix documentation for this short process).
I can not invest the time into this bug so I hope some people involving the author of this software will get to solving this bug.

Looking at the log, I fail to see the error. Could you please cut/paste the relevant lines here.

That's the build. The build succeeds, but running it fails. I last debugged this in the beginning of this year and can not supply more info.. I can add strace, gdb, and normal error output to the downstream or this bug if it helps?

Just looked up Guix.

  1. Guix is beta software. It specifically says not to use it in production environments.
  2. Does LISPF4 work for you without Guix?

Thanks.

Bkake

Please skip Guix for now, and give me a log of any issue.

Thanks.

Blake

Beta software depends on your view (needs, expectations etc). Guix is used already in institutes, HPCs, and I build software on it.

I can do a "normal" build without my package recipe.. I think we talked about this earlier this year when I first tried to solve the bug. It works, but as soon as SYSATOMS is outside of users home it fails.
Back then I've tried this on Gentoo and Debian - both user builds - and I just like to figure out where the problem lies. I don't depend on lispf4, and I doubt that the items on the roadmap of Guix are roadblockers for lispf4 to work. I recently packages another lisp which is created equal to lispf4, works for me.

I'll add logs in some minutes, need to run and build it first.

To be more specific: software in Guix is like in Nix installed in an immutable store. If your software wants to write something, it won't succeed. But the problem is opening the SYSATOMS when lispf4 is invoked without the filename. That's not a problem of permissions either, I went through that already. Appended is a strace of what happens when you start lispf4 how it is build on Guix (using the binary substitute build on hydra). Build as a user it works, but as soon as it hits this immutable store, it won't. I'm trying to figure out what Guix needs to patch that it will work. This is terrible old software I do not like to spend more time with then I already did in January to February, so this is just to provide some more documentation for anyone who wants to fix it. The goal should be to come to some conclusion / tips how it can be fixed, independent from the public declared status of Guix (I predict the same problems for Nix).

ng0@shadowwalker ~ [env]$ lispf4
Can't open 'SYSATOMS'
ng0@shadowwalker ~ [env]$ strace lispf4
execve("/gnu/store/a9k7123sys54www6pgb0afq6v0jwb85v-profile/bin/lispf4", ["lispf4"], [/* 63 vars /]) = 0
brk(0) = 0x1053000
mmap(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7ff167e26000
access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory)
open("/gnu/store/5s1hiqaxadhq9bxhb95wwp0vn22ashxs-cairo-1.14.6/lib/tls/x86_64/libm.so.6", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
stat("/gnu/store/5s1hiqaxadhq9bxhb95wwp0vn22ashxs-cairo-1.14.6/lib/tls/x86_64", 0x7fffad03ca60) = -1 ENOENT (No such file or directory)
open("/gnu/store/5s1hiqaxadhq9bxhb95wwp0vn22ashxs-cairo-1.14.6/lib/tls/libm.so.6", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
stat("/gnu/store/5s1hiqaxadhq9bxhb95wwp0vn22ashxs-cairo-1.14.6/lib/tls", 0x7fffad03ca60) = -1 ENOENT (No such file or directory)
open("/gnu/store/5s1hiqaxadhq9bxhb95wwp0vn22ashxs-cairo-1.14.6/lib/x86_64/libm.so.6", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
stat("/gnu/store/5s1hiqaxadhq9bxhb95wwp0vn22ashxs-cairo-1.14.6/lib/x86_64", 0x7fffad03ca60) = -1 ENOENT (No such file or directory)
open("/gnu/store/5s1hiqaxadhq9bxhb95wwp0vn22ashxs-cairo-1.14.6/lib/libm.so.6", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
stat("/gnu/store/5s1hiqaxadhq9bxhb95wwp0vn22ashxs-cairo-1.14.6/lib", {st_mode=S_IFDIR|0555, st_size=4096, ...}) = 0
open("/gnu/store/m9vxvhdj691bq1f85lpflvnhcvrdilih-glibc-2.23/lib/tls/x86_64/libm.so.6", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
stat("/gnu/store/m9vxvhdj691bq1f85lpflvnhcvrdilih-glibc-2.23/lib/tls/x86_64", 0x7fffad03ca60) = -1 ENOENT (No such file or directory)
open("/gnu/store/m9vxvhdj691bq1f85lpflvnhcvrdilih-glibc-2.23/lib/tls/libm.so.6", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
stat("/gnu/store/m9vxvhdj691bq1f85lpflvnhcvrdilih-glibc-2.23/lib/tls", 0x7fffad03ca60) = -1 ENOENT (No such file or directory)
open("/gnu/store/m9vxvhdj691bq1f85lpflvnhcvrdilih-glibc-2.23/lib/x86_64/libm.so.6", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
stat("/gnu/store/m9vxvhdj691bq1f85lpflvnhcvrdilih-glibc-2.23/lib/x86_64", 0x7fffad03ca60) = -1 ENOENT (No such file or directory)
open("/gnu/store/m9vxvhdj691bq1f85lpflvnhcvrdilih-glibc-2.23/lib/libm.so.6", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\3\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0`U\0\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0555, st_size=1141048, ...}) = 0
mmap(NULL, 3166528, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7ff167900000
mprotect(0x7ff167a05000, 2093056, PROT_NONE) = 0
mmap(0x7ff167c04000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x104000) = 0x7ff167c04000
close(3) = 0
open("/gnu/store/5s1hiqaxadhq9bxhb95wwp0vn22ashxs-cairo-1.14.6/lib/libgcc_s.so.1", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
open("/gnu/store/m9vxvhdj691bq1f85lpflvnhcvrdilih-glibc-2.23/lib/libgcc_s.so.1", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
open("/gnu/store/9nifwk709wajpyfwa0jzaa3p6mf10vxs-gcc-4.9.3-lib/lib/tls/x86_64/libgcc_s.so.1", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
stat("/gnu/store/9nifwk709wajpyfwa0jzaa3p6mf10vxs-gcc-4.9.3-lib/lib/tls/x86_64", 0x7fffad03ca30) = -1 ENOENT (No such file or directory)
open("/gnu/store/9nifwk709wajpyfwa0jzaa3p6mf10vxs-gcc-4.9.3-lib/lib/tls/libgcc_s.so.1", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
stat("/gnu/store/9nifwk709wajpyfwa0jzaa3p6mf10vxs-gcc-4.9.3-lib/lib/tls", 0x7fffad03ca30) = -1 ENOENT (No such file or directory)
open("/gnu/store/9nifwk709wajpyfwa0jzaa3p6mf10vxs-gcc-4.9.3-lib/lib/x86_64/libgcc_s.so.1", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
stat("/gnu/store/9nifwk709wajpyfwa0jzaa3p6mf10vxs-gcc-4.9.3-lib/lib/x86_64", 0x7fffad03ca30) = -1 ENOENT (No such file or directory)
open("/gnu/store/9nifwk709wajpyfwa0jzaa3p6mf10vxs-gcc-4.9.3-lib/lib/libgcc_s.so.1", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0p
\0\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0444, st_size=100848, ...}) = 0
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7ff167e25000
mmap(NULL, 2185952, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7ff1676ea000
mprotect(0x7ff167700000, 2093056, PROT_NONE) = 0
mmap(0x7ff1678ff000, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x15000) = 0x7ff1678ff000
close(3) = 0
open("/gnu/store/5s1hiqaxadhq9bxhb95wwp0vn22ashxs-cairo-1.14.6/lib/libc.so.6", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
open("/gnu/store/m9vxvhdj691bq1f85lpflvnhcvrdilih-glibc-2.23/lib/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>\0\1\0\0\0 \t\2\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0555, st_size=1942128, ...}) = 0
mmap(NULL, 3808896, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7ff167348000
mprotect(0x7ff1674e1000, 2093056, PROT_NONE) = 0
mmap(0x7ff1676e0000, 24576, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x198000) = 0x7ff1676e0000
mmap(0x7ff1676e6000, 16000, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x7ff1676e6000
close(3) = 0
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7ff167e24000
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7ff167e23000
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7ff167e22000
arch_prctl(ARCH_SET_FS, 0x7ff167e23700) = 0
mprotect(0x7ff1676e0000, 16384, PROT_READ) = 0
mprotect(0x7ff167c04000, 4096, PROT_READ) = 0
mprotect(0x7ff167e28000, 4096, PROT_READ) = 0
rt_sigaction(SIGINT, {0x406f40, [INT], SA_RESTORER|SA_RESTART, 0x7ff16737b390}, {SIG_DFL, [], 0}, 8) = 0
mmap(NULL, 401408, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7ff167dc0000
mmap(NULL, 401408, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7ff167d5e000
brk(0) = 0x1053000
brk(0x1076000) = 0x1076000
open("SYSATOMS", O_RDONLY) = -1 ENOENT (No such file or directory)
write(2, "Can't open 'SYSATOMS'\n", 22Can't open 'SYSATOMS'
) = 22
exit_group(1) = ?
+++ exited with 1 +++

First, after the line:

ng0@shadowwalker ~ [env]$ lispf4
Can't open 'SYSATOMS'

I need to see:

ls -l

If LISPF4 works without Guix but fails with some unanticipated re-packaging such as Guix, the problem is either Guix or the way it is being used, period.

ng0@shadowwalker ~$ guix build lispf4
/gnu/store/2xw8jlp58x2k075fpr0kqrlrbc0ldn07-lispf4-0.0.0-1-174d876-doc
/gnu/store/2mmqgx310pl56lsad6qlxlimhc7fxnaq-lispf4-0.0.0-1-174d876
ng0@shadowwalker ~$ cd /gnu/store/2mmqgx310pl56lsad6qlxlimhc7fxnaq-lispf4-0.0.0-1-174d876
ng0@shadowwalker /gnu/store/2mmqgx310pl56lsad6qlxlimhc7fxnaq-lispf4-0.0.0-1-174d876$ ls
bin/
ng0@shadowwalker /gnu/store/2mmqgx310pl56lsad6qlxlimhc7fxnaq-lispf4-0.0.0-1-174d876$ cd bin/
ng0@shadowwalker /gnu/store/2mmqgx310pl56lsad6qlxlimhc7fxnaq-lispf4-0.0.0-1-174d876/bin$ ls
BASIC.IMG lispf4 SYSATOMS

Which should also be visible and clear if you read the source:
http://git.savannah.gnu.org/cgit/guix.git/tree/gnu/packages/lisp.scm#n446

We might be able to solve this after all. I'm trying this on my package definition now.