Re: [fpc-pascal] Defining sonames?

2017-08-15 Thread Fred van Stappen
A concrete example. A Linux/FreeBSD fpc release was compiled using the pascal headers for libX11.so.6 and using symlink libX11.so >> libX11.so.6.0.8. This release was installed on a system (with libX11-dev too to make it work). If, some time later, a system-update was done to the brand new vers

Re: [fpc-pascal] Defining sonames?

2017-08-14 Thread Fred van Stappen
> Exactly, and it is why, for each fpc version, the appropriate symlink should > be assigned ( at the moment libX11.so.6 ) And this is the OS, with his updates, that will assign symlink libX11.so.6 to the last installed libX11.6.1.2.3.4.so Fre;D __

Re: [fpc-pascal] Defining sonames?

2017-08-13 Thread Fred van Stappen
>> You have a opinion that every respect, me first. > It's simply how it is and has been for the past 60 years or so. Ha, ok, with this argument, I stop to try to change things. Sorry for the noise. Fre;D ___ fpc-pascal maillist - fpc-pascal@lists.f

Re: [fpc-pascal] Defining sonames?

2017-08-13 Thread Fred van Stappen
Please Sven, keep cool. You have a opinion that every respect, me first. But maybe it could be interesting to listen to other, even if you think that those people are stupid. > The *-dev packages also contain the symbolic link from the library without > version to the versioned one. IMHO,

Re: [fpc-pascal] Defining sonames?

2017-08-13 Thread Fred van Stappen
Hello Martin. Description of libx11-dev package (in /DEBIAN/control). Package: libx11-dev ... Description: This package contains the development headers for the library found in libx11-6. Non-developers likely have little use for this package. ... Afaik, fpc does not use the C headers (I did no

Re: [fpc-pascal] uses myunit in '../src/myunit.pas' ?

2017-02-11 Thread Fred van Stappen
Hello Tim. OK, many thanks for your light. Fre;D De : fpc-pascal-boun...@lists.freepascal.org de la part de Tim Veldhuizen Envoyé : samedi 11 février 2017 06:04 À : fpc-pascal@lists.freepascal.org Objet : Re: [fpc-pascal] uses myunit in '../src/myunit.pas' ? Unit names are considered to

[fpc-pascal] fphttpserver and streaming ?

2017-02-07 Thread Fred van Stappen
Hello. Is it possible to do a web-streaming-server with fphttpserver ? If yes, are there examples ? If no, what are the steps to realize it? In a loop, a buffer of float is filled at each loop. What must be done for: - Prepare the server to welcome that buffer. - On each loop, copy the buffer t

Re: [fpc-pascal] Blind Users

2016-10-26 Thread Fred van Stappen
Hello. Thanks Graeme for your clear explanations. sak (Speaker Assitive Kit) is working for LCL, fpGUI and MSEgui. Here demo of sak in action: https://sites.google.com/site/designerext/test_sak_mse_fred.mp4 ideU is a voice assisted IDE, derived from MSEide. Binary release for Windows, L

Re: [fpc-pascal] Lazarus vs MSEgui

2016-04-08 Thread Fred van Stappen
> > Maybe (once again IMO) the only con is that MSEide cannot deal with > > LCL projects. > > Maybe not designing forms visually, but there is no problems in > compiling LCL based projects with MSEide. In fact, I have done that many > times before. Oooops, I did not know that it was possible. So,

Re: [fpc-pascal] Lazarus vs MSEgui

2016-04-08 Thread Fred van Stappen
> con of mside why I don't use it: > > The behaviour of the cursor on the end of the line. You cannot go behind the > line as it is usual in almost every other editor. Huh, what do you mean ? I do not feel any difference with other editors... The big plus, IMO, of MSEide is his weight. : less

Re: [fpc-pascal] ideU version 1.0.0.

2015-12-27 Thread Fred van Stappen
> that qualifies as different client software ;) ;) ;) Thanks Kitty for your light ;-) I seems that answers sent from hotmail.com gives my full name... I prefer "fredvs" so I will use only http://free-pascal-general.1045716.n5.nabble.com/ for answer/create new topic. Thanks to note it. Fre;D

Re: [fpc-pascal] ideU version 1.0.0.

2015-12-24 Thread Fred van Stappen
> From: paul2...@brenemanlabs.com > Date: Thu, 24 Dec 2015 09:24:29 -0500 > Subject: Re: [fpc-pascal] ideU version 1.0.0. > > Thanks for a simple IDE that a beginner can install. I've already > posted a few links on my pages. Many thanks ;-) @ Martin, dont worry, MSEide is clearly mentioned, i

Re: [fpc-pascal] Sound procedure does not work

2015-09-15 Thread Fred van Stappen
> What component can I use when i only want to play only the specified > Hz frequency of sound? Hello and thanks to try uos. You do not need a special component, there is the procedure => uos_AddFilterIn(); Take a look at filterplay.pas example (both for LCL and fpGUI). But, of course, you may

Re: [fpc-pascal] Sound procedure does not work

2015-09-15 Thread Fred van Stappen
> I checked... The demos have it, but the actual UOS units don't... OK, Graeme, you win ;-) I will update it asap. Many thanks. Fre;D ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.fre

Re: [fpc-pascal] FreeBSD distro with fpc as star.

2015-09-06 Thread Fred van Stappen
> After increasing the memory I'm up and running. Thanks! Fantastic ;-) ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] FreeBSD distro with fpc as star.

2015-09-04 Thread Fred van Stappen
> That will be very convenient for setting up quick > development VM's per project or client. Thanks Graeme :-) Huh, you may use it as VM project but as iso-live cdrom/ usb too. And you may also install it to device, like your main server ;-). Cheers. Fre;D

Re: [fpc-pascal] FreeBSD and fpc messages.

2015-08-17 Thread Fred van Stappen
> Well done! I'm glad you finally got it sorted out. > > Regards, > - Graeme - Thanks Graeme. After trying many fpc releases, install all FreeBSD distros that exist, re-compiling fpc, changing the background image of desktop, the battery of the netbook, my haircut, finally it works ... Happ

Re: [fpc-pascal] FreeBSD and fpc messages.

2015-08-16 Thread Fred van Stappen
Re-re- hello Pierre, Aaargh, I have to take a rest... No, the image is ok, first command use full path to compiler (and message are not ok) and second command use full path of the symlink to compiler. So, to resume (and sorry for all this doubts): Using full path to compiler to run it, like =>

Re: [fpc-pascal] FreeBSD and fpc messages.

2015-08-16 Thread Fred van Stappen
Re-hello Pierre. Oops, indeed, sorry for previous post, both commands are using full path in image. I have to recheck all, clean everything to know what was wrong and where. Write you later. Fre;D ___ fpc-p

Re: [fpc-pascal] FreeBSD and fpc messages.

2015-08-16 Thread Fred van Stappen
Hello Pierre and thank to help. > Did you notice that the date of compilation is also different > in both cases... > > Are you really sure that the symlink points to the same file? Bien vu ! (well seen). Indeed. Before to find the "trick", i have installed many different fpc version, compiled

Re: [fpc-pascal] FreeBSD and fpc messages.

2015-08-12 Thread Fred van Stappen
> All it needs is binutils (and in case of i386 and x86-64 on ELF > platforms such as FreeBSD, only the binutils linker). Hello. I have try with old binutils but same result. See attachment. Thanks. Fre;D __

Re: [fpc-pascal] FreeBSD and fpc messages.

2015-08-12 Thread Fred van Stappen
> > What libraries are used by fpc to render the output messages? > > FPC does not use any library. Which language are you using for the messages? I use the default language (En). What i do not understand is that, in console, gcc gives messages ok and fpc only hexa characters. > > By the way, d

Re: [fpc-pascal] How to get the permission f a file ?

2015-06-17 Thread Fred van Stappen
> Fred, the tiSetFileReadOnly() I sent you the other day already uses > fpstat() before checking/setting the read-only flag. So you are halfway > there. ;-) Yep, many thanks. ;-) PS: Bart's tip works like lovely charm... => function FileIsExecutable(const AFilename: string): boolean; var In

[fpc-pascal] loadlibrary() unsafe ?

2015-06-11 Thread Fred van Stappen
Hello. Here the thing: a open-source program, eSpeak (voice synthezer) uses 2 libraries: espeak-library and portaudio. In eSpeak source => - For the Windows version, the libraries are included in the executable (static linked). To do run the program => it is easy => just run the executa

Re: [fpc-pascal] Error compile library on Linux.

2014-03-22 Thread Fred van Stappen
>> Works fine for me if I compile everything with those parameters >> (and -trunk) I assume you compiled with the build.sh and then >> didn't clean up properly when you started adding parameters, >> thus leaving units compiled without the pic params. Hello. I have re-created a new fpc.cfg a

Re: [fpc-pascal] Error compile library on Linux.

2014-03-22 Thread Fred van Stappen
Yep, many thanks for the attention you give : => http://bugs.freepascal.org/view.php?id=25901 Hum, Marco explained : >> Works fine for me if I compile everything with those parameters >> (and -trunk) I assume you compiled with the build.sh and then >> didn't clean up properly when you started

Re: [fpc-pascal] Error compile library on Linux.

2014-03-21 Thread Fred van Stappen
>> Indeed, not all bug reports are followed up within two days... Yep, i feel better now ;-) Thanks Jonas. ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.fre

Re: [fpc-pascal] Error compile library on Linux.

2014-03-20 Thread Fred van Stappen
> It's quite possible that there is nevertheless a bug, but you will have to > provide the source code required to reproduce it and compilation > instructions, otherwise there is nothing we can do (as always). Hum, not too much answer here... ;-( Re-resumed : Units/Project => https://github.com/g

Re: [fpc-pascal] Error compile library on Linux.

2014-03-18 Thread Fred van Stappen
> but you will have to provide the source code required to reproduce > it and compilation instructions, otherwise there is nothing we can do (as > always).> Jonas Hum, ok (but you promise not to tell, it is still a secret...) ;-) The project-units : >> https://github.com/graemeg/fpGUI/tree/deve

Re: [fpc-pascal] Error compile library on Linux.

2014-03-18 Thread Fred van Stappen
> /usr/bin/ld: /home/fred/mylib/lib/x86_64-linux/thefile.o: réadressage de > R_X86_64_32S en vertu de « .bss.n_u_$thefile_$$_usedfirstmessage » cannot > be used when creation of shared object, recompile with -fPIC/home>> > >/fred/fmylib/lib/x86_64-linux/thefile.o: error adding symbols: Bad value

Re: [fpc-pascal] Library.StringFunction() : PChar => NO

2014-03-17 Thread Fred van Stappen
> (not getting the name thing but wanting to enter into the spirit of the > things) PS : Cfr your studies in Poudlard school... :-) ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepa

Re: [fpc-pascal] Library.StringFunction() : PChar => NO

2014-03-16 Thread Fred van Stappen
> Date: Sun, 16 Mar 2014 10:43:17 +0100 > From: reinierolislag...@gmail.com > To: fpc-pascal@lists.freepascal.org > Subject: Re: [fpc-pascal] Library.StringFunction() : PChar => NO > > On 15/03/2014 12:21, Fred van Stappen wrote: > >> I thought that it was men

Re: [fpc-pascal] Library.StringFunction() : PChar => NO

2014-03-15 Thread Fred van Stappen
> I thought that it was mentioned there somewhere already... > If nit feel free to add it. That's what a wiki is good for afterall. ^^ Done. => http://wiki.freepascal.org/shared_library Many thanks Sven. ___ fp

Re: [fpc-pascal] Library.StringFunction() : PChar => NO

2014-03-15 Thread Fred van Stappen
>I thought that it was mentioned there somewhere already... > If nit feel free to add it. That's what a wiki is good for afterall. ^^ Hum, never seen... I will add it ASAP ;-) > You don't need the MyString variable, you can simply use > AStringClass.SomeText. => OK > And you should definitel

Re: [fpc-pascal] Library.StringFunction() : PChar => NO

2014-03-14 Thread Fred van Stappen
> Note: if your MyString is valid through the complete lifetime it could > be used you can also use "Result := PChar(MyString);" Hum, to be sure that i understand... type TStringClass = class(TObject) Name: AnsiString; does not change SomeText: AnsiString; / may change.. en

Re: [fpc-pascal] Library.StringFunction() : PChar => NO

2014-03-14 Thread Fred van Stappen
> Date: Fri, 14 Mar 2014 23:11:14 +0100 > From: pascaldra...@googlemail.com > To: fpc-pascal@lists.freepascal.org > Subject: Re: [fpc-pascal] Library.StringFunction() : PChar => NO > > On 14.03.2014 22:07, Fred van Stappen wrote: > > > It's not a problem, as lo

Re: [fpc-pascal] Error compile library on Linux.

2014-03-14 Thread Fred van Stappen
Hello. Here are some news from the front : The fpc Library : TheRevolutionaryLibrary library; uses TheBigUnit; begin end. fpc compiler parameter => -fPIC. => Windows 32 bit => Compiles and works more than perfect. => Windows 64 bit => Compiles and works more than perfect. => Linux 32 bit => C

Re: [fpc-pascal] Library.StringFunction() : PChar => NO

2014-03-14 Thread Fred van Stappen
> It's not a problem, as long as you provide an API to dispose the memory > used by the returned PChar. > The responsibility of calling this API is delegated > to the application. Yep, with pleasure,... but how to provide an API (and what do you mean with "provide an API to dispose the memory") ?

