Received: from maia.hub.org (maia-5.hub.org [200.46.204.29]) by mail.postgresql.org (Postfix) with ESMTP id 9EF0BB5DBC5 for ; Wed, 22 Jun 2011 08:21:36 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.29]) (amavisd-maia, port 10024) with ESMTP id 12273-06 for ; Wed, 22 Jun 2011 11:21:36 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from wwwmaster.postgresql.org (wwwmaster.postgresql.org [217.196.146.204]) by mail.postgresql.org (Postfix) with ESMTP id 0D63AB5D90E for ; Wed, 22 Jun 2011 08:21:35 -0300 (ADT) Received: from wwwmaster.postgresql.org (wwwmaster.postgresql.org [217.196.146.204]) by wwwmaster.postgresql.org (8.14.3/8.14.3) with ESMTP id p5MBLZif063066 for ; Wed, 22 Jun 2011 11:21:35 GMT (envelope-from www@wwwmaster.postgresql.org) Received: (from www@localhost) by wwwmaster.postgresql.org (8.14.3/8.14.3/Submit) id p5MBLZrV063065; Wed, 22 Jun 2011 11:21:35 GMT (envelope-from www) Date: Wed, 22 Jun 2011 11:21:35 GMT Message-Id: <201106221121.p5MBLZrV063065@wwwmaster.postgresql.org> To: pgsql-bugs@postgresql.org Subject: BUG #6073: VPATH build fails in src/backend/replication for src tarball, repl_scanner.c not found From: "Hartmut "Hardy" Raschick" Content-Type: text/plain; charset=utf-8 X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 201106/190 X-Sequence-Number: 30569 The following bug has been logged online: Bug reference: 6073 Logged by: Hartmut "Hardy" Raschick Email address: hartmut.raschick@keymile.com PostgreSQL version: 9.1beta2 Operating system: Solaris Description: VPATH build fails in src/backend/replication for src tarball, repl_scanner.c not found Details: WHAT: postgresql-9.1beta2.tar.bz WHERE: SunOS 5.9 Generic_122300-46 sun4u sparc SUNW,Sun-Fire-V440 GNU Make 3.80 cc: Sun C 5.9 SunOS_sparc Patch 124867-01 2007/07/12 HOW: cd /tmp tar xvjf postgresql-9.1beta2.tar.bz cd postgresql-9.1beta2 mkdir build cd build ../configure ... make /opt/studio12/SUNWspro/bin/cc -Xa -v -O -I../../../src/include -I/tmp/postgresql-9.1beta2/build/../src/include -c -o repl_gram.o /tmp/postgresql-9.1beta2/build/../src/backend/replication/repl_gram.c "repl_gram.y", line 106: warning: enum type mismatch: op "=" "repl_gram.y", line 116: warning: enum type mismatch: op "=" "repl_gram.y", line 161: warning: enum type mismatch: op "=" "repl_gram.y", line 169: cannot find include file: "repl_scanner.c" cc: acomp failed for /tmp/postgresql-9.1beta2/build/../src/backend/replication/repl_gram.c gmake: *** [repl_gram.o] Error 2 FIX: adding CFLAGS += -I$(top_srcdir)/src/backend/replication say, between lines 13 and 15 in src/backend/replication/Makefile fixes this for me; this is surely not the "proper" fix though (seeing flex build and all...). NOTE: "CFLAGS += -I." does not help, as this again is eval'd as the build dir (we want src) NOTE2: Sun's (make that Oracle's) CC apparently does not, as gcc does, implicitly add the current src dir (as seen from -c e.g.) to the list of include dirs...