Welcome, Guest
Username: Password: Remember me
CodeTyphon Cross-Build Development, discussions and problems
  • Page:
  • 1

TOPIC:

How to build app for Raspberry Pi from Windows 7 11 years 1 month ago #4616

  • Rabiul
  • Rabiul's Avatar Topic Author
  • Offline
  • New Member
  • New Member
  • Posts: 5
  • Thank you received: 2
Hello all,
Greetings.

I am new to CodeTyphon, as well as Raspberry Pi. I have installed CodeTyphon version 4.5 on Windows 7. I have built a small test application for windows 7 without any problem. Now, I want to make/crossbuild application for Raspberry Pi from Windows. Can someone please let me know the details to achieve this? A step by step guide is really appreciated.

Thank you in advance.

Best regards.

Please Log in or Create an account to join the conversation.

How to build app for Raspberry Pi from Windows 7 11 years 1 month ago #4625

  • Rain
  • Rain's Avatar
  • Offline
  • Junior Member
  • Junior Member
  • Posts: 71
  • Thank you received: 8
The fastest way to use lazarus is using it on the Raspberry itself:

sudo apt-get update
sudo apt-get upgrade
sudo apt-get install fpc
sudo apt-get install lazarus

Of course the additional components from pl_* are not present in this solution.
If those are really required, the usual cross compiling is needed, including collecting all raspbian libs for linking etc. (Not tested yet myself, am happy with first described solution)

Please Log in or Create an account to join the conversation.

How to build app for Raspberry Pi from Windows 7 11 years 1 month ago #4627

  • Rain
  • Rain's Avatar
  • Offline
  • Junior Member
  • Junior Member
  • Posts: 71
  • Thank you received: 8
Here a picture of lazarus running on ARM Raspberry, using X-Forwarding (Xming 6.9.0.31) via SSH to display on Windows7:
Command line in SSH terminal is:
pi@raspberrypi ~ $ lazarus-ide &

Please Log in or Create an account to join the conversation.

Last edit: by Rain.

How to build app for Raspberry Pi from Windows 7 11 years 1 month ago #4628

  • Rabiul
  • Rabiul's Avatar Topic Author
  • Offline
  • New Member
  • New Member
  • Posts: 5
  • Thank you received: 2
Alhamdulillah.

Thanks for your reply. I understand that it's best to build the application on the platform itself. But, I wanted to crossbuild for testing or whatever else I don't know clearly, may be on the Raspberry pi it will compile slower than Windows 7, however.... Anyway, I was successful to achieve this. I shall describe bellow what I did (probably this may help someone.), although I don't know whether all the steps are correct/necessary or not. But it worked. And the post here helped - www.pilotlogic.com/sitejoom/index.php/fo...ian-app?limitstart=0 , I have downloaded the libraries from the link mentioned in the 1st post - docs.google.com/folder/d/0B-v0GC8WoWuad0...FtZG43T1U/edit?pli=1 .

Steps:
======
Download CodeTyphon Studio Version 4.5, Revision 004500 (for win7 32bit)

Run install.bat

Select "Install CodeTyphon"

Select "Remove and Build ALL"

This will install CodeTyphon Studio.

Run "C:\codetyphon\binCenter\i386-win32-win32\CodeTyphon.exe" which has a shortcut icon on desktop named CodeTyphon64

Click menu "CrossBuild"->"Toolchains Builder". For "FPC Target CPU-OS", select "arm-linux". Click "Build" button. See Image-1 bellow:

Image-1


After the above building process finishes, click menu "CrossBuild"->"FreePascal32bits"->"FPC32 build cross element arm-linux". See Image-2 bellow:

Image-2


Click menu "Typhon"->"Run Typhon32"

After the IDE opens, click menu "Project"->"Project Options".

Select "Compiler Options"->"Paths". For "Libraries" box select the folder that contains Raspberry Pi libraries (which can be downloaded from the link given above... 1st post of the another topic). See Image-3 bellow:

Image-3


