[fpc-pascal] installing on RHEL5 (libtinfo)

2010-03-04 Thread Bruce Bauman
I'm running CentOS 5.3 (x86_64), and want to install FPC 2.4 on my
machine, preferably from an RPM, but I can't because of a failed
dependency on libtinfo. I've found many references to this problem in
the mailing lists, but am unsure of what the easiest solution is.

1) Can I install the FPC RPM with an option to ignore the missing
dependency (--ignoredeps?)?
2) Is there a compatible RPM which contains libtinfo somewhere?
3) Is there an updated RPM for FPC 2.4.0 which removes the dependency?

Or, do I need to rebuild the RPM from source after removing the
dependency?
Is it easier to rebuild from an SVN checkout of the correct branch, or
should I use the original source RPM and rebuild from that?

Thanks for your advice.

-- Bruce
CONFIDENTIALITY NOTICE: This e-mail is confidential and intended
solely for the use of the individual or entity to which it is addressed.  If
you are not the intended recipient, be advised that you have received 
this email in error and that any use, dissemination, forwarding, printing 
or copying of this e-mail is strictly prohibited. If you received this e-mail
in error, please delete it from your computer and contact the sender.

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


Re: [fpc-pascal] installing on RHEL5 (libtinfo)

2010-03-04 Thread Jonas Maebe


On 04 Mar 2010, at 14:44, Bruce Bauman wrote:


1) Can I install the FPC RPM with an option to ignore the missing
dependency (--ignoredeps?)?


Probably, yes. The only thing that depends on that library is the text  
mode IDE. The compiler and all other utilities do not use it.



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


[fpc-pascal] Re: gdb, dwarf, and ansistring

2010-03-04 Thread Seth Grover
> I believe this is a bug that was introduced with GDB 7.0
...
> I don't know whether anyone already reported this bug to the GDB developers.


http://sourceware.org/bugzilla/show_bug.cgi?id=11349

I just reported it as a bug to GDB.

-SG

--
This email is fiction. Any resemblance to actual events
or persons living or dead is purely coincidental.

Seth Grover
sethdgrover[at]gmail[dot]com
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Re: gdb, dwarf, and ansistring

2010-03-04 Thread Jonas Maebe


On 04 Mar 2010, at 15:45, Seth Grover wrote:


I believe this is a bug that was introduced with GDB 7.0

...
I don't know whether anyone already reported this bug to the GDB  
developers.


http://sourceware.org/bugzilla/show_bug.cgi?id=11349

I just reported it as a bug to GDB.


To ensure that it's as easy as possible to reproduce and fix by the  
gdb people, you should preferably include a compiled version of the  
program, and the result of "readelf -gw", and optionally if possible a  
version of a program that demonstrates the problem compiled to  
assembler code with any dependencies on the FPC RTL removed (so they  
can add it to the gdb test suite). E.g., maybe the problem is also  
reproducible with a pchar that's passed as "var" parameter (since  
ansistring is currently just an alias for pchar in the DWARF debug  
info) and the string concatenation is also unnecessary to reproduce  
the problem.


It's similar to how people reporting a bug in FPC shouldn't include a  
test program that depends on Qt, KDE or even Lazarus, because that
a) makes it harder to test (because you have to install all  
dependencies, and then figure out whether the problem is in these  
extra libraries, how they are used, or in the compiler/rtl)

b) harder to reduce to a test case that can included in the test suite

I.e., I think this program will also demonstrate the problem:

procedure doit (var s : pchar);
begin
end;

var
 s : pchar;
begin
 s := 'test';
 doit(s);
end.

If you compile this to assembler code and strip out all the  
unnecessary references to threadvars, RTL init code etc, it should  
become a nice, self-contained example that the GDB developers can  
easily use without having to install FPC first.



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


Re: [fpc-pascal] installing on RHEL5 (libtinfo)

2010-03-04 Thread Zaher Dirkey
On Thu, Mar 4, 2010 at 3:52 PM, Jonas Maebe wrote:

> --ignoredeps


I have same problem on OpenSUSE 11.2, how i can install FPC 2.4.0 on it.

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

Re: [fpc-pascal] installing on RHEL5 (libtinfo)

2010-03-04 Thread Zaher Dirkey
On Thu, Mar 4, 2010 at 10:43 PM, Zaher Dirkey  wrote:

> On Thu, Mar 4, 2010 at 3:52 PM, Jonas Maebe wrote:
>
>> --ignoredeps
>
>
> I have same problem on OpenSUSE 11.2, how i can install FPC 2.4.0 on it.
>
> --
> Zaher Dirkey
>

I forced to install by
rpm -i --force --nodeps *.rpm

but the IDE not worked.

Thanks in advanced.

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

Re: [fpc-pascal] installing on RHEL5 (libtinfo)

2010-03-04 Thread Juha Manninen
Hello.

> I forced to install by
> rpm -i --force --nodeps *.rpm

> but the IDE not worked.

Right. The text mode IDE is the only thing that doesn't work.
Please use Lazarus instead as your IDE. :-)

I remember asking the same question earlier about libtinfo dependency. The 
answer was something like that there shouldn't be such dependencies any more. 
It seems to be still there.

> Thanks in advanced.

You are welcome!


P.S.
I use OpenSUSE 11.2, too. Could you please, if you are not extremely busy, 
check if you can reproduce the problem in issue:
0015885: QT Combobox flickers when updating items list 
URL: http://bugs.freepascal.org/view.php?id=15885

The QT bindings maintainer is not able to reproduce it. I am already prepared 
to install the official (original) version of QT and a different window 
manager to see if the problem is related to OpenSuse tweaks.


Regards,
Juha Manninen
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] installing on RHEL5 (libtinfo)

2010-03-04 Thread Zaher Dirkey
On Fri, Mar 5, 2010 at 12:45 AM, Juha Manninen wrote:

>
> P.S.
> I use OpenSUSE 11.2, too. Could you please, if you are not extremely busy,
> check if you can reproduce the problem in issue:
> 0015885: QT Combobox flickers when updating items list
> URL: http://bugs.freepascal.org/view.php?id=15885
>
> The QT bindings maintainer is not able to reproduce it. I am already
> prepared
> to install the official (original) version of QT and a different window
> manager to see if the problem is related to OpenSuse tweaks.
>
>
>
I am new to Linux, i still fighting with it :), but i remember in WiCE slow
devices there is a flikker when adding items even when use
BeginUpdate/EndUpdate.

For win32/wince add/insert item ignore the UpdateState when recalc the
height of combobox,

in \lcl\interfaces\win32\win32listsl.inc

procedure TWin32ComboBoxStringList.Insert(Index: integer; const S: string);
begin
  inherited Insert(Index, S);
  if GetCount = 1 then
UpdateComboHeight;
end;

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

Re: [fpc-pascal] installing on RHEL5 (libtinfo)

2010-03-04 Thread Zaher Dirkey
On Fri, Mar 5, 2010 at 12:45 AM, Juha Manninen wrote:

> Hello.
>
> > I forced to install by
> > rpm -i --force --nodeps *.rpm
>
> > but the IDE not worked.
>
> Right. The text mode IDE is the only thing that doesn't work.
> Please use Lazarus instead as your IDE. :-)
>
> I remember asking the same question earlier about libtinfo dependency. The
> answer was something like that there shouldn't be such dependencies any
> more.
> It seems to be still there.
>
>
I resolved my problem,
download from this page
http://rpmfind.net/linux/rpm2html/search.php?query=libtinfo.so.5
ncurses-libs-5.7-3.20090207.fc12.i686.rpm
extract file
/lib/libtinfo.so.5.7
to you PC
/lib
and rename it by remove .7 to be libtinfo.so.5
and launch the FP

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

[fpc-pascal] Re: gdb, dwarf, and ansistring

2010-03-04 Thread Seth Grover
Thanks, I have done as you suggested and attached a compiled version
of the program, the output of readelf -gw, and the assembly generated
by "fpc -a -al -an" as well.

Hopefully this will allow the GDB developers to more easily figure out
the problem.

-SG

--
This email is fiction. Any resemblance to actual events
or persons living or dead is purely coincidental.

Seth Grover
sethdgrover[at]gmail[dot]com
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


[fpc-pascal] Linking statically C code with stdcall functions

2010-03-04 Thread cobines
Hello,

I'm trying to link my program statically with bzip2 library under
Win32. The exported functions are declared as stdcall. I can link
dynamically by declaring functions like this:

function BZ2_bzCompressInit(...): Integer; stdcall; external 'bz2';

It seems that whenever I explicitly give the library name after
'external' FPC always links dynamically, so if I want to link
statically I do:

{$LINKLIB bz2}
function BZ2_bzCompressInit(...): Integer; stdcall; external;

But the names are mangled FPC style:

# nm abbzip2.o | grep -i bzCompressInit
 U 
ABBZIP2_BZ2_BZCOMPRESSINIT$TBZSTREAMREC$LONGINT$LONGINT$LONGINT$$LONGINT

I found I can do this by specifying names of the functions, but I have
to use mangled names:

{$LINKLIB bz2}
function BZ2_bzCompressInit(...): Integer; stdcall; external name
'_bz2_bzcompressi...@16';

Is there a way I can declare the external function to use "C" style mangling?


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