Discussion:
klee-uclibc not compiling
Double Dave
2013-12-31 21:15:46 UTC
Permalink
Hello all,

i basically followed these instructions on a i686 machine with Xubuntu 12.04:
http://www.pcc.me.uk/~peter/klee-fp/

I could compile llvm and clang,  
but when compiling uclibc with

$ ./configure --with-llvm=/../kleefp/llvm_and_clang/bin
$ make

i get the following error:

  AS libc/sysdeps/linux/x86_64/__longjmp.os
libc/sysdeps/linux/x86_64/__longjmp.S:32:18: error: register %rdi is only available in 64-bit mode
 movq (JB_RBX*8)(%rdi),%rbx
                 ^~~~
...

before that, i did following:
export PATH=$PATH:/../kleefp/llvm_and_clang/bin/Release+Debug+Asserts/bin
export C_INCLUDE_PATH=/usr/include/i386-linux-gnu
export CPLUS_INCLUDE_PATH=/usr/include/i386-linux-gnu

.. resemble the path to my desktop.



what is the cause of that, i mean i know that i have a 32bit machine, but where do i specify that to uclibc.

Regards,

David
Daniel Liew
2014-01-02 13:24:05 UTC
Permalink
Hi Dave,

I don't support that particular variant of klee-uclibc. However you
can probably change the architecture of the build by doing...

$ cd /path/to/root/of/klee-uclibc
$ make menuconfig

Now change the configuration so that the architecture is i386 instead
of x86_64 . This should change a hidden file ".config".

Now clean out the old build files and re-compile.
$ make clean
$ make

Hope that helps.

Thanks,
Dan Liew.
Post by Double Dave
Hello all,
i basically followed these instructions on a i686 machine with Xubuntu
http://www.pcc.me.uk/~peter/klee-fp/
I could compile llvm and clang,
but when compiling uclibc with
$ ./configure --with-llvm=/../kleefp/llvm_and_clang/bin
$ make
AS libc/sysdeps/linux/x86_64/__longjmp.os
libc/sysdeps/linux/x86_64/__longjmp.S:32:18: error: register %rdi is only
available in 64-bit mode
movq (JB_RBX*8)(%rdi),%rbx
^~~~
...
export PATH=$PATH:/../kleefp/llvm_and_clang/bin/Release+Debug+Asserts/bin
export C_INCLUDE_PATH=/usr/include/i386-linux-gnu
export CPLUS_INCLUDE_PATH=/usr/include/i386-linux-gnu
.. resemble the path to my desktop.
what is the cause of that, i mean i know that i have a 32bit machine, but
where do i specify that to uclibc.
Regards,
David
Double Dave
2014-01-07 21:28:47 UTC
Permalink
Thanks Dan,

that helped me a little bit, but then i ran into more errors.

Eventually i could compile klee-fp by following the official klee instructions,  rather than the klee-fp instructions.
I only had to change the  "# LLVM Capable Compiler" part in the Makefile.rules , to this https://llvm.org/viewvc/llvm-project/llvm/trunk/Makefile.rules?diff_format=h&revision=96935.





On Thursday, January 2, 2014 8:24 AM, Daniel Liew <daniel.liew-AQ/***@public.gmane.org> wrote:

Hi Dave,

I don't support that particular variant of klee-uclibc. However you
can probably change the architecture of the build by doing...

$ cd /path/to/root/of/klee-uclibc
$ make menuconfig

Now change the configuration so that the architecture is i386 instead
of x86_64 . This should change a hidden file ".config".

Now clean out the old build files and re-compile.
$ make clean
$ make

Hope that helps.

Thanks,
Dan Liew.
Post by Double Dave
Hello all,
i basically followed these instructions on a i686 machine with Xubuntu
http://www.pcc.me.uk/~peter/klee-fp/
I could compile llvm and clang,
but when compiling uclibc with
$ ./configure --with-llvm=/../kleefp/llvm_and_clang/bin
$ make
  AS libc/sysdeps/linux/x86_64/__longjmp.os
libc/sysdeps/linux/x86_64/__longjmp.S:32:18: error: register %rdi is only
available in 64-bit mode
  movq (JB_RBX*8)(%rdi),%rbx
                  ^~~~
...
export PATH=$PATH:/../kleefp/llvm_and_clang/bin/Release+Debug+Asserts/bin
export C_INCLUDE_PATH=/usr/include/i386-linux-gnu
export CPLUS_INCLUDE_PATH=/usr/include/i386-linux-gnu
.. resemble the path to my desktop.
what is the cause of that, i mean i know that i have a 32bit machine, but
where do i specify that to uclibc.
Regards,
David
Loading...