Thanks for the help below.

Here is the x86 related error. I did (working directory:
/data/fpc_trunc/svn )
 svn up
 svn info
Path: .
URL: http://svn.freepascal.org/svn/fpc/trunk
Repository Root: http://svn.freepascal.org/svn/fpc
Repository UUID: 3ad0048d-3df7-0310-abae-a5850022a9f2
Revision: 12025
Node Kind: directory
Schedule: normal
Last Changed Author: jonas
Last Changed Rev: 12025
Last Changed Date: 2008-11-03 21:18:27 +0000 (Mon, 03 Nov 2008)

 gmake distclean
 gmake all

The last lines from this make are below. At this stage it is using
ppc386 from the cvn directory, and it is also using the rtl from svn.
 /data/fpc_trunc/svn/compiler/ppc386 -V
Free Pascal Compiler version 2.3.1 [2008/11/03] for i386
Copyright (c) 1993-2008 by Florian Klaempfl

The Error, I get

gmake[3]: Leaving directory `/data/fpc_trunc/svn/packages/openssl'
gmake -C graph smart
gmake[3]: Entering directory `/data/fpc_trunc/svn/packages/graph'
gmake all LINKSMART=1 CREATESMART=1
gmake[4]: Entering directory `/data/fpc_trunc/svn/packages/graph'
/bin/mkdir -p units/i386-freebsd
/data/fpc_trunc/svn/compiler/ppc386 -XX -CX -Ur -Xs -O2 -n -S2
-Fu/data/fpc_trunc/svn/rtl/units/i386-freebsd
-Fu/data/fpc_trunc/svn/packages/pthreads/units/i386-freebsd
-Fu/data/fpc_trunc/svn/packages/x11/units/i386-freebsd
-Fu/data/fpc_trunc/svn/packages/sdl/units/i386-freebsd -Fisrc/freebsd
-Fisrc/inc -Fisrc/unix -FE. -FUunits/i386-freebsd -di386 -dRELEASE
-Isrc/inc src/unix/graph.pp
Fatal: Can't find unit x86 used by Graph
Fatal: Compilation aborted
gmake[4]: *** [graph.ppu] Error 1
gmake[4]: Leaving directory `/data/fpc_trunc/svn/packages/graph'
gmake[3]: *** [fpc_smart] Error 2
gmake[3]: Leaving directory `/data/fpc_trunc/svn/packages/graph'
gmake[2]: *** [graph_smart] Error 2
gmake[2]: Leaving directory `/data/fpc_trunc/svn/packages'
gmake[1]: *** [packages_smart] Error 2
gmake[1]: Leaving directory `/data/fpc_trunc/svn'
gmake: *** [build-stamp.i386-freebsd] Error 2

Any idea?




But thanks for the hint on make install
 gmake install FPC=xxx  INSTALL_PREFIX=foo
worked well (created a 2.3.1 dir)
Same if I use PP= instead of FPC=. Is there a difference?

I looked at the buildfaq at http://www.stack.nl/~marcov/buildfaq.pdf
(not sure if this is up to date?)
Chapter 2, pages 22: The first 2 examples have "make install" with *no*
PP=. Of course my fault, I didn't read properly. It then explains that
they are wrong.

Maybe it would be easier for users to follow if either no wrong examples
where given, or maybe the hint "# wrong example" was given on the same
line as the command. So you would more liekly get to read it, if you
copied and pasted it?
I know it's my fault not to read it proper. But i could imagine, that
othere may get into similar trouble...

Thanks Martin


Jonas Maebe wrote:

On 03 Nov 2008, at 16:03, Martin Friebe wrote:

I have a few question, regarding my attempts to install fpc from trunc

Small aside: it's trunk (as in "trunk of a tree", compared to "branches"), not trunc (as in "truncate").

* First problem: I found if I simply go to the parent (svn) directory,
and do a "gmake all PP=/data/fpc_trunc/svn/compiler/ppc386" there, it
will do some clean out, and stop because halfway through it will have
deleted this compiler.

That's correct.

So instead (which is not mentioned in the buildfaq?), I have installed
the compiler and rtl at this stage:
 gmake install  INSTALL_PREFIX=/data/fpc_trunc/inst/
 cd ../rtl
 gmake install  INSTALL_PREFIX=/data/fpc_trunc/inst/

You don't have to install the compiler/rtl. You only have to copy the compiler binary someplace safe. In face, you don't need the cycle at all, you can immediately do a "gmake all".

* Second Problem: when using fpc (instead of ppc), it will always find
the ppc386 in the default installation. The only way I can change this
is "fpc -Xp/path/to/my/ppc386". (Which I found no documentation for. I
got that from looking through the source) However, if I want to use fpc
from lazarus, I may not be able to pass that (convenient) on the command
line.

Does lazarus call fpc or ppcXXX?

Is there any INI file?

No.

(fpc.cfg did not help here, at least not the
fpc.cfg in the same path as fpc exe).
Or is it save to substitute fpc, with ppc386 everywhere it is called?

Yes, that's safe.

any way I then go and create my fpc.cfg:
cd ../../inst
./bin/fpcmkcfg -d basepath=/data/fpc_trunc/inst/lib/fpc/2.2.2 >
bin/fpc.cfg

I'm not sure how well maintained fpcmkcfg is. For the (*nix) releases we use the samplecfg script (from compiler/utils) to generate configurations. But you shouldn't need a new configuration file, afaik samplecfg is identical in fixes and trunk (and in 2.2.2).

* 3rd problem, it uses the same prefix for the units (-Fu) and the bin
(-FD), so the above creates correct -Fu config, but I must change the
-FD conf. Any solution to this ?
-Fu will be correct:
-Fu/data/fpc_trunc/inst/lib/fpc/2.2.2/units/$FPCTARGET/rtl
but -FD will *NOT* be (which I think it should?, or am I wrong?)
-FD/data/fpc_trunc/inst/bin

-FD is used to find utilities like as and ld. Unless you have special binutils versions which you only want to use with this particular version of the compiler, you should not use and -FD parameter.

* 4th Problem the compilation aborted (Sorry I don't remember where)
because it tried to access the x11 package
=> I did solve that by going int packages/x11, did the make there, and
did install it (with the install prefix)

Without the actual error message, there's not much to add.

* 5th problem packages/graph stops, because it tries to use x86. (This
exists in the sources rtl/unix/x86.pp) Somehow all the above has not
installed this (not on my FreeBSD), the package is missing int he
inst/lib.... directory

I thought there were people who regularly compile the FreeBSD version, but it seems that is not the case if such errors exist.

And last not least, having checked out trunc (or being under the
impression to have done so), why has the "make install" in the rtl
installed something with 2.2.2 in the path? (If I run the ppc386 that
was installed it will say 2.3.1.

You have to install using

make FPC=/path/to/newly/compiled/ppc386 install INSTALL_PREFIX=...


Jonas

_______________________________________________
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal

_______________________________________________
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal

Reply via email to