Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot build binutils #28

Closed
lmrs2 opened this issue Jan 29, 2019 · 2 comments
Closed

Cannot build binutils #28

lmrs2 opened this issue Jan 29, 2019 · 2 comments

Comments

@lmrs2
Copy link

lmrs2 commented Jan 29, 2019

Hi

I am trying out your fuzzer, thanks for making it open source! I'm running into troubles when compiling binutils. See steps below to reproduce:

wget https://ftp.gnu.org/gnu/binutils/binutils-2.27.tar.gz
tar xvzf binutils-2.27.tar.gz && cd binutils-2.27
mkdir build && cd build
CC=$ANGORA_DIR/bin/angora-clang CXX=$ANGORA_DIR/bin/angora-clang++ LD=$ANGORA_DIR/bin/angora-clang ../configure --disable-shared --disable-nls --disable-werror --disable-gdb --disable-libdecnumber --disable-readline --disable-sim
USE_TRACK=1 make

[...]

make[3]: Entering directory /path/to/angora/binutils-2.27/build/bfd/doc' /path/to/angora/Angora/bin/angora-clang -o chw$$ -g -O2 \ -I.. -I../../../bfd/doc/.. -I../../../bfd/doc/../../include -I../../../bfd/doc/../../intl -I../../intl ../../../bfd/doc/chew.c; \ /bin/bash ../../../bfd/doc/../../move-if-change \ chw$$ chew; \ touch chew.stamp angora-llvm-pass [+] Track Mode. ModName: ../../../bfd/doc/chew.c -- 200537235 ./chew -f ../../../bfd/doc/doc.str < ../../../bfd/doc/../aoutx.h >aoutx.tmp /bin/bash: line 1: 20940 Segmentation fault ./chew -f ../../../bfd/doc/doc.str < ../../../bfd/doc/../aoutx.h > aoutx.tmp make[3]: *** [aoutx.stamp] Error 139 make[3]: Leaving directory /path/to/angora/binutils-2.27/build/bfd/doc'
make[2]: *** [info-recursive] Error 1
make[2]: Leaving directory /path/to/angora/binutils-2.27/build/bfd' make[1]: *** [all-bfd] Error 2 make[1]: Leaving directory /path/to/angora/binutils-2.27/build'
make: *** [all] Error 2


Note: Using USE_FAST=1 works. I've not had time to troubleshoot myself...

@spinpx
Copy link
Member

spinpx commented Jan 30, 2019

Thank you for your feedback. I am still debugging this issue. It seems I modify something wrong in my llvm pass or dfsan pass.

There are some other ways to bypass this issue.

  • use gllvm & wllvm, I use this way to compile it now. see build angora by wllm
  • or remove doc generation in binutils.
find . -name "Makefile*" -exec sed -i 's/SUBDIRS\s=\sdoc\spo/SUBDIRS =po/' {} + 
  • or try to remove CXX=$ANGORA_DIR/bin/angora-clang++

I hope these can help you.

@lmrs2
Copy link
Author

lmrs2 commented Feb 1, 2019

compiling with gllvm worked.

@lmrs2 lmrs2 closed this as completed Feb 1, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants