Re: [fpc-pascal] RE: Get Local IP using glib (eth0,eth1)

2006-10-06 Thread Micha Nelissen
Jeff Pohlmeyer wrote: function to read the local IP eth0/eth1 using glibc library. This one is a little cleaner... program ip_addr; {$MODE OBJFPC} uses libc; It doesn't seem like you're using libc specific functions ? You can also write a fpc 'native' one using fpsocket and fpioctl in

[fpc-pascal] Unistalling FPC (and reinstalling from svn)

2006-10-06 Thread Adrian Maier
Hello, I have a silly question : which is the best way to uninstall FPC ? I have used the 2.0.4 tarball (Linux) and the install script included within. I chose to install it in /usr/local. Now, I need to compile from sources (so debug some problems with sqldb) and i want to make sure that

Re: [fpc-pascal] Unistalling FPC (and reinstalling from svn)

2006-10-06 Thread Marco van de Voort
I have a silly question : which is the best way to uninstall FPC ? I have used the 2.0.4 tarball (Linux) and the install script included within. I chose to install it in /usr/local. No automatic way. Maybe the script should keep a filelist of what it installs somehow. Everything sqldb

Re: [fpc-pascal] RE: Get Local IP using glib (eth0,eth1)

2006-10-06 Thread TOUZEAU DAVID
Many Thanks Jeff and Micha. This function works perfectly without need to regex ifconfig... And i use glibc I develop only on linux system. Great respects... Just another question... (this because i came from Windows OS) how can i list wich interface loaded without need to parse

Re: [fpc-pascal] RE: Get Local IP using glib (eth0,eth1)

2006-10-06 Thread Marco van de Voort
This function works perfectly without need to regex ifconfig... And i use glibc I develop only on linux system. Note that it is linux/x86 only. No 64-bit, or other platforms. ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org

[fpc-pascal] Re: fpUnit - AssertEquals gives Access violation

2006-10-06 Thread Graeme Geldenhuys
Oh, I forgot to mention. If the ObjectStates match, the test passes fine, and doesn't give an access violation. While creating the new AssertEquals method, I purposefully created a failure with then gives the access violation, instead to the comparison message I expected: Failing on 1:

Re: [fpc-pascal] Re: fpUnit - AssertEquals gives Access violation

2006-10-06 Thread Vincent Snijders
Graeme Geldenhuys schreef: Oh, I forgot to mention. If the ObjectStates match, the test passes fine, and doesn't give an access violation. While creating the new AssertEquals method, I purposefully created a failure with then gives the access violation, instead to the comparison message I

[fpc-pascal] [libtar.pas]:Error: Illegal type conversion: ShortString to ^Char without compilator options

2006-10-06 Thread TOUZEAU DAVID
Dear I would like to use some units developped from delphi/klyx with Lazarus IDE On Linux. It seems that there is some differences between delphi/freepascal especially for longstring conversion. Many times, i received this compilator error : For example by using the LibTar.pas

Re: [fpc-pascal] [libtar.pas]:Error: Illegal type conversion: ShortString to ^Char without compilator options

2006-10-06 Thread Vincent Snijders
TOUZEAU DAVID schreef: Dear I would like to use some units developped from delphi/klyx with Lazarus IDE On Linux. It seems that there is some differences between delphi/freepascal especially for longstring conversion. Many times, i received this compilator error : For example by using

Re: [fpc-pascal] Last missing benchmark: regex-dna

2006-10-06 Thread Marco van de Voort
Although fpc has a regexpr unit: http://svn.freepascal.org/svn/fpc/trunk/packages/base/regexpr/regexpr.pp It has many todos, such as adding support for | in the search expression. So this unit doesn't have enough functionality. While '|' support is to be considered basic regex

Re: [fpc-pascal] Re: fpUnit - AssertEquals gives Access violation

2006-10-06 Thread Graeme Geldenhuys
Here is the backtrace. I removed all other Assert tests, so only the one that causes the problem is executed. What is strange though, is that I created a new test that only creates the object and then tests the ObjectState. It it works, but all the other actual tests don't. I hate such

Re: [fpc-pascal] [libtar.pas]:Error: Illegal type conversion: ShortString to ^Char without compilator options

2006-10-06 Thread TOUZEAU DAVID
Many thanks Vincent the {$mode delphi} is a good way... Vincent Snijders a écrit : TOUZEAU DAVID schreef: Dear I would like to use some units developped from delphi/klyx with Lazarus IDE On Linux. It seems that there is some differences between delphi/freepascal especially for longstring

[fpc-pascal] RE: Get Local IP using glib (eth0,eth1)

