Move a couple of initdb's subroutines into src/port/.
authorTom Lane <tgl@sss.pgh.pa.us>
Sat, 11 Dec 2010 00:42:44 +0000 (19:42 -0500)
committerTom Lane <tgl@sss.pgh.pa.us>
Sat, 11 Dec 2010 00:42:44 +0000 (19:42 -0500)
commit671199929d09397e0a60e269aec28846669216db
treee8d7d9c7e49a2f2c6d9c038238f7e7d6124278d2
parent04f4e10cfc158239ca00a6ed6a84428c7acb1e6d
Move a couple of initdb's subroutines into src/port/.

mkdir_p and check_data_dir will be useful in CREATE TABLESPACE, since we
have agreed that that command should handle subdirectory creation just like
initdb creates the PGDATA directory.  Push them into src/port/ so that they
are available to both initdb and the backend.  Rename to pg_mkdir_p and
pg_check_dir, just to be on the safe side.  Add FreeBSD's copyright notice
to pgmkdirp.c, since that's where the code came from originally (this
really should have been in initdb.c).  Very marginal code/comment cleanup.
src/bin/initdb/initdb.c
src/include/port.h
src/port/Makefile
src/port/pgcheckdir.c [new file with mode: 0644]
src/port/pgmkdirp.c [new file with mode: 0644]