Re: [fpc-pascal] FPC + fpGUI + Raspberry Pi = fantastic

2012-09-13 Thread Den Jean
On Thursday 13 September 2012 19:55:04 Graeme Geldenhuys wrote:
> normal 'xwd' or 'import' applications where not available (the latter 
I do not have a Rasberry, but I noticed that libqt4pas-dev is available 
in the packages (just like on the N900). Thx to Matthias Klumpp. 

Would you be so kind to try one of the qt4 binding demo programs 
just to verify that it works ? Screenshots are welcome.

Btw fpGui is ofcourse fantastic :-) 

Package List:
http://archive.raspbian.org/raspbian/dists/wheezy/main/binary-armhf/Packages
brief listing: grep -P '^Package:' Packages | cut -d' ' -f2

Kind regards,

Den Jean





___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] libQT4Pas - Why it is needed?

2012-01-30 Thread Den Jean
On Monday 30 January 2012 23:08:36 Krzysztof wrote:
> > the qt interface. The gpl? license may or may not make that possible
the binding and Qt are LGPL 
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] libQT4Pas - Why it is needed?

2012-01-30 Thread Den Jean
On Monday 30 January 2012 09:28:00 michael.vancann...@wisa.be wrote:
> There are no plans to support it, since every C++ compiler uses it's own
> (incompatible) format, and G++ changes it format regularly, so I was 
> given to understand.
even with support for calling c++ methods,
the many inlined functions are still an issue
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] fpc 2.6.0-rc1 for arm-embedded

2011-12-08 Thread Den Jean
On Thursday 08 December 2011 13:49:16 Koenraad Lelong wrote:
> /usr/lib/fpc/2.6.0/units/arm-embedded/rtl/system.o does not support 
> interworking, whereas test-1.elf does
does this thread help ?
http://lists.freepascal.org/lists/fpc-devel/2011-August/025615.html
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] Getting Hardware information in Linux

2011-10-18 Thread Den Jean
On Tuesday 18 October 2011 19:36:48 ik wrote:
> Does anyone know or can point me on how to do it ?
read the output of lshw or read its source on how to do it yourself.
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] FPC i386 and x86_64 using the same source

2011-08-22 Thread Den Jean
On Monday 22 August 2011 23:24:29 Jonas Maebe wrote:
> 3. Install everything to the same prefix. Add CROSSINSTALL=1 to the "make
> install" line for which you do not want to install the utilities (e.g., if
> you want the default compiler to be the i386 one, add CROSSINSTALL=1 when
> installing the 64 bit compiler)
these options like crosszipinstall, crossinstall, ... are probably documented 
in a dozen places, albeit not visible enough for my blind eyes.
Wouldn't it be nice if they showed up in the BuildFaq 
http://www.stack.nl/~marcov/buildfaq.pdf

regards,

Den Jean
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Re: operator overloading and counting references / creating / destoying anonymous instances

2011-07-29 Thread Den Jean
On Friday 29 July 2011 13:43:58 Bernd wrote:
> With interfaces and their reference counting it can be made to work
> but the cost of doing this seems so immense that I don't believe it is
> justifiable in many real world applications (at least not in my
> application).
The performance penalty was the same reason 
why I abandoned the use of interfaces in the 
qt4 binding, just look at the way I used it in the qt2 binding:
Though it was pretty nifty, people may not be aware of 
the performance cost of such albeit nice abstractions.

http://qtforfpc.cvs.sourceforge.net/viewvc/qtforfpc/qte/demo/qteobjects.pas?revision=1.2&view=markup
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] FPC + Haiku

2011-01-31 Thread Den Jean
On Monday 31 January 2011 09:07:47 Marco van de Voort wrote:
> > Qt based in fact ;-) But, yes, Lazarus runs quite well. Integrated
Nice to know it still works
> If you are in Brussels again next week, don't forget to show me :-)
Fosdem ? 
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] CDDB unit

2010-12-19 Thread Den Jean
On Saturday 18 December 2010 23:56:24 Andrew Haines wrote:
> Does anyone have the cddb unit that was on the wiki once upon a time?
> http://wiki.lazarus.freepascal.org/CDDB
> 
> The link on that page is now dead.
is this one not useful ?
fpc/packages/cdrom/src/fpcddb.pp
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Status of fpc on Nokia n810

2009-08-22 Thread Den Jean
On Saturday 22 August  2009 18:21:38 Luca Olivetti wrote:
> You can buy the moses smartq5 on dealextreme, then install mer on it

are sources of all drivers available to recompile under Mer?
That is the problem always, like with zaurus or archos 5,
a lot of the H/W (audio, touchscreen, special keys, ... ) may 
not work on a non vendor linux OS (whilst vendor linux may not 
provide arm gcc).

I've heard it was rather slow, but faster with Mer 
(but no sound, keys, wifi not perfect...)

I am even considering TomTom (framebuffer), because they are not 
so expensive. If the project is accepted, the users would 
need to buy 100 devices, it is unlikely that they will accept to 
pay for something like the Asus R50A which is 1000 EUR over here.

thx for the info.

Den Jean 

 
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Status of fpc on Nokia n810

2009-08-22 Thread Den Jean
On Friday 21 August  2009 22:08:13 Luiz Americo Pereira Camara wrote:
> Recently, the price of Nokia n810 dropped significantly and i got some

because the N900 is almost out, but for my purposes 
the screen is less interesting than the N810.

http://linux.slashdot.org/story/09/08/21/1155217/Nokia-Leaks-Phone-With-Full-GNULinux-Distribution?art_pos=1

I am also seriously interested in the Optimae 5E with Maemo, 
but it will probably not be available in Europe. 
Any chinese FPC user reading this and interested in a percentage :-) ?

http://www.engadget.com/2009/07/16/optima-op5-e-mid-first-non-nokia-mid-to-run-maemo/

> interest in it, but before i buy i'd like to know if, currently, is
> possible to compile programs with fpc to this platform.
>
> Is someone using fpc to develop in such devices?

I will also procure one and try to develop Qt/FPC/Lazarus applications on it,
I do not expect problems (no garantie :-). You can always try to already 
compile on scratchbox. When I developed on Zaurus, any problems
were immediately solved by FPC Dev.

http://maemo.org/development/sdks/maemo_4-1-2_diablo/
http://www.scratchbox.org/documentation/general/application/simpleapp.html

 
kind regards,

Den Jean
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] DirectFB for FPC beta tarball

2009-06-01 Thread Den Jean
On Monday 01 June 2009 17:06:39 Paul Ishenin wrote:
> Try to think whether lazarus need 10 widgetsets 30% ready or 3
> widgetsets 100% ready? I would choose last.

I strongly agree, there are too many half-finished
... it would be nice to ... and therefore useless projects.

Qt can do framebuffer and X11. For embedded devices:
 http://www.klc.net.nz/linux/?page_id=13
or Nokia 800 (810):
http://qt4.garage.maemo.org/

qt4 WebKit embedded:
http://qt4.garage.maemo.org/screenshots/arora.png

Nokia Tablets are not the only devices where Gtk and Qt are mixed in embedded:
http://www.openmoko.com/download.html
http://www.openmoko.com/download-qtopia.html

Lazarus on Frame buffer:  
http://users.telenet.be/Jan.Van.hijfte/qtforfpc/qvfb_lazarus.png
when will a new widget set project achieve this ? 

Preemptive answer: Qt is available under LGPL aswell (same license as Gtk).

regards,

Den Jean


___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Gecko / Firefox / XPCOM

2009-05-24 Thread Den Jean
On Thursday 21 May 2009 22:34:52 Henrik Genssen wrote:
> I am trying to use the gecko libs from
>  http://sourceforge.net/projects/d-gecko with lazarus.

in case you didn't know
http://lists.lazarus.freepascal.org/pipermail/qt/2009-May/001212.html
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Help converting h-file

2008-09-21 Thread Den Jean
On Sunday 21 September 2008 12:28:29 Felipe Monteiro de Carvalho wrote:
> * Use Qt 4 (needs a commercial license for non-gpl software)

Did you notice this:
http://www.klc.net.nz/linux/?page_id=13

regards,

Den Jean

___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] > ARM and graphic libraries

2008-02-25 Thread Den Jean
On Friday 22 February 2008 11:40:55 pm Weyert de Boer wrote:
> Does anyone here have any experience with using FreePascal using ARM
> microprocessor and drawing graphics?

Zaurus (arm based) + qt/embedded) +freepascal:
http://users.pandora.be/Jan.Van.hijfte/qtforfpc/qtedemo.html


with Trolltech bought by Nokia, Qtopia (Qt/Embedded) is alive :-) :
last weekend: http://www.fosdem.org/2008/schedule/events/kde_telecom_qtopia

___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] beginner in pascal for Mac

2008-01-17 Thread Den Jean
On Thursday 17 January 2008 09:36:39 pm Graeme Geldenhuys wrote:
> covered on the Lazarus Wiki. I believe I saw something there a while

http://www.freepascal.org/

The very first section (overview) of the freepascal home page 
already contains links for mac fans : http://www.freepascal.org/fpcmac.var :-)




___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Lazarus + Qt4 in FreeBSD

2007-12-21 Thread Den Jean
On Friday 21 December 2007 03:06:32 am [EMAIL PROTECTED] wrote:
> Den, you want screenshots? Then see...

thanks

___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Lazarus + Qt4 in FreeBSD

2007-12-21 Thread Den Jean
On Wednesday 19 December 2007 11:37:33 am [EMAIL PROTECTED] wrote:
> I do some tests in my FreeBSD 6.1. In another FreeBSD 6.2 I build QT from
> ports (that is an automated process, that applies some patchs before
> build). In my FreeBSD 6.1 I build QT without ports (./configure, make, make
> install) and I got the same result, but with a more detailed backtrace
> (because QT compiled with debug enabled).

I tried FreeBSD, but X always seg failed, so then I tried PC-BSD.

