In which language is TC written??

Here you can propose new features, make suggestions etc.

Moderators: white, Hacker, petermad, Stefan2

VSB
Member
Member
Posts: 136
Joined: 2006-12-12, 12:02 UTC
Location: Russia

Post by *VSB »

2ghisler(Author)

Here is some workaround to call 32bit COM object, which can accept all current parameters (may bee in other data types) + plugin dll name and send them to 32 bit plugin.
Also, COM wrapper allows to elevate plugins throw UAC to admin rights (by writing simple CoCreateInstanceAsAdmin function instead standard CoCreateInstance)
User avatar
norfie²
Power Member
Power Member
Posts: 986
Joined: 2006-02-10, 07:27 UTC

Post by *norfie² »

2ghisler(Author)
I'm currently porting to Lazarus/Free Pascal
Do you know Double Commander?
It's a TC clone written in Lazarus and it's GPL2. It looks good and is available in 64 and 32 bit and for Linux too. :D
User avatar
fenix_productions
Power Member
Power Member
Posts: 1979
Joined: 2005-08-07, 13:23 UTC
Location: Poland
Contact:

Post by *fenix_productions »

2norfie²
Could you ever get any plugins to work with it? Using DC Configuration dialogue I am able to add WLX ones only but they don't work at all despite that (not that any other work at all).

I am observing DC development since 2008 (IIRC) and I have lost my hopes for it long ago.
"When we created the poke, we thought it would be cool to have a feature without any specific purpose." Facebook...

#128099
Egh
Junior Member
Junior Member
Posts: 41
Joined: 2009-02-06, 20:37 UTC

Post by *Egh »

Hmmm, funny enough DC though does have hard link / symlink feature. Not that it actually works properly here, but at least that's a step to the right direction :P
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48074
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

just out of curiousity, how do you communicate now between x86 and x64 ?
I'm using a named pipe. Look up CreateNamedPipe on MSDN:
http://msdn.microsoft.com/en-us/library/aa365150%28VS.85%29.aspx
Here is some workaround to call 32bit COM object
I cannot use that, because COM objects need to be registered with admin rights in the registry. Therefore it will not work when running TC from an USB stick.

Btw, since Friday, TC compiles in 64-bit Lazarus. :)
Unfortunately many functions don't work yet, or work incorrectly, but the basics already work: Directory browsing, archive browsing, unzip, ftp, Lister (partially), Synchronize dirs, compare by content, change attributes have been tested.

The most work was needed for updating Assembler functions to 64-bit, and for variables which changed from 32-bit to 64-bit. There is still a lot of work to do until everything works as it should, e.g. porting support dlls like the zip packer to 64-bit.
Author of Total Commander
https://www.ghisler.com
Egh
Junior Member
Junior Member
Posts: 41
Joined: 2009-02-06, 20:37 UTC

Post by *Egh »

[q]
I'm using a named pipe. Look up CreateNamedPipe on MSDN:
http://msdn.microsoft.com/en-us/library/aa365150%28VS.85%29.aspx[/q]

Yeah, pretty good workaround. Named pipes are used e.g. in SQL server.

Very happy to see x64 working (to some extend!).

Btw, in terms of convenience, how good is Lazarus compared to Delphi?
User avatar
Lefteous
Power Member
Power Member
Posts: 9535
Joined: 2003-02-09, 01:18 UTC
Location: Germany
Contact:

Post by *Lefteous »

2ghisler(Author)
Btw, since Friday, TC compiles in 64-bit Lazarus.
Congratulations! :D
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48074
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

how good is Lazarus compared to Delphi
It's surprisingly good for being free, but there are still many problems/bugs. The biggest problem is lack of documentation, e.g. it's hard to figure out the differences in the inline Assembler between Delphi and Lazarus.

Also Compile+Link times are MUCH longer than with Delphi, and the created EXE files are HUGE because they contain all the debug info. I really don't understand why they aren't put in a separate file. This would certainly make the link process much faster (EXE file writing is very slow due to virus scanners).

There are also some bugs, e.g. the str() function doesn't put a terminating 0 when using pchar/array of char variables.

But all in all it's OK on a fast computer.
Author of Total Commander
https://www.ghisler.com
User avatar
wanderer
Power Member
Power Member
Posts: 1578
Joined: 2003-03-28, 14:35 UTC
Location: Sol

Post by *wanderer »

Hi Christian.

So, are we to assume that the next TC version's (i guess 8.0) main "feature" will be that it will be compiled in Lazarus and it will come in two "flavors" (32-bit and 64-bit)? If so, it will be a pretty big challenge to have a bug-free release. Every single TC feature will have to be re-tested...
- Wanderer -

¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯
Normally using latest TC on:
x32: WinXPx32 SP3
x64: Clients/Servers from Win7 to Win11 and Win2K12Srv to Win2K22Srv, mainly Win10 though.
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48074
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

Indeed that takes most of the time. Therefore I will probably have to release a 7.56 bugfix version based on Delphi first.
Author of Total Commander
https://www.ghisler.com
User avatar
xrmb
Junior Member
Junior Member
Posts: 63
Joined: 2003-04-05, 16:54 UTC

Post by *xrmb »

@ghisler
We all know you spent years writing WC/TC.
I know that I as a full time developer have hacked in about 75k line of code this year, so I'll likely hit my 100k target again. (Ok, I'm lucky I only write new stuff, dont maintain code)

But how many lines of code is TC? Or how many bytes of source (w/o resources)?

And, I secretly think you're awesome... I started my developer carreer in pascal/delphi then I found c/c++ and never turned back to my old love... but it's to be used for my big love TC.
I was born with Norton Commander, grew up with DCC, after school I played with Windows Commander, graduated, married and had kids with Total Commander and will die using whatever its called then Commander.
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48074
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

I have just checked it, the *.pas files alone are a bit more than 10 Megabytes.
Author of Total Commander
https://www.ghisler.com
drac
Junior Member
Junior Member
Posts: 37
Joined: 2006-04-04, 19:50 UTC

Post by *drac »

ghisler(Author) wrote: Also Compile+Link times are MUCH longer than with Delphi, and the created EXE files are HUGE because they contain all the debug info. I really don't understand why they aren't put in a separate file. This would certainly make the link process much faster (EXE file writing is very slow due to virus scanners).
Doesn't "strip" help to have the exe without debug info? More info here
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48074
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

Yes it does, but that's not the point. If it would put the debug info in a separate file from the beginning, linking would be much faster, and the stripped file could still be debugged...
Author of Total Commander
https://www.ghisler.com
nmeyer
Junior Member
Junior Member
Posts: 2
Joined: 2010-10-15, 11:37 UTC

Post by *nmeyer »

ghisler(Author) wrote:

Btw, since Friday, TC compiles in 64-bit Lazarus. :)
Unfortunately many functions don't work yet, or work incorrectly, but the basics already work: Directory browsing, archive browsing, unzip, ftp, Lister (partially), Synchronize dirs, compare by content, change attributes have been tested.

The most work was needed for updating Assembler functions to 64-bit, and for variables which changed from 32-bit to 64-bit. There is still a lot of work to do until everything works as it should, e.g. porting support dlls like the zip packer to 64-bit.
Is Lazarus a Cross Compiler? Can it also compile for MacOS or Linux?
Post Reply