supranational / supra_seal

Apache License 2.0
32 stars 21 forks source link

build failed #1

Closed eleven-pixel closed 1 year ago

eleven-pixel commented 1 year ago

/filecoin/supra_seal$ ./build.sh

dot-asm commented 1 year ago

This looks very much like an out-of-date compiler. What's your system? Either way, there are two possible outcomes. We either try to make it work on older systems, or simply declare that it's supported on Ubuntu >=22 (or maybe >=20) or equivalent. Provided that it's a rather specialized application, it doesn't make much sense to invest an effort in the former... It might be sensible to enforce a minimum C++ standard compliance level, but it would still be "if there still is a problem, point to the reference platform in the README.md."

dot-asm commented 1 year ago

It might be sensible to enforce a minimum C++ standard compliance level

For reference, as following:

index 171b518..da083db 100755
--- a/build.sh
+++ b/build.sh
@@ -16,10 +16,12 @@ NVCC=${NVCC:-nvcc}
 CUDA=$(dirname $(dirname $(which $NVCC)))
 SPDK="deps/spdk-v22.09"
 CUDA_ARCH="-arch=sm_80 -gencode arch=compute_70,code=sm_70"
+CXXSTD=`$CXX -dM -E -x c++ /dev/null | \
+        awk '{ if($2=="__cplusplus" && $3<"2011") print "-std=c++11"; }'`

 INCLUDE="-I$SPDK/include -I$SPDK/isa-l/.. -I$SPDK/dpdk/build/include"
 CFLAGS="$SECTOR_SIZE -O2 -g $INCLUDE -D__ADX__"
-CPPFLAGS="$CFLAGS \
+CPPFLAGS="$CFLAGS $CXXSTD \
           -fno-omit-frame-pointer -Wall -Wextra -Wno-unused-parameter \
           -Wno-missing-field-initializers -fno-strict-aliasing \
           -march=native -Wformat -Wformat-security \
dot-asm commented 1 year ago

It's likely to be fixed by #6. Or at least there is hardly anything else we can offer.