The qt4 ports install include files to close to qt3 include files (you fall on 
qt3 files first). The PREFIX stuff does not work. 
The qt4-gui ports does not link with the PREFIX (does not find libqtcore, 
whatever you do with ldconfig)

If you play with ldconfig, bash becomes unstable-> you cannot launch
any program or any new konsole anymore, the messages you get are common problems
(google says: update ports recompile everything, but my ports are fresh :-) -> 
reboot -> I have never rebooted this much :-(.(BSD ? :-)

with LD_LIBRARY_PATH and a manually (no ports) compiled qt4 (put in 
/usr/local/KDE4) I can finally compile lazarus 
(some pthreads link hurdle aside)

lazarus compiled with:
#!/bin/bash
cd lazarus
export LD_LIBRARY_PATH=/usr/local/KDE4/lib
gmake LCL_PLATFORM=qt clean all OPT="-dDEBUG -dUSE_QT_4_3 
-k'-L/usr/local/KDE4/lib' -k'-lpthread'"

qt4intf compiled with:
cat ./compile_lib.bash
#!/bin/bash
export QT4=/usr/local/KDE4
export QT4I=$QT4/include
export LD_LIBRARY_PATH=$QT4/lib
if [ -e "$LD_LIBRARY_PATH/libQtCore.so.4" ]
then
  g++ -D UNIX -I. -I$QT4I -I$QT4I/Qt -I$QT4I/QtGui -I$QT4I/QtCore -Iqlcl 
qtpas.cpp -o libqt4intf.so -shared -fPIC -Xlinker $QT4/lib/libQtCore.so.4 
$QT4/lib/libQtGui.so.4 "-soname=libqt4intf.so"
  strip --strip-all libqt4intf.so
else
  echo "Please Modify location of Qt4 in this script"
fi


lazarus runs, but has continuously exceptions:

 $2911D9EA
  $2911E1AA
  $291417EF
  $2881BAB8
  $082400DE  TQTTHEMESERVICES__DRAWELEMENT,  line 168 of qtthemes.pas
  $081BFF95  TCUSTOMSPEEDBUTTON__PAINTBACKGROUND,  line 629 
of ./include/speedbutton.inc
  $081BF6B2  TCUSTOMSPEEDBUTTON__PAINT,  line 518 of ./include/speedbutton.inc
  $0819B979  TGRAPHICCONTROL__WMPAINT,  line 64 
of ./include/graphiccontrol.inc
  $08060F91
  $08191C92  TCONTROL__PERFORM,  line 1016 of ./include/control.inc
  $0818710B  TWINCONTROL__PAINTCONTROLS,  line 4294 
of ./include/wincontrol.inc
  $08186E66  TWINCONTROL__PAINTHANDLER,  line 4233 of ./include/wincontrol.inc
QPainter::end: Painter ended with 2 saved states
TApplication.HandleException Access violation
  Stack trace:
  $28E88EE

I also noticed that the gtk2 version crashes when started with ./startlazarus 
but runs fine when started with ./lazarus ???

so something is wrong ... 
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Lazarus + Qt4 in FreeBSD

2007-12-18 Thread Den Jean
On Tuesday 18 December 2007 11:39:44 am Jonas Maebe wrote:
> It appears that you misunderstood the question: he asked *which*  
> FreeBSD, not *why* FreeBSD.

yes what should I download :-) ? 6.2, 6.3RC1 or 7.0BETA4

ncftp ...FreeBSD/ISO-IMAGES-i386 > ls 6.2
6.2-RELEASE-i386-bootonly.iso  6.2-RELEASE-i386-docs.iso
6.2-RELEASE-i386-disc1.iso CHECKSUM.MD5
6.2-RELEASE-i386-disc2.iso CHECKSUM.SHA256
ncftp ...reeBSD/ISO-IMAGES-i386 > ls 6.3
6.3-RC1-i386-bootonly.iso  6.3-RC1-i386-disc2.iso CHECKSUM.MD5
6.3-RC1-i386-disc1.iso 6.3-RC1-i386-docs.iso  CHECKSUM.SHA256
ncftp ...reeBSD/ISO-IMAGES-i386 > ls 7.0
7.0-BETA4-i386-bootonly.iso7.0-BETA4-i386-docs.isoCHECKSUM.SHA256
7.0-BETA4-i386-disc1.iso   7.0-BETA4-i386-livefs.iso
7.0-BETA4-i386-disc2.iso   CHECKSUM.MD5

___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Lazarus + Qt4 in FreeBSD

2007-12-17 Thread Den Jean
On Saturday 15 December 2007 02:25:59 pm [EMAIL PROTECTED] wrote:
>  I will try disable SSE2 instructions...

It was a long shot ...

can you tell us which freebsd ? if I have time I may give it a try

please try latest lazarus svn source again.
(you are already using fpc 2.2.0 I see, Ok).




___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Lazarus + Qt4 in FreeBSD

2007-12-12 Thread Den Jean
On Wednesday 12 December 2007 07:33:15 pm Den Jean wrote:
> do you have a sse2 capable processor ?

compile and run pure pascal (no qt or lazarus) program below to check anyhow
(more verbose version of testsse2 of svn/fpctrunk/tests/test/testsse2.pp)

{ %OPT=-OaVARMAX=16 -OaVARMIN=16 }
{ %CPU=i386 }
uses
   mmx;

{ only a small test to see if it works in principle }

var
  b : byte;
  q : array[0..15] of byte;

begin
  if is_sse2_cpu then
begin
writeln('executing sse2 instructions ...');
asm
{$ifdef FPC_PIC}
   call .LPIC
.LPIC:
   popl %ecx
{$ifdef darwin}
   movdqa%xmm1,%xmm2
   movdqaq-.LPIC(%ecx),%xmm4
   psubq %xmm1,%xmm2
   psubq q-.LPIC(%ecx),%xmm4
{$else darwin}
   addl  $_GLOBAL_OFFSET_TABLE_,%ecx
   movdqa%xmm1,%xmm2
   movdqa[EMAIL PROTECTED](%ecx),%xmm4
   psubq %xmm1,%xmm2
   psubq [EMAIL PROTECTED](%ecx),%xmm4
{$endif darwin}
{$else FPC_PIC}
   movdqa%xmm1,%xmm2
   movdqaq,%xmm4
   psubq %xmm1,%xmm2
   psubq q,%xmm4
{$endif FPC_PIC}
end;
end else writeln('not sse2 cpu');
end.
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Lazarus + Qt4 in FreeBSD

2007-12-12 Thread Den Jean
On Wednesday 12 December 2007 12:24:02 pm [EMAIL PROTECTED] wrote:
> $28cf59fa in qt_memfill32_sse2 () from /usr/local/lib/libQtGui.so.4

do you have a sse2 capable processor ?

http://en.wikipedia.org/wiki/SSE2

___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Lazarus + Qt4 in FreeBSD

2007-12-11 Thread Den Jean
On Tuesday 11 December 2007 08:05:49 pm [EMAIL PROTECTED] wrote:
> Attached the script that build libqt4intf.so in FreeBSD (test)

try to run the demoes of c++ qt4 
e.g. 
cd qt-x11-opensource-src-4.3.1/demos/textedit
./textedit


try to build the demo of the fpc qt4 bindings and run those 

make sure you do not have 2 Qt's mixed in the library paths.
Although different versions are claimed to be compatible, a 
different ./configure by distrib vendor may even make a same 
version a completely different Qt lib. 

There is a help about in the bindings mainwindow demo that gives the Qt 
version. 

use ldd to find the the path of the used lib on your system

ldd ./mainwindow | grep -i qt
libqt4intf.so => /usr/lib/libqt4intf.so (0xb7d3f000)
libQtCore.so.4 => /usr/lib/qt4/lib/libQtCore.so.4 (0xb7a6f000)
libQtGui.so.4 => /usr/lib/qt4/lib/libQtGui.so.4 (0xb72b2000)
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Lazarus + Qt4 in FreeBSD

2007-12-07 Thread Den Jean
On Tuesday 04 December 2007 05:08:15 pm [EMAIL PROTECTED] wrote:
> If you ran ldd libqt4intf.so, what is the output?


$ ldd -r libqt4intf.so
linux-gate.so.1 =>  (0xe000)
libQtCore.so.4 => /usr/lib/qt4/lib/libQtCore.so.4 (0xb7be8000)
libQtGui.so.4 => /usr/lib/qt4/lib/libQtGui.so.4 (0xb742b000)
libstdc++.so.6 => /usr/lib/libstdc++.so.6 (0xb733d000)
libm.so.6 => /lib/i686/libm.so.6 (0xb7318000)
libgcc_s.so.1 => /lib/libgcc_s.so.1 (0xb730b000)
libc.so.6 => /lib/i686/libc.so.6 (0xb71cb000)
libz.so.1 => /lib/libz.so.1 (0xb71b8000)
librt.so.1 => /lib/i686/librt.so.1 (0xb71af000)
libpthread.so.0 => /lib/i686/libpthread.so.0 (0xb7198000)
libdl.so.2 => /lib/libdl.so.2 (0xb7194000)
libpng12.so.0 => /usr/lib/libpng12.so.0 (0xb716c000)
libSM.so.6 => /usr/lib/libSM.so.6 (0xb7164000)
libICE.so.6 => /usr/lib/libICE.so.6 (0xb714b000)
libXi.so.6 => /usr/lib/libXi.so.6 (0xb7142000)
libXrender.so.1 => /usr/lib/libXrender.so.1 (0xb7139000)
libXrandr.so.2 => /usr/lib/libXrandr.so.2 (0xb7131000)
libXfixes.so.3 => /usr/lib/libXfixes.so.3 (0xb712c000)
libXcursor.so.1 => /usr/lib/libXcursor.so.1 (0xb7122000)
libXinerama.so.1 => /usr/lib/libXinerama.so.1 (0xb711f000)
libfreetype.so.6 => /usr/lib/libfreetype.so.6 (0xb70a4000)
libfontconfig.so.1 => /usr/lib/libfontconfig.so.1 (0xb7075000)
libXext.so.6 => /usr/lib/libXext.so.6 (0xb7066000)
libX11.so.6 => /usr/lib/libX11.so.6 (0xb6f62000)
/lib/ld-linux.so.2 (0x8000)
libxml2.so.2 => /usr/lib/libxml2.so.2 (0xb6e2d000)
libXau.so.6 => /usr/lib/libXau.so.6 (0xb6e2a000)
libXdmcp.so.6 => /usr/lib/libXdmcp.so.6 (0xb6e24000)
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Lazarus + Qt4 in FreeBSD

2007-12-07 Thread Den Jean
On Tuesday 04 December 2007 05:08:15 pm [EMAIL PROTECTED] wrote:
> {$IFDEF FREEBSD}
>  QtIntf  = 'libqt4intf.so';
>  {$ENDIF}

but there are many LINUX ifdefs. (see below)
It would be complicated to add "... or FREEBSD or NETBSD"  everywhere etc.

I am considering to replace LINUX with UNIX everywhere,
but need to check if this does not break things.

Can you also read Lazarus Qt Widget Set List.

I will ask there what they think about that.

$ grep -ir LINUX qt4.pas lib
qt4.pas:{$IFDEF LINUX}
qt4.pas:{$ifdef DARWIN or LINUX }
qt4.pas:{$ifdef LINUX }
qt4.pas:{$ifdef LINUX }
qt4.pas:{$ifdef LINUX }
qt4.pas:{$ifdef DARWIN or LINUX }
qt4.pas:{$ifdef DARWIN or LINUX }
qt4.pas:{$ifdef LINUX }
qt4.pas:{$ifdef LINUX }
qt4.pas:{$ifdef LINUX }
qt4.pas:{$ifdef LINUX }
qt4.pas:{$ifdef DARWIN or LINUX }
qt4.pas:{$ifdef DARWIN or LINUX }
qt4.pas:{$ifdef LINUX }
qt4.pas:{$IFDEF LINUX}
lib/qcoreapplication.hb:#if defined DARWIN || LINUX
lib/qcoreapplication.cppb:#if defined DARWIN || LINUX
lib/qapplication.hb:#if defined LINUX
lib/qapplication.hb:#if defined LINUX
lib/qapplication.cppb:#if defined LINUX
lib/qapplication.cppb:#if defined LINUX
lib/qwidget.hb:#if defined LINUX
lib/qwidget.hb:#if defined DARWIN || LINUX
lib/qwidget.cppb:#if defined LINUX
lib/qwidget.cppb:#if defined DARWIN || LINUX
lib/qcursor.hb:#if defined DARWIN || LINUX
lib/qcursor.hb:#if defined LINUX
lib/qcursor.cppb:#if defined DARWIN || LINUX
lib/qcursor.cppb:#if defined LINUX
lib/qx11info_x11.hb:#if defined LINUX
lib/qx11info_x11.cppb:#if defined LINUX
lib/qx11info_x11.cppb:#if defined LINUX
lib/qcolor.hb:#if defined LINUX
lib/qcolor.cppb:#if defined LINUX
lib/qregion.hb:#if defined LINUX
lib/qregion.cppb:#if defined LINUX
lib/qprinter.hb:#if defined DARWIN || LINUX
lib/qprinter.cppb:#if defined DARWIN || LINUX
lib/qfont.hb:#if defined DARWIN || LINUX
lib/qfont.cppb:#if defined DARWIN || LINUX
lib/qpixmap.hb:#if defined LINUX
lib/qpixmap.cppb:#if defined LINUX



___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Lazarus + Qt4 in FreeBSD

2007-12-02 Thread Den Jean
On Saturday 01 December 2007 12:28:21 pm [EMAIL PROTECTED] wrote:
> 6) Rebuild Lazarus without sucess... :(

in point 5 you succesfully got a libqt4intf.so ?. Great.
So the rest is just compiling lazarus. 

cd lazarus
make LCL_PLATFORM=qt clean all OPT=dUSE_QT_4_3 

and look at output

The option USE_QT_4_3 is if you use the Qt 4.3.1 libs.
Do not add it if you used the Qt 4.2.3 libs.
 
Did you put llibQtCore.so.4 and libQtGui.so.4 in /usr/local/lib as well ?
and ran ldconfig or the bsd equivalent ?

The resulting executable ofcourse depends on Qt :-)

 ldd ./lazarus | grep -i qt
libqt4intf.so => /usr/lib/libqt4intf.so (0xb7d21000)
libQtCore.so.4 => /usr/lib/qt4/lib/libQtCore.so.4 (0xb7a51000)
libQtGui.so.4 => /usr/lib/qt4/lib/libQtGui.so.4 (0xb7294000)

(/usr/lib on my system) 


regards,

Den Jean
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Lazarus + Qt4 in FreeBSD

2007-11-24 Thread Den Jean
On Thursday 22 November 2007 04:50:59 pm [EMAIL PROTECTED] wrote:
> Qt 4.3.1 is installed from ports and my Lazarus snapshot verion 0.9.25 of
> 22-nov-2007...

probably because the linker does not find libqt4intf.so.
I have so bsd experience. Are you interested in 
creating a libqt4intf.so for bsd :-). ?
if so start from the linux source code and compile script.

kind regards,

Den Jean


___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Is there some binary packet for ARM version 2.2

2007-11-15 Thread Den Jean
On Thursday 15 November 2007 05:35:06 pm Henry Vermaak wrote:
> there's an i386-win32 to arm-wince cross compiler on the download
> page.  the arm-linux one is native, so you'll have to build  your own
> cross compiler, if i'm not mistaken.

I just build a  cross fpc with svn 9263, but noticed
that the trigonometric functions fail.

It has been wrong before. Here is some old test code that I used
before to test it and that does not fail with the cross fpc available on the 
freepascal home page (version 2.0.4)


 
cat testtrig.pp:
program testtrig;

uses
{$IFDEF CPU86}
  CMem,
{$ENDIF}
  SysUtils,Math;

const

 dim = 36;
 MaxFloat = 1.1000E+4932;

 // from dcc
 sinus : array[1..dim] of double = (
 1.7364817766693035E-0001, 3.4202014332566873E-0001, 5.E-0001, 
6.4278760968653933E-0001,
 7.660311897804E-0001, 8.6602540378443865E-0001, 9.3969262078590838E-0001, 
9.8480775301220806E-0001,
 1.E+, 9.8480775301220806E-0001, 9.3969262078590838E-0001, 
8.6602540378443865E-0001,
 7.660311897804E-0001, 6.4278760968653933E-0001, 5.E-0001, 
3.4202014332566873E-0001,
 
1.7364817766693035E-0001,-5.4210108624275222E-0020,-1.7364817766693035E-0001,-3.4202014332566873E-0001,
-5.E-0001,-6.4278760968653933E-0001,-7.660311897804E-0001,-8.6602540378443865E-0001,
-9.3969262078590838E-0001,-9.8480775301220806E-0001,-1.E+,-9.8480775301220806E-0001,
-9.3969262078590838E-0001,-8.6602540378443865E-0001,-7.660311897804E-0001,-6.4278760968653933E-0001,
-5.E-0001,-3.4202014332566873E-0001,-1.7364817766693035E-0001, 
1.0842021724855044E-0019
 );

var
  i : integer;
  Delta,Ref,Value : Double;


const
  MaxErr = 1E-14;
  pi =  3.1415926535897932E+;


begin
for i:=1 to dim do
  begin
  // Generate constant array above output
  write(sin(i*10/180.0*pi),',');
  if i mod 4 = 0 then writeln;
  end;


writeln('Testing SIN');
for i:=1 to dim do
  begin
  Ref:=sinus[i];
  Value:=sin(i*10/180.0*pi);
  Delta := Value - Ref;
  if Abs(Delta) > MaxErr then
begin
  writeln('  Error for Sin(',i*10,') was:',Value,' should be:',Ref) ;
//   halt(1);
end;
  end;


writeln('Testing COS');
for i:=1 to dim do
  begin
  Ref := sin(pi/2-i*10/180*pi);
  Value := cos(i*10/180*pi);
  Delta := Value - Ref;
  if Abs(Delta) > MaxErr then
begin
  writeln('  Error for Cos(',i*10,') was:',Value,' should be:',Ref) ;
//   halt(1);
end;
  end;


writeln('Testing TAN');
for i:=1 to dim do
  begin
if i=9 then Ref := MaxFloat
else if i=27 then Ref := -Maxfloat
else Ref:=sin(i*10/180*pi)/cos(i*10/180*pi);
Value := tan(i*10/180*pi);
Delta := Value - Ref;
if Abs(Delta) > MaxErr then
  begin
writeln('  Error for Tan(',i*10,') was:',Value,' should be:',Ref) ;
// halt(1);
  end;
  end;


writeln('Testing ARCTAN...');
for i:=1 to 8 do
  begin
  Ref := i*10;
  Value := arctan(tan(i*10/180*pi))/pi*180;
  Delta := Value - Ref;
  if Abs(Delta) > MaxErr then
begin
  writeln('  Error for ArcTan(',i*10,') was:',Value,' should be:',Ref);
//   halt(1);
end;
  end;


for i:=-1 downto -8 do
  begin
  Ref := i*10;
  Value := arctan(tan(i*10/180*pi))/pi*180;
  Delta := Value - Ref;
  if Abs(Delta) > MaxErr then
begin
  writeln('  Error for ArcTan(',i*10,') was:',Value,' should be:',Ref);
//   halt(1);
end;
  end;

writeln('Tan +/- 90 deg test:');
writeln('tan(89.999):',tan(89.999/180*pi));
writeln('tan(90.000):',tan(90.000/180*pi));

writeln('tan(-89.999):',tan(-89.999/180*pi));
writeln('tan(-90.000):',tan(-90.000/180*pi));

writeln('ArcTan2 kwadrants:');
writeln('Kwadrant 1 ( 1, 1):',arctan2( 1, 1)/pi*180:5:1,' deg');
writeln('Kwadrant 2 (-1, 1):',arctan2( 1,-1)/pi*180:5:1,' deg');
writeln('Kwadrant 3 (-1,-1):',arctan2(-1,-1)/pi*180:5:1,' deg');
writeln('Kwadrant 4 ( 1,-1):',arctan2(-1, 1)/pi*180:5:1,' deg');

writeln('ArcTan2 special cases:');
writeln('Kwadrant X ( 0, 0):',arctan2( 0, 0)/pi*180:5:1,' deg');
writeln('Kwadrant 1 ( 1, 0):',arctan2( 0, 1)/pi*180:5:1,' deg');
writeln('Kwadrant 2 ( 0, 1):',arctan2( 1, 0)/pi*180:5:1,' deg');
writeln('Kwadrant 3 (-1, 0):',arctan2( 0,-1)/pi*180:5:1,' deg');
writeln('Kwadrant 4 ( 0,-1):',arctan2(-1, 0)/pi*180:5:1,' deg');



end.
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] GTK2 Lazarus Project, but I want QT.

2007-06-21 Thread Den Jean
On Thursday 21 June 2007 11:58:38 am Catalin Zamfir Alexandru wrote:
> Still compiling. 4 hours have passed and Qt is still compiling.
hehe, that is why I just bought a new computer (Core2Duo,2GB): < 20 minutes 
now :-).
But 4 hours is a lot, it did not take that long on my 2.54GHz with 256 MB.
Compiling C++ needs memory.

regards,

Den Jean


___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] GTK2 Lazarus Project, but I want QT.

2007-06-21 Thread Den Jean
On Thursday 21 June 2007 11:32:56 am Felipe Monteiro de Carvalho wrote:
> I am trying here, but it's hard to install qt 4.3 on my Mandriva ... I
> found some pre-compiled packages, but they require that I update my
> glibc (and I am definetively not doing that, it's easier to reinstall
> the entire os)

Linux:
download from trolltech Qt 4.3 source.
compile and install. By far the easiest.
The compile options are important.
The default compile options do not even add Font AA.

mine was configured with: 
./configure -prefix /usr -opengl -xrender -xcursor -xrandr

for Mandriva 2007 Spring do 
urpmi libxrender1-devel libxcursor1-devel libxrandr2-devel libxinerama1 
libxinerama1-devel libmesagl1-devel libmesaglu1-devel
to have all the required files for compilation.


Windows:
download and install from trolltech.
do not forget to set environment variable of Qt


regards,

Den Jean



___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] size of "long" on different platforms

2006-11-16 Thread Den Jean
On Wednesday 15 November 2006 21:27, Marco van de Voort wrote:
> long is 32-bit on win64 afaik (longlong is 64-bit), it is defined as 64-bit
> in ctypes.

I hope you don't mind that I created a reminder:
http://www.freepascal.org/mantis/view.php?id=7831

regards,

Den Jean


___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] size of "long" on different platforms

2006-11-15 Thread Den Jean
On Wednesday 15 November 2006 08:48, Florian Klaempfl wrote:
> > I do not see the win64 exception in the defines ??
>
> Win64 has no such exceptions?

because I was not sure, I was posting.

Is WIN64 not LLP64 ?

http://en.wikipedia.org/wiki/64-bit

...
Another alternative is the LLP64 model that maintains compatibility with 32 
bit code, by leaving both int and long as 32-bit. "LL" refers to the "long 
long" type, which is at least 64 bits on all platforms, including 32 bit 
environments. Most 64 bit compilers today use the LP64 model (including 
Solaris, AIX, HP, Linux, MacOS native compilers), Microsoft however decided 
to use the LLP64 model.
Note that a programming model is a choice made on a per compiler basis, and 
several can coexist on the same OS. However typically the programming model 
chosen by the OS API as primary model dominates.
...

does this mean that the long in

 bool myEventFilter(void *message, long *result);

is 32 bit on win64 ??? 

regards,

Den Jean
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] size of "long" on different platforms

2006-11-14 Thread Den Jean
On Tuesday 14 November 2006 22:28, Jonas Maebe wrote:

> There's a unit called ctypes in the rtl with all these types defined
> (prefixed by "c", i.e. cshort, cchar, clong, ...)
>

thx,

I do not see the win64 exception in the defines ??

regards,

Den Jean








___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


[fpc-pascal] size of "long" on different platforms

2006-11-14 Thread Den Jean
Hi,

the c long int type is always mapped to longint in h2pas 

but I guess this is not correct in linux (have no 64 bit to verify)

If I am correct:
linux64: c long int -> pascal int64
win64  : c long int -> pascal longint
What is the size of long on the Mac Os X platform ?

Is there a pascal integer type defined somewhere in rtl
that allows me to map to this c-type sometimes
used in api's ?

Qt4 API sample
 bool myEventFilter(void *message, long *result);

my current definition

  PLong = ^Long;
{$ifdef CPU64 and not WIN64}
   Long = Int64;
{$else}
   Long = LongInt;
{$endif}


kind regards,

Den Jean

___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Set format

2006-11-14 Thread Den Jean
On Tuesday 14 November 2006 11:47, Jonas Maebe wrote:
> Hello,
>
> I have a quick question: are there (m)any people here who store/load
> sets to/from files?

It would be nice to have an option like
{$MINENUMSIZE xxx}

so that binary compatibility with frequently used
bitmasks in C APIs is easier

kind regards,

Den Jean



___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Qt4 binding ported to 64bit

2006-10-24 Thread Den Jean
On Friday 20 October 2006 21:05, Florian Klaempfl wrote:

>
> What do you think about integrating the qt4 stuff into the fpc svn
> repository? 

responded off list on how & feasibility ...

Den Jean


___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


[fpc-pascal] Qt4 binding ported to 64bit

2006-10-20 Thread Den Jean
Hi,

FYI:
thanks to a patch from Giulio Berna, the Qt4 binding 
now also works on 64 bit platforms ( ifdef _LP64... )

Important note from Giulio: 
there is a bug on fpc 2.0.4 that prevents parameters to be 
passed correctly to C functions on x86_64 
(http://www.freepascal.org/mantis/view.php?id=7613).
Now it has been fixed, even if fpc 2.1.1 won't compile itself on x86_64 (as 
suggested by Peter Vreman, you can build a compiler using -Aas: it will fail 
compiling some base packages, but it's enough to have a compiler and rtl 
that can compile qt4.pas and demos on x86_64).

kind regards,

Den Jean
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


[fpc-pascal] FPC Qt4 Binding V1.18

2006-09-12 Thread Den Jean
Hi,

FYI: 

  The FPC Qt4 binding now also includes support for MS Windows
  Linux X11 and OS X support were already present.

kind regards,

Den Jean



 
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


[fpc-pascal] 2.0.4-rc2: compiling mseide gives Fatal Internal errors

2006-07-31 Thread Den Jean
Hi,

when compiling without -B we get internal errors like 200110203 and 200306067

is more info as below required ?



200110203 :
...
 mseclasses.pas(2122,7) Warning: Class types "tmsecomponent" and 
"TComponentcracker" are not related
mseclasses.pas(2320,2) Note: Local variable "ca1" not used
mseclasses.pas(2398,1) Fatal: Internal error 200110203
mseclasses.pas(87,48) Fatal: Compilation aborted

or

200306067:
...
mseclasses.pas(533,4) Note: Private field "TComponentcracker.FDesignInfo" is 
never used
mseclasses.pas(534,4) Note: Private field "TComponentcracker.FVCLComObject" is 
never used
mseclasses.pas(535,4) Note: Private field "TComponentcracker.FComponentState" 
is never used
Compiling /other/storage/rpms/fpc/cvs/mseide-msegui/lib/common/kernel/msesys.pas
mseevent.pas(120,1) Fatal: Internal error 200306067
mseevent.pas(87,48) Fatal: Compilation aborted

svn info:
Path: .
URL: https://svn.sourceforge.net/svnroot/mseide-msegui/trunk/apps/ide
...
Revision: 107

Free Pascal Compiler version 2.0.4-rc2 [2006/07/23] for i386

compile command
ppc386 -B -omseide 
-Fu/other/storage/rpms/fpc/cvs/mseide-msegui/lib/common/kernel/i386-linux/ 
-Fu/other/storage/rpms/fpc/cvs/mseide-msegui/lib/common/kernel/ 
-Fi/other/storage/rpms/fpc/cvs/mseide-msegui/lib/common/kernel/ 
-Fu/other/storage/rpms/fpc/cvs/mseide-msegui/lib/common/*/ -l -Mobjfpc -Sh 
-gl mseide.pas

kind regards,

Den Jean


___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] X Windows and FPC

2006-07-28 Thread Den Jean
On Friday 28 July 2006 11:16, Graeme Geldenhuys wrote:
> I am currently busy creating a FPC widget set (based on Qt, fpGUI and
> lptk), hence my interest in this document.  The widget set uses
> Windows GDI and XLib directly, no underlying 3rd party widget set
> requirements.  Integration with Lazarus will have to wait until the
> widget set is more robust, but that is one of my goals.

What are your thoughts on msegui, also a gui 
library on top of xlib and gdi ?

It would be nice if an xlib expert would join Martin :-)

kind regards,

Den Jean

___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


[fpc-pascal] FPC Qt4 for Mac

2006-05-12 Thread Den Jean
Hi,

The small Qt4 binding for FPC now also works on Mac Os X.
http://www.freepascal.org/wiki/index.php/Qt4_binding

Everyone with a Mac, feel free to try and comment.

The PowerPC binary was provided by Hess, Philip J

Anyone with a Mac Intel, feel free to send me 
a compiled binary for Mac Intel :-)

kind regards,

Den Jean
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


[fpc-pascal] another fpc RAD: MSEide

2006-04-18 Thread Den Jean
Hi,

Movie:
=
For those who did not try MSEide yet, here is a movie teaser.
http://users.pandora.be/Jan.Van.hijfte/qtforfpc/mse01.html

Wiki:
===
http://www.freepascal.org/wiki/index.php/MSEide_&_MSEgui

Can someone provide a more appropriate entry in the wiki 
for this page. I cannot modify all pages, but did not find an 
appropriate page either. 
Perhaps there should be some page: fpc related projects. 

kind regards,

Den Jean
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


[fpc-pascal] FOSDEM 2006

2006-02-21 Thread Den Jean
Hi,

is someone going to the FOSDEM 2006 this WE in Brussels ?

http://www.fosdem.org/2006

kind regards,

Den Jean
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


[fpc-pascal] Slashdot article

2006-02-17 Thread Den Jean
Hi,

The following article featured on slashdot.
http://linux.slashdot.org/article.pl?sid=06/02/16/1343239

According to this article, Novell thinks that
Adobe Photoshop is the most wanted application
on Linux. Novell proposes several alternatives.
http://www.desktoplinux.com/news/NS2844646285.html

The first alternative for the most wanted applications
is  Pixel Image Editor, a FreePascal application.

kind regards,

Den Jean




___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] GTK2 and arm-linux

2005-12-26 Thread Den Jean
On Monday 26 December 2005 02:10 pm, Koenraad Lelong wrote:
> Hi,
> Has anyone successfully used the GTK2-library for an arm-processor ?
> Today I tried the helloworld-demoes, which segfault. I tried gdb but

The Zaurus does not come with Gtk(2). Only Qt/E (ie Qtopia). 
Did you install another ROM with an X11 server/ Gtk libraries ?

The advantage of Qtopia it that it has its own lightweight
fast replacement for X11, tailored for embedded.

But many also seem to use X11 on higher end Zauri.
I just never bothered to try it.

Are there any problems with using Qt/E Qtopia + FPC on the Zaurus ?
Something I can fix ?


kind regards,

Den Jean
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] New Pascal cross platform GUI library with IDE

2005-12-09 Thread Den Jean
On Friday 09 December 2005 01:13 pm, Mattias Gaertner wrote:
> > - Compiles on FPC 2.0.2 or FPC 2.0.3.
> > - Tested on i386-linux SuSE 9.0,9.2,10.0 and i386-win32 98 and 2000.
> > - Links to xlib and gdi32, no external widget library needed.
> > - Internal character encoding is UCS2.
> > - Uses anti aliased fonts on Linux (XFT).
> > - All screen drawing is double buffered.
> > - Has docking forms.
> > - Has embedded forms (similar to TFrame).

impressive

Den Jean

___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Sharp Zaurus ARM port stability?

2005-10-24 Thread Den Jean
On Monday 24 October 2005 09:52 am, Michael Van Canneyt wrote:
> Maybe we can check it in in FPC's SubVersion under packages ?
> This way it can be used/tested by everyone.
contacted off list
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


[fpc-pascal] Sharp Zaurus ARM port stability?

2005-10-23 Thread Den Jean
Hi,

http://lists.freepascal.org/lists/fpc-pascal/2005-July/008764.html

still interested in a Qt4/binding ?

I have created one, that contains enough of libQtGui 
to start porting CLX to Qt4.
But I can always use help. Someone should create pascal
Qt4 programs to verify the binding. 

In the mean time I need to create some special classes by hand
that were also created by by Borland to accomodate special behaviour 
not possible directly with Qt2 via the binding.
You can recognize these classes with : grep QCLX -i Qt.pas |  grep -i class

kind regards,

Den Jean
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Sharp Zaurus ARM port stability?

2005-07-21 Thread Den Jean
On Thursday 21 July 2005 06:53 pm, Alain Vitry wrote:
> Den,
> Could you point me to some reading/starting point on how to make those 
> bindings ?
> Swig doesn't support pascal yet.
> I have  a fresh QT4 bindings for pascal in mind.
> Thanks

There are several ways:

kalyptus: see cvs/fpc/utils/kalyptus 
google on kde bindings / qt bindings
Florian started from the c-kalyptus one.

http://www.lazarus.freepascal.org/list_archives/lazarus/08-17-02_01-02-04/msg04138.html

smoke: more for scripting languages

smoke/refract: c++ headers to xml using the gcc parsing capability.
C++ may look to be the perfect parser for c++,  

but qt is not c++ but an enhanced delphi like 
language (hence why the moc)
so distance to qt language is big.
http://wiki.dotgnu.info/Smoke/Refract

freeclx: based on moc parsing. Moc converts qt language to c++. 
 So Moc is close to the qt language and it gives you a very 
able parser.
 With some modifications to the lex/yacc you can let moc 
produce a pascal qt binding. 
 
 But each time trolltech adds to the qt language, they 
renew the moc, 
 then you need to port your adaptations to the moc lex/yacc 
again.

 We adapted the qt part of freeclx from qt 2.2.4 to qt 
2.3.2 and qt/embedded
 The result is on 
http://cvs.sourceforge.net/viewcvs.py/qtforfpc/qt2/FreeClx/
  
qtc binding:  as pascal can easily use c-libraries, the qtc binding 
seems a good base 
but difficult to maintain at each update of the qtc 
binding.
Andreas Hausladen is very productive in this 
matter. (allready qt3 binding),
I guess qt4 is in the make. Perhaps you can join 
forces with him.
http://andy.jgknet.de/oss/qt/qt3forFPC/

http://andy.jgknet.de/oss/kylix/wiki/index.php/Qt3_for_Kylix


kind regards,

Den Jean 

___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Sharp Zaurus ARM port stability?

2005-07-21 Thread Den Jean
On Thursday 21 July 2005 05:21 pm, Matt Emson wrote:

> Excellent. I do have a Mandrake 8.1 and Mandrake 9.0 install CD hanging
> about. Are either of those preferable? I would also like to get it going
> under Windows.. just because I know I'll be in Windows for more frequently.
> Was there a specific reason for using LINUX, bar the obvious QTE runs on
> Zaurus, Zaurus uses LINUX thing?
> 

I do not program in windows anymore, so I did not try 
to have a windows version of the qt embedded binding.
It was already enough work in itself.  You are ofcourse free
to make one :-)

The binding is made in C/C++, one of the makefiles is 2730 lines. 
So it helped me remember why I prefer to code in pascal. 
Compiling the binding was a nightmare, because of the incompatibilities
between the c-compilers. You need the exact same compiler
as the one the qt/embedded library was created with. And it is impossible
to just take the source of that compiler and compile it
with a recent compiler, the compiler source is not compatible
anymore. So you need to cycle back several times.

Mandrake: You can always download a fresher iso. It is worth it.
Kylix works fine till and including version 10.1 (so not 2005 or 10.2, but that 
is off list)

kind regards,

Den Jean

___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Sharp Zaurus ARM port stability?

2005-07-21 Thread Den Jean
On Thursday 21 July 2005 04:22 pm, Florian Klaempfl wrote:
> > I realise this is slightly off
> > topic, but I remember the developer working on the bindings posted to this
> > list a while back.
> > 

The fpc qte binding demo program shows that it is usable.
If however you have problems and think it is binding or fpc
related, I am always willing to investigate this.
I just did so for someone who had a problem with QLCDNumber,
it probably is a small fpc bug concerning passing a double parameter.

If you use something else than Mandrake, it would be nice if 
you could adapt my installation instructions to match your
experience on your distro. I will add then update my webpage and
the fpc wiki (they need an update anyhow)

http://users.pandora.be/Jan.Van.hijfte/qtforfpc/qtedemo.html
http://www.freepascal.org/wiki/index.php/Setup_Cross_Compile_For_ARM

 kind regards,

Den Jean

___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] ARM compiler platforms

2005-07-07 Thread Den Jean
On Wednesday 06 July 2005 07:32 am, Marc Santhoff wrote:
> Hi,
> 
> since the website only seems to mention the Zaurus as device for running
> fpc and executing it's program i assume (cross)compiling at least works
> on linux.
> 

For a sample application created with FPC take look at:

http://users.pandora.be/Jan.Van.hijfte/qtforfpc/qtedemo.html


___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] installing ppcrossarm from cvs

2005-05-12 Thread Den Jean
On Thursday 12 May 2005 11:19 am, Jose Pascual wrote:
> but
>
> > make crossinstall CPU_TARGET=arm
>


Please read README.TXT of arm fpc qt binding demo.

http://prdownloads.sourceforge.net/qtforfpc/demo-qteintf-0.9.tar.gz?download
http://users.pandora.be/Jan.Van.hijfte/qtforfpc/qtedemo.html

the ... from CVS instructions ... (arm or even i386) are way at the bottom.
I thought the PREFIX option may interest you.


kind regards,

Den Jean

___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


[fpc-pascal] CLX for FPC + Bug i386 cdecl

2005-03-08 Thread Den Jean
Hi,

We are porting CLX to FPC. You can see a first snapshot here:
http://sourceforge.net/project/screenshots.php?group_id=116605
The use of the BitBtn shows that we dealt with {$R QButtons.res}

The code will be available at:
http://sourceforge.net/projects/qtforfpc/

There is still alot of work to do, diffs are welcome.
The FPC Wiki shows someone else is busy at it too, 
any cooperation would be great.
By the way thx for the many updates to the rtl, 
it is much easier than back in July when I first tried this. 
Also thx for renaming rtlconst(s) just after I had already replaced it 
everywhere :-)

BTW, our aim is to be able to kinda just recompile Kylix programs
if ever we encounter problems with dcc on newer distributions.
Some programs that have some qt dependencies, just cannot
be ported that easy to LCL (yet). New programs should ofcourse
use the lazarus/LCL and profit of its nice form editor. 
We will try to convert the xfm files with lazres after 
some further study of the classes unit 

i386 FPC CDecl Bug encountered:
=
When using libqtintf we call c-code and get called by c-code.
For eg c-code calls this function in BindHelp.pas

function GetPointsLength(const PA: TPointArray): Integer; cdecl; export;

But with FPC this call fails. The way 'const TPointArray' is passed on the 
stack seems not ABI correct. I am an ABI analphabet, but I guess the address 
of the points should be on EBP+8 so the following test program tests this.
With Kylix (dcc) it works and with FPC it fails.

=
== Output of both compilers  ==
=
[EMAIL PROTECTED] dcc TestPointArray
writeln('end of program');

[EMAIL PROTECTED] dcc -q TestPointArray ; ./TestPointArray
Borland Delphi for Linux Version 14.5
Copyright (c) 1983,2002 Borland Software Corporation
59 lines, 0.03 seconds, 137636 bytes code, 7204 bytes data.
GetPointsLength 1:
   Length:3
GetPointsLength 2:
   Length:3

[EMAIL PROTECTED] ppc386 -Sd -v0 TestPointArray.pas ; ./TestPointArray
Free Pascal Compiler version 1.9.9 [2005/03/08] for i386
Copyright (c) 1993-2005 by Florian Klaempfl
GetPointsLength 1:
   Length:3
GetPointsLength 2:
   Oooops:i<>p
   Length:3

=
==  Test Program:  ==
=
program TestPointArray;
{$H+}

uses
  Classes, SysUtils, Types;

type
  PPointArray = ^TPointArray;
  TPointArray = array of TPoint;

var
  Points : TPointArray;
  p  : PPointArray;
  i  : integer;


function GetPointsLength1 (PA: pointer): Integer; cdecl;
begin
  asm
mov EAX,[EBP+$08]
mov i,eax
  end;
writeln('GetPointsLength 1:');
if i <> integer (p) then writeln ('   Oooops:i<>p');
if integer(PA) <> integer (p) then writeln ('   Oooops:PA<>p');
Result:=Length(TPointArray(PA));
writeln('   Length:',Result);
end;

{$IFDEF FPC}
{$asmmode intel}
{$ENDIF}

function GetPointsLength2 (const PA: TPointArray): Integer; cdecl;
begin
  asm
mov EAX,[EBP+$08]
mov i,eax
  end;
writeln('GetPointsLength 2:');
if i <> integer (p) then writeln ('   Oooops:i<>p');
if integer(PA) <> integer (p) then writeln ('   Oooops:PA<>p');
Result:=Length(PA);
writeln('   Length:',Result);
end;


begin
SetLength (Points, 3);
Points [0] := Point (1,2);
Points [1] := Point (3,4);
Points [2] := Point (5,6);
p:[EMAIL PROTECTED];
getPointsLength1(Points);
getPointsLength2(Points);
end.


===

kind regards,

Den Jean

___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


[fpc-pascal] Qt binding for FPC

2005-02-13 Thread Den Jean
Hi,

I have put the source of a demo program 
that shows the use of a Qt binding
for FPC on the Zaurus (arm) on my webpage.

I also added a recent fpc arm snapshot that fixes previous issues. 
(thx Florian for the arm port)

There are detailed installation instructions on the webpage
and even more in the tar file. So give it a go and please give me 
some feedback on the instruction. 
Are there any other FPC users with a Zaurus ? :-)

webpage:
http://users.pandora.be/Jan.Van.hijfte/qtforfpc/qtedemo.html

If you are interested in a similiar Qt binding for i386, please contact me.
I will move everything (Qt/Embedded and Qt i386) to sourceforge.

http://sourceforge.net/projects/qtforfpc/
http://sourceforge.net/project/screenshots.php?group_id=116605


kind regards,

Den Jean

___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] new arm snapshot

2005-01-11 Thread Den Jean
On Friday 07 January 2005 06:25 pm, Den Jean wrote:
>
> There are still some problems with:
> * trigonometric functrions:
>They do not crash anymore (something was changed).
>But the results are wrong. In Intel its ok
>
> I should/shall make some small programs to demonstrate this.
>

It is only arctan2 who has a problem. 
Small Test Program will be mailed off-list.

kind regards,

Jan



___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] new arm snapshot

2005-01-07 Thread Den Jean
On Thursday 06 January 2005 05:29 pm, Florian Klaempfl wrote:

> Uploaded a new one :)

Thx a lot again.

I uploaded the new version of the binding with  
the fix for the "Error: Can't declare procedure as EXTERNAL"

With fpc 1.9.3 (intel) I had overloading problems, so in the binding
I had to rename some functions to make them unique. I removed this
and everything works fine now.

There were also some reference counting problems, for that
reason there were some AddRef instructions. With 1.9.6
I could remove them.

There are still some problems with:
* trigonometric functrions:
   They do not crash anymore (something was changed). 
   But the results are wrong. In Intel its ok
*  TPointArray; passing a TPointArray to Polygon crashes in arm
*  Interfaces bug: writeln(App.Desktop.Width) crashes in intel and arm!

I should/shall make some small programs to demonstrate this.

To everyone with a Zaurus, If you try this demo, please send some
feedback to improve the instructions in README.TXT. 
I will put everything on the FPC wiki aswell. 


http://users.pandora.be/Jan.Van.hijfte/qtforfpc/qtedemo.html

kind regards,

Den Jean

___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] new arm snapshot

2005-01-04 Thread Den Jean
On Tuesday 04 January 2005 10:54 am, Florian Klaempfl wrote:
> Though arm/linux didn't make it in 1.9.6, I built a new cross snapshot,

cross ?! it only contains arm executables :-)


[EMAIL PROTECTED] 1.9.7]# file ppcarm
ppcarm: ELF 32-bit LSB executable, ARM, version 1 (ARM), for GNU/Linux 2.0.0, 
statically linked, strippednly contains arm executables (not cross)


I created a cross ppcarm from CVS and it works :-)  thanks.
Could you still correct the snapshot so that I can link to it in the wiki.

Great timing by the way, I just finished updating 
my Qt/Embedded binding for the 
"Error: Can't declare procedure as EXTERNAL" problem.

I will post it on the web asap and update the wiki

Btw, the trigonometric functions still fail on arm.

Did you manage to install 3.5.1 (or 3.5.2) ?


kind regards,

Den Jean


 

___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


[fpc-pascal] Error: Can't declare procedure as EXTERNAL

2004-12-02 Thread Den Jean
Hi,

the new FPC CVS release of 29/11 forbids
delphi / kylix type of library use

eg 

--
interface

function QObjectList_create: QObjectListH; cdecl; overload;
function QObjectList_create(list: QObjectListH): QObjectListH; cdecl; overload;

implementation

function QObjectList_create(list: QObjectListH): QObjectListH; cdecl; external 
QtShareName name QtNamePrefix + 'QObjectList_create2';
function QObjectList_create: QObjectListH; cdecl; external QtShareName name 
QtNamePrefix + 'QObjectList_create';
--

is forbidden now and generates a "Error: Can't declare procedure as EXTERNAL" 
when compiling.

Apparently the external directive has to be moved to the INTERFACE section.
I do not know why this has changed (perhaps a very good reason),
but to me it seems not so good:

   1) This is not Delphi/Kylix compatible (just try to compile Qt.pas)

   2) This breaks a lot of existing code, especially bindings ( I will need to 
move 3283 external directives in my qte binding) 

   And most importantly:
   3) This way the interface gets cluttered with implementation details like 
"name QtNamePrefix + 'QObjectList_create2'"


kind regards,

Den Jean


___
fpc-pascal maillist  -  [EMAIL PROTECTED]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] FPC on ARM (eg Zaurus)

2004-11-28 Thread Den Jean
On Sunday 28 November 2004 02:56 pm, Den Jean wrote:

> In the mean time enjoy these animated screenshots of the demo program running 
> on the Zaurus.
>http://users.pandora.be/Jan.Van.hijfte/qtforfpc/ScreenShot03.html
> 

I updated the animation for the non Konqueror browsers.
Now those MSIE visitors are also able to view the animation.
If you already visited it, press the refresh button the bypass the cache.

kind regards,

Den Jean

___
fpc-pascal maillist  -  [EMAIL PROTECTED]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] FPC on ARM (eg Zaurus)

2004-11-28 Thread Den Jean
On Wednesday 24 November 2004 10:47 am, Florian Klaempfl wrote:

> I know, but I've to get my arm working first :(

Another incentive to get your zaurus up and running again.
The demo program now works on the Zaurus :-)

The updated now uses LargeInt instead of TMethod.
Some temporary trigonometric functions (cos/sin/arctan) have been added to demo 
program for the arm.
I still have some problems with interfaces 
   --> lifetime problems with _addref and 
   --> plain crashes for what seems to be valid code. (I avoided these calls 
for the moment)
But I will try to isolate these problems into a very small program.

In the mean time enjoy these animated screenshots of the demo program running 
on the Zaurus.
   http://users.pandora.be/Jan.Van.hijfte/qtforfpc/ScreenShot03.html

for sources look on 
http://users.pandora.be/Jan.Van.hijfte/qtforfpc/qtedemo.html 


kind regards,

Den Jean


___
fpc-pascal maillist  -  [EMAIL PROTECTED]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] FPC on ARM (eg Zaurus)

2004-11-23 Thread Den Jean
On Tuesday 23 November 2004 11:13 am, Florian Klaempfl wrote:

> This is indeed an improper implemntation of the arm abi, I'll fix it 
> asap. 

Thanks a lot. In the mean time I changed the binding so that it uses
LargeInt instead of TMethod. So the big demo program almosts works :-)

---
QHookH = LargeInt; // was TMethod before
procedure QButton_hook_hook_clicked(handle: QButton_hookH; hook: QHookH); cdecl;

procedure TQButton.Hook_clicked(Proc: QButton_clicked_Event);
begin
  QButton_hook_Hook_clicked(Hooks,LargeInt(TMethod(Proc)));  // Proc gets 
passed by value :-)
end;//   ^^^
---


I am struggling now with (or having fun with, depending on the view point)
 
 * Trigonometric functions. 
So temporarily I am using series like sin x = x- x^3/3! 
Is this related to the fact that there is no Math processor on the 
Zaurus ? 
"dmesg" reveals that there is a Netwinder Floating Point Emulator.
I haven't looked into the details yet. (which values crash what 
functions, I use cos/sin and arctan2). 
I'll do so asap.

 * dynamic arrays : TIntArray = array of integer.
On Intel it works fine but on arm not.
Bindhelp.pas provides TIntArray pascal helper functions to the binding that 
is written in C++

eg. this C-code copies integers from the Qt Int Array to the Pascal dynamic 
Array of integer

---
inline void copyQIntsToPInts(const QValueList &qi, PIntArray pi)
  {
int len = qi.count();
int *ints;
setIntsLength(pi, len); // this is call to a pascal SetIntsLength function
ints = (int *)getIntsPtr(pi);  // this is a call to a pascal GetIntsPtr 
function
for (int i = 0; i < len; i++)
  ints[i] = qi[i]; // here it crashes
  }


I crashes when it uses the address returned by getintsptr
GetIntsPtr is provided by bindhelp.pas:

  // Int array helpers
  function GetIntsPtr(const PA: TIntArray): Pointer; cdecl; export;
  begin
Result := @PA[0];
  end;


It works on intel and not on arm. 
But when I change the definition of GetIntsPtr to:


  function GetIntsPtr(var PA: TIntArray): Pointer; cdecl; export;
  begin
Result := @PA[0];
  end;


Then it works on the arm to. (changed const to var !)

By the way the definition of the pascal library function in the C++ library is:

  typedef void *PIntArray;
  typedef void *(*GetIntsPtr)(PIntArray pi);
  extern GetIntsPtr getIntsPtr;


*  I am using the last arm snapshot you provided because the current cvs 
version does not compile

   
> BTW: What OS do you run on your Zaurus? I've a lot of trouble with  
> OZ 3.5.1 e.g. with that ridiculous dropbear ssh demon used by OZ 3.5.1

I have a Zaurus SL6000. As it is rather new, an upgrade was not a priority yet.
I haven't seen update roms for the SL6000 either.
The SL6000 has a libqte.so.2.3.2 and a libqpe.so.1.5.0


kind regards, 

Jan

___
fpc-pascal maillist  -  [EMAIL PROTECTED]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] FPC on ARM (eg Zaurus)

2004-11-22 Thread Den Jean
On Sunday 21 November 2004 11:41 pm, Den Jean wrote:
> I also debugged it on the zaurus with gdb.
> 


I debugged somewhat more and this learned me that the record Method 
is passed by reference instead of by value as it should.
With a little hack I managed to force a call by value.


Library extract that shows the function that expects a record by value.
--
   // C definition in library of function that expects a record of type TMethod 
by value (hook parameter)
   C_EXPORT void QButton_hook_hook_clicked(QButton_hookH handle, QHookH hook);

  // definition of QHookH in library
  typedef struct {
void *func;
void *data;
  } QHook;
  typedef QHook QHookH;
--



Here is the Pascal code that passed the record by reference instead of by value
--
  // Pascal definition of external library function
  QHookH = TMethod;
  procedure QButton_hook_hook_clicked(handle: QButton_hookH; hook: QHookH); 
cdecl;
  procedure QButton_hook_hook_clicked; external QtShareName name QtNamePrefix + 
'QButton_hook_hook_clicked';
  
  // pascal code that calls the library function and passes the record by 
reference instead of by value
  QButton_hook_hook_clicked(button_hook,Method);
--



Here is the hack that enables me to force passing by value (the program than 
works)
--
  procedure QButton_hook_hook_clicked2(handle: QButton_hookH; func: integer; 
data: integer); cdecl;
  procedure QButton_hook_hook_clicked2; external QtShareName name QtNamePrefix 
+ 'QButton_hook_hook_clicked';

  // this call works
  
QButton_hook_hook_clicked2(button_hook,integer(Method.code),integer(Method.data));
--



I hope this helps in fixing the arm-port. :-)

kind regards,

Jan

___
fpc-pascal maillist  -  [EMAIL PROTECTED]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] FPC on ARM (eg Zaurus)

2004-11-21 Thread Den Jean
On Saturday 20 November 2004 11:53 pm, Den Jean wrote:

> it crashes
> when compiled for ARM 
> 

I also debugged it on the zaurus with gdb.

On clicking the button that is attached to AppQuit I get:
   Program received signal SIGILL, Illegal instruction.
   $000a0e84 in U_SYSUTILS_UPPERCASETABLE ()

I also checked wether method.func corresponds to @MyClass.AppQuit
and method.data to MyClass.  So I added this pascal code.

--
QButton_clicked_Event(Method):=MyClass.AppQuit;
writeln('@MyClass.AppQuit:',IntToHex(integer(@MyClass.AppQuit),4));
writeln('@Method.code:',IntToHex(integer(Method.code),4));
writeln('MyClass:',IntToHex(integer(MyClass),4));
writeln('@Method.data:',IntToHex(integer(Method.data),4))
--

A screenshot for fun of gdb debugging this fpc program on the zaurus is here:
http://users.pandora.be/Jan.Van.hijfte/qtforfpc/test01.png

I hope this helps.

kind regards,

Jan

___
fpc-pascal maillist  -  [EMAIL PROTECTED]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] FPC on ARM (eg Zaurus)

2004-11-20 Thread Den Jean
On Wednesday 10 November 2004 02:45 am, Florian Klaempfl wrote:

> >>Before I can test it, I've to reinstall my Zaurus, when updating to 
> >>3.5.1, the installation got broken :/

I have prepared something to test.

I created a small C-program as a reference (that works)
and then a FPC program that has a problem (it crashes
when compiled for ARM but not when compiled for intel/qvfb)

The program is a minimal Qt program with only one button.
We want to connect a pascal procedure to that button.
The binding is for pascal so it provides hooks to connect pascal TMethods.


// Pascal code that connects a method to the slot clicked()
QButton_clicked_Event(Method):=MyClass.AppQuit;
QButton_hook_hook_clicked(button_hook,Method);


It is this code that does not work under arm,
when the Method is called (the button is clicked), 
the program crashes.

By the way (not related to the problem)
  I did not give the button any text, because
  for this I need to initialize the binding with 
  some external pascal code (see bindhelp),
  and this is not possible in the simple C program.

To show how the Pascal Method gets called in the binding
Here are some extracts of the binding.
The signal clicked() gets connected to a slot of the Qt binding

--
// this is C++ code that implements 
QButton_hook_hook_clicked(button_hook,Method);
// Method is passed as parameter hook and stored in variable clicked_event

void hook_clicked(QHook &hook) { 
  if ( !clicked_event.func )
connect(handle, SIGNAL(clicked()), this, SLOT(clicked_hook()));
  clicked_event = hook;
  if ( !hook.func )
disconnect(handle, SIGNAL(clicked()), this, SLOT(clicked_hook()));
...
...
// clicked_event is defined as this
QHook clicked_event; 
...
...
// QHook is defines as this
typedef struct {
  void *func;
  void *data;
} QHook;
typedef QHook QHookH;
...

In the slot handler it calls the pascal method.
--
   void clicked_hook() {
  if ( clicked_event.func ) {
typedef void (*func_type)(void *data);
(*(func_type)clicked_event.func)(clicked_event.data);
  }private slots:
--


I hope this is enough starting information for this bug of the fpc arm 
crosscompiler.
Ask anything you may feel helpfull to solve this.

The codes is here:
http://users.pandora.be/Jan.Van.hijfte/qtforfpc/test01.tar.gz


By the way (perhaps related), for the intel/qvfb I need to add unit CMem as the 
first unit
of the uses clause to make any FPC Qt program work. 

If I add CMem when compiling  for arm, the program does not want to start. 
it complains with :
-
QSocket::writeBlock: Socket is not open
QSocket::writeBlock: Socket is not open
QSocket::writeBlock: Socket is not open
QSocket::writeBlock: Socket is not open
 No Qt/Embedded server appears to be running. 
 If you want to run this program as a server,
 add the -qws command line option.
-----


kind regards,

Den Jean

___
fpc-pascal maillist  -  [EMAIL PROTECTED]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] FPC on ARM (eg Zaurus)

2004-11-08 Thread Den Jean
On Sunday 07 November 2004 04:30 am, Florian Klaempfl wrote:
> 
> Before I can test it, I've to reinstall my Zaurus, when updating to 
> 3.5.1, the installation got broken :/
> 

It is time to reinstall your Zaurus. 
I just managed to create a small Qt program with FPC on the Zaurus :-)

Zaurus screenshot:
 http://users.pandora.be/Jan.Van.hijfte/qtforfpc/ScreenShot02.html
get sources on:
 http://users.pandora.be/Jan.Van.hijfte/qtforfpc/qtedemo.html


The bigger demo does not work yet on ARM, though it does on INTEL,

Intel Framebuffer screenshot:
http://users.pandora.be/Jan.Van.hijfte/qtforfpc/ScreenShot01.html

So there are some problems to solve. 
I will try to isolate the code that is problematic.


kind regards,

Den Jean




___
fpc-pascal maillist  -  [EMAIL PROTECTED]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] FPC on ARM (eg Zaurus)

2004-11-05 Thread Den Jean
On Friday 05 November 2004 08:57 am, Florian Klaempfl wrote:

> I built a new cross snapshot with all those issues fixed:

Big Big Big Thanks.

I can already cross-compile my demo program of 

http://users.pandora.be/Jan.Van.hijfte/qtforfpc/qtedemo.html

I updated it (wrong libraryname and some other stuff)
and added some screenshots.

Now I am struggling with stuff like

-
No Qt/Embedded server appears to be running 
If you want to run this program as a server
add the -qws command-line option
-

Though it should be (I think, not sure) when I am on the Zaurus ?!
And when I add -qws as suggested, I get

-
cannot find font definition file /usr/local/qte-embedded/lib/fonts/fontdir
is QTDIR set correctly 
-

echo $QTDIR reveals /home/QtPalmtop
and there is a  /home/QtPalmtop/lib/fontdir as it should be.
So I do not know
I'll search further

***
Thanks again for the great work on the arm compiler.
***

I will report asap when I get something of Qt/E running on the Zaurus with FPC.
(I already tried the C++ example and that works)

kind regards,

Den Jean





___
fpc-pascal maillist  -  [EMAIL PROTECTED]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] FPC on ARM (eg Zaurus)

2004-11-04 Thread Den Jean
Hi, 


On Sunday 31 October 2004 06:14 pm, Marco van de Voort wrote:
> 
> Try to add -Xd
> 

Thanks, it does what I need. Did not find this in the manual nor in fpc -h.

*
uses Dl;
*

I managed to compile my qt binding for arm (the library is C/C++ code)
but to test fpc's capability of using it on arm I'd like to do stuff like
Handle := dlopen(PChar(LibraryName), RTLD_NOW or RTLD_GLOBAL);
Addr := dlsym (Handle, PChar(LibQteIntfFunctions [i]));
if Addr = nil then writeln ('Function ''' + LibQteIntfFunctions[i] + ''' not found 
in library');

so I need to have a  "USES dl"  but a simple program like the following does not 
compile

==
program small;
uses SysUtils,Dl;
begin
writeln ('Hello World');
end.
==

ppcarm -Xd -Sd -XParm-linux- -Fl/opt/Embedix/tools/arm-linux/lib* 
-Fl/opt/Embedix/tools/lib/gcc-lib/arm-linux/2.95.2 small.pas
Free Pascal Compiler version 1.9.3 [2004/04/05] for arm
Copyright (c) 1993-2004 by Florian Klaempfl
Target OS: Linux for ARM
Compiling small.pas
Assembling small
Linking small
/usr/bin/arm-linux-ld: cannot find /lib/ld.so.1
small.pas(7) Error: Error while linking
Closing script ppas.sh


if I omit the linking stage (-Cn) Link.res contains 


INPUT(
-ldl
/lib/ld.so.1
)

So I fix this by replacing /lib/ld.so.1 with 
/opt/Embedix/tools/arm-linux/lib/ld-2.2.2.so
and compile with arm-linux-ld -o small link.res
The resulting program gives the following strange error


./small[enter]
bash:./small: No such or directory
---

But ./small really is there.

strace ./small gives:

---
strace: exec: No such file or directory
execve("./small",["./small"],[/* 30 vars */]) = 0
---

