Recent

Author Topic: Can't find latest fpc (not Lazarus) (Mac OS / Apple Si)  (Read 1002 times)

AlanTheBeast

  • Sr. Member
  • ****
  • Posts: 390
  • My software never cras....
Can't find latest fpc (not Lazarus) (Mac OS / Apple Si)
« on: June 25, 2025, 08:23:15 pm »
Mix and repeat time.

Mac OS - Apple Si.

In an effort to try some code from Thaddy, I have to update fpc from 3.2.2 to at least 3.3.1.
Quote
/Users/alanbeast/pascal $ mfpc simthrd
simthrd.pas(1,31) Error: User defined: minimum supported version is fpc 331.
   1{$if fpc_fullversion < 30301}{$error minimum supported version is fpc 331.}{$ifend}
   2{$apptype console}

Following the Dowloads link on Lazarus:
https://www.freepascal.org/download.html

latest there is 3.2.2

SourceForge is the entire Lazarus package (can't find fpc alone there).

GitLab - nothing.

Delving into the Source Forge for Lazarus 3.8 the fpc package is 3.2.2 ...



Alas ... where oh where is fpc 3.3.x  ... for MacOS / Apple Si.

Edit: did find 3.2.2 with Laz 3.8
« Last Edit: June 25, 2025, 08:36:22 pm by AlanTheBeast »
Everyone talks about the weather but nobody does anything about it.
..Samuel Clemens.

Nicole

  • Hero Member
  • *****
  • Posts: 1207
Re: Can't find latest fpc (not Lazarus) (Mac OS / Apple Si)
« Reply #1 on: June 25, 2025, 08:39:38 pm »

AlanTheBeast

  • Sr. Member
  • ****
  • Posts: 390
  • My software never cras....
Re: Can't find latest fpc (not Lazarus) (Mac OS / Apple Si)
« Reply #2 on: June 25, 2025, 08:43:07 pm »
Thanks, w/o warranty, you can remove that post as I was looking for the Apple Si [ AARCH ] version not _x86. :D

I also used the link you provided to back out and dive in at trunk and v33, but didn't find it.
« Last Edit: June 25, 2025, 08:47:16 pm by AlanTheBeast »
Everyone talks about the weather but nobody does anything about it.
..Samuel Clemens.

Nicole

  • Hero Member
  • *****
  • Posts: 1207
Re: Can't find latest fpc (not Lazarus) (Mac OS / Apple Si)
« Reply #3 on: June 25, 2025, 09:12:55 pm »
I am offline for today. But try ChatGPT by yourself. You must be harsh and insist on one single link. Finally I got it. The first attempts were those chatty failures.

AlanTheBeast

  • Sr. Member
  • ****
  • Posts: 390
  • My software never cras....
Re: Can't find latest fpc (not Lazarus) (Mac OS / Apple Si)
« Reply #4 on: June 25, 2025, 09:28:37 pm »
I am offline for today. But try ChatGPT by yourself. You must be harsh and insist on one single link. Finally I got it. The first attempts were those chatty failures.

Thanks for you help attempt.  But 2 observations:

1- it did not work.
2- ChatGPT, at least the unpaid model online, uses internet datascrapes that date back to 2021 or so.  (Subscription ChatGPT uses up to very recent information).

As always with ChatGPT, one must take care to review what it provides to make sure it is relevant, correct, and contains no obvious boo-boos.  Why coding with LLM's is fraught with hazard and still requires analysis of the code to be sure it is good.
Everyone talks about the weather but nobody does anything about it.
..Samuel Clemens.

cdbc

  • Hero Member
  • *****
  • Posts: 2246
    • http://www.cdbc.dk
Re: Can't find latest fpc (not Lazarus) (Mac OS / Apple Si)
« Reply #5 on: June 25, 2025, 09:31:58 pm »
Hi
FPC 3.3.1 does NOT come prepackaged.
You can:
1) Use FpcUpDeluxe to install it in your /home/you/fpc331/ directory
2) Download the source from GitLab
3) Use GIT to clone the repository and build it from there. This has the
    advantage, that you can easily update main/trunk, when you feel like it.
Regards Benny
If it ain't broke, don't fix it ;)
PCLinuxOS(rolling release) 64bit -> KDE5 -> FPC 3.2.2 -> Lazarus 3.6 up until Jan 2024 from then on it's both above &: KDE5/QT5 -> FPC 3.3.1 -> Lazarus 4.99

AlanTheBeast

  • Sr. Member
  • ****
  • Posts: 390
  • My software never cras....
Re: Can't find latest fpc (not Lazarus) (Mac OS / Apple Si)
« Reply #6 on: June 25, 2025, 10:51:10 pm »
Hi
FPC 3.3.1 does NOT come prepackaged.
You can:
1) Use FpcUpDeluxe to install it in your /home/you/fpc331/ directory
2) Download the source from GitLab
3) Use GIT to clone the repository and build it from there. This has the
    advantage, that you can easily update main/trunk, when you feel like it.
Regards Benny

Well - that would explain it!  %)
I'll use FpcUpDeluxe as I need it for something else in any case.
Thanks!

