Michelle Caisse wrote: > Also, two tests fail with the following diff when the build is > configured with --enable-coverage. > RETURNS trigger > AS > '/home/michelle/trunkClean/pgsql/src/test/regress/../../../contrib/spi/refi >nt.so' LANGUAGE C; > + ERROR: could not load library > "/home/michelle/trunkClean/pgsql/src/test/regress/../../../contrib/spi/refi >nt.so": > /home/michelle/trunkClean/pgsql/src/test/regress/../../../contrib/spi/refin >t.so: undefined symbol: __gcov_merge_add
The reason for that problem is that the shared object needs to be linked with -fprofile-arcs -ftest-coverage. (One of these causes -lgcov to be linked, which includes the missing symbol.) This is not done because the shared object link rules don't use CFLAGS. I think for most platforms it would actually be more correct to use CFLAGS in linking. There may be the odd exception, but usually CFLAGS contains some assortment of -O, -g, -W, and maybe -f options, which should do more good than harm when linking. Any concerns about selectively adding CFLAGS to shared library linking rules? -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers