[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Getting freepascal to work



After many years of not working with Pascal, I want to use it again.

When testing out the postgresql connection using an example (testpg2.pp) in the documentation I can compile it with the original Makefile, but not when I want to complie a 64-bit binary on my Debian.  The Makefile seems to use 32-bit compilation.

The error I am regularly getting is (from both the fp and fpc that it cannot find the unit postgres.

So after a lot of experimentation I added

-Fu/usr/share/fpcsrc/2.6.0/packages/postgres/src/  in /etc/fpc.cfg.

Now  the compilation ends with

Searching file /usr/share/fpcsrc/2.6.0/packages/postgres/src/dllist.pp... found
dllisttypes.inc(33)  Back in dllist.pp
(DLLIST)   Loading implementation units from DLLIST
dllist.pp(29,1) (DLLIST)   Parsing implementation of DLLIST
dllist.pp(32,1) Error: Can't create object file: /usr/share/fpcsrc/2.6.0/packages/postgres/src/dllist.o
dllist.pp(32,1) Fatal: Can't create object /usr/share/fpcsrc/2.6.0/packages/postgres/src/dllist.o
Searching file /usr/share/fpcsrc/2.6.0/packages/postgres/src/postgres.pp... found
Fatal: Compilation aborted
Error: /usr/bin/ppcx64 returned an error exitcode (normal if you did not specify a source file to be compiled)

Do I first have to comple the package postgres before I use it? 

Will this be the case for all the units?

Regards
Johann



--
Because experiencing your loyal love is better than life itself,
my lips will praise you.  (Psalm 63:3)

Reply to: