Lazarus

Programming => Operating Systems => Other => Topic started by: vonskie on May 13, 2019, 07:24:53 pm

Title: Anyone able to get 3.0.4 fpc to compile lazarus 2.0.2 on rasberry PI?
Post by: vonskie on May 13, 2019, 07:24:53 pm
Anyone able to get 3.0.4 fpc to compile lazarus 2.0.2 on rasberry PI?

latest on back ports is 1.8.4

Title: Re: Anyone able to get 3.0.4 fpc to compile lazarus 2.0.2 on rasberry PI?
Post by: af0815 on May 14, 2019, 11:02:53 am
try it with fpcupdeluxe and fix the error for not installed packages. You have to expand the swap with factor 10 to get no linker error from fpc.

Code: Pascal  [Select][+][-]
  1. #!/bin/bash
  2. # Paketliste auf neusten Stand bringen und Updaten
  3. sudo apt-get update
  4. sudo apt-get upgrade
  5.  
  6. # Die fehlenden Pakete installieren.
  7. sudo apt-get install libx11-dev
  8. sudo apt-get install libgdk-pixbuf2.0-dev
  9. sudo apt-get install libpango1.0-dev
  10. sudo apt-get install libgtk2.0-dev
  11.  
  12. # Für SVN
  13. sudo apt-get install subversion
  14.  
  15. # Für GIT
  16. sudo apt-get install git
  17.  
  18. #Auf dem Raspi muss evtl. für OpenGL folgendes installiert werden.
  19. sudo apt-get install libgl-dev
Source = http://wiki.freepascal.org/fpcupdeluxe/de

fpcupdeluxe from https://github.com/newpascal/fpcupdeluxe/releases/latest

Title: Re: Anyone able to get 3.0.4 fpc to compile lazarus 2.0.2 on rasberry PI?
Post by: Thaddy on May 14, 2019, 03:48:31 pm
Anyone able to get 3.0.4 fpc to compile lazarus 2.0.2 on rasberry PI?

latest on back ports is 1.8.4
-This is written from a Raspberry pi 3 - did you solve it? because I am on Laz trunk and FPC trunk and there are no problems at all...
Code: Bash  [Select][+][-]
  1. pi@raspberrypi:~/fpc331 $ fpc -v
  2. Free Pascal Compiler version 3.3.1-r42061 [2019/05/14] for arm
  3. Copyright (c) 1993-2018 by Florian Klaempfl and others
  4.  

So what were your exact steps? (I really mean exact...e.g. some Russian po files have conflicts today, but these are not vital)
Title: Re: Anyone able to get 3.0.4 fpc to compile lazarus 2.0.2 on rasberry PI?
Post by: han on June 26, 2019, 05:40:39 pm
I had also problems and could only compile an older nightly edition Lazarus 1.9 (not the latest). Other versions where also problematic. However after installing the latest Raspbian operating system Buster, you get Lazarus 2.0.0 and FPC 3.0.4 by simply:

sudo apt-get install lazarus


Title: Re: Anyone able to get 3.0.4 fpc to compile lazarus 2.0.2 on rasberry PI?
Post by: Thaddy on June 26, 2019, 05:48:04 pm
I had also problems and could only compile an older nightly edition Lazarus 1.9 (not the latest). Other versions where also problematic. However after installing the latest Raspbian operating system Buster, you get Lazarus 2.0.0 and FPC 3.0.4 by simply:

sudo apt-get install lazarus
No. Use - one time - fpcdeluxe. There are no problems. Again written from a Raspberri Pi 3 b. This weekend from a RPi 4 I hope... 8-)
If there are any problems, report back. I can compile ANY (stable) version that supports armhf on a Raspberry Pi without problems. Lazarus too...It's not rocket science, everybody can do it.
Can even be done on a RPi 1 B
Code: Bash  [Select][+][-]
  1. pi@raspberrypi:~ $ fpc -v
  2. Free Pascal Compiler version 3.3.1-r42284 [2019/06/25] for arm
  3. Copyright (c) 1993-2018 by Florian Klaempfl and others
Title: Re: Anyone able to get 3.0.4 fpc to compile lazarus 2.0.2 on rasberry PI?
Post by: af0815 on June 26, 2019, 06:38:15 pm
fpc fixes32 with Laz fixe20 also possible with fpcupdeluxe an a raspi 3B+ with enlarged swap !!!!!
Title: Re: Anyone able to get 3.0.4 fpc to compile lazarus 2.0.2 on rasberry PI?
Post by: Thaddy on June 26, 2019, 06:43:28 pm
Indeed, I would recommend a swap of at least 1 Gb (but not more than 2), certainly to compile Lazarus. FPC has less strain.
Title: Re: Anyone able to get 3.0.4 fpc to compile lazarus 2.0.2 on rasberry PI?
Post by: han on June 26, 2019, 11:05:49 pm
No. Use - one time - fpcdeluxe. There are no problems. Again written from a Raspberri Pi 3 b. This weekend from a RPi 4 I hope... 8-)
If there are any problems, report back. I can compile ANY (stable) version that supports armhf on a Raspberry Pi without problems. Lazarus too...It's not

Well, I again run into problems. If I want to recompile the installed Lazarus 2.0.0 in a Pi3 it stops with an error:

lazarus.pp(1,1) Fatal cannot find fpdebug.  used by Lazarus

But it is available in /usr/lib/lazarus/2.0.0/components so shouldn't be a problem. Path is set in tools environment

If I compile manually fpdebug.lpk, it stops at can't find virtualtree.....

Frustrating. It would be nice if a simple .deb installer was available on Sourceforge. I'm thinking going back to a older trunk 1.90 dailly build which worked fine for me and just type "make clean bigide".  Strange  enough "make clean bigide" doesn't work for the latest dailly build. Never had these problems in amd64.

Will have a look to fpcupdeluxe and memory swap size.  :(

Han
Title: Re: Anyone able to get 3.0.4 fpc to compile lazarus 2.0.2 on rasberry PI?
Post by: han on June 27, 2019, 09:22:12 am
Okay increased the swap size as described https://www.bitpi.co/2015/02/11/how-to-change-raspberry-pis-swapfile-size-on-rasbian/ (https://www.bitpi.co/2015/02/11/how-to-change-raspberry-pis-swapfile-size-on-rasbian/)

Checked swap size by "free -m" indicating a swap of 1023

Did a rebuild of Lazarus 2.0.0 and get the same error:

   lazarus.pp(1,1) Fatal cannot find fpdebug  used by Lazarus

Title: Re: Anyone able to get 3.0.4 fpc to compile lazarus 2.0.2 on rasberry PI?
Post by: af0815 on June 27, 2019, 10:11:53 am
Ok, actual working tested is
  fpc fixes32 with Laz fixe20 (by me)
  fpc trunk with Laz trunk (by Thaddy)

Maybe Lazarus 2.0.0 with FPC ??3.0.4?? is not working. 

Did this working with one of the working configurations ?
Quote
Will have a look to fpcupdeluxe and memory swap size.  :(

Quote
Frustrating. It would be nice if a simple .deb installer was available on Sourceforge. I'm thinking going back to a older trunk 1.90 dailly build which worked fine for me and just type "make clean bigide".  Strange  enough "make clean bigide" doesn't work for the latest dailly build. Never had these problems in amd64.
If you try it with the simply fpcupdeluxe installer, you need not to deal with packages. To have some 'nice' deb packages you need more peoplepower for building .deb packages for all flowers of linux with different 'spezialities'. This is on of the reasons for fpcupdeluxe - you can build direct from the sources with a well mainted tool (THX to Alfred !!!) on a lot of platforms. 
Title: Re: Anyone able to get 3.0.4 fpc to compile lazarus 2.0.2 on rasberry PI?
Post by: han on June 27, 2019, 10:21:32 am
Hello Andreas,

1) Tried all your update commands. Only the following did something effectively:

sudo apt-get install subversion

2) Then I tried to compile from command line

