Recent

Author Topic: Help Needed in Installing the Lazarus IDE on Raspberry PI 3  (Read 3789 times)

Xor-el

  • Sr. Member
  • ****
  • Posts: 404
Help Needed in Installing the Lazarus IDE on Raspberry PI 3
« on: November 09, 2018, 10:05:45 am »
Hi,
So I just got my Raspberry PI 3 some days back and decided to get Lazarus and FPC installed on it.

I first of all installed FPC from ftp://freepascal.stack.nl/pub/mirrors/fpc/dist/3.0.4/arm-linux/fpc-3.0.4.arm-linux-eabihf-raspberry.tar, it installed successfully.
So I tried installing Lazarus 2.0RC2 from svn https://svn.freepascal.org/svn/lazarus/tags/lazarus_2_0_0_RC2/ , after downloading the sources, I followed the instructions, the build started successfully but started failing at some point with this error message below

Quote
pi@raspberrypi:/usr/local/lazarus/source $ sudo make bigide
make -C packager/registration
make[1]: Entering directory '/usr/local/lazarus/source/packager/registration'
/bin/rm -f ../units/arm-linux/fcllaz.ppu
/usr/local/bin/ppcarm -MObjFPC -Scghi -O1 -g -gl -l -vewnhibq -Fu. -Fu/usr/local/lib/fpc/3.0.4/units/arm-linux/rtl -FE. -FU../units/arm-linux -darm fcllaz.pas
Hint: (11030) Start of reading config file /etc/fpc.cfg
Hint: (11031) End of reading config file /etc/fpc.cfg
Free Pascal Compiler version 3.0.4 [2017/10/11] for arm
Copyright (c) 1993-2017 by Florian Klaempfl and others
(1002) Target OS: Linux for ARMHF
(3104) Compiling fcllaz.pas
(9009) Assembling fcllaz
(1008) 21 lines compiled, 0.8 sec
(1022) 2 hint(s) issued
/bin/cp -f Makefile.compiled ../units/arm-linux/FCL.compiled
make[1]: Leaving directory '/usr/local/lazarus/source/packager/registration'
make -C components/lazutils
make[1]: Entering directory '/usr/local/lazarus/source/components/lazutils'
/bin/rm -f lib/arm-linux/lazutils.ppu
/usr/local/bin/ppcarm -MObjFPC -Scghi -O1 -g -gl -l -vewnhibq -Fu../../packager/units/arm-linux -Fu. -Fu/usr/local/lib/fpc/3.0.4/units/arm-linux/rtl -FE. -FUlib/arm-linux -darm lazutils.pas
Hint: (11030) Start of reading config file /etc/fpc.cfg
Hint: (11031) End of reading config file /etc/fpc.cfg
Free Pascal Compiler version 3.0.4 [2017/10/11] for arm
Copyright (c) 1993-2017 by Florian Klaempfl and others
(1002) Target OS: Linux for ARMHF
(3104) Compiling lazutils.pas
(9009) Assembling lazutils
(1008) 35 lines compiled, 1.0 sec
(1022) 2 hint(s) issued
/bin/cp -f Makefile.compiled lib/arm-linux/LazUtils.compiled
make[1]: Leaving directory '/usr/local/lazarus/source/components/lazutils'
make -C components/codetools
make[1]: Entering directory '/usr/local/lazarus/source/components/codetools'
/bin/rm -f units/arm-linux/codetools.ppu
/usr/local/bin/ppcarm -MObjFPC -Sci -O1 -g -gl -l -vewnhibq -Fu../../packager/units/arm-linux -Fu../lazutils/lib/arm-linux -Fu. -Fu/usr/local/lib/fpc/3.0.4/units/arm-linux/rtl -FE. -FUunits/arm-linux -darm codetools.pas
Hint: (11030) Start of reading config file /etc/fpc.cfg
Hint: (11031) End of reading config file /etc/fpc.cfg
Free Pascal Compiler version 3.0.4 [2017/10/11] for arm
Copyright (c) 1993-2017 by Florian Klaempfl and others
(1002) Target OS: Linux for ARMHF
(3104) Compiling codetools.pas
(9009) Assembling codetools
(1008) 33 lines compiled, 1.0 sec
(1022) 2 hint(s) issued
/bin/cp -f Makefile.compiled units/arm-linux/CodeTools.compiled
make[1]: Leaving directory '/usr/local/lazarus/source/components/codetools'
make -C lcl LCL_PLATFORM=nogui
make[1]: Entering directory '/usr/local/lazarus/source/lcl'
/bin/rm -f units/arm-linux/alllclunits.ppu
/usr/local/bin/ppcarm -gl -Sic -Fu../packager/units/arm-linux -Fu../components/lazutils/lib/arm-linux -Fu. -Funonwin32 -Fuforms -Fuwidgetset -Fu/usr/local/lib/fpc/3.0.4/units/arm-linux/rtl -Fiinclude -FE. -FUunits/arm-linux -darm alllclunits.pp
Free Pascal Compiler version 3.0.4 [2017/10/11] for arm
Copyright (c) 1993-2017 by Florian Klaempfl and others
Target OS: Linux for ARMHF
Compiling alllclunits.pp
Assembling alllclunits
42 lines compiled, 3.7 sec
/bin/cp -f Makefile.compiled units/arm-linux/LCLBase.compiled
make -C interfaces all
make[2]: Entering directory '/usr/local/lazarus/source/lcl/interfaces'
make -C nogui all
make[3]: Entering directory '/usr/local/lazarus/source/lcl/interfaces/nogui'
/bin/rm -f ../../units/arm-linux/nogui/lcl.ppu \
    ../../units/arm-linux/nogui/lcl.o