Re: [fpc-pascal] Library.StringFunction() : PChar => NO

2014-03-14 Thread Fred van Stappen
> Date: Fri, 14 Mar 2014 08:20:46 -0700 > From: leledumbo_c...@yahoo.co.id > To: fpc-pascal@lists.freepascal.org > Subject: Re: [fpc-pascal] Library.StringFunction() : PChar => NO > > > It will be the memory manager of the library who deals with the PChar > result. > So difficult for the main appl

[fpc-pascal] Library.StringFunction() : PChar => NO

2014-03-14 Thread Fred van Stappen
Hello great fpc people. It is about functions dealing with string inside a library... If i use that kind of function inside the library : >> InLibStringFunction() : PChar ; It will be the memory manager of the library who deals with the PChar result. So difficult for the main application to ma

[fpc-pascal] Error compile library on Linux.

2014-03-11 Thread Fred van Stappen
Hello. After successfully translate a useful unit into a universal library, i want to do the same with something bigger. I have compile that unit into a Windows library. Perfect, it compile and works. But when i try to compile it on Linux a get that error message, even if i compile it with -f

Re: [fpc-pascal] fp universal library ?

2014-02-26 Thread Fred van Stappen
>> I wonder if uos would allow for this use of DSP-Effects: >>- read a wav file and output it to a new wav file ("playing" it is not necessary/sensible here) >>on the fly "insert" a DSP effect (i.e. run the samples through an effect processor) >> the parameter(s) of the

Re: [fpc-pascal] fp universal library ?

2014-02-26 Thread Fred van Stappen
>> PS : I will do a wiki for uoslib too. OK, updated >> http://wiki.lazarus.freepascal.org/uos PS : I think that the code of the examples in /fpc_examples from >> https://github.com/fredvs/uoslib are more self-explained... Thanks. Fred. __

Re: [fpc-pascal] fp universal library ?

2014-02-26 Thread Fred van Stappen
> GREAT > Any documentation to make this usable ? > -Michael All the examples have lot of explanations. ;-) There is also a wiki for uos : >> http://wiki.lazarus.freepascal.org/uos The only things to change for uoslib are: In uses section, add uoslib_h in place of uos. And to

Re: [fpc-pascal] fp universal library ?

2014-02-25 Thread Fred van Stappen
Hello everybody. I am extremely happy to announce the birth of the universal uos library version 1.0. uos (United Open-libraries of Sound) unifies the best open-source audio libraries. With uos you can: . Listen to mp3, ogg, wav, flac,... audio files. . With 16, 32 or float 32 bit resolution.

Re: [fpc-pascal] fp libraries do not like cmem ?

2014-02-15 Thread Fred van Stappen
Hello Jeff. I will study your code. Many thanks. Fred ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] fp libraries do not like cmem ?

2014-02-14 Thread Fred van Stappen
>Also note that this is a good approach with respect to `universiality`, but if you need to... > Ewald Thanks Ewald for your useful advices. Now, a other battle will begin : Create headers for C, CNet, Basic, Java, ... and translate all the uos Pascal examples. But that is not the problem of

Re: [fpc-pascal] fp libraries do not like cmem ?

2014-02-14 Thread Fred van Stappen
>What I have been wondering for some time now (perhaps you wrote it in a > mail and I missed it): do you use the same memory manager in the library > and in your test program? > Ewald Yeep, Ewald, you are the Winner. And you impress me a lot with your perspicacity. The battle has ended, with

Re: [fpc-pascal] fp libraries do not like cmem ?

2014-02-14 Thread Fred van Stappen
>What I have been wondering for some time now (perhaps you wrote it in a >mail and I missed it): do you use the same memory manager in the library >and in your test program? Oops, indeed i forget that point... The test now are with cmem only in program, not in library. I will test with cmem into

Re: [fpc-pascal] fp libraries do not like cmem ?

2014-02-14 Thread Fred van Stappen
Hello. It seams to me that i monopolize the forum here. Please advice if it borrow you, i will stop directly... ;-) I still fight with cmem and trust me, it is a hard battle. Mainly because the debugger gives me very few infos and because, if i do not use cmem, all examples are working perfectly

Re: [fpc-pascal] fp libraries do not like cmem ?

2014-02-13 Thread Fred van Stappen
>> bt full ? (gdb) bt full #0 0x7fffefe02c14 in ?? () from /home/fred/uoslib/src/libuoslib.so No symbol table info available. #1 0x0040 in ?? () No symbol table info available. #2 0x7fffefe02d0e in ?? () from /home/fred/uoslib/src/libuoslib.so No symbol table info available

Re: [fpc-pascal] fp libraries do not like cmem ?

2014-02-13 Thread Fred van Stappen
> bt full ? Yep, thanks Ewald, i will try that. ;-) > But if you don't have debug info for your library this won't help you much. Hum, the library is fp, so i can compile with debug option. But maybe i do not use the good compiler-parameters. What compiler-parameters will give me the most detai

Re: [fpc-pascal] fp libraries do not like cmem ?

2014-02-13 Thread Fred van Stappen
Hello. Here news from the front. The good news. All console and fpGUI programs using cmem are working with the fp uos library. There is only problem with LCL widgetset + cmem. Here the result of debug + bt of a LCL program using cmem (no problem without cmem) : it does not help me, i do not u

Re: [fpc-pascal] fp libraries do not like cmem ?

2014-02-13 Thread Fred van Stappen
@ Sven and Tomas : many, many thanks for answer. Ok, i will fight with the code tonight to (try) to understand what is wrong. Write you later... PS : Without cmem, the library is working perfectly. Last night i listen to songs many hours, with lot of DSP applied, changing that DPS at runtime, p

Re: [fpc-pascal] fp libraries do not like cmem ?

2014-02-13 Thread Fred van Stappen
> Please provide a simple, self contained example that shows this problem. >Regards, >Sven Hello. Hum, i have done a simple library, with a thread and a simple program calling this library. Not usefully to show it because, both using cmem are working perfectly... ;-) So the

[fpc-pascal] fp libraries do not like cmem ?

2014-02-13 Thread Fred van Stappen
Hello. This to note that a fp library does crash the program who call it, if that program uses cmem. To reproduce the crash, create a fp library with a thread. Start the thread via the main program (who uses cmem) and it will crash when the library reach thread.terminate. If you use cmem for

Re: [fpc-pascal] fp universal library ?

2014-02-13 Thread Fred van Stappen
>The bad news : >All programs using LCL (Lazarus widgetset) crash after thread.terminate >>inside the library... >I dont know why, it is the same code and the same library. >Maybe i have to do something but i dont know what. >Using directly the uos unit, without using the library, is ok for L

Re: [fpc-pascal] Can a library synchronize foreign procedure ?

2014-02-12 Thread Fred van Stappen
>But as TThread is an Object and Objects are implemented on the heap, I >suppose that you need synchronized heaps between the library and the >main program. Exactly, that is what i want... >AFAIK, there is a way to have a library (if written with fpc) "attach" to the >ma

[fpc-pascal] Can a library synchronize foreign procedure ?

2014-02-12 Thread Fred van Stappen
Hello everybody. The question is certainly stupid because i guess it is impossible, but who knows... Is is possible for a library to synchronize a procedure form the program who use that library ? I guess no but does it exist a "universal" way for a library to sent message to the program who u

Re: [fpc-pascal] fp universal library ?

2014-02-12 Thread Fred van Stappen
> I don't use Lazarus, i.e. .lpi files are of no use for me. The option > -fPIC isn't necessary for the Win32 target, i.e. I didn't miss that one > (but I was aware of it - at least it was well visible unlike the others > which I had to find by trial and error). Ok and thanks to note it. Hum, i ha

Re: [fpc-pascal] fp universal library ?

2014-02-11 Thread Fred van Stappen
> It might be better to mention the necessary compiler options (-Mobjfpc > -Sh) or even better include them directly in the respective sources. > > In addition, compiling "uoslib.pas" results in "uoslib.dll", whereas you > try to load uos.dll from libconsoleplay.pas. Yep, sorry. But if you compi

Re: [fpc-pascal] fp universal library ?

2014-02-11 Thread Fred van Stappen
Hello. Here next adventure of uos library... I have good news for fpc. ;-) I have try with a "hello world" 32bit library in Windows 7 64bit. It works, a 32bit program can access a 32bit fpc library. But i have bad news for me. :-( I have try with uoslib, and try, and try, changing everything, b

Re: [fpc-pascal] fp universal library ?

2014-02-11 Thread Fred van Stappen
>I have changed all cdecl into stdcall but without luck... >Did you change the calling convention for both the import and the export > code? (just a sidenote: on Linux you should use cdecl no matter what ifnt >your library to be used by other languages and

Re: [fpc-pascal] fp universal library ?

2014-02-10 Thread Fred van Stappen
Hello. Here next episode of the conversion of a useful unit into a universal library. In a recent topic i was taking about the total victory of the conversion in Linux OS. Now im fighting to do it in Windows. I have Windows 7-64 bit. If compiling the library with fpc-64bit, all is working perfect

Re: [fpc-pascal] High() and Low() for empty dynamic arrays

2014-02-09 Thread Fred van Stappen
> So: don't touch it! ;) > > Regards, > Sven Yep, many thanks for that clear answer. ;-) ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pas

Re: [fpc-pascal] High() and Low() for empty dynamic arrays

2014-02-09 Thread Fred van Stappen
> Date: Sun, 9 Feb 2014 13:08:16 +0100 > From: freepas...@ypa-software.de > To: fpc-pascal@lists.freepascal.org > Subject: Re: [fpc-pascal] High() and Low() for empty dynamic arrays > > Am 09.02.2014 13:05, schrieb Fred van Stappen: > > if length(MyArray) > 0 th

Re: [fpc-pascal] High() and Low() for empty dynamic arrays

2014-02-09 Thread Fred van Stappen
Hello everybody. I have a question (maybe stupid) about dynamic arrays... Usually, before to close the application, to avoid memory leak, i do : if length(MyArray) > 0 then for x := 0 to high(MyArray) do MyArray[x].Free; But, if i use : setlength(MyArray, 0) ; would it do the same job ?

Re: [fpc-pascal] fp universal library ?

2014-02-09 Thread Fred van Stappen
Hello everybody. Here next episode of the conversion of a useful fp unit into a universal library... After a hard battle, ... i win. But mainly because of the extremely high quality of fpc. The compiler gives me useful tips to realise that unique library. Unique because that dynamic loaded

Re: [fpc-pascal] fp universal library ?

2014-02-04 Thread Fred van Stappen
> Now what I would like in the compiler is a warning: potential memory > leak at myclass := TMyUnitClass.Create; > > ;) Oops, prior message was cut... Yep, before to get that sympathetic message, i changed the code, now all the class.create are done inside the unit used by the library and i wil

Re: [fpc-pascal] fp universal library ?

2014-02-04 Thread Fred van Stappen
> - Here example for function inside a class of myunit: > > > > library mylib ; > > > > uses > > myunit; > > > > function mylibclassfunction() : integer; cdecl; > > var > > myclass : TMyUnitClass; /// class defined in myunit (if can be a > > variable outside the function) > > > > begin > >

Re: [fpc-pascal] Size of program vs library ?

2014-02-04 Thread Fred van Stappen
>>(*) Once dynamic runtime packages are supported this might change though... >>Regards, >> Sven Ok, thanks Sven, that will be the best... But before the triumph of fp, i will do that universal audio open source library with fp too... Many thanks for all of you, fp desi

Re: [fpc-pascal] Size of program vs library ?

2014-02-04 Thread Fred van Stappen
> If I am correct, the compiler will add the PIC by itself. > But someone of the compiler team should confirm this... > > Michael. Yep, Michael, many thanks for answer. Sorry to insist on that, but the size of fp library is very too big vs other libraries (C for example). But there are huge a

Re: [fpc-pascal] Size of program vs library ?

2014-02-03 Thread Fred van Stappen
> Date: Mon, 3 Feb 2014 18:30:57 +0100 > From: mich...@freepascal.org > To: fpc-pascal@lists.freepascal.org > Subject: Re: [fpc-pascal] Size of program vs library ? > > > > On Mon, 3 Feb 2014, Fred van Stappen wrote: > > > Hello. > > > > Here siz

[fpc-pascal] Size of program vs library ?

2014-02-03 Thread Fred van Stappen
Hello. Here size of "nude" program and library compiled with fpc 2.7.1. Why is it a so big size-difference ? Compiled with => fpc 2.7.1 => linux 64 Compiler parameters : -MObjFPC -Scghi -CX -Os1 -Xs -XX -vewnhi -fPIC program prognude ; begin end. => 26.9 k library libnude ; begin end. => 196

Re: [fpc-pascal] fp universal library ?

2014-02-02 Thread Fred van Stappen
Yep, a other useful tip : To avoid future problems, use name mangling : Like that : exports myFunc name 'myFunction' ; ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-b

Re: [fpc-pascal] fp universal library ?

2014-02-02 Thread Fred van Stappen
Hello everybody. Here next episode of the conversion of a useful fp unit into a universal library... The goal is to make a library from a unit used by programs. That unit has lot of complicated procedures-functions, inside some home-made classes, using many dynamic arrays who vary in length and

Re: [fpc-pascal] fp universal library ?

2014-02-02 Thread Fred van Stappen
> From: hinsta...@yandex.ru > To: fpc-pascal@lists.freepascal.org > Date: Sun, 2 Feb 2014 15:31:00 +0400 > Subject: Re: [fpc-pascal] fp universal library ? > > > > 02.02.2014, 02:45, "Fred van Stappen" : > >> > Yep, thanks Michael. > >>

Re: [fpc-pascal] fp universal library ?

2014-02-01 Thread Fred van Stappen
> > Yep, thanks Michael. > > > > Hum, may i export dynamic array ? > > No, you'll need to export these as (typed) pointers and a count. > > Regards, > Sven Re-Argh, ok, (and i understand now why the library-examples are so simple :-) ). Many thanks for that brilliant explanations. Ok, so

Re: [fpc-pascal] fp universal library ?

2014-02-01 Thread Fred van Stappen
> > > On Sat, 1 Feb 2014, Fred van Stappen wrote: > > > > > > > Hello everybody. > > > > > > > > Ok, i jump... > > > > > > [snip] > > > > > > > > > > > Stop compil showing error at dot of

Re: [fpc-pascal] fp universal library ?

2014-02-01 Thread Fred van Stappen
> Date: Sat, 1 Feb 2014 17:00:02 +0100 > From: mich...@freepascal.org > To: fpc-pascal@lists.freepascal.org > Subject: Re: [fpc-pascal] fp universal library ? > > > > On Sat, 1 Feb 2014, Fred van Stappen wrote: > > > Hello everybody. > > > > Ok,

Re: [fpc-pascal] fp universal library ?

2014-02-01 Thread Fred van Stappen
Hello everybody. Ok, i jump... I decide to begin the conversion of a unit (wrapper to other libraries + lot of functions who link those libraries) into a universal fp library. After Googling a while (and finding very poor doc, only few for Delphi, with always the hypra-simple same example...),

Re: [fpc-pascal] fp universal library ?

2014-01-29 Thread Fred van Stappen
> You might want to take a look here: >http://winff.org Oops, Winff is fp... i did not know that. So, no excuse, it is possible to do a universal fp library. @ Leledumdo and Paul => many thanks. PS : Because of fp, i need to study lot other languages now :-). Fred

[fpc-pascal] fp universal library ?

2014-01-29 Thread Fred van Stappen
Hello everybody ;-) I have developed a fp-wrapper, uos, who links to the best audio open-source libraries: >> https://github.com/fredvs/uos/ This main fp-wrapper uses other fp-wrappers who link to those audio-libraries. Those fp-audio-wrappers have much more features than the c original audio-

Re: [fpc-pascal] Pure FPC ?

2014-01-27 Thread Fred van Stappen
> Date: Mon, 27 Jan 2014 08:53:25 +0100 > From: xhaj...@hajny.biz > To: fpc-pascal@lists.freepascal.org > Subject: Re: [fpc-pascal] Pure FPC ? > > On Mon, January 27, 2014 01:38, Fred van Stappen wrote: > > Ok, i will try to explain better. > > > > When you com

Re: [fpc-pascal] Pure FPC ?

2014-01-26 Thread Fred van Stappen
Hello Waldo. Aaargh, there is double-topic, can you look at the twins topic ? Thanks. ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] Pure FPC ?

2014-01-26 Thread Fred van Stappen
Ok, i will try to explain better. When you compile fpc, you do > make clean + make all. Is it possible to configure fpc-compil and disable Delphi compatibility...? If not possible, no problem, i only want to know :-) . Fred __

Re: [fpc-pascal] Pure FPC ?

2014-01-26 Thread Fred van Stappen
Re-hum,... It seams to me that fpc do not need delphi-compatibility to compile himself (or i miss something). So it could be possible to compile fpc without any Delphi-compatible module (Yes/No). But maybe it does not will change lot of things, only it will make fpc a few "lighter" (so forget

Re: [fpc-pascal] Pure FPC ?

2014-01-26 Thread Fred van Stappen
> What extent of Delphi incompatibility would satisfy you? > > {$objfpc} > has offered 'mild' incompatibility for many years. > What additional incompatibilities are you looking for? > > Howard Hum, maybe i do not explain good the proposition... I do not want a other {$define not Delphi}, i w

Re: [fpc-pascal] Pure FPC ?

2014-01-26 Thread Fred van Stappen
Ooops, sorry for 2X same topic... I used http://free-pascal-general.1045716.n5.nabble.com/ for first topic it responds that the message was refused... So i sent the second one, as usual, with hotmail.com... Fred _

[fpc-pascal] Pure FPC ?

2014-01-26 Thread Fred van Stappen
Hello. Does it exist a option to compile fpc without Delphi compatibility ? If no, what do you think about that ? I know, it will be lot of work (like create a Delhi_Compatiblizer class...) but it could be great for people who want a "lighter" compiler...(like me, who have already done, since

Re: [fpc-pascal] windows.GetProcAddress() vs DynLibs.GetProcAddress()

2014-01-18 Thread Fred van Stappen
Yep, yep, yep, i get it... I will (try) to explain the thing... The error comes mainly because i was focused on SoundTouchDLL.h. (Thanks to Ludo). That wrapper is for windows only. Before to call a DSP-buffer-procedure, you must do : FHandle := soundtouch_createInstance(); But the result of n

Re: [fpc-pascal] windows.GetProcAddress() vs DynLibs.GetProcAddress()

2014-01-17 Thread Fred van Stappen
> That routine is defined in SoundTouchDLL.cpp which is the windows dll > wrapper. Do you have the linux equivalent? Oops, im full of doubt now... Do you think the SoundTouchDLL.h wrapper is for Windows only ( and, yes, the old wrapper uses stdcall (who is windows only)). And for linux how does

Re: [fpc-pascal] windows.GetProcAddress() vs DynLibs.GetProcAddress()

2014-01-17 Thread Fred van Stappen
>Ha, then you use/compiled a different version. Since a `extern "C"` preserves > the symbol name (that is the trick I use to link in a lot of external C++ > code: >just put extern "C" in front of the symbol). or it could be that I am >completely >missing something here. [for example: is the symbo

Re: [fpc-pascal] windows.GetProcAddress() vs DynLibs.GetProcAddress()

2014-01-17 Thread Fred van Stappen
> Yep, there is a brand new wrapper from trunk : Of course, all the tests i have done are with that new wrapper... ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/m

Re: [fpc-pascal] windows.GetProcAddress() vs DynLibs.GetProcAddress()

2014-01-17 Thread Fred van Stappen
> Note one detail: it is declared there as __stdcall, not as __cdecl, so > perhaps this has something to do with it? > > @Fred: Also note that the type HANDLE is defined there as a pointer, so [as a > sanity test of sorts] sizeof(Handle {in pascal}) should be equal to > sizeof(HANDLE /*in C/C+

Re: [fpc-pascal] windows.GetProcAddress() vs DynLibs.GetProcAddress()

2014-01-17 Thread Fred van Stappen
> That routine is defined in SoundTouchDLL.cpp which is the windows dll > wrapper. Do you have the linux equivalent? > > Ludo PS : For new new arriving : SoundTouchDLL.cpp is part of SoundTouch, a audio processing library : >> http://www.surina.net/soundtouch/download.html @ Ludo : In /sourc

Re: [fpc-pascal] windows.GetProcAddress() vs DynLibs.GetProcAddress()

2014-01-17 Thread Fred van Stappen
> I don't know if the Handle type in the header is defined by the C++ compiler > or by the package itself. Consult their respective documentation for more > info. Here declaration of create instance : // Create a new instance of SoundTouch processor. SOUNDTOUCHDLL_API HANDLE __cdecl soundtouch_c

Re: [fpc-pascal] windows.GetProcAddress() vs DynLibs.GetProcAddress()

2014-01-17 Thread Fred van Stappen
> Writeln(sizeof(THandle)); // for console apps FHandle := soundtouch_createInstance(); writeln(FHandle); Writeln(sizeof(FHandle)); Gives that result : 10321232 4 > I don't know if the Handle type in the header is defined by the > C++ compiler or by the package itself. > Consult their respect

Re: [fpc-pascal] windows.GetProcAddress() vs DynLibs.GetProcAddress()

2014-01-17 Thread Fred van Stappen
> What is the value of the handle that was returned? > > Ludo Re-hello Ludo. That code : if ST_Load('/home/fred/dynlib_vs_windows/libSoundTouch.so') then writeln('libSoundTouch.so loaded'); if FHandle <> NilHandle then soundtouch_clear(FHandle); FHandle := soundtouch_createInstance();

Re: [fpc-pascal] windows.GetProcAddress() vs DynLibs.GetProcAddress()

2014-01-17 Thread Fred van Stappen
> On 01/17/2014 03:55 PM, Fred van Stappen wrote: > > > >> > I run nm and find the name of the procedures ( PS : without > > nm-Ewald's tip, you must be a high soothsayer to find it) > >> > For example, a C called procedure

  1   2   >