Select "Config and Target". For "Target OS" - select "Linux", for "Target CPU family" - select "arm". See Image-4 bellow:

Image-4


Select "Debugging", Uncheck "Generate debugging info...". See Image-5 bellow:

Image-5


Click OK, and write then build your project :). Thank you all.

Best regards.
The following user(s) said Thank You: Rain

Please Log in or Create an account to join the conversation.

How to build app for Raspberry Pi from Windows 7 11 years 1 month ago #4632

  • zeljko
  • zeljko's Avatar
  • Offline
  • Junior Member
  • Junior Member
  • Posts: 207
  • Thank you received: 38
board beaglebone black
install: ubuntu-precise-12.04.2-armhf-3.8.13-bone20.img
- update
- upgrade
- install lxde
- intall firebird2.1-super
- install flamerobin
- install fpc
- install lazarus
fpc and lazarus work

codetyphon 4.5 compile cross arm-linux
project1 not work error:

Field to execute child process "/home/ubuntu/Desktop/project1"
(No such file or directory)


any help

Please Log in or Create an account to join the conversation.

How to build app for Raspberry Pi from Windows 7 11 years 1 month ago #4655

  • chulwoong
  • chulwoong's Avatar
  • Offline
  • New Member
  • New Member
  • Posts: 15
  • Thank you received: 2
Dear Seven,

Have you tried to used a scrollbar in your application?
In my case, my application crashes whenever I change scrollbar.
How about yours?

Please Log in or Create an account to join the conversation.

How to build app for Raspberry Pi from Windows 7 11 years 1 month ago #4658

  • Rabiul
  • Rabiul's Avatar Topic Author
  • Offline
  • New Member
  • New Member
  • Posts: 5
  • Thank you received: 2
Hello 'emailadd',

I haven't see raspberry pi much till now, so don't know about it much. Doing some other projects. Right now, I have "RaspbianMate" OS ( RaspbianMate ) on the SD card. I made a small application which has "TMemo" with both scrollbars. I put some text in it to fill the box. WordWrap set to False for testing horizontal scrollbar. Both the scrollbar worked ok, and application didn't crash.

I shall try it on default Raspbian OS. And let you know the result when completed :).

Best regards.

Please Log in or Create an account to join the conversation.

How to build app for Raspberry Pi from Windows 7 11 years 1 month ago #4659

  • chulwoong
  • chulwoong's Avatar
  • Offline
  • New Member
  • New Member
  • Posts: 15
  • Thank you received: 2
Thanks for you reply.
Can I have one more question?
When I built my app, it had a scrollbar and Label. The Label was upposued t o show the current scrollbar value. However, it was crashed if I tried to change the scrollbar position.
Do you think the same thing happens on your enviroment?

Please Log in or Create an account to join the conversation.

How to build app for Raspberry Pi from Windows 7 11 years 1 month ago #4660

  • Rabiul
  • Rabiul's Avatar Topic Author
  • Offline
  • New Member
  • New Member
  • Posts: 5
  • Thank you received: 2
It would be better if you can upload the project somewhere, then I can download it and compile for testing. Don't hesitate for asking question, not 1 ask 100 :). If it is beyond my capability I shall answer.

Best regards.

Please Log in or Create an account to join the conversation.

How to build app for Raspberry Pi from Windows 7 11 years 1 month ago #4661

  • chulwoong
  • chulwoong's Avatar
  • Offline
  • New Member
  • New Member
  • Posts: 15
  • Thank you received: 2
Dear Seven,

I am enclosing my test project.
Would you test this project with your cross compile enviroment at Raspberry Pi?
Attachments:

Please Log in or Create an account to join the conversation.

How to build app for Raspberry Pi from Windows 7 11 years 1 month ago #4664

  • Rabiul
  • Rabiul's Avatar Topic Author
  • Offline
  • New Member
  • New Member
  • Posts: 5
  • Thank you received: 2
Dear 'emailadd',
I have tested it. And yes, it crashes if I try to use the ScrollBar.

Please Log in or Create an account to join the conversation.

  • Page:
  • 1