From: | Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us> |
---|---|
To: | Joe Conway <mail(at)joeconway(dot)com> |
Cc: | "Hackers (PostgreSQL)" <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: gcc: unrecognized option `-pthreads' |
Date: | 2004-08-18 19:28:39 |
Message-ID: | 200408181928.i7IJSde25806@candle.pha.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Joe Conway wrote:
> I'm seeing "gcc: unrecognized option `-pthreads'" over and over when
> building from cvs tip.
>
> # pg_config --configure
> '--prefix=/usr/local/pgsql-8.0' '--with-pgport=55435' '--with-perl'
> '--with-tcl' '--with-tclconfig=/usr/lib' '--without-tk' '--with-python'
> '--enable-nls' '--enable-debug' '--enable-cassert' '--enable-depend'
> '--with-pam' '--enable-integer-datetimes' '--enable-thread-safety'
> '--with-openssl' '--with-krb5' '--with-includes=/usr/include/kerberosIV'
> '--with-includes=/usr/include/et'
>
> # uname -a
> Linux jec-linux-lt 2.6.7-1.494.2.2 #1 Tue Aug 3 09:39:58 EDT 2004 i686
> i686 i386 GNU/Linux
Yep, I see that too:
gcc -O2 -fno-strict-aliasing -Wall -Wmissing-prototypes -Wmissing-declarations -O1 -Wall -Wmissing-prototypes -Wmissing-declarations -Wpointer-arith -Wcast-align -Kthread -kthread -pthread -pthreads -D_REENTRANT -D_THREAD_SAFE -D_POSIX_PTHREAD_SEMANTICS -fpic -I. -I../../../src/include -I/usr/local/include/readline -I/usr/contrib/include -I../../../src/port -DFRONTEND -c -o fe-auth.o fe-auth.c
gcc: unrecognized option `-Kthread'
gcc: unrecognized option `-kthread'
gcc: unrecognized option `-pthreads'
What is happening is that config/acx_pthread.m4 is now adding any option
that allows it to compile, so we get -pthread and -lpthread for Linux,
among other things.
The problem is that for certain flags, gcc reports the option as
unrecognized, but doesn't generate an error. I can't think of how to
check for such output from the compiler from configure.
--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 359-1001
+ If your life is a hard drive, | 13 Roberts Road
+ Christ can be your backup. | Newtown Square, Pennsylvania 19073
From | Date | Subject | |
---|---|---|---|
Next Message | Andreas Pflug | 2004-08-18 20:43:56 | PGPASSWORD and client tools |
Previous Message | Bruce Momjian | 2004-08-18 18:38:06 | Re: initdb failure on win32 |