Update: I DL'd FpcDeLuxe from github and on install MacOS declares it damaged.  I've messaged @DonAlfredo here in LazForum.


« Last Edit: June 25, 2025, 11:12:03 pm by AlanTheBeast »
Everyone talks about the weather but nobody does anything about it.
..Samuel Clemens.

rca

  • Full Member
  • ***
  • Posts: 104
Re: Can't find latest fpc (not Lazarus) (Mac OS / Apple Si)
« Reply #7 on: June 26, 2025, 02:45:21 am »
Well - that would explain it!  %)
I'll use FpcUpDeluxe as I need it for something else in any case.
Thanks!

Update: I DL'd FpcDeLuxe from github and on install MacOS declares it damaged.  I've messaged @DonAlfredo here in LazForum.

Try what it says in the readme:
https://github.com/LongDirtyAnimAlf/fpcupdeluxe?tab=readme-ov-file#apple-osx

Code: Bash  [Select][+][-]
  1. xattr -cr fpcupdeluxe-aarch64-darwin-cocoa.app

Thaddy

  • Hero Member
  • *****
  • Posts: 17379
  • Ceterum censeo Trump esse delendam
Re: Can't find latest fpc (not Lazarus) (Mac OS / Apple Si)
« Reply #8 on: June 26, 2025, 07:15:43 am »
There are no pre-builds - officially - for 3.3.1 at all.
(there used to be an option zipinstall, but that does not seem to work on newer macs)
Hence I protected the code with a warning.
You should build it from source, which is not very difficult if 3.2.2 is installed and git is installed.

If you really have problems building from source I can guide you through the steps.
« Last Edit: June 26, 2025, 07:19:25 am by Thaddy »
Due to censorship, I changed this to "Nelly the Elephant". Keeps the message clear.

dbannon

  • Hero Member
  • *****
  • Posts: 3407
    • tomboy-ng, a rewrite of the classic Tomboy
Re: Can't find latest fpc (not Lazarus) (Mac OS / Apple Si)
« Reply #9 on: June 26, 2025, 10:02:46 am »
You should build it from source, which is not very difficult if 3.2.2 is installed and git is installed.

You don't need git, just download a zip ball. If its just a one off, easier and much kinder on disk and bandwidth.

Davo
Lazarus 3, Linux (and reluctantly Win10/11, OSX Monterey)
My Project - https://github.com/tomboy-notes/tomboy-ng and my github - https://github.com/davidbannon

Nicole

  • Hero Member
  • *****
  • Posts: 1207
Re: Can't find latest fpc (not Lazarus) (Mac OS / Apple Si)
« Reply #10 on: June 26, 2025, 10:41:38 am »
@Alan, yes, this is true.
This is the reason why I added the hint, I got it "only" from ChatGPT. You shall be warned.

CI says about itself, it would only have data from 2021 and cannot search the internet. Another false information. Some elements it insists on old and false sources, some other seems to be trained. Evidently it uses GIT.

The quality of the output varies much. On some days it worked for me like an assistant, wrote code, found snipes and syntax errors. What I use it are e.g. string-manipulation or missing brackets search. Or SQL queries. Simple code, it writes more quickly than me.

And then are those days, where you say "you are fired". Well, there is a cross in the top right corner for such days. To sum up: The servers behind seem to differ much from day to day.

What I got many times are things like this:

myStringList.Add('I am stupid');
myStringList:=TStringList.Create;

Then I say, "this must crash"
In those cases CI says, "You are absolutely correct. I am sorry, that I have confused you" and explains me, why it crashes.

In the long run, CI wll take lots of jobs. The first jobs will be those of programmers. Not because, CI would be able to do the job, - but because greedy bosses think, it would. They will pay the CI-subscriptions and hope, they would get the same quality for a much cheaper price. We all will suffer from this. If you are programmer or customer.

Thaddy

  • Hero Member
  • *****
  • Posts: 17379
  • Ceterum censeo Trump esse delendam
Re: Can't find latest fpc (not Lazarus) (Mac OS / Apple Si)
« Reply #11 on: June 26, 2025, 12:49:07 pm »
You should build it from source, which is not very difficult if 3.2.2 is installed and git is installed.

You don't need git, just download a zip ball. If its just a one off, easier and much kinder on disk and bandwidth.

Davo
I am aware not everybody has a glass fiber connection. But I never used a tarball or zip for fpc.
For me, a proper setup and git works best.
Ten years ago I would eat 1/5 of AIX. Now it is common, I tend to forget that.... :D (at least in NL)

I am doing a Bil Gates 640k now:who cares about bandwidth..
So sorry, and you woke me up.

Anyway, build from source. You do not have to use fpcupdeluxe for that, just 3.2.2.
« Last Edit: June 26, 2025, 12:59:50 pm by Thaddy »
Due to censorship, I changed this to "Nelly the Elephant". Keeps the message clear.

AlanTheBeast

  • Sr. Member
  • ****
  • Posts: 390
  • My software never cras....