Some any ideas ?

*
uses Libc;
*
I also need Libc.
But when compiling


program small;
uses SysUtils,libc;
begin
writeln ('Hello World');
end.


I get 


arm-linux-ld: warning: cannot find entry symbol _start; defaulting to 84c8
/usr/lib/fpc/1.9.3/cross/arm-linux/units/rtl/system.o: In function 
`SYSTEM_SYSTEM_EXIT':
/usr/lib/fpc/1.9.3/cross/arm-linux/units/rtl/system.o(.text+0x147a8): undefined 
reference to `_haltproc'
-

So I add /usr/lib/fpc/1.9.3/cross/arm-linux/units/rtl/prt0.o to link.res (thank you 
Jose Pascual for this idea)   
Again this compiles but the resulting executable give the same ... "No such file or 
directory"...error as above.



Anyone any ideas left ???


kind regards,

Den Jean







___
fpc-pascal maillist  -  [EMAIL PROTECTED]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] FPC on ARM (eg Zaurus)

2004-10-31 Thread Den Jean
Hi,

I am trying to cross-compile a program a bit more
complicated than Hello World and I have the following problem.

ppcarm uses the wrong libraries because it uses some default lib paths
first before it uses the library paths added with -Fl

eg:

ppcarm -Sd -XParm-linux- -k'-z nodefaultlib'  -vt -Fl/opt/Embedix/tools/arm-linux/lib* 
-Fl/opt/Embedix/tools/lib/gcc-lib/arm-linux/2.95.2 test_dl.pas

gives error:
/usr/lib/crti.o: could not read symbols: File in wrong format

which is true,  /opt/Embedix/tools/arm-linux/lib/crti.o should be used

the -vt options tells me that /usr/lib is searched first.

Using library path: /lib/
Using library path: /usr/lib/
Using library path: /usr/X11R6/lib/
Using library path: /opt/Embedix/tools/arm-linux/lib/
 etc ...

With  -k'-z nodefaultlib' i tried in vain to omit searching for default libraries


So, how can I tell ppcarm not to use /usr/lib ?


When fiddling with LD_LIBRARY_PATH, I found out that 
the compiler programs ofcourse cannot cope with a library path to arm libs.


kind regards,
Den Jean



___
fpc-pascal maillist  -  [EMAIL PROTECTED]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] FPC on ARM (eg Zaurus)

2004-10-25 Thread Den Jean
On Monday 25 October 2004 02:36 am, Florian Klaempfl wrote:
> What about putting these information into the fpc wiki?
> 

see my first wiki page on: 
http://www.freepascal.org/wiki/index.php/Setup_Cross_Compile_For_ARM

linked by [Arm] (under development)
http://www.freepascal.org/wiki/index.php/Platform_list

If you have a better place than Platform List, just move it.


kind regards,

Den  Jean

___
fpc-pascal maillist  -  [EMAIL PROTECTED]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] FPC on ARM (eg Zaurus)

2004-10-22 Thread Den Jean
On Friday 22 October 2004 04:22 pm, Florian Klaempfl wrote:
>The "official" way is to do use -XP:
>ppcarm -XParm-linux- hello
>and install the arm-linux-as and arm-linux-ld into e.g. /usr/local/bin

Nice. Webpage has been updated.
But the help of ppcarm -h does not show this option XP  (if I checked correctly)
Perhaps some docs I missed.
Thx for the arm compiler work. 

ppcarm -h

  -X executable options:
  -Xclink with the c library
  -Xsstrip all symbols from executable
  -XDtry to link dynamic  (defines FPC_LINK_DYNAMIC)
  -XStry to link static (default) (defines FPC_LINK_STATIC)
  -XXtry to link smart(defines FPC_LINK_SMART)

kind regards,

Jan

___
fpc-pascal maillist  -  [EMAIL PROTECTED]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] FPC on ARM (eg Zaurus)

2004-10-22 Thread Den Jean
On Thursday 21 October 2004 06:02 pm, Florian Klaempfl wrote:
> > 
> > * Does anyone have a working ARM snapshot  ?
> 
> ftp://ftp.freepascal.org/fpc/snapshot/v19/linux-arm/fpc-1.9.3.arm.tar
> 

Hi

Thanks.
It works fine with the snapshot you pointed out.
For a report see : 
http://users.pandora.be/Jan.Van.hijfte/qtforfpc/SetupFPCCrossCompile.html

kind regards,

Den Jean

___
fpc-pascal maillist  -  [EMAIL PROTECTED]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


[fpc-pascal] FPC on ARM (eg Zaurus)

2004-10-21 Thread Den Jean
Hi,

Cross-compile for ARM:
==
I'd like to develop an application on Zaurus (arm) with FPC, 
but I do not manage to create a cross-compile setup. 

Qt/Embedded binding for FPC:
==
I already created a binding for FPC to Qt/Embedded that works
with libqte (the Qt/Embedded library) on Intel (under qvfb)

I did not have time yet to put it on Sourceforge, 
but you can get a binary libqteintf + pascal sources on:

http://users.pandora.be/Jan.Van.hijfte/qtforfpc/qtedemo.html


Compile errors in fpc/compiler/arm:
===

With the latest cvs (20 Oct 2004) I get the error below


make clean all OS_TARGET=linux CPU_TARGET=arm BINUTILSPREFIX=arm-linux-

---
..fpc/compiler/ppc   -darm -dGDB -dBROWSERLOG -dNOOPT -Xs -OG2p3 -n -Fuarm 
-Fusystems -Fu/other/storage/progs/fpcarm/fpc/rtl/linux -Fiarm -FE. -dRELEASE 
pp.pas
cpubase.pas(511,59) Fatal: Syntax error, "," expected but ")" found
---

When I fix this by adding a OS_NO to subreg2cgsize 
(do not know what I am doing :-)
the compilation continues and stops with:

---
cpupara.pas(44,94) Error: Identifier not found "tvarargspara"
---

So I fix this by adding 'parabase' to the uses clause of cpupara.pas 

Then I get the following compile error:

---
cpupara.pas(41,20) Error: There is no method in an ancestor class to be 
overridden: "tarmparamanager.getintparaloc(tproccalloption, LongInt):"
---

* Does anyone have a working ARM snapshot  ?
* Or a FPC CVS date on which the ARM part compiles ? 
* I already tried 30 Jan 2003. The date on which the FPC news 
   webpage announces that it works on Zaurus

kind regards,

Den Jean

___
fpc-pascal maillist  -  [EMAIL PROTECTED]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


[fpc-pascal]compiling CLX with FPC and Classes.Inc

2004-02-03 Thread Den Jean
Hi,

I'd like to use fpc with FreeCLX, but when compiling I stumbled on the
fact the SListIndexError is not known because {$i classes.inc} is included
after implementation and not just behind interface.

I hope this an error ? 

In kylix/source alike constants (constse.inc) are defined in 
RtlConsts and used everywhere.

kind regards,

Den Jean




___
fpc-pascal maillist  -  [EMAIL PROTECTED]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal]problems linking to libborqt

2004-01-26 Thread Den Jean
On Monday 26 January 2004 08:28 pm, Pedro Lopez-Cabanillas wrote:
> use:
> fpc -Fl/usr/lib/kylix3 test.pas
>

It worked.
Thank you very much.

kind regards,

Den Jean 


___
fpc-pascal maillist  -  [EMAIL PROTECTED]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal