Recent

Author Topic: WinCE-cpuarm compilation problem {$asmmode GAS}  (Read 13261 times)

roeug

  • Jr. Member
  • **
  • Posts: 67
    • http://roeug.50megs.com/
WinCE-cpuarm compilation problem {$asmmode GAS}
« on: October 18, 2006, 08:47:13 pm »
WinCE-cpuarm compilation problem {$asmmode GAS}

Lazarus-0.9.19-fpc-2.1.1-20061018-win32.exe - Installed (default paths)
New Project

Project->Compiler options
1. LCL widget typr: wince
2. target OS: WinCE
3. target CPU: arm

Environment \ Compiler Options
Compiler path (not changed): c:\lazarus\fpc\2.1.1\bin\i386-win32\ppc386.exe


Ctrl+F9
C:\lazarus\fpc\2.1.1\source\rtl\inc\system.inc(80,4) Fatal: Can't open include file "i386.inc"
Added to c:\lazarus\fpc\2.1.1\source\rtl\inc\system.inc  (Line 1-5)
{$ifdef wince}
 {$define arm}
 {$define cpuarm}
 {$undef cpui386}
{$endif cpuarm}


Ctrl+F9
C:\lazarus\fpc\2.1.1\source\rtl\arm\arm.inc(18,2) Error: Illegal assembler style specified "GAS"
in the line: {$asmmode GAS}


later when open the progect I det a messageBox (mbError)
"The system.ppu was not found in the FPC dirrectory.Make sure fpc is installed correctly and the fpc.cfg points to the right directory"

In the case of
 LCL widget typr: win32
 target OS: Win32
 target CPU: i386
everything is OK (no messages with the "The system.ppu was not found...", build, run)

felipemdc

  • Administrator
  • Hero Member
  • *
  • Posts: 3538
Re: WinCE-cpuarm compilation problem {$asmmode GAS}
« Reply #1 on: October 18, 2006, 09:26:19 pm »
The lazarus snapshot you are using does not contain a arm-wince cross-compiler, which is needed to compile for Windows CE.

Quote from: "roeug"

Environment \ Compiler Options
Compiler path (not changed): c:\lazarus\fpc\2.1.1\bin\i386-win32\ppc386.exe


Take a look at your compiler name. It's ppc386. The name of the cross compiler is ppccrossarm.exe

You should install the Snapshot on the bottom of this webpage:

http://wiki.lazarus.freepascal.org/Windows_CE_Interface

It already comes pre-configured to work for Windows CE, with a pre-compile cross-compiler and everything set.

Another (harder) option to get this working is to compile the cross-compiler yourself. There are instructions for this on the webpage above.

roeug

  • Jr. Member
  • **
  • Posts: 67
    • http://roeug.50megs.com/
RE: Re: WinCE-cpuarm compilation problem {$asmmode GAS}
« Reply #2 on: October 19, 2006, 09:18:22 am »
I've tryed http://www.see-cure.de/files/lazarus-arm-wince-20060707.7z early
I don't no why but the compilled code doesn't run on WM5 (and a lot of problems in compillation process: only emty forms are compilled !!!)
Thanks
PS. I am a researcher but programmer (I've used Delphi5)
Now I am trying to convert my Appl (http://snow.prohosting.com/roeug/NKE.htm ) to iPOD. If you have any suggestions ! would be luck to hear

CCRDude

  • Hero Member
  • *****
  • Posts: 596
RE: Re: WinCE-cpuarm compilation problem {$asmmode GAS}
« Reply #3 on: October 19, 2006, 10:53:00 am »
Well, I used that version to write an app that actually runs quite well on many WM5 devices - but using native API, not LCL. MAybe that LCL version is a bit outdated; I'll try to create a new snapshot in the next days, need to set up Lazarus on another machine anyway.

felipemdc

  • Administrator
  • Hero Member
  • *
  • Posts: 3538
Re: RE: Re: WinCE-cpuarm compilation problem {$asmmode GAS}
« Reply #4 on: October 19, 2006, 01:02:54 pm »
Quote from: "roeug"
I don't no why but the compilled code doesn't run on WM5


Ummm, acctually I only have Microsoft emulator to test, so it's hard to debug this.

Quote
(and a lot of problems in compillation process: only emty forms are compilled !!!)


What errors in the compilation? Can you paste them here?

Quote
Now I am trying to convert my Appl (http://snow.prohosting.com/roeug/NKE.htm ) to iPOD.


iPod runs Windows Mobile 5 ?

My best quick solution is to use the Windows API directly (like you would have to do anyway if you were programming for c, or c++), or use a smaller framework. I think CCRDude had done one some time ago, but I don't remember the link.

CCRDude

  • Hero Member
  • *****
  • Posts: 596
RE: Re: RE: Re: WinCE-cpuarm compilation problem {$asmmode G
« Reply #5 on: October 19, 2006, 03:51:23 pm »
I tested on real WM 5 devices, both PocketPC and Smartphone :)
The only exception is Windows Mobile 2003 Smartphone edition, which needs different binaries for some reason.

Example without any classes
Mini framework for CE native API (Win32 compatible fdor testing)
Documentation of the above
Sorry that I didn't find the time recently to continue on this topic, otherwise I probably would've helped with the LCL; that framework was just a solution I needed quickly ;)

felipemdc

  • Administrator
  • Hero Member
  • *
  • Posts: 3538
Re: RE: Re: RE: Re: WinCE-cpuarm compilation problem {$asmmo
« Reply #6 on: October 19, 2006, 07:21:57 pm »
Quote from: "CCRDude"
Sorry that I didn't find the time recently to continue on this topic, otherwise I probably would've helped with the LCL; that framework was just a solution I needed quickly ;)


I added a link to your framework on the windows ce page.

On the long run, my plan is to prepare fpGUI to become a small framework that people can use to write smaller windows CE application using Free Pascal, while the app remains cross-platform.

http://opensoft.homeip.net/fpgui/

There will also be a lcl-interface for fpgui.

roeug

  • Jr. Member
  • **
  • Posts: 67
    • http://roeug.50megs.com/
RE: Re: RE: Re: RE: Re: WinCE-cpuarm compilation problem {$a
« Reply #7 on: October 24, 2006, 08:18:29 pm »
Lazarus (Lazarus-0.9.19-fpc-2.1.1-20061018-win32.exe ) with Recompiled FPC works (OK? - Under testing)
Thanks everybody
PS. The main problem (at the moment) was NOT to use WindowStyles other than wsNormal

 

TinyPortal © 2005-2018