in ubuntu-14.10_amd64,i compiler smplayer-14.9.0.6690 clang/llvm-3.4. changed makefile in src, like:
cc=clang cxx=clang cflags = -emit-llvm ... cxxflags = -emit-llvm ... link = llvm-link target = smplayer.bc
...
at last got smplayer.bc
. used
$ llvm-dis smplayer.bc -o smplayer.ll $ lli -load=... -load=...... smplayer.ll
but got error:
llvm error: program used external function '__dso_handle' not resolved!
then used clang build bc native executable this:
$ clang smplayer.bc -v -o smplayer.na -m64 -l/usr/lib/x86_64-linux-gnu -lz -lqtdbus -lqtscript -lqtxml -lqtgui -lqtnetwork -lqtcore -lpthread
the error is:
/usr/bin/ld: /tmp/smplayer-7c5fc5.o: undefined reference symbol '__cxa_pure_virtual@@cxxabi_1.3' /usr/lib/x86_64-linux-gnu/libstdc++.so.6: error adding symbols: dso missing command line
try using '-fno-use-cxa-atexit' clang. should rid of use of '__dso_handle'.
http://lists.cs.uiuc.edu/pipermail/llvmdev/2013-january/058748.html
it useful.
Comments
Post a Comment