/usr/local/bin/ppcarm -gl -dnogui -Fu../../units/arm-linux -Fu../../../packager/units/arm-linux -Fu../../../components/lazutils/lib/arm-linux -Fu.. -Fu. -Fu/usr/local/lib/fpc/3.0.4/units/arm-linux/rtl -FE. -FU../../units/arm-linux/nogui -darm ../lcl.pas
Free Pascal Compiler version 3.0.4 [2017/10/11] for arm
Copyright (c) 1993-2017 by Florian Klaempfl and others
Target OS: Linux for ARMHF
Compiling ../lcl.pas
Assembling lcl
21 lines compiled, 2.0 sec
/bin/cp -f Makefile.compiled ../../units/arm-linux/nogui/LCL.compiled
make[3]: Leaving directory '/usr/local/lazarus/source/lcl/interfaces/nogui'
make[2]: Leaving directory '/usr/local/lazarus/source/lcl/interfaces'
make[1]: Leaving directory '/usr/local/lazarus/source/lcl'
make -C tools
make[1]: Entering directory '/usr/local/lazarus/source/tools'
make[1]: *** No targets.  Stop.                                                                                                        <<================================= Error started from here.
make[1]: Leaving directory '/usr/local/lazarus/source/tools'
Makefile:3371: recipe for target 'lazbuild' failed
make: *** [lazbuild] Error 2
pi@raspberrypi:/usr/local/lazarus/source $

Can anyone help me out please?
Am already loosing my mind.
Stuck on this for 2 days now.

By the way, I have already increased the swap file size.

Thanks.

Thaddy

  • Hero Member
  • *****
  • Posts: 14205
  • Probably until I exterminate Putin.
Re: Help Needed in Installing the Lazarus IDE on Raspberry PI 3
« Reply #1 on: November 09, 2018, 10:51:15 am »
Two things:
- compiling lazarus does not need sudo so don't use it.
- did you check out lazarus from git?

My recipe works like this:
First get subversion if you do not have it installed already:
sudo apt-get update && sudo apt-get dist-upgrade -y && sudo apt-get install subversion -y

svn co https://svn.freepascal.org/svn/lazarus/tags/lazarus_1_8_4/ lazarus

cd lazarus

A first time may need a make all:
make clean all useride

The simplest solution, however, and this also resolves any dependencies, is to add stretch-backports to sources.list and install fpc 3.0.4 and lazarus 1.8.4 through the raspbian package manager.
I showed how to do that before on this forum.

If noon of this works, plz report back: I am writing most of my stuff here from a RPi3 of some sort so I can make it work.
« Last Edit: November 09, 2018, 11:18:50 am by Thaddy »
Specialize a type, not a var.

Xor-el

  • Sr. Member
  • ****
  • Posts: 404
Re: Help Needed in Installing the Lazarus IDE on Raspberry PI 3
« Reply #2 on: November 09, 2018, 11:25:34 am »
Two things:
- compiling lazarus does not need sudo so don't use it.
- did you check out lazarus from git?

My recipe works like this:
First get subversion if you do not have it installed already:
sudo apt-get update && sudo apt-get dist-upgrade -y && sudo apt-get install subversion -y

svn co https://svn.freepascal.org/svn/lazarus/tags/lazarus_1_8_4/ lazarus

cd lazarus

A first time may need a make all:
make clean all useride

The simplest solution, however, and this also resolves any dependencies, is to add stretch-backports to sources.list and install fpc 3.0.4 and lazarus 1.8.4 through the raspbian package manager.
I showed how to do that before on this forum.

If noon of this works, plz report back: I am writing most of my stuff here from a RPi3 of some sort so I can make it work.

thanks thaddy.
I tried make clean all useride and I got an error message (about cleanide).

I will try the stretch backports and report back.
Thanks once again.

Xor-el

  • Sr. Member
  • ****
  • Posts: 404
Re: Help Needed in Installing the Lazarus IDE on Raspberry PI 3
« Reply #3 on: November 09, 2018, 04:20:45 pm »
Hi Thaddy.
Am glad to inform you that it did work perfectly using the backport method.  :)
Thanks a lot.

Bad news though  :'(
After I did restart the PI, it refused to boot up, I guess may be the OS did crash.
will reformat the SD Card later when I have some time.
Thanks once again.

Thaddy

  • Hero Member
  • *****
  • Posts: 14205
  • Probably until I exterminate Putin.
Re: Help Needed in Installing the Lazarus IDE on Raspberry PI 3
« Reply #4 on: November 09, 2018, 05:12:31 pm »
Make sure the power supply is at least 2.1A Best to use the official one. (that's 2.5A)
That is the most common cause of crashed cards.
Also: I actually run the OS from a - fast - USB stick on one or two Pi's, that seems more stable.
Specialize a type, not a var.

Xor-el

  • Sr. Member
  • ****
  • Posts: 404
Re: Help Needed in Installing the Lazarus IDE on Raspberry PI 3
« Reply #5 on: November 09, 2018, 05:27:40 pm »
Make sure the power supply is at least 2.1A Best to use the official one. (that's 2.5A)
That is the most common cause of crashed cards.
Also: I actually run the OS from a - fast - USB stick on one or two Pi's, that seems more stable.

Duly noted.
Thanks.
side question?
Do you use a hdmi display or you SSH into your pi and connect with any vnc viewer?

 

TinyPortal © 2005-2018