Thread: compile error

compile error

From
Soma Interesting
Date:
I'm attempting to recompile postgres with perl support. Perl compiled fine,
however postgres insists on compiling with odbc...

I'm getting the following error when I attempt to ./configure

linking ./include/port to interfaces/odbc/port
mkdir: cannot create directory `interfaces/odbc': No such file or directory
ln: ./include/port: hard link not allowed for directory
configure: error: can not link interfaces/odbc/port to ./include/port

using the following ./configure statement:

./configure --prefix=/usr/lib/pgsql --with-perl --enable-multibyte
--with-odbc=no

I only added the --with-odbc=no, after it gave the above error. Compiling
is pretty new to me, so its probably something simple that I'm doing wrong.


Re: compile error

From
Soma Interesting
Date:
At 11:03 AM 4/2/2001 -0700, you wrote:
>linking ./include/port to interfaces/odbc/port
>mkdir: cannot create directory `interfaces/odbc': No such file or directory
>ln: ./include/port: hard link not allowed for directory
>configure: error: can not link interfaces/odbc/port to ./include/port

Ok, that error was because I'd only installed postgres from the base
archive. Silly me.

However this error... who knows....

Pg.xs: In function `XS_Pg_PQprint':
Pg.xs:584: `na' undeclared (first use in this function)
Pg.xs:584: (Each undeclared identifier is reported only once
Pg.xs:584: for each function it appears in.)
Pg.xs: In function `XS_PG_results_fetchrow':
Pg.xs:1255: `sv_undef' undeclared (first use in this function)
Pg.xs: In function `XS_PG_results_print':
Pg.xs:1295: `na' undeclared (first use in this function)
make[2]: *** [Pg.o] Error 1
make[2]: Leaving directory `/home/dfunct/postgresql-7.0.3/src/interfaces/perl5'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/home/dfunct/postgresql-7.0.3/src/interfaces'
make: *** [all] Error 2

Judging by the mailing list archives, lots of people have ran into this,
but none received answers. (why is it searching the mailing list on
anything 75% of the time returns multiple people asking the same thing with
no answers in the thread?).


Re: compile error

From
Tom Lane
Date:
Soma Interesting <dfunct@telus.net> writes:
> Judging by the mailing list archives, lots of people have ran into this,
> but none received answers.

You must not have looked in the right threads.

If you're building interfaces/perl5 by hand (ie, not letting
src/interfaces/Makefile do it for you) then you need to say

    perl Makefile.PL POLLUTE=1

which is what the Makefile does (at least in recent releases).

This is fixed in 7.1, but earlier releases need the "POLLUTE=1".

            regards, tom lane

Re: compile error

From
Soma Interesting
Date:
At 06:38 PM 4/2/2001 -0400, you wrote:
>Soma Interesting <dfunct@telus.net> writes:
> > Judging by the mailing list archives, lots of people have ran into this,
> > but none received answers.
>
>You must not have looked in the right threads.
>
>If you're building interfaces/perl5 by hand (ie, not letting
>src/interfaces/Makefile do it for you) then you need to say
>
>         perl Makefile.PL POLLUTE=1
>
>which is what the Makefile does (at least in recent releases).
>
>This is fixed in 7.1, but earlier releases need the "POLLUTE=1".
>
>                         regards, tom lane

Thanks, Tom. One last hurdle (yeah right),

I copied plperl.so into the same folder as plpgsql.so (/usr/lib/pgsql/lib).
Then ran createlang --PGLIB=/usr/lib/pgsql/lib plperl database_name and got
no errors.

I then wrote a hello world plperl function and called it but got this error:

ERROR:  Load of file /usr/lib/pgsql/lib/plperl.so failed: libperl.so:
cannot open shared object file: No such file or directory.


Re: compile error

From
Tom Lane
Date:
Soma Interesting <dfunct@telus.net> writes:
> ERROR:  Load of file /usr/lib/pgsql/lib/plperl.so failed: libperl.so:
> cannot open shared object file: No such file or directory.

Is libperl.so known to your dynamic linker?  It has to be found via
LD_LIBRARY_PATH, /etc/ld.so.conf, or local equivalent.

            regards, tom lane