From: Hasso Tepper Date: Tue, 14 Jul 2009 16:14:15 +0000 (+0300) Subject: Fix randomly seen problems with linking C++ programs. X-Git-Tag: v2.4.0~445^2~2^2 X-Git-Url: https://gitweb.dragonflybsd.org/dragonfly.git/commitdiff_plain/7a045c67fcd319271fea59b66b99c5c979293e59 Fix randomly seen problems with linking C++ programs. Binutils 2.17 supports COMDAT groups and .nsubspa comdat option. It should fix randomly seen linking errors like: `.gnu.linkonce.t.something' referenced in section `.gnu.linkonce.r.something' of some_object: defined in discarded section `.gnu.linkonce.t.something' of some_object. Digged-out-by: corecode@ --- diff --git a/gnu/usr.bin/cc41/cc_prep/dragonfly-native.h b/gnu/usr.bin/cc41/cc_prep/dragonfly-native.h index 25693dc968..05e795c0c8 100644 --- a/gnu/usr.bin/cc41/cc_prep/dragonfly-native.h +++ b/gnu/usr.bin/cc41/cc_prep/dragonfly-native.h @@ -306,7 +306,7 @@ /* Define 0/1 if your assembler and linker support COMDAT groups. */ #ifndef USED_FOR_TARGET -#define HAVE_COMDAT_GROUP 0 +#define HAVE_COMDAT_GROUP 1 #endif @@ -722,7 +722,7 @@ /* Define if your assembler supports .nsubspa comdat option. */ #ifndef USED_FOR_TARGET -/* #undef HAVE_GAS_NSUBSPA_COMDAT */ +#define HAVE_GAS_NSUBSPA_COMDAT 1 #endif