linking errors
cnd opened this issue · comments
[83/168] : && /usr/lib64/ccache/bin/x86_64-pc-linux-gnu-g++ -O2 -march=native -mtune=native -pipe -Wl,-O1 -Wl,--as-needed lkg/tmp/skip_to_llvm.gen.o lkg/CMakeFiles/skip_to_llvm.lkg.dir/runtime/native/src/sk_standalone.cpp.o -o lkg/bin/skip_to_llvm lkg/runtime/native/libskip_runtime.a third-party/googletest/libgtest_main.a third-party/install/lib/libfolly.a /usr/lib/libdouble-conversion.so /usr/lib/libgflags.so /usr/lib/libglog.so -ldl /usr/lib/libevent.so /usr/lib/libboost_thread-mt.so /usr/lib/libboost_system-mt.so /usr/lib/libboost_context-mt.so /usr/lib/libboost_filesystem-mt.so /usr/lib/libboost_chrono-mt.so /usr/lib/libboost_date_time-mt.so /usr/lib/libboost_atomic-mt.so -Wl,-rpath,/usr/lib /usr/lib/libunwind.a -lpthread third-party/install/lib/libicutu.a third-party/install/lib/libicuio.a third-party/install/lib/libicui18n.a third-party/install/lib/libicuuc.a third-party/install/lib/libicudata.a -lpcre -lrt /usr/lib/libjemalloc.so && :
FAILED: lkg/bin/skip_to_llvm
: && /usr/lib64/ccache/bin/x86_64-pc-linux-gnu-g++ -O2 -march=native -mtune=native -pipe -Wl,-O1 -Wl,--as-needed lkg/tmp/skip_to_llvm.gen.o lkg/CMakeFiles/skip_to_llvm.lkg.dir/runtime/native/src/sk_standalone.cpp.o -o lkg/bin/skip_to_llvm lkg/runtime/native/libskip_runtime.a third-party/googletest/libgtest_main.a third-party/install/lib/libfolly.a /usr/lib/libdouble-conversion.so /usr/lib/libgflags.so /usr/lib/libglog.so -ldl /usr/lib/libevent.so /usr/lib/libboost_thread-mt.so /usr/lib/libboost_system-mt.so /usr/lib/libboost_context-mt.so /usr/lib/libboost_filesystem-mt.so /usr/lib/libboost_chrono-mt.so /usr/lib/libboost_date_time-mt.so /usr/lib/libboost_atomic-mt.so -Wl,-rpath,/usr/lib /usr/lib/libunwind.a -lpthread third-party/install/lib/libicutu.a third-party/install/lib/libicuio.a third-party/install/lib/libicui18n.a third-party/install/lib/libicuuc.a third-party/install/lib/libicudata.a -lpcre -lrt /usr/lib/libjemalloc.so && :
/usr/lib/gcc/x86_64-pc-linux-gnu/8.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: lkg/tmp/skip_to_llvm.gen.o: in function `sk.Instr__visitInputs':
/Users/joesavona/github/skip-oss/src/native/IR.sk:626: undefined reference to `SKIP_Obstack_note_inl'
/usr/lib/gcc/x86_64-pc-linux-gnu/8.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: lkg/tmp/skip_to_llvm.gen.o: in function `BoolCmpEq__clone':
/Users/joesavona/github/skip-oss/src/native/IR.sk:963: undefined reference to `SKIP_Obstack_note_inl'
/usr/lib/gcc/x86_64-pc-linux-gnu/8.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: lkg/tmp/skip_to_llvm.gen.o: in function `Int::>=<Int>':
/Users/joesavona/github/skip-oss/src/runtime/prelude/core/primitives/Int.sk:82: undefined reference to `SKIP_Obstack_note_inl'
/usr/lib/gcc/x86_64-pc-linux-gnu/8.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: /Users/joesavona/github/skip-oss/src/runtime/prelude/core/primitives/Int.sk:82: undefined reference to `SKIP_Obstack_note_inl'
/usr/lib/gcc/x86_64-pc-linux-gnu/8.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: lkg/tmp/skip_to_llvm.gen.o: in function `Sequence<String>::iterator':
/Users/joesavona/github/skip-oss/src/runtime/prelude/core/language/Sequence.sk:37: undefined reference to `SKIP_Obstack_note_inl'
/usr/lib/gcc/x86_64-pc-linux-gnu/8.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: lkg/tmp/skip_to_llvm.gen.o:/Users/joesavona/github/skip-oss/src/runtime/prelude/core/primitives/Array.sk:303: more undefined references to `SKIP_Obstack_note_inl' follow
collect2: error: ld returned 1 exit status
You probably ran out of memory.
It's going to be difficult for me to debug just like that.
What made me think of an out of memory issue is that I had a similar problem when trying to compile in a docker image.
I realized after the fact that docker has a setting that limits the overall memory that can be used by docker containers (setup to 2 Gigs by default). So I had to go into the GUI menu of my mac to fix it (using the command line -m thing did not help).
What is your config? Are you using ubuntu?
I will need a lot more details to help you here ...
@pikatchu there is ebuild (source based package) I'm trying to use/develop for that project https://github.com/Heather/gentoo-cynede/blob/master/dev-lang/skip/skip-9999.ebuild
Gotcha.
Was anything else failing? How did you run cmake? Was it release or debug?
Could you copy paste what commands you ran? Thanks!
Sorry I am not familiar with ebuild ... But I will try to make sense of it!
I've seen this when the build modes are somehow mismatched - SKIP_Obstack_note_inl only appears as a real symbol in certain cases - it's expected to be inlined in the preamble.ll
cc: @edwinsmith