I've found that various Makefiles, including "psl/dist/Makefile", "./packages/foreign/cuba/Makefile", "packages/foreign/gurobi/Makefile", "packages/foreign/nlopt/Makefile", "packages/foreign/z3/Makefile", "libraries/SoftFloat-3*/build/.../Makefile", a few Makefiles in the libffi test suite, and a couple other random spots I may have missed are calling "gcc", even when Reduce was configured to use a different compiled (calling configure with the CC and CXX variables set.)
Also, CFLAGS is not being passed to the compiler in these rules where gcc is used.
I've verified the resulting binaries are in fact compiled using both the requested compiler and GCC:
» cd /usr/local/lib/reduce/cslbuild/csl
» strings reduce | grep -E '(^Intel|^GCC:)'
GCC: (GNU) 10.2.1 20201125 (Red Hat 10.2.1-9)
Intel(R) oneAPI DPC++ Compiler 2021.1.2 (2020.10.0.1214)
» strings csl | grep -E '(^Intel|^GCC:)'
GCC: (GNU) 10.2.1 20201125 (Red Hat 10.2.1-9)
Intel(R) oneAPI DPC++ Compiler 2021.1.2 (2020.10.0.1214)
» strings bootstrapreduce | grep -E '(^Intel|^GCC:)'
GCC: (GNU) 10.2.1 20201125 (Red Hat 10.2.1-9)
Intel(R) oneAPI DPC++ Compiler 2021.1.2 (2020.10.0.1214)
Interestingly, it also seems that /usr/local/lib/reduce/pslbuild/psl/bpsl is not built using either my system compiler or the requested compiler at all, but is using a pre-built binary from psl/dist/kernel/AMD64/:
» strings /usr/local/lib/reduce/pslbuild/psl/bpsl | grep -E '(^Intel|^GCC:)'
GCC: (Ubuntu 7.5.0-3ubuntu1~18.04) 7.5.0
I should probably add this is on a Linux/x86_64/Fedora 33 system, and using SVN r5693.
As far as bpsl is concerned, this is not a bug, it is deliberate. The PSL kernel (bpsl) is a very small shell around the C runtime. It is used to bootstrap the lisp interpreter by loading compiled lisp code.
Building the PSL kernel is somewhat tricky. While it would probably work with other compilers (e.g. llvm), it is not tested. Providing a prebuilt bpsl executable is the safest way.
As for the psl/dist/Makefile: I see that is a leftover from the time when it was necessary to create a sparse file, when the latter contains a lot of data initialized to zero. This was decades ago, and I see no reason to do this anymore. I'll remove it from the Makefile.
Rainer
Both AOCC and DPC++ are based on LLVM - I'll have to read up and see if building bpsl works with them (or LLVM, more generally). However, your response does address my concerns, so you can close out this bug.
Thank you for the quick response!