No bison and NAMEDATALEN > 31: initdb failure? - Mailing list pgsql-hackers

From Ian Barwick
Subject No bison and NAMEDATALEN > 31: initdb failure?
Date
Msg-id 200207300011.47378.barwick@gmx.net
Whole thread Raw
Responses Re: No bison and NAMEDATALEN > 31: initdb failure?
List pgsql-hackers
I had occasion (and a perfectly good reason) to install 7.1.3 on
a fresh server [1]. Installation succeeded as normal, data failed
to load because some relation names go beyond
31 characters. <smack forehead>, alter NAMEDATALEN,
recompile. initdb fails immediately after the message
"creating template1 database in...". There followed much
wrinkling of brows, gnashing of directories, recompilation from afresh
etcera, during the course of which I noticed the following output from
configure:
configure: warning:
*** Without Bison you will not be able to build PostgreSQL from CVS or
*** change any of the parser definition files.  You can obtain Bison from
*** a GNU mirror site.  (If you are using the official distribution of
*** PostgreSQL then you do not need to worry about this because the Bison
*** output is pre-generated.)  To use a different yacc program (possible,
*** but not recommended), set the environment variable YACC before running
*** 'configure'.

This being because I had omitted to install Bison. As I wasn't building from
CVS, and mucking around with the parser definition files was not high on
my list of priorities, it was only much later I hit on the idea of installing
Bison, then rebuilding with higher NAMEDATALEN. And as if by magic
initdb succeeded. (Note: initdb with no Bison but unchanged NAMEDATALEN
also succeeded).

For reference, 7.2.1 exhibits exactly the same behaviour [2]. I have poked
around but have no idea what I'm looking for, so I'm not sure if this
is intended behaviour.

Questions:
- Does src/include/postgres_ext.h count as a parser definition file?
- If not shouldn't the above warning include something like "And don't even think about changing NAMEDATALEN"?

Apologies if I've missed something obvious.


Ian Barwick
barwick@gmx.net


[1] FreeBSD 4.6, installing from source
[2] Sample output from initdb:

ian > /home/ian/devel/postgres/pg721a/bin/initdb -D /tmp/pg721
The files belonging to this database system will be owned by user "ian".
This user must also own the server process.

creating directory /tmp/pg721... ok
creating directory /tmp/pg721/base... ok
creating directory /tmp/pg721/global... ok
creating directory /tmp/pg721/pg_xlog... ok
creating directory /tmp/pg721/pg_clog... ok
creating template1 database in /tmp/pg721/base/1...
initdb failed.
Removing /tmp/pg721.




pgsql-hackers by date:

Previous
From: Marc Lavergne
Date:
Subject: Re: outer join help...
Next
From: Bruce Momjian
Date:
Subject: Re: That CREATE OPERATOR CLASS patch