Subject: Re: Problems with pkgsrc or compiling PostgreSQL
To: Marten Karl <marten@milkbar.ul.bawue.de>
From: Joseph A. Dacuma <jadacuma@ched.gov.ph>
List: netbsd-help
Date: 07/24/2007 22:30:48
> Hello.
>
> I want to have postgresql82 on my NetBSD 3.1 sytem (running on an alpha
> system). There was no real problem to get it on my system. Jump
> into /usr/pkgsrc/databases/postgresql82, doing make an make install,
> finding
> how to start at boot time et voila, it's running nice.
>
> But then I found out, that the language plpythonu could not be created.
> Even
> not after make;make install in
> /usr/pkgsrc/databases/postgresql82-plpython.
>
> I found my problem as I do not know how to set options for the make
> process. A
> hopeless -Dplpython was not successful. I have gone through the pkgsrc
> manual. But when I tried the shown possibility to find out about options
> the
> makefile says: Not options supported.
> In the file Makefile.common I found the line:
> CONFIGURE_ARGS+=    --without-python
>
> Here I think the problem is, but how to resolve? I even tried to comment
> out
> the line in the Makefile (with bad feeling in the stomach as I do not
> think
> Makefile editing is the right way). Also a -Dwith-python or a
> --with-python
> does not help. So I'm sitting around with a nice database management
> system,
> but without my functions it is not even half of the fun.
>
> After a search through the internet (at least some part of it) it seems to
> me
> that I'm the only one with this problem.
>
> But to cut the long story short, two questions:
> 1. How to compile python support into postgresql?
> 2. Am I on the right way to solve the problem or missed I some important
> source around postgresql an NetBSD or the pkgsrc-system on NetBSD?
>

What exactly do you want to do with your Postgres DB? If you want to add
Python interface to PostgreSQL, try py-postgresql also under the databases
directory of pkgsrc.

If you want to set options using pkgsrc you can simply invoke the command
"make show-options" and follow the instructions (usually pointing to
mk.conf for changes). However, postgresql82 from the looks of it does not
use options framework even the plpython variant. Also, please note that
PL/Python  has security issues with it, it doesnt have any restrictions
for safe user execution.

Lastly, -D option if I remember correctly, was for FreeBSD ports of old.
You can refer to this link written by Mr. Alistair Crooks and Mr. Hubert
Feyrer:

http://www.netbsd.org/docs/pkgsrc/

HTH,

Joseph