2006-10-06 Thread Jeff Pohlmeyer
how can i list wich interface loaded without need to parse /etc/networks/...? I would parse /proc/net/dev instead program ifnames; var s:shortstring; f:text; p:LongInt; begin assign(f,'/proc/net/dev'); reset(f); while not eof(f) do begin readln(f,s); p:=pos(':',s); if ( p

Re: [fpc-pascal] RE: Get Local IP using glib (eth0,eth1)

2006-10-06 Thread Marco van de Voort
I would parse /proc/net/dev instead Better, but still Linux only. For a good solution, a resolver unit that accesses libc should be written that is portable (unlike the libc unit) ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org

Re: [fpc-pascal] RE: Get Local IP using glib (eth0,eth1)

2006-10-06 Thread TOUZEAU DAVID
Many Thanks for this way jeff... /proc/net/dev is more compatible Impressed it for your information. My program will run only on linux system... Marco van de Voort a écrit : I would parse /proc/net/dev instead Better, but still Linux only. For a good solution, a resolver unit that

Re[2]: [fpc-pascal] Last missing benchmark: regex-dna

2006-10-06 Thread Пётр Косаревский
Basic seems to be: |()?*+ (non-UNICODE) support (from wikipedia). | is not basic afaik. From re_format BSD Manpage: Obsolete (``basic'') regular expressions differ in several respects. `|' is an ordinary character and there is no equivalent for its functional- ity. `+' and

[fpc-pascal] RE: Get Local IP using glib (eth0,eth1)

2006-10-06 Thread Jeff Pohlmeyer
Better, but still Linux only. For a good solution, a resolver unit that accesses libc should be written that is portable (unlike the libc unit) If I understood correctly, the OP had two questions: 1. Retrieve a list of interface names on a *linux* system. 2. Return the IP address for a given

Re[2]: [fpc-pascal] Last missing benchmark: regex-dna

2006-10-06 Thread Пётр Косаревский
Then there is also synregexpr.pas: http://svn.freepascal.org/svn/lazarus/trunk/components/synedit/synregexpr.pas But that is not distrubuted with fpc. And I don't know, if the license is open source. Is it looks likes a BSD derivative, but item 3, about income, doesn't seem to fit in.

Re: [fpc-pascal] Last missing benchmark: regex-dna

2006-10-06 Thread Vincent Snijders
Пётр Косаревский schreef: Then there is also synregexpr.pas: http://svn.freepascal.org/svn/lazarus/trunk/components/synedit/synregexpr.pas But that is not distrubuted with fpc. And I don't know, if the license is open source. Is it looks likes a BSD derivative, but item 3, about income, doesn't

Re: [fpc-pascal] RE: Get Local IP using glib (eth0,eth1)

2006-10-06 Thread Graeme Geldenhuys
I have these two functions in my .bashrc file. You only need to run ii for the cool output. Now back to the question - If it is for linux only, why not just use the /sbin/ifconfig output. After all, it is accurate and seem much easier than all those libc/library methods. I pull the IPs and

Re: [fpc-pascal] RE: Get Local IP using glib (eth0,eth1)

2006-10-06 Thread Marco van de Voort
Better, but still Linux only. For a good solution, a resolver unit that accesses libc should be written that is portable (unlike the libc unit) If I understood correctly, the OP had two questions: 1. Retrieve a list of interface names on a *linux* system. 2. Return the IP address for

Re: [fpc-pascal] Unistalling FPC (and reinstalling from svn)

2006-10-06 Thread Jochem Berndsen
On Friday 06 October 2006 10:49, Adrian Maier wrote: I have a silly question : which is the best way to uninstall FPC ? I don't know. Also, after compiling FPC with 'make build' , if i execute 'make install' will it copy everyting in /usr/local by default ? Is the destination

Re: [fpc-pascal] RE: Get Local IP using glib (eth0,eth1)

2006-10-06 Thread TOUZEAU DAVID
Many thanks to the community To reply to Graeme : why not just use the /sbin/ifconfig output ? Simply to be more dev compliance... using an external program is slower and sometime ifconfig doesn't exist or is deleted on target computers. To reply to Marco : And the only good solution is a

[fpc-pascal] visualserver from VisualSynapse how implement it as a Linux console Daemon

2006-10-06 Thread TOUZEAU DAVID
Dear is anybody there use visualserver from VisualSynapse (http://visualsynapse.sourceforge.net/?id=8) and impleted it on Linux has a console mode...?? Examples given is only on application interface ... Problems: 1) When the application start, no web page are generated... 2) i would like

[fpc-pascal] THREADVARLIST_FVCOMMON THREADVARLIST_MEMORY undefined symbols while linking

2006-10-06 Thread Ken G. Brown
Downloaded fpc 2.0.4 yesterday and I am trying to compile a legacy CW Pro 2 app on Mac 10.4.8 with Xcode 2.4. I am getting undefined symbols THREADVARLIST_FVCOMMON THREADVARLIST_MEMORY when trying to link, and I have no clue how to get past this problem. I searched my hard drive and found them

Re: [fpc-pascal] RE: h2pas error report

2006-10-06 Thread Marc Santhoff
Am Donnerstag, den 05.10.2006, 22:19 -0500 schrieb Jeff Pohlmeyer: Errm, I actually forgot the obvious questions: What's wrong here? How can I get around it? cat input.h | awk '{gsub(/\__int64\/, long long ); print}' output.h - should work, at least on Linux x86 That has done the

[fpc-pascal] Install freepascal Mysql package to kylix 3

2006-10-06 Thread suryono_03
Hi, does anyone know how to install freepascal mysql component to kylix 3 open edition? Or is there any database component that can be use with kylix 3 open edition? Thx b4. = ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org