pg.ddx.io pgsql-admin@postgresql.org mailing list archive
help / color / mirror / Atom feedproblem while compiling user c functions in 7.1beta4
6+ messages / 3 participants
[nested] [flat]
* problem while compiling user c functions in 7.1beta4
@ 2001-02-22 07:28 hubert depesz lubaczewski <depesz@depesz.pl>
2001-02-22 09:21 ` Re: [GENERAL] problem while compiling user c functions in 7.1beta4 Christopher Sawtell <csawtell@xtra.co.nz>
0 siblings, 1 reply; 6+ messages in thread
From: hubert depesz lubaczewski @ 2001-02-22 07:28 UTC (permalink / raw)
To: pgsql-general@postgresql.org; +Cc: pgsql-admin; pgsql-hackers@postgresql.org
hi,
i have functin which did compile on 7.0.3 and 7.1beta1, and now it doesn't.
it includes were:
#include <stdio.h>
#include <string.h>
#include <ctype.h>
#include <postgres.h>
since in 7.1beta4 there is no postgres.h i changed this to:
#include <stdio.h>
#include <string.h>
#include <ctype.h>
#include <c.h>
all i need this for is to have type declarations, and postgresql versions of
malloc, realloc and free - i.e. i dont use spi.
when compiling i get this errors:
gcc -O2 -Wall -ansi -I "/home/users/pgdba/work/include/postgresql/" -c dfti.c
-fpic
In file included from dfti.c:4:
/home/users/pgdba/work/include/postgresql/c.h:312: parse error before `regproc'
/home/users/pgdba/work/include/postgresql/c.h:312: warning: type defaults to `int' in declaration of `regproc'
/home/users/pgdba/work/include/postgresql/c.h:312: warning: data definition has no type or storage class
/home/users/pgdba/work/include/postgresql/c.h:313: parse error before `RegProcedure'
/home/users/pgdba/work/include/postgresql/c.h:313: warning: type defaults to `int' in declaration of `RegProcedure'
/home/users/pgdba/work/include/postgresql/c.h:313: warning: data definition has no type or storage class
/home/users/pgdba/work/include/postgresql/c.h:364: parse error before `oidvector'
/home/users/pgdba/work/include/postgresql/c.h:364: warning: type defaults to `int' in declaration of `oidvector'
/home/users/pgdba/work/include/postgresql/c.h:364: warning: data definition has no type or storage class
/home/users/pgdba/work/include/postgresql/c.h:373: `NAMEDATALEN' undeclared here (not in a function)
dfti.c: In function `empty_text':
dfti.c:16: warning: implicit declaration of function `palloc'
dfti.c: In function `dfti_prepare':
dfti.c:37: warning: implicit declaration of function `elog'
dfti.c:37: `ERROR' undeclared (first use in this function)
dfti.c:37: (Each undeclared identifier is reported only once
dfti.c:37: for each function it appears in.)
dfti.c:84: warning: implicit declaration of function `repalloc'
dfti.c:86: warning: implicit declaration of function `pfree'
my knowledge of c is extremly limited, so i can't work on those errors.
my postgresql is build from cvs snapshot taken 21th of february 11:23.
can anyone help me with this?
depesz
p.s. i'm not posting the whole function code since it's ugly, long and it *did*
work (without warnings) with previous persions.
--
hubert depesz lubaczewski http://www.depesz.pl/
------------------------------------------------------------------------
najwspanialszą rzeczą jaką dało nam nowoczesne społeczeństwo,
jest niesamowita wręcz łatwość unikania kontaktów z nim ...
^ permalink raw reply [nested|flat] 6+ messages in thread
* Re: [GENERAL] problem while compiling user c functions in 7.1beta4
2001-02-22 07:28 problem while compiling user c functions in 7.1beta4 hubert depesz lubaczewski <depesz@depesz.pl>
@ 2001-02-22 09:21 ` Christopher Sawtell <csawtell@xtra.co.nz>
2001-02-22 09:39 ` Re: problem while compiling user c functions in 7.1beta4 hubert depesz lubaczewski <depesz@depesz.pl>
0 siblings, 1 reply; 6+ messages in thread
From: Christopher Sawtell @ 2001-02-22 09:21 UTC (permalink / raw)
To: hubert depesz lubaczewski <depesz@depesz.pl>; pgsql-general@postgresql.org; +Cc: pgsql-admin; pgsql-hackers@postgresql.org
On Thu, 22 Feb 2001 20:28, hubert depesz lubaczewski wrote:
> since in 7.1beta4 there is no postgres.h i changed this to:
I did a cvsup update about 12 hours ago and look:-
22:05:23 chris@berty:/usr/src/cvs/pgsql $ find . -name postgres.h
./src/include/postgres.h
22:16:22 chris@berty:/usr/src/cvs/pgsql $
--
Sincerely etc.,
NAME Christopher Sawtell
CELL PHONE 021 257 4451
ICQ UIN 45863470
EMAIL csawtell @ xtra . co . nz
CNOTES ftp://ftp.funet.fi/pub/languages/C/tutorials/sawtell_C.tar.gz
-->> Please refrain from using HTML or WORD attachments in e-mails to me
<<--
^ permalink raw reply [nested|flat] 6+ messages in thread
* Re: problem while compiling user c functions in 7.1beta4
2001-02-22 07:28 problem while compiling user c functions in 7.1beta4 hubert depesz lubaczewski <depesz@depesz.pl>
2001-02-22 09:21 ` Re: [GENERAL] problem while compiling user c functions in 7.1beta4 Christopher Sawtell <csawtell@xtra.co.nz>
@ 2001-02-22 09:39 ` hubert depesz lubaczewski <depesz@depesz.pl>
2001-02-22 10:24 ` Re: problem while compiling user c functions in 7.1beta4 Christopher Sawtell <csawtell@xtra.co.nz>
2001-02-23 03:50 ` Re: problem while compiling user c functions in 7.1beta4 Tom Lane <tgl@sss.pgh.pa.us>
0 siblings, 2 replies; 6+ messages in thread
From: hubert depesz lubaczewski @ 2001-02-22 09:39 UTC (permalink / raw)
To: pgsql-general@postgresql.org
On Thu, Feb 22, 2001 at 10:21:12PM +1300, Christopher Sawtell wrote:
> I did a cvsup update about 12 hours ago and look:-
> 22:05:23 chris@berty:/usr/src/cvs/pgsql $ find . -name postgres.h
> ./src/include/postgres.h
> 22:16:22 chris@berty:/usr/src/cvs/pgsql $
sorry. my fault. i was wrong because the files were not installed in working
directory. strange. error in makefile's?
depesz
--
hubert depesz lubaczewski http://www.depesz.pl/
------------------------------------------------------------------------
najwspanialszą rzeczą jaką dało nam nowoczesne społeczeństwo,
jest niesamowita wręcz łatwość unikania kontaktów z nim ...
^ permalink raw reply [nested|flat] 6+ messages in thread
* Re: problem while compiling user c functions in 7.1beta4
2001-02-22 07:28 problem while compiling user c functions in 7.1beta4 hubert depesz lubaczewski <depesz@depesz.pl>
2001-02-22 09:21 ` Re: [GENERAL] problem while compiling user c functions in 7.1beta4 Christopher Sawtell <csawtell@xtra.co.nz>
2001-02-22 09:39 ` Re: problem while compiling user c functions in 7.1beta4 hubert depesz lubaczewski <depesz@depesz.pl>
@ 2001-02-22 10:24 ` Christopher Sawtell <csawtell@xtra.co.nz>
2001-02-22 11:44 ` Re: problem while compiling user c functions in 7.1beta4 hubert depesz lubaczewski <depesz@depesz.pl>
1 sibling, 1 reply; 6+ messages in thread
From: Christopher Sawtell @ 2001-02-22 10:24 UTC (permalink / raw)
To: hubert depesz lubaczewski <depesz@depesz.pl>; pgsql-general@postgresql.org
On Thu, 22 Feb 2001 22:39, hubert depesz lubaczewski wrote:
> On Thu, Feb 22, 2001 at 10:21:12PM +1300, Christopher Sawtell wrote:
> > I did a cvsup update about 12 hours ago and look:-
> > 22:05:23 chris@berty:/usr/src/cvs/pgsql $ find . -name postgres.h
> > ./src/include/postgres.h
> > 22:16:22 chris@berty:/usr/src/cvs/pgsql $
>
> sorry. my fault. i was wrong because the files were not installed in
> working directory. strange. error in makefile's?
Very strange indeed.
I have found that using cvsup is a very reliable way to keep the code
in order. In my experience postgresql is of ultra-superior quality and
everything just makes "out of the box".
--
Sincerely etc.,
NAME Christopher Sawtell
CELL PHONE 021 257 4451
ICQ UIN 45863470
EMAIL csawtell @ xtra . co . nz
CNOTES ftp://ftp.funet.fi/pub/languages/C/tutorials/sawtell_C.tar.gz
-->> Please refrain from using HTML or WORD attachments in e-mails to me
<<--
^ permalink raw reply [nested|flat] 6+ messages in thread
* Re: problem while compiling user c functions in 7.1beta4
2001-02-22 07:28 problem while compiling user c functions in 7.1beta4 hubert depesz lubaczewski <depesz@depesz.pl>
2001-02-22 09:21 ` Re: [GENERAL] problem while compiling user c functions in 7.1beta4 Christopher Sawtell <csawtell@xtra.co.nz>
2001-02-22 09:39 ` Re: problem while compiling user c functions in 7.1beta4 hubert depesz lubaczewski <depesz@depesz.pl>
2001-02-22 10:24 ` Re: problem while compiling user c functions in 7.1beta4 Christopher Sawtell <csawtell@xtra.co.nz>
@ 2001-02-22 11:44 ` hubert depesz lubaczewski <depesz@depesz.pl>
0 siblings, 0 replies; 6+ messages in thread
From: hubert depesz lubaczewski @ 2001-02-22 11:44 UTC (permalink / raw)
To: pgsql-general@postgresql.org
On Thu, Feb 22, 2001 at 11:24:48PM +1300, Christopher Sawtell wrote:
> Very strange indeed.
> I have found that using cvsup is a very reliable way to keep the code
> in order. In my experience postgresql is of ultra-superior quality and
> everything just makes "out of the box".
i had the same problems in past too. i'm usings cvs -z9 update, and ...
everything builds great. works out of the box, just some files in include
directory are missing.
depesz
--
hubert depesz lubaczewski http://www.depesz.pl/
------------------------------------------------------------------------
najwspanialszą rzeczą jaką dało nam nowoczesne społeczeństwo,
jest niesamowita wręcz łatwość unikania kontaktów z nim ...
^ permalink raw reply [nested|flat] 6+ messages in thread
* Re: problem while compiling user c functions in 7.1beta4
2001-02-22 07:28 problem while compiling user c functions in 7.1beta4 hubert depesz lubaczewski <depesz@depesz.pl>
2001-02-22 09:21 ` Re: [GENERAL] problem while compiling user c functions in 7.1beta4 Christopher Sawtell <csawtell@xtra.co.nz>
2001-02-22 09:39 ` Re: problem while compiling user c functions in 7.1beta4 hubert depesz lubaczewski <depesz@depesz.pl>
@ 2001-02-23 03:50 ` Tom Lane <tgl@sss.pgh.pa.us>
1 sibling, 0 replies; 6+ messages in thread
From: Tom Lane @ 2001-02-23 03:50 UTC (permalink / raw)
To: depesz@depesz.pl; +Cc: pgsql-general@postgresql.org
hubert depesz lubaczewski <depesz@depesz.pl> writes:
> sorry. my fault. i was wrong because the files were not installed in working
> directory. strange. error in makefile's?
No, an extremely deliberate change, which was discussed at length in the
mailing lists. The default install now installs only client-side header
files, no server-side files. If you want to compile server-side code,
either point your -I path at pgsql/src/include or do "make
install-all-headers".
regards, tom lane
^ permalink raw reply [nested|flat] 6+ messages in thread
end of thread, other threads:[~2001-02-23 03:50 UTC | newest]
Thread overview: 6+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2001-02-22 07:28 problem while compiling user c functions in 7.1beta4 hubert depesz lubaczewski <depesz@depesz.pl>
2001-02-22 09:21 ` Christopher Sawtell <csawtell@xtra.co.nz>
2001-02-22 09:39 ` hubert depesz lubaczewski <depesz@depesz.pl>
2001-02-22 10:24 ` Christopher Sawtell <csawtell@xtra.co.nz>
2001-02-22 11:44 ` hubert depesz lubaczewski <depesz@depesz.pl>
2001-02-23 03:50 ` Tom Lane <tgl@sss.pgh.pa.us>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox