Re: [lazarus] LCL in Dll
On Nov 22, 2007 6:01 PM, Leonardo M. Ramé [EMAIL PROTECTED] wrote: That means Zeos uses LCL?, I still don't understand why the dll works correctly by compiling in FPC from command line and not by compiling from Lazarus. Maybe some compilation switch, probably stripping is the issue. Razvan _ To unsubscribe: mail [EMAIL PROTECTED] with unsubscribe as the Subject archives at http://www.lazarus.freepascal.org/mailarchives
Re: [lazarus] LCL in Dll
The problem was solved by upgrading the compiler to 2.3.1., I was using 2.2.1 supplied with Lazarus snapshot. Razvan Adrian Bogdan escribió: On Nov 22, 2007 6:01 PM, Leonardo M. Ramé [EMAIL PROTECTED] wrote: That means Zeos uses LCL?, I still don't understand why the dll works correctly by compiling in FPC from command line and not by compiling from Lazarus. Maybe some compilation switch, probably stripping is the issue. Razvan _ To unsubscribe: mail [EMAIL PROTECTED] with unsubscribe as the Subject archives at http://www.lazarus.freepascal.org/mailarchives _ To unsubscribe: mail [EMAIL PROTECTED] with unsubscribe as the Subject archives at http://www.lazarus.freepascal.org/mailarchives
Re: [lazarus] LCL in Dll
Leonardo M. Ramé wrote: I'd try to compile Zeos Library in a Dll using Lazarus, it comiples, but can't be loaded at least using LoadLibrary in Windows, resulting in an Unknown Run-Time error 202. Reading in old forums, I found that isn't possible to create forms in dlls because of LCL problems, a bug report was created regarding this issue (check this: http://www.freepascal.org/mantis/view.php?id=7181 ), but it seems to be frozen. Not frozen, but the target is set to post 1.0. That means that at least the developers won't adress it now. My think my problem is related to that bug, because I can create the dll using straight FPC from command line and it works correctly. Creating dlls is not the problem, but anything TAppliation related cannot be used in a dll. (delphi uses some hhoks to connect the TAppliation instance in the dll to the one in the mainapp) Does anyone addressed the issue? any positive feedback? Marc _ To unsubscribe: mail [EMAIL PROTECTED] with unsubscribe as the Subject archives at http://www.lazarus.freepascal.org/mailarchives
Re: [lazarus] LCL in Dll
Marc Weustink escribió: Leonardo M. Ramé wrote: Creating dlls is not the problem, but anything TAppliation related cannot be used in a dll. (delphi uses some hhoks to connect the TAppliation instance in the dll to the one in the mainapp) That means Zeos uses LCL?, I still don't understand why the dll works correctly by compiling in FPC from command line and not by compiling from Lazarus. Leonardo. _ To unsubscribe: mail [EMAIL PROTECTED] with unsubscribe as the Subject archives at http://www.lazarus.freepascal.org/mailarchives
Re: [lazarus] LCL in DLL
Hi all, The library can be compiled with lcl. But, for example with form, there is no response when we clic on it. Does anyone know which Lazarus/FPC unit(s) manage win events or messages ? Nobody is interested with lcl in dll (see bug id 0007182) ? thanks a lot PS:sorry for my bad english 2007/6/27, Christian Budde [EMAIL PROTECTED]: Felipe Monteiro de Carvalho schrieb: On 6/27/07, Yury Sidorov [EMAIL PROTECTED] wrote: Please test the latest FPC 2.3.1 from trunk. The problem with debugingo in DLLs was fixed yesterday. Would that be considered for 2.2.2? As far as I saw, the fix has already been merged to the fixes_2_2 branch, but I might be wrong here. _ To unsubscribe: mail [EMAIL PROTECTED] with unsubscribe as the Subject archives at http://www.lazarus.freepascal.org/mailarchives
Re: [lazarus] LCL in DLL
yes, its interests me, but apparently it is not a priority, It is necessary to still wait… Thanks, 2007/7/10, fvpats [EMAIL PROTECTED]: Hi all, The library can be compiled with lcl. But, for example with form, there is no response when we clic on it. Does anyone know which Lazarus/FPC unit(s) manage win events or messages ? Nobody is interested with lcl in dll (see bug id 0007182) ? thanks a lot PS:sorry for my bad english 2007/6/27, Christian Budde [EMAIL PROTECTED]: Felipe Monteiro de Carvalho schrieb: On 6/27/07, Yury Sidorov [EMAIL PROTECTED] wrote: Please test the latest FPC 2.3.1 from trunk. The problem with debugingo in DLLs was fixed yesterday. Would that be considered for 2.2.2? As far as I saw, the fix has already been merged to the fixes_2_2 branch, but I might be wrong here. _ To unsubscribe: mail [EMAIL PROTECTED] with unsubscribe as the Subject archives at http://www.lazarus.freepascal.org/mailarchives -- Laurent. My Web : http://wile64.neuf.fr/ French Forum : http://lazforum-fr.tuxfamily.org/index.php
Re: [lazarus] LCL in DLL
Btw. can someone please make the default extension for libraries '.dll' instead of '.exe'. It doesn't make any sense, does it? AFAIK, it is .dll if you create a library project and not an application. Vincent _ To unsubscribe: mail [EMAIL PROTECTED] with unsubscribe as the Subject archives at http://www.lazarus.freepascal.org/mailarchives
Re: [lazarus] LCL in DLL
From: Christian Budde [EMAIL PROTECTED] Hi Phil, This has never worked. There was a time when you could put a form in a DLL and it would start okay (on Windows), but it wouldn't respond to keyboard inputs, as I recall. Now I can't even get a DLL containing a form to start without crashing the host app. I got it working here with very carefully chosen compiler settings. It is still buggy as hell when it comes to libraries. With FPC 2.1.5 I'm able to compile a library (unfortunately without debug information). The problem is that the initialisation doesn't seem to be called correctly. For this reason I do all the initialisation in runtime. Please test the latest FPC 2.3.1 from trunk. The problem with debugingo in DLLs was fixed yesterday. Yury. _ To unsubscribe: mail [EMAIL PROTECTED] with unsubscribe as the Subject archives at http://www.lazarus.freepascal.org/mailarchives
Re: [lazarus] LCL in DLL
Hi Vincent, AFAIK, it is .dll if you create a library project and not an application. Unfortunately this doesn't work if I converted a library project from Delphi to Lazarus using the menuitem under 'tools'. In this case it is always an .exe file. Do you (or anyone else) have an idea of how to change this? Is it some kind of option to set. Right now I always adjust the filename after the conversation, but I think there mus be a more genuine way to do that. Kind regards, Christian _ To unsubscribe: mail [EMAIL PROTECTED] with unsubscribe as the Subject archives at http://www.lazarus.freepascal.org/mailarchives
Re: [lazarus] LCL in DLL
From: Christian Budde [EMAIL PROTECTED] Hi Yury, Please test the latest FPC 2.3.1 from trunk. The problem with debugingo in DLLs was fixed yesterday. Yes, now the DLLs are finally valid. However debugging doesn't work (it simply ignores the breakpoint and crashes after the execution), but it's probably because I'm not sure how to pass the options '-Aas -Xe' to the compiler. I tried using the project settings 'pass to linker', but I guess it's not the same. However, thanks a lot, Try gdb 6.6 also. With the latest fpc trunk DLL debugging works for me. Yury. _ To unsubscribe: mail [EMAIL PROTECTED] with unsubscribe as the Subject archives at http://www.lazarus.freepascal.org/mailarchives
Re: [lazarus] LCL in DLL
On Wed, 27 Jun 2007 19:58:03 +0300 Yury Sidorov [EMAIL PROTECTED] wrote: From: Christian Budde [EMAIL PROTECTED] Hi Yury, Please test the latest FPC 2.3.1 from trunk. The problem with debugingo in DLLs was fixed yesterday. Yes, now the DLLs are finally valid. However debugging doesn't work (it simply ignores the breakpoint and crashes after the execution), but it's probably because I'm not sure how to pass the options '-Aas -Xe' to the compiler. I tried using the project settings 'pass to linker', but I guess it's not the same. This is the right place: Compiler Options - Other - Custom options. Vincent _ To unsubscribe: mail [EMAIL PROTECTED] with unsubscribe as the Subject archives at http://www.lazarus.freepascal.org/mailarchives
Re: [lazarus] LCL in DLL
Hi Vincent, This is the right place: Compiler Options - Other - Custom options. Thanks! _ To unsubscribe: mail [EMAIL PROTECTED] with unsubscribe as the Subject archives at http://www.lazarus.freepascal.org/mailarchives
Re: [lazarus] LCL in DLL
On 6/27/07, Yury Sidorov [EMAIL PROTECTED] wrote: Please test the latest FPC 2.3.1 from trunk. The problem with debugingo in DLLs was fixed yesterday. Would that be considered for 2.2.2? Maybe we could make a wish list for 2.2.2? Waiting for 2.4 may take several years, and having more reliable dlls is very important. -- Felipe Monteiro de Carvalho _ To unsubscribe: mail [EMAIL PROTECTED] with unsubscribe as the Subject archives at http://www.lazarus.freepascal.org/mailarchives
Re: [lazarus] LCL in DLL
Felipe Monteiro de Carvalho schrieb: On 6/27/07, Yury Sidorov [EMAIL PROTECTED] wrote: Please test the latest FPC 2.3.1 from trunk. The problem with debugingo in DLLs was fixed yesterday. Would that be considered for 2.2.2? As far as I saw, the fix has already been merged to the fixes_2_2 branch, but I might be wrong here. _ To unsubscribe: mail [EMAIL PROTECTED] with unsubscribe as the Subject archives at http://www.lazarus.freepascal.org/mailarchives
RE: [lazarus] LCL in DLL
This has never worked. There was a time when you could put a form in a DLL and it would start okay (on Windows), but it wouldn't respond to keyboard inputs, as I recall. Now I can't even get a DLL containing a form to start without crashing the host app. On Delphi this works fine and you just set the DLL form's Application.Handle to the calling app's Handle to integrate it with the main app. I tested this with OS X recently too: same crash. Bottom line is that it doesn't appear as though you can put a form in a DLL with Lazarus. For now, it's best to use only non-UI units in the DLL code. Thanks. -Phil -Original Message- From: fvpats [mailto:[EMAIL PROTECTED] Sent: Tue 6/26/2007 12:30 PM To: lazarus@miraclec.com Subject: [lazarus] LCL in DLL hi, i would like using lcl in a library (dll) but i didn't find any answer anywhere (net, bugtracker fpc, ...) does anyone know how doing this ? thanks a lot winmail.dat
Re: [lazarus] LCL in DLL
Hi Phil, This has never worked. There was a time when you could put a form in a DLL and it would start okay (on Windows), but it wouldn't respond to keyboard inputs, as I recall. Now I can't even get a DLL containing a form to start without crashing the host app. I got it working here with very carefully chosen compiler settings. It is still buggy as hell when it comes to libraries. With FPC 2.1.5 I'm able to compile a library (unfortunately without debug information). The problem is that the initialisation doesn't seem to be called correctly. For this reason I do all the initialisation in runtime. However keystrokes still don't work. Btw. can someone please make the default extension for libraries '.dll' instead of '.exe'. It doesn't make any sense, does it? Kind regards, Christian _ To unsubscribe: mail [EMAIL PROTECTED] with unsubscribe as the Subject archives at http://www.lazarus.freepascal.org/mailarchives