Latest securebridge won't compile on Linux

Discussion of open issues, suggestions and bugs regarding network security and data protection solution - SecureBridge
Post Reply
snorkel
Posts: 384
Joined: Tue 08 Aug 2006 15:10
Location: Milwaukee WI USA

Latest securebridge won't compile on Linux

Post by snorkel » Mon 10 Feb 2014 18:22

Getting this error with the latest 6.2 on Lazarus 1.0.14:
(prior I was using version 5.x on linux)

/home/snorkel/laz_components/sbridge/Source/CRSocketImpl.inc(317,16) Error: Duplicate identifier "Socket"

Ok, so I renamed the socket function to _socket, then I get this:

/home/snorkel/laz_components/sbridge/Source/CRSocketImpl.inc(416,24) Hint: Local variable "Hints" does not seem to be initialized
/home/snorkel/laz_components/sbridge/Source/CRSocketImpl.inc(20,16) Hint: Local type "PPAddrInfo" is not used
/home/snorkel/laz_components/sbridge/Source/ScSSHSocket.pas(72,25) Error: Identifier not found "PSockAddr"
/home/snorkel/laz_components/sbridge/Source/ScSSHSocket.pas(72,25) Error: Error in type definition
/home/snorkel/laz_components/sbridge/Source/ScSSHSocket.pas(74,43) Error: Identifier not found "PSockAddr"
/home/snorkel/laz_components/sbridge/Source/ScSSHSocket.pas(80,25) Error: Identifier not found "PSockAddr"
/home/snorkel/laz_components/sbridge/Source/ScSSHSocket.pas(80,25) Error: Error in type definition
/home/snorkel/laz_components/sbridge/Source/ScSSHSocket.pas(86,43) Error: Identifier not found "PSockAddr"
/home/snorkel/laz_components/sbridge/Source/ScSSHSocket.pas(103,1) Fatal: There were 6 errors compiling module, stopping

snorkel
Posts: 384
Joined: Tue 08 Aug 2006 15:10
Location: Milwaukee WI USA

Re: Latest securebridge won't compile on Linux

Post by snorkel » Mon 10 Feb 2014 19:44

FYI,
I tried to compile 6.1 and that did not work either.

Dimon
Devart Team
Posts: 2910
Joined: Mon 05 Mar 2007 16:32

Re: Latest securebridge won't compile on Linux

Post by Dimon » Tue 11 Feb 2014 11:11

In order to solve the problem, apply the following changes.
1. Find the lines below of the CRSocketImpl.inc unit and delete them:

Code: Select all

function socket(af, struct, protocol: Integer): TSocket;
begin
  Result := fpsocket(af, struct, protocol);
end;
2. Add the Sockets unit to the uses clause of the ScSSHSocket.pas source file.
3. Add the following code to the implementation section of the ScSSHSocket.pas unit:

Code: Select all

{$IFDEF UNIX}
function inet_ntoa(Entry: in_addr): AnsiString;
begin
  Result := NetAddrToStr(Entry);
end;
{$ENDIF}

snorkel
Posts: 384
Joined: Tue 08 Aug 2006 15:10
Location: Milwaukee WI USA

Re: Latest securebridge won't compile on Linux

Post by snorkel » Sun 23 Feb 2014 16:09

Thanks,
Compiles and installs,but when I drop a ssh client component on a form it raises
a generic access violation.

Clicking ok to ignore it just repeats it over and over, and cancel closes the IDE.

This is on Lazarus 1.2RC2, but the last 5.x vesion installs and works fine.

Note: the AV is also raised when I drop a ssl client on the form. All the other components drop on the form fine with no AV, just the two client ones.

snorkel
Posts: 384
Joined: Tue 08 Aug 2006 15:10
Location: Milwaukee WI USA

Re: Latest securebridge won't compile on Linux

Post by snorkel » Sun 23 Feb 2014 20:18

Just a FYI,
I also installed it in the stable version of Lazarus 1.0.14 and it does the same thing. This is with the 2.6.2 compiler.

Dimon
Devart Team
Posts: 2910
Joined: Mon 05 Mar 2007 16:32

Re: Latest securebridge won't compile on Linux

Post by Dimon » Mon 24 Mar 2014 14:13

I can not reproduce the problem. Please specify the exact version of the operation system on your machine.

Dimon
Devart Team
Posts: 2910
Joined: Mon 05 Mar 2007 16:32

Re: Latest securebridge won't compile on Linux

Post by Dimon » Mon 24 Mar 2014 14:16

Please, try to download the latest Lazarus build and check if this problem still exists.

Post Reply