Recent

Author Topic: Can't get 32 bit packages installed  (Read 1610 times)

geraldholdsworth

  • Jr. Member
  • **
  • Posts: 53
Re: Can't get 32 bit packages installed
« Reply #15 on: January 07, 2021, 02:07:05 pm »
Because of the length of the output, I've attached it as a text file.

I can't see any Errors, but there are 344 warnings. But these don't look too troublesome.

On doing the ls -la /usr/bin/ppcross386 command I was told that the folder does not exist (it's in the log), so I went to Finder and created the folder. I now get a couple of different errors when trying to switch to 32 bit:
Code: [Select]
The current FPC has no config file. It will probably miss some units. Check your installation of fpc.and then
Code: [Select]
The project uses target OS=linux and CPU=i386.
The system.ppu for this project was not found in the FPC binary directories.
Make sure fpc is installed correctly for this target and the fpc.cfg contains the right directories.

And, yes, you are correct - I used 3.2.0 of the FPC. In fact, the three DEB files I have are:
fpc-laz_3.2.0-1_amd64.deb
fpc-src_3.2.0-1_amd64.deb
lazarus-project_2.0.10-0_amd64.deb

They were actually downloaded through Safari on the Mac, but I can't see that making any difference.

Cheers,

Gerald.

geraldholdsworth

  • Jr. Member
  • **
  • Posts: 53
Re: Can't get 32 bit packages installed
« Reply #16 on: January 07, 2021, 05:20:49 pm »
I've done a bit more investigating...haven't got anywhere, but I've got some info that might help - or might be irrelevant.

First, I did a search for system.ppu and found it in:
/usr/lib/fpc/3.2.0/units/i386-linux/rtl
/usr/lib/fpc/3.2.0/units/x86_64-linux/rtl
/usr/local/lib/fpc/3.2.0/units/i386-linux/rtl
/usr/share/fpcsrc/3.2.0/rtl/units/i386-linux
/usr/share/fpcsrc/3.2.0/rtl/units/x86_64-linux

I also went back to the instructions. Right at the start it mentions editing the fpc.cfg file, but also mentions to check that the files are in there - screen shot attached. I've also attached the fpc.cfg file. Again, probably irrelevant.

Cheers,

Gerald.

dbannon

  • Hero Member
  • *****
  • Posts: 1295
    • tomboy-ng, a rewrite of the classic Tomboy
Re: Can't get 32 bit packages installed
« Reply #17 on: January 08, 2021, 01:35:36 am »
OK, about your note that the folder does not exist and you created it ?

Do you mean the message Cannot access '/usr/bin/ppcross386': No such file or directory ?  I believe that message is telling you that the file (binary or symlink) ppcross386 does not exist. But if you then had to create /usr/bin its a whole new ball game !  Linux mint ?  Based on Debian ?  I believe you should already have a /usr/bin and it should already have a heap of binaries in it.  If now, then your main bin dir is /usr/local/bin  We can easily check, please type echo $PATH and send the output. Or look in /usr/bin and see if there are lots of files there that are dated before you ran the install.

If your system does not use /usr/bin then the install command should have been -
Code: Bash  [Select][+][-]
  1. $ sudo make crossinstall CPU_TARGET=i386

Now, continuing on incase the above is a non issue -

Everything seems to work fine, its just that you don't end up with ppcross386 in your /usr/bin directory.  I am petty sure that it should be a symlink but not certain (I install mine a bit differently).

I see clearly where ppcross386 is built, its in /usr/share/fpcsrc/3.2.0/compiler/ppcross386

It gets 'installed' to /usr/lib/fpc/3.2.0/ppcross386
(which is a strange FPC-ism, we should not have executables under /usr/lib but thats what they do!)

Can you please check to see if those files are there ?

If so, lets cheat a bit and see if you can create the necessary symlink ?

Code: Bash  [Select][+][-]
  1. sudo ln -s    /usr/lib/fpc/3.2.0/ppcross386    /usr/bin/ppcross386

Another issue is the fashionable alternative directory, please run this command -

Code: Bash  [Select][+][-]
  1. ls -l /etc/alternatives/pp*

Its a means of easily swapping which versions of things you use. You should see a symlink to our ppcross386 there too, interesting to see where it points.

Sorry this is becoming such a epic task, it really should not be !  It will be usefull to see why its such a problem for you and correct the wiki ....

Davo

some notes as I look through your log -

Interesting stuff starts at #813, ppcross386 seems to be built without issues.

Install starts at #2909

#2924 copies /usr/share/fpcsrc/3.2.0/compiler/ppcross386 to /usr/lib/fpc/3.2.0/ppcross386
Lazarus 2, Linux (and reluctantly Win10, OSX)
My Project - https://github.com/tomboy-notes/tomboy-ng

geraldholdsworth

  • Jr. Member
  • **
  • Posts: 53
Re: Can't get 32 bit packages installed
« Reply #18 on: January 08, 2021, 09:37:33 am »
OK, about your note that the folder does not exist and you created it ?
The folder 'ppcross386' did not exist, so I created it. I've removed it now.
If now, then your main bin dir is /usr/local/bin  We can easily check, please type echo $PATH and send the output. Or look in /usr/bin and see if there are lots of files there that are dated before you ran the install.
Code: Bash  [Select][+][-]
  1. gerald@gerald-VirtualBox:~$ echo $PATH
  2. /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin
There were loads of files dated before I installed Lazarus. The two I created where the newest, while the rest appeared to be dated before I installed Linux.
Code: Bash  [Select][+][-]
  1. $ sudo make crossinstall CPU_TARGET=i386
Failed with 'No rule to make target crossinstall'.
It gets 'installed' to /usr/lib/fpc/3.2.0/ppcross386
(which is a strange FPC-ism, we should not have executables under /usr/lib but thats what they do!)

Can you please check to see if those files are there ?
Yep, there are there.
If so, lets cheat a bit and see if you can create the necessary symlink ?

Code: Bash  [Select][+][-]
  1. sudo ln -s    /usr/lib/fpc/3.2.0/ppcross386    /usr/bin/ppcross386
Ran, no problems and no output.
Another issue is the fashionable alternative directory, please run this command -

Code: Bash  [Select][+][-]
  1. ls -l /etc/alternatives/pp*

Its a means of easily swapping which versions of things you use. You should see a symlink to our ppcross386 there too, interesting to see where it points.
Code: Bash  [Select][+][-]
  1. ls: cannot access '/etc/alternatives/pp*': No such file or directory
The /etc/alternatives/ folder is there, just nothing starting with pp inside.
Sorry this is becoming such a epic task, it really should not be !  It will be usefull to see why its such a problem for you and correct the wiki ....
Needs be. If I have problems, someone else also might.

After doing the above, I tried cross compiling in Lazarus again and it worked.

If there's any more tests you'd like me to run, I'm happy to do so.

Many thanks,

Gerald.

dbannon

  • Hero Member
  • *****
  • Posts: 1295
    • tomboy-ng, a rewrite of the classic Tomboy
Re: Can't get 32 bit packages installed
« Reply #19 on: January 08, 2021, 10:17:47 am »
OK, so it worked because you created an appropriate symlink with the -

Code: Bash  [Select][+][-]
  1. sudo ln -s    /usr/lib/fpc/3.2.0/ppcross386    /usr/bin/ppcross386

command.  That should have happened during the install phase, I cannot see why it did not.  If you now run

ls -la /usr/bin/ppc*

you will see it there. I guess I will build a Mint VM and see if I can replicate this issue. In the mean time, use it by all means if its working but do keep in mind that 'something' went wrong during the initial install.

Davo
Lazarus 2, Linux (and reluctantly Win10, OSX)
My Project - https://github.com/tomboy-notes/tomboy-ng

MarkMLl

  • Hero Member
  • *****
  • Posts: 2073
Re: Can't get 32 bit packages installed
« Reply #20 on: January 08, 2021, 10:25:28 am »
Well done Gerald, and thanks for keeping people updated with your conclusions.

MarkMLl
Turbo Pascal v1 on CCP/M-86, multitasking with LAN and graphics in 128Kb.
Pet hate: people who boast about the size and sophistication of their computer.

geraldholdsworth

  • Jr. Member
  • **
  • Posts: 53
Re: Can't get 32 bit packages installed
« Reply #21 on: January 08, 2021, 01:53:14 pm »
I guess I will build a Mint VM and see if I can replicate this issue. In the mean time, use it by all means if its working but do keep in mind that 'something' went wrong during the initial install.
Thank you for all your help Davo.

I'll probably also try and replicate this on another machine - I've got a laptop I installed Mint on, and have installed Lazarus but hardly used it, so I'll see if it does the same thing.

Cheers,

Gerald.

geraldholdsworth

  • Jr. Member
  • **
  • Posts: 53
Re: Can't get 32 bit packages installed
« Reply #22 on: January 17, 2021, 02:55:56 pm »
Just as a 'FYI'...I fired up my Linux laptop, which had a fresh, hardly used, install of Lazarus 64 bit on it and tried installing the same cross compiler with the same result. I did note that it produced a couple of errors after the first command, which I typed in what it suggested (which didn't work).

Anyway, I pressed on and found, as before, that Lazarus wouldn't compile in 32 bit mode. So I ran the extra line Davo suggested and it now works. I've attached the logs, for information.

Cheers,

Gerald.

MarkMLl

  • Hero Member
  • *****
  • Posts: 2073
Re: Can't get 32 bit packages installed
« Reply #23 on: January 17, 2021, 03:03:50 pm »
So for completeness, what fp* and ppc* files do you have in your /usr/bin and /usr/local/bin directories and what is your PATH?

I suggest appending the output of

Code: [Select]
ls -l /usr/bin/fp*
ls -l /usr/bin/ppc*
ls -l /usr/local/bin/fp*
ls -l /usr/local/bin/ppc*
echo $PATH

MarkMLl
Turbo Pascal v1 on CCP/M-86, multitasking with LAN and graphics in 128Kb.
Pet hate: people who boast about the size and sophistication of their computer.

geraldholdsworth

  • Jr. Member
  • **
  • Posts: 53
Re: Can't get 32 bit packages installed
« Reply #24 on: January 17, 2021, 06:36:42 pm »
I get:
Code: Bash  [Select][+][-]
  1. gerald@Laptop2:~$ ls -l /usr/bin/fp*
  2. -rwxr-xr-x 1 root root 4771200 Jul  7  2020 /usr/bin/fp
  3. -rw-r--r-- 1 root root    4515 May 16  2005 /usr/bin/fp.ans
  4. -rwxr-xr-x 1 root root  508112 Jul  7  2020 /usr/bin/fpc
  5. -rwxr-xr-x 1 root root 1061488 Jul  7  2020 /usr/bin/fpcjres
  6. -rwxr-xr-x 1 root root 1436032 Jul  7  2020 /usr/bin/fpclasschart
  7. -rwxr-xr-x 1 root root 1010928 Jul  7  2020 /usr/bin/fpcmake
  8. -rwxr-xr-x 1 root root 1269456 Jul  7  2020 /usr/bin/fpcmkcfg
  9. -rwxr-xr-x 1 root root 1062272 Jul  7  2020 /usr/bin/fpcres
  10. -rwxr-xr-x 1 root root  855552 Jul  7  2020 /usr/bin/fpcsubst
  11. -rwxr-xr-x 1 root root 2570080 Jul  7  2020 /usr/bin/fpdoc
  12. -rwxr-xr-x 1 root root 2414864 Jul  7  2020 /usr/bin/fppkg
  13. -rwxr-xr-x 1 root root  873472 Jul  7  2020 /usr/bin/fprcp
  14. -rwxr-xr-x 1 root root   14640 Apr 16  2020 /usr/bin/fprintd-delete
  15. -rwxr-xr-x 1 root root   23408 Apr 16  2020 /usr/bin/fprintd-enroll
  16. -rwxr-xr-x 1 root root   14640 Apr 16  2020 /usr/bin/fprintd-list
  17. -rwxr-xr-x 1 root root   14720 Apr 16  2020 /usr/bin/fprintd-verify
  18. gerald@Laptop2:~$ ls -l /usr/bin/ppc*
  19. lrwxrwxrwx 1 root root 29 Jan 17 11:15 /usr/bin/ppcross386 -> /usr/lib/fpc/3.2.0/ppcross386
  20. lrwxrwxrwx 1 root root 25 Dec 10 15:45 /usr/bin/ppcx64 -> /usr/lib/fpc/3.2.0/ppcx64
  21. gerald@Laptop2:~$ ls -l /usr/local/bin/fp*
  22. -rw-r--r-- 1 root root 4515 May 16  2005 /usr/local/bin/fp.ans
  23. gerald@Laptop2:~$ ls -l /usr/local/bin/ppc*
  24. ls: cannot access '/usr/local/bin/ppc*': No such file or directory
  25. gerald@Laptop2:~$ echo $PATH
  26. /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin
  27.  

 

TinyPortal © 2005-2018