Im working on windows, and I want to prepare linux path string. There are many useful mathods in TPath, so I made this (it doesn't work):
TPosixPath = TPath;
I wanted do same thing with System.SysUtils to use e.g IncludeTrailingPathDelimiter but both don't work.
Any idea how use those units in linux way? Or another idea for manipulate linux strings paths using existing units?
That does not work because the POSIX conditional is used when the unit is compiled and not when it is used.
In order to prepare a POSIX path on a non-POSIX system you are going to have to prepare some bespoke methods. You can use the IOUtils unit as a guide although be warned that unit has a few wrinkles. Try not to transcribe any design flaws in your own variants.