howto: install posgresql on darwin/osxpb

Поиск
Список
Период
Сортировка
От Bruce Hartzler
Тема howto: install posgresql on darwin/osxpb
Дата
Msg-id E13nHNR-0003Xu-00@smtp03.mrf.mail.rcn.net
обсуждение исходный текст
Ответы Re: howto: install posgresql on darwin/osxpb  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
<flushleft><fontfamily><param>Helvetica</param><x-tabstops><param>72L;144L;216L;288L;360L;0L;</param>Here's a patch to
getpostgresql up and running (I've only tested it on PB w/ dev tools but it should work on Darwin as well). It's very
roughbut I thought I'd put it up for those of you who are interested. If anyone has suggestions or help for some of the
remainingissues listed below, please email me. Thanks. 


http://www.gerga.com/pg_darwin_patch.tar.gz


to install:


wget ftp://ftp.postgresql.org/pub/v7.0.2/postgresql-7.0.2.tar.gz

wget http://www.gerga.com/pg_darwin_patch.tar.gz

tar xzvf postgresql-7.0.2.tar.gz

tar xzvf pg_darwin_patch.tar.gz

cd postgresql-7.0.2

patch -p1 << ../pg_darwin_patch


(WARNING! You need to put a symlink in your /usr/include/sys dir to sem.h. OSXPB doesn't have the sysv semaphore
implementationincluded but it seems to be in the newer kernels -- so check before you clobber something you might
alreadyhave. I'm currently just using the qnx semaphore port but this should probably be removed when Apple's semaphore
implementationarrives.) 


ln -s `pwd`/src/backend/port/darwin/sem.h /usr/include/sys/sem.h


cd src

./configure --without-CXX -with-perl

(c++ lib needs to be hacked; perl seems to work; I haven't really tried other options yet.)

make

make install


these default paths help:


export DYLD_LIBRARY_PATH="${DYLD_LIBRARY_PATH}:/usr/local/pgsql/lib"

export PGDATA="/usr/local/pgsql/data"

export PGLIB="/usr/local/pgsql/lib"


read postgresql-7.0.2/INSTALL for setting up the postmaster and getting things going.

(initdb /usr/local/pgsql/data; postmaster)


for the regression tests:

cd postgres-7.0.2/src/tests/regress

make

make runtest

(int2 & int4 will "fail" because of different error messages)

(geometry "fails" because 0 != -0 for some reason)



some issues/problems:


- if you try to load a badly made dynamic library, you will get an error like:

dyld: /usr/local/pgsql/bin/./postmaster Undefined symbols:

dyld_stub_binding_helper

Server process (pid 8932) exited with status 17152 at Sun Oct 22 00:41:22 2000

Terminating any active server processes...

Server processes were terminated at Sun Oct 22 00:41:22 2000

Reinitializing shared memory and semaphores


Need to fix/make the error routine in src/backend/port/dynloader/darwin.c?


-running the regression tests more than once seems to corrupt the database. it can't be dropped or created the second
time.I I haven't found a way to get rid of it beside re-initdb-ing the data directory which isn't a very useful
solutionat all. ideas/suggestions? 


- there may be semaphore/shared memory leaking going on. the routines are a bit of a cludge and the postgres ipcclean
utilityneeds ipcs. is there an osx equivalent?  


- when compiled with any -O, the following regression tests fail:

oidjoins .. failed

type_sanity .. failed

opr_sanity .. failed

<x-tabstops><param>28L;56L;84L;112L;140L;168L;196L;224L;252L;280L;308L;336L;</param>
</x-tabstops></x-tabstops></fontfamily></flushleft>

В списке pgsql-hackers по дате отправления:

Предыдущее
От: Tatsuo Ishii
Дата:
Сообщение: Re: incompatible changes of PQsetdbLogin()
Следующее
От: Tom Lane
Дата:
Сообщение: Re: howto: install posgresql on darwin/osxpb