cd /etc/alternatives/lazarus
sudo make clean bigide

That worked.

3) Then I tried to rebuild "normal ide" from the Lazarus menu and this time it works! But why? I'm puzzled.

Han

Title: Re: Anyone able to get 3.0.4 fpc to compile lazarus 2.0.2 on rasberry PI?
Post by: af0815 on June 27, 2019, 10:24:09 am
troubles with path and maybe old versions hanging around ?!
Title: Re: Anyone able to get 3.0.4 fpc to compile lazarus 2.0.2 on rasberry PI?
Post by: han on June 27, 2019, 10:46:34 am
I installed a clean Buster twice on my Pi3 and the same problem occurred. I have the impression that "make clean bigide" did the trick. Soon my Pi4 will arrive and I will try again.

Thanks for the advice.

Han
Title: Re: Anyone able to get 3.0.4 fpc to compile lazarus 2.0.2 on rasberry PI?
Post by: Thaddy on June 27, 2019, 10:59:56 am
Be careful with Buster: even I went through hoops after installing it on a RPi 3.... and I am very experienced.
There are a lot of package dependencies that needs to be built yourself from source.  RaspBian Buster is rather incomplete.
Mostly make and ./configure but not suitable for people that have no experience with building C libraries from source.
I'd recommend to keep Stretch for a few months unless you can do the above.

We'll see: I am awaiting three RPi's 4 too....  :D ;) :) (2 two Gb, one 4 Gb )

BTW: The compiler itself is not the problem: simply go to the ./compiler directory and do make cycle.
Title: Re: Anyone able to get 3.0.4 fpc to compile lazarus 2.0.2 on rasberry PI?
Post by: han on June 27, 2019, 11:31:27 am
Be careful with Buster: even I went through hoops after installing it on a RPi 3.... and I am very experienced.
Stretch is no longer available. You get default Buster. I'm glad with it since it has Lazarus 2.0.0 (better then 1.6.2), so that's fine for me

I did some more testing and I think I found the reason why it doesn't recompile. I removed the compiled files of fpdebug as follows:

cd /etc/alternatives/components/fpdebug/lib/arm-linux
sudo rm *.*

So this removes all .ppu and .o files. Then I tried again in Lazarus rebuild. It stops at the same error "lazarus.pp(1,1) Fatal cannot find fpdebug  used by Lazarus"

So why are the *.o and *.ppu  *.compiled not generated by the rebuild? Is it not simply administrative rights? Lazarus is in /usr/lib/lazarus/2.0.0 What would be the correct approach to get the required rights? (Normally I work under Windows, so I'm unfamiliar with this)

Han
Title: Re: Anyone able to get 3.0.4 fpc to compile lazarus 2.0.2 on rasberry PI?
Post by: Jacob21 on July 27, 2019, 04:59:28 pm
Hi, I have the same problem
Has anyone a solution?
Title: Re: Anyone able to get 3.0.4 fpc to compile lazarus 2.0.2 on rasberry PI?
Post by: af0815 on July 27, 2019, 05:53:51 pm
what kind of same problem ?

There see some different problems in this thread.

What kind of RasPi, how did you install?
Title: Re: Anyone able to get 3.0.4 fpc to compile lazarus 2.0.2 on rasberry PI?
Post by: Thaddy on July 27, 2019, 05:56:15 pm
I can compile it on any Raspberry Pi so what is the exact problem?
- Version of the Raspberry Pi?
- Version of Raspbian?
- Version of FPC and Lazarus you need?

If you give that information I can give guidance.

BTW: you are definitely not on Raspbian buster, because then 3.0.4 can be installed from Apt.
Or Raspbian stretch with back-ports.

More info needed. It is quite easy.

In short: you did not ever upgrade your system.< >:D 8-)>

If you really did not do that, you are a beginner and I would be glad to explain how to get the most recent FPC and Lazarus on a Raspberyy Pi.
TinyPortal © 2005-2018