Error while building uberspark libraries

Hey guys,
I was able to install the uberspark toolchain and verify the uberspark libraries, but when running make build-ubersparklibs I run into this error:

xmhfgeec_slabmapdef.c:60: error: initializer element is not a compile-time constant (undefined cast)
1 error detected.
libxmhfgeec.mk:46: recipe for target 'xmhfgeec_slabmapdef.o' failed
make[1]: *** [xmhfgeec_slabmapdef.o] Error 2

Apparently the line causing this is:
__attribute__ ((section(".stackhdr"))) uint32_t _slab_tos[MAX_PLATFORM_CPUS]= {
but everything looks like a compile-time constant…

I also tried to build and verify an uberxmhf image, but I run into:
/usr/local/uberspark/include/uberspark.h:52:20: fatal error: stdint.h: No such file or directory
while compiling each file, which is strange because stdint.h exists in the include folder and I’m able to compile test files that include stdint.h (not sure if this is because I don’t have the uberspark libraries installed or something to do with the makefile)

Any clues as to what’s causing this? btw I’m running all of this on WSL Ubuntu 16.04.6

Moving this to the appropriate forum area.

@yeeb, can you please provide the following information so we can debug this further?
I am assuming you are working with the “current generation” toolkit.

  1. the branch (master or develop) that you are working with
  2. your complete build console output log for make build-ubersparklibs (you can attach your console output as a text file)
  3. output of ccomp -v

I also tried to build and verify an uberxmhf image, but I run into: …

You will need to install uberspark (including libraries) successfully before being able to build uberXMHF

I’m using the current gen toolkit on the master branch.
Here’s the build output: build_out.txt (135.7 KB)

Apparently ccomp -version: The CompCert C verified compiler, version 3.0.1, but I followed the directions in the uberspark documentation to build version 3.1.

So I rebuilt compcert and ran make instead of just make build-ubersparklibs and everything built without a problem.
ccomp -version is still 3.0.1, but for some reason everything worked this time. I was also able to build the uxmhf image.

I’m not sure if there was something wrong with my initial install of compcert, but that must have been the culprit.

Perfect @yeeb!

I’m not sure if there was something wrong with my initial install of compcert, but that must have been the culprit.

Yeah, I could not reproduce this error on my side either. It seems to work fine for me with both make and make build-ubersparklibs. Just to clarify, can you confirm it works for you now with make build-ubersparklibs as stated in the documentation?

Thanks!

Yep, works with make build-ubersparklibs too!

Ok great!

I think this might just be a case of Compcert not being installed properly the first time.

Thanks!