------- Comment #9 from kargl at gcc dot gnu dot org 2010-07-16 04:28 -------
(In reply to comment #6)
> Please don't keep reopening this bug.
> The symbols are weak undefs because libgfortran doesn't require (and shouldn't
> require) libpthread, it is thread-safe only when libpthread is linked in.
>
After reviewing the thread (and recalling others along this line),
Jakub, if you want to make the combination of -static -fopenmp
a fatal error for gfortran, a patch is pre-approved. Something
like
Index: options.c
===================================================================
--- options.c (revision 161930)
+++ options.c (working copy)
@@ -390,6 +390,9 @@ gfc_post_options (const char **pfilename
if (pedantic && gfc_option.flag_whole_file)
gfc_option.flag_whole_file = 2;
+ if (gfc_option.flag_openmp && THE_STATIC_FLAG)
+ gfc_fatal_error ("Conflicting options -fopenmp and -static");
+
gfc_cpp_post_options ();
/* FIXME: return gfc_cpp_preprocess_only ();
where I could not find the right flag for THE_STATIC_FLAG.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44927