Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / fpc-pascal / 2023-03

Fpc 3.2.2 fails to "make install" on RPi4 to local directory

3 messages · 2 people ·

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Bo Berglund

I have a RaspberryPi4 where I have installed several versions of Lazarus/Fpc over some time.
The latest versions are (fpc from Tools/Options/Compiler_executable):

Laz 2.0.8 with Fpc 3.0.4 set to use fpc: fpc
Laz 2.0.10 with Fpc 3.2.0 set to use fpc: /home/pi/lib/fpc/3.2.0/ppcarm Laz 2.0.12 with Fpc 3.2.0 set to use fpc: /home/pi/lib/fpc/3.2.0/ppcarm

Now I wanted to add a new Lazarus version and update my FPC to 3.2.2 as well.

So I have done what I always do, gotten the fpc sources from GitLab into a new dir ~/dev/fpc/3.2.2, then executed inside that dir using fpc 3.2.0 as seed:

make clean FPC="/home/pi/dev/fpc/3.2.0/compiler/ppcarm" make all FPC="/home/pi/dev/fpc/3.2.0/compiler/ppcarm"

And then after that succeeded:

make install prefix="$HOME" FPC="$HOME/dev/fpc/3.2.2/compiler/ppcarm" which throws an error! So I tried without $HOME:

make install prefix="/home/pi" FPC="/home/pi/dev/fpc/3.2.2/compiler/ppcarm" which also throws the error, it displays this sequence:

make installbase FPC=/home/pi/dev/fpc/3.2.2/compiler/ppcarm ZIPDESTDIR=/home/pi/dev/fpc/3.2.2
FPCMAKE=/home/pi/dev/fpc/3.2.2/utils/fpcm/bin/arm-linux/fpcmake make[1]: Entering directory '/home/pi/dev/fpc/3.2.2' /usr/bin/install -m 755 -d /usr/local/lib/fpc/3.2.2 /usr/bin/install: cannot create directory ‘/usr/local/lib/fpc’: Permission denied
make[1]: *** [Makefile:2858: installbase] Error 1
make[1]: Leaving directory '/home/pi/dev/fpc/3.2.2' make: *** [Makefile:2875: installall] Error 2

This has *never* happened before to me and I do not understand why it brings up /usr/bin/ and /usr/local/lib/, the whole point of my use of the argument prefix="/home/pi"
is to install *locally* below the home dir and not to a global location where you nhave to be sudo to do anything...

Note:
my $HOME/.fpc.cfg from 2019 contains exclusively paths looking like this:

#ifndef VER2
-FM/home/pi/lib/fpc/../../share/fpc/$fpcversion/unicode/ #endif
# searchpath for units and other system dependent things -Fu/home/pi/lib/fpc/$fpcversion/units/$fpctarget
-Fu/home/pi/lib/fpc/$fpcversion/units/$fpctarget/* -Fu/home/pi/lib/fpc/$fpcversion/units/$fpctarget/rtl

Is this a new behaviour for Fpc 3.2.2 different from that of Fpc 3.2.0 where it did not happen???

If not, what could have happened and in both cases how do I fix it?

Bo Berglund Developer in Sweden
Marco van de Voort
to Bo Berglund
Bo Berglund wrote
make install prefix="$HOME" FPC="$HOME/dev/fpc/3.2.2/compiler/ppcarm"

It is install_prefix= not install prefix=  iow, insert a underscore

Bo Berglund
to Marco van de Voort
Marco van de Voort wrote 6 lines
On 28-3-2023 13:43, Bo Berglund via fpc-pascal wrote: > make install prefix="$HOME" FPC="$HOME/dev/fpc/3.2.2/compiler/ppcarm" It is install_prefix= not install prefix=  iow, insert a underscore

No, the problem was *case sensitivity*!
the command should be:

make install PREFIX="$HOME" FPC="$HOME/dev/fpc/3.2.2/compiler/ppcarm"

Stupid confusion of case sensitive OS with Windows where case does not come into play...

Bo Berglund Developer in Sweden