Re: Can't find latest fpc (not Lazarus) (Mac OS / Apple Si)
« Reply #12 on: June 26, 2025, 05:50:04 pm »
Using fpcupdeluxe installed 3.3.1 - I can find it - but the OS can't - always goes to the previously installed 3.2.2 (which I put way down in the system folders at /usr/local/bin/fpc a couple years ago).

So I renamed fpc (3.2.2) to fpcxxx ....

Exported a path to the new fpc (3.3.1) but the OS can't seem to find it.
(If I run fpc from that folder, then 3.3.1 happily comes up).

Is this something FPCupDeluxe is supplosed to handle , or not?

Can't locate the tarball on Github either - as I'd try to re-build 3.3.1 from scratch with 3.2.2...

UPDATE - managed to git something ... /standby
 >:( git downloaded the x86 / Win version.  Of course.   F-it.  Time for lunch - will resume tomorrow.
:-[ Because: I didn't read the Wiki carefully.  That's why.  /later.

I suck at this shit.  No contest.

Another attempt (2025-06-26@15:00 ish):
- installed again using FpcUpDeluxe (having gotten hopelessly lost trying to do it other ways ...

Result trying to compile Thaddy's code (with 3.3.1):
Quote
/Users/alanbeast/pascal $ fpc -k"-framework Cocoa" machtimeexample
Free Pascal Compiler version 3.3.1-18074-ge8b6075311-dirty [2025/06/24] for aarch64
Copyright (c) 1993-2025 by Florian Klaempfl and others
Target OS: Darwin for AArch64
Compiling machtimeexample.pas
Fatal: Can't find unit system used by MachTimeExample
Fatal: Compilation aborted
Error: /usr/local/bin/ppca64 returned an error exitcode

Nor can I compile my own stuff - so installing 3.3.1 remains a mystery for me.
« Last Edit: June 26, 2025, 10:17:06 pm by AlanTheBeast »
Everyone talks about the weather but nobody does anything about it.
..Samuel Clemens.

dbannon

  • Hero Member
  • *****
  • Posts: 3407
    • tomboy-ng, a rewrite of the classic Tomboy
Re: Can't find latest fpc (not Lazarus) (Mac OS / Apple Si)
« Reply #13 on: June 27, 2025, 02:55:33 am »
Alan, you need to look at the PATH and the contents of fpc.cfg. fpcupdeluxe has its own way to manage this but it sounds like you don't use that ? Thats OK but you will need to learn about PATH and fpc.cfg

From your command line try -

Code: Bash  [Select][+][-]
  1. $> echo $PATH

You will see a of directories separated by ':'.  One entry will be where your existing fpc322 is. You could, for this terminal session, add the path to where ever you 3.3.1 is installed, so it appears before (!) the existing content.

Code: Bash  [Select][+][-]
  1. $> export PATH="path_to_331":$PATH

Where you (obviously) replace "path_to_331" with the full path to the ~/bin directory in your fpcupdeluxe 331 install. Then fpc.cfg, I am expecting  fpcupdeluxe has made a fpc.cfg up in its own /etc directory, its probably all you need, copy it to $HOME (bck p exosting one first) as .fpc.cfg

Or use the script that  fpcupdeluxe provides, fpc.bash (???), it will ensure fpc uses the correct fpc.cgf. Your command line will find that script AFTER you have set that PATH as above.

But, honestly, fpcupdeluxe does set these things up for you, you would probably be better using its system, its a constraint, you must do things fpcupdeluxe's way but it works. If you cannot use the fpcupdeluxe model, go back to building your FPC331 by hand in a directory of your choice.

Davo
Lazarus 3, Linux (and reluctantly Win10/11, OSX Monterey)
My Project - https://github.com/tomboy-notes/tomboy-ng and my github - https://github.com/davidbannon

AlanTheBeast

  • Sr. Member
  • ****
  • Posts: 390
  • My software never cras....
Re: Can't find latest fpc (not Lazarus) (Mac OS / Apple Si)
« Reply #14 on: June 27, 2025, 09:32:35 pm »
Thanks,

I did have the path set up to the location of the 3.3.1 version and thus on simply entering fpc I would get the 3.3.1 version reported as I noted earlier.  See in red below.

Quote
/Users/alanbeast/pascal $ fpc -k"-framework Cocoa" machtimeexample
Free Pascal Compiler version 3.3.1-18074-ge8b6075311-dirty [2025/06/24] for aarch64
Copyright (c) 1993-2025 by Florian Klaempfl and others
Target OS: Darwin for AArch64
Compiling machtimeexample.pas
Fatal: Can't find unit system used by MachTimeExample
Fatal: Compilation aborted
Error: /usr/local/bin/ppca64 returned an error exitcode

Further, with the above my own code would no longer compile either.  So wiped out the 331 v., restored the 3.2.2 from TM and  reset the path.

I don't have time to work on this until next week where I'll start all over until I get it right.  I'll let FPCUpDeluxe rule ...

Maybe hear some of you on ARRL Field Day this weekend, I'll be under club colours as VE2CRL.
73
Beast.
« Last Edit: June 27, 2025, 10:33:29 pm by AlanTheBeast »
Everyone talks about the weather but nobody does anything about it.
..Samuel Clemens.

 

TinyPortal © 2005-2018