Bug 58284 - Compiling jvgenmain failes with lots of "undefined reference" errors
Summary: Compiling jvgenmain failes with lots of "undefined reference" errors
Status: UNCONFIRMED
Alias: None
Product: gcc
Classification: Unclassified
Component: java (show other bugs)
Version: 4.7.2
: P3 normal
Target Milestone: ---
Assignee: Not yet assigned to anyone
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-08-30 16:08 UTC by Winston Smith
Modified: 2013-09-02 13:09 UTC (History)
0 users

See Also:
Host: x86_64-unknown-linux-gcc
Target: x86_64-unknown-linux-gcc
Build: x86_64-unknown-linux-gcc
Known to work:
Known to fail:
Last reconfirmed:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Winston Smith 2013-08-30 16:08:32 UTC
I am compiling gcc-4.7.2 with the following configuration:

  $ /root/tmp/gcc-4.7.2/configure --prefix=/usr/ --with-local-prefix=/usr/local/ --with-native-system-header-dir=/usr/include/ --enable-libada --enable-libssp --enable-libquadmath --enable-libgcj --enable-nls --with-included-gettext --enable-fixed-point --enable-shared --enable-threads --enable-bootstrap --enable-languages=all,ada,go,obj-c++ --enable-stage1-languages=all --enable-werror --enable-checking=all --enable-stage1-checking=all --enable-gather-detailed-mem-stats --enable-libgcj-debug

I am getting the following error when compiling jvgenmain:

make[3]: Entering directory `/home/_/gcc-4.7.2-build/gcc'
rm -f jvgenmain
gcc   -g -fkeep-inline-functions -DIN_GCC   -W -Wall -Wwrite-strings -Wcast-qual -Wstrict-prototypes -Wmissing-prototypes -Wmissing-format-attribute -pedantic -Wno-long-long -Wno-variadic-macros -Wno-overlength-strings -Wold-style-definition -Wc++-compat -fno-common  -DHAVE_CONFIG_H  -o jvgenmain java/jvgenmain.o java/mangle_name.o \
	libcommon.a ../libcpp/libcpp.a ./../intl/libintl.a  ../libiberty/libiberty.a ../libdecnumber/libdecnumber.a 
java/jvgenmain.o: In function `VEC_tree_base_last':
/root/tmp/gcc-4.7.2/gcc/vecir.h:28: undefined reference to `vec_assert_fail'
java/jvgenmain.o: In function `VEC_tree_base_index':
/root/tmp/gcc-4.7.2/gcc/vecir.h:28: undefined reference to `vec_assert_fail'
java/jvgenmain.o: In function `VEC_tree_base_space':
/root/tmp/gcc-4.7.2/gcc/vecir.h:28: undefined reference to `vec_assert_fail'
java/jvgenmain.o: In function `VEC_tree_base_splice':
/root/tmp/gcc-4.7.2/gcc/vecir.h:28: undefined reference to `vec_assert_fail'
java/jvgenmain.o: In function `VEC_tree_base_quick_push':
/root/tmp/gcc-4.7.2/gcc/vecir.h:28: undefined reference to `vec_assert_fail'
java/jvgenmain.o:/root/tmp/gcc-4.7.2/gcc/vecir.h:28: more undefined references to `vec_assert_fail' follow
java/jvgenmain.o: In function `VEC_tree_gc_alloc':
/root/tmp/gcc-4.7.2/gcc/vecir.h:29: undefined reference to `vec_gc_p_reserve_exact'
... <lots of such errors, omitted for brevity>
java/mangle_name.o: In function `VEC_method_entry_gc_safe_grow':
/root/tmp/gcc-4.7.2/gcc/java/java-tree.h:873: undefined reference to `vec_assert_fail'
collect2: ld returned 1 exit status
make[3]: *** [jvgenmain] Error 1
make[3]: Leaving directory `/home/_/gcc-4.7.2-build/gcc'
make[2]: *** [all-stage1-gcc] Error 2
make[2]: Leaving directory `/home/_/gcc-4.7.2-build'
make[1]: *** [stage1-bubble] Error 2
make[1]: Leaving directory `/home/_/gcc-4.7.2-build'
make: *** [all] Error 2


Is there anything wrong with the configure arguments that could cause this (I have scanned through the INSTALL directory html pages and could not find anything)? Googling does not seem to help either.

One thing to mention: I am building in a directory in /root/tmp/gcc-4.7.2-build which lives on /, but there wasn't enough free space in that partition, so I symlinked it to /home/_/gcc-4.7.2-build/ (which lives on a different partition). Could this cause the issue?

Thanks.
Comment 1 Winston Smith 2013-08-31 09:45:29 UTC
The same happens if the build dir is not a symlink.
Comment 2 Winston Smith 2013-09-01 09:49:05 UTC
Same error with 4.7.3, but 4.8.1 gets past it. Until it hit http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57900.
Comment 3 Andrew Pinski 2013-09-01 18:03:00 UTC
>--enable-stage1-languages=all

Don't use that, it is not useful really.
Comment 4 Winston Smith 2013-09-02 13:09:58 UTC
I see. Is that the cause for the issue?