Re: Compile error while building postgresql 10.3

From: Terry Phelps <tgphelps50(at)gmail(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Andres Freund <andres(at)anarazel(dot)de>, pgsql-hackers(at)lists(dot)postgresql(dot)org
Subject: Re: Compile error while building postgresql 10.3
Date: 2018-03-19 20:07:17
Message-ID: CAMUfR_v_3=fUTe-bD1BFs_FhzDq5Ci_UZOcRULbT27JD1a0jWA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin pgsql-hackers

I did:
cd src/port
gmake -s clean
gmake

It says:

gmake -C ../backend submake-errcodes
gmake[1]: Entering directory '/usr/home/tgphelps/postgresql/src/backend'
gmake[1]: Nothing to be done for 'submake-errcodes'.
gmake[1]: Leaving directory '/usr/home/tgphelps/postgresql/src/backend'
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -msse4.2 -I../../src/port -DFRONTEND
-I../../src/include -c -o pg_crc32c_sse42.o pg_crc32c_sse42.c
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -DFRONTEND -I../../src/include -c
-o pg_crc32c_sb8.o pg_crc32c_sb8.c
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -DFRONTEND -I../../src/include -c
-o pg_crc32c_choose.o pg_crc32c_choose.c
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -DFRONTEND -I../../src/include -c
-o chklocale.o chklocale.c
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -DFRONTEND -I../../src/include -c
-o erand48.o erand48.c
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -DFRONTEND -I../../src/include -c
-o inet_net_ntop.o inet_net_ntop.c
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -DFRONTEND -I../../src/include -c
-o noblock.o noblock.c
echo "#define PGBINDIR \"/usr/local/pgsql/bin\"" >pg_config_paths.h
echo "#define PGSHAREDIR \"/usr/local/pgsql/share\"" >>pg_config_paths.h
echo "#define SYSCONFDIR \"/usr/local/pgsql/etc\"" >>pg_config_paths.h
echo "#define INCLUDEDIR \"/usr/local/pgsql/include\"" >>pg_config_paths.h
echo "#define PKGINCLUDEDIR \"/usr/local/pgsql/include\""
>>pg_config_paths.h
echo "#define INCLUDEDIRSERVER \"/usr/local/pgsql/include/server\""
>>pg_config_paths.h
echo "#define LIBDIR \"/usr/local/pgsql/lib\"" >>pg_config_paths.h
echo "#define PKGLIBDIR \"/usr/local/pgsql/lib\"" >>pg_config_paths.h
echo "#define LOCALEDIR \"/usr/local/pgsql/share/locale\""
>>pg_config_paths.h
echo "#define DOCDIR \"/usr/local/pgsql/share/doc/\"" >>pg_config_paths.h
echo "#define HTMLDIR \"/usr/local/pgsql/share/doc/\"" >>pg_config_paths.h
echo "#define MANDIR \"/usr/local/pgsql/share/man\"" >>pg_config_paths.h
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -DFRONTEND -I../../src/include -c
-o path.o path.c
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -DFRONTEND -I../../src/include -c
-o pgcheckdir.o pgcheckdir.c
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -DFRONTEND -I../../src/include -c
-o pgmkdirp.o pgmkdirp.c
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -DFRONTEND -I../../src/include -c
-o pgsleep.o pgsleep.c
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -DFRONTEND -I../../src/include -c
-o pgstrcasecmp.o pgstrcasecmp.c
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -DFRONTEND -I../../src/include -c
-o pqsignal.o pqsignal.c
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -DFRONTEND -I../../src/include -c
-o qsort.o qsort.c
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -DFRONTEND -I../../src/include -c
-o qsort_arg.o qsort_arg.c
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -DFRONTEND -I../../src/include -c
-o quotes.o quotes.c
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -DFRONTEND -I../../src/include -c
-o sprompt.o sprompt.c
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -DFRONTEND -I../../src/include -c
-o tar.o tar.c
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -D_THREAD_SAFE -pthread -D_REENTRANT -D_THREAD_SAFE
-D_POSIX_PTHREAD_SEMANTICS -I../../src/port -DFRONTEND
-I../../src/include -c -o thread.o thread.c
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -DFRONTEND -I../../src/include -c
-o pg_strong_random.o pg_strong_random.c
rm -f libpgport.a
ar cr libpgport.a pg_crc32c_sse42.o pg_crc32c_sb8.o pg_crc32c_choose.o
chklocale.o erand48.o inet_net_ntop.o noblock.o path.o pgcheckdir.o
pgmkdirp.o pgsleep.o pgstrcasecmp.o pqsignal.o qsort.o qsort_arg.o quotes.o
sprompt.o tar.o thread.o pg_strong_random.o
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -msse4.2 -I../../src/port -I../../src/include -c
pg_crc32c_sse42.c -o pg_crc32c_sse42_srv.o
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -I../../src/include -c
pg_crc32c_sb8.c -o pg_crc32c_sb8_srv.o
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -I../../src/include -c
pg_crc32c_choose.c -o pg_crc32c_choose_srv.o
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -I../../src/include -c
chklocale.c -o chklocale_srv.o
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -I../../src/include -c erand48.c
-o erand48_srv.o
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -I../../src/include -c
inet_net_ntop.c -o inet_net_ntop_srv.o
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -I../../src/include -c noblock.c
-o noblock_srv.o
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -I../../src/include -c path.c -o
path_srv.o
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -I../../src/include -c
pgcheckdir.c -o pgcheckdir_srv.o
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -I../../src/include -c pgmkdirp.c
-o pgmkdirp_srv.o
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -I../../src/include -c pgsleep.c
-o pgsleep_srv.o
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -I../../src/include -c
pgstrcasecmp.c -o pgstrcasecmp_srv.o
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -I../../src/include -c pqsignal.c
-o pqsignal_srv.o
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -I../../src/include -c qsort.c -o
qsort_srv.o
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -I../../src/include -c
qsort_arg.c -o qsort_arg_srv.o
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -I../../src/include -c quotes.c
-o quotes_srv.o
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -I../../src/include -c sprompt.c
-o sprompt_srv.o
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -I../../src/include -c tar.c -o
tar_srv.o
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -I../../src/include -c thread.c
-o thread_srv.o
cc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement
-Wendif-labels -Wmissing-format-attribute -Wformat-security
-fno-strict-aliasing -fwrapv -Wno-unused-command-line-argument
-I/usr/local/include -I../../src/port -I../../src/include -c
pg_strong_random.c -o pg_strong_random_srv.o
rm -f libpgport_srv.a
ar cr libpgport_srv.a pg_crc32c_sse42_srv.o pg_crc32c_sb8_srv.o
pg_crc32c_choose_srv.o chklocale_srv.o erand48_srv.o inet_net_ntop_srv.o
noblock_srv.o path_srv.o pgcheckdir_srv.o pgmkdirp_srv.o pgsleep_srv.o
pgstrcasecmp_srv.o pqsignal_srv.o qsort_srv.o qsort_arg_srv.o quotes_srv.o
sprompt_srv.o tar_srv.o thread_srv.o pg_strong_random_srv.o

On Mon, Mar 19, 2018 at 4:01 PM, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:

> Andres Freund <andres(at)anarazel(dot)de> writes:
> > There seems to be something sketchy afoot here, even outside of
> > CFLAGS_SSE42 itself. From the original email:
>
> > cc -I/usr/local/include -I../../src/port -DFRONTEND -I../../src/include
> > -c -o pg_crc32c_sse42.o pg_crc32c_sse42.c
>
> > isn't this missing a number of important flags? Like at least
> > -fno-strict-aliasing -fwrapv -fexcess-precision=standard?
>
> Good point ... seems like we lost *all* CFLAGS not just the SSE42 ones.
> I believe the options we see here are all from CPPFLAGS not CFLAGS.
>
> Terry, could we see a full "make" trace from src/port/? Something like
>
> cd src/port
> make -s clean
> make
>
> I'm curious whether the flags lossage affects all .c files in that
> directory, or only ones that are trying to add on custom flags.
>
> regards, tom lane
>

In response to

Responses

Browse pgsql-admin by date

  From Date Subject
Next Message Andres Freund 2018-03-19 20:11:38 Re: Compile error while building postgresql 10.3
Previous Message Terry Phelps 2018-03-19 20:03:46 Re: Compile error while building postgresql 10.3

Browse pgsql-hackers by date

  From Date Subject
Next Message Andres Freund 2018-03-19 20:11:38 Re: Compile error while building postgresql 10.3
Previous Message Terry Phelps 2018-03-19 20:03:46 Re: Compile error while building postgresql 10.3