Migrate Delphi XE5 to FPC/Lazarus, any advice?

classic Classic list List threaded Threaded
8 messages Options
Reply | Threaded
Open this post in threaded view
|

Migrate Delphi XE5 to FPC/Lazarus, any advice?

Bo Berglund
I have this big tomographic data interpretation and visualization
program on my hands for maintenance. It was started back in 2002 by
another developer using Delphi7 and the main development was done up
until 2009 using D7, BDS2006 and RAD2007 by the same guy, who then
left.
Later on when I took over maintenance I unicodified it and updated the
GUI using Delphi XE5 back in 2014-15. I also had to patch the GLScene
code to make it work, not much but essential.

Now in view of the way Embarcadero is licensing the development system
I am thinking about moving over to FPC/Lazarus instead. New functions
have been called for and the original developer is able to consult.

So I am looking for advice on what to think about when doing this
migration to FPC.
The project uses an older version of GLScene, which cannot be replaced
by any current version because of the way GLScene obsoleted methods
and properties in the older versions such that I never could make it
work back in 2014, hence the unicode patch of the older version.
Apart from this it only uses standard functions in Delphi as far as I
know. Plus our own components, which we have full control over...

Suggestions, links etc appreciated!


--
Bo Berglund
Developer in Sweden

_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: Migrate Delphi XE5 to FPC/Lazarus, any advice?

Bo Berglund
On Wed, 06 Jun 2018 17:25:21 +0200, Bo Berglund
<[hidden email]> wrote:

>Suggestions, links etc appreciated!

I found this when searching but it is dated back in 2007 so it does
not cover how to deal with the string to unicode string change in
Delphi 2009 and forward....

https://www.freepascal.org/~michael/articles/lazport2/lazport2.pdf


--
Bo Berglund
Developer in Sweden

_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: Migrate Delphi XE5 to FPC/Lazarus, any advice?

Michael Schnell
On 07.06.2018 12:04, Bo Berglund wrote:
> I found this when searching but it is dated back in 2007 so it does
> not cover how to deal with the string to unicode string change in
> Delphi 2009 and forward....
Which might be a major issue as Delphi uses UTF-16, While Lazarus uses
UTF-8.

-Michael

_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: Migrate Delphi XE5 to FPC/Lazarus, any advice?

R0b0t1
In reply to this post by Bo Berglund
On Wed, Jun 6, 2018 at 10:25 AM, Bo Berglund <[hidden email]> wrote:

> I have this big tomographic data interpretation and visualization
> program on my hands for maintenance. It was started back in 2002 by
> another developer using Delphi7 and the main development was done up
> until 2009 using D7, BDS2006 and RAD2007 by the same guy, who then
> left.
> Later on when I took over maintenance I unicodified it and updated the
> GUI using Delphi XE5 back in 2014-15. I also had to patch the GLScene
> code to make it work, not much but essential.
>
> Now in view of the way Embarcadero is licensing the development system
> I am thinking about moving over to FPC/Lazarus instead. New functions
> have been called for and the original developer is able to consult.
>
> So I am looking for advice on what to think about when doing this
> migration to FPC.
> The project uses an older version of GLScene, which cannot be replaced
> by any current version because of the way GLScene obsoleted methods
> and properties in the older versions such that I never could make it
> work back in 2014, hence the unicode patch of the older version.
> Apart from this it only uses standard functions in Delphi as far as I
> know. Plus our own components, which we have full control over...
>
> Suggestions, links etc appreciated!
>

Yours is a very interesting problem (so please keep the list updated
on it if you can), but one that Lazarus and FPC are  a very good fit
for. Most of the functionality that is hard to duplicate is found in
the newer versions of Delphi, such as libraries that rely on anonymous
functions and so on.

Have you attempted to port the code? People will probably be able to
help better if they are aware of specific problems you are having.

Can you explain the functionality now missing from GLScene that can't
be added back? You may need to maintain your own patches to that
component, but I fail to see how it would be impossible to bring
forward. This isn't to say bringing it forward will be trivial, but
even if it is not, getting your codebase compatible with Lazarus/FPC
is likely a good longer term goal.

Cheers,
     R0b0t1
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: Migrate Delphi XE5 to FPC/Lazarus, any advice?

Bo Berglund
On Thu, 7 Jun 2018 12:44:10 -0500, R0b0t1
<[hidden email]> wrote:

>Can you explain the functionality now missing from GLScene that can't
>be added back?

If I remembered correctly I tried to use GLScene 1.0.something instead
of the older version 0.8.2 and the showstopper was that the Canvas
property had been removed in the 1.x version and this was heavily used
throughout the code.
Since I was just porting the code without understanding the inner
workings I could not work around it so I returned to 0.8.2 and patched
this for the unicode changes.

The software I am looking at consists of 3 seprate projects for 1D, 2D
and 3D processing.
I think I will change foot here and look at the 1D first since this is
a pure Delphi native application. Uses Delphi's own graphics.

2D uses GLScene for graphics and 3D is mainly a C++Builder project
with some parts implmented using Delphi and the graphics via VTK
(which no longer supports Borland compilers).
I think 3D is out for FPC...

--
Bo Berglund
Developer in Sweden

_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: Migrate Delphi XE5 to FPC/Lazarus, any advice?

Bo Berglund
On Fri, 08 Jun 2018 07:25:21 +0200, Bo Berglund
<[hidden email]> wrote:

>I think I will change foot here and look at the 1D first since this is
>a pure Delphi native application. Uses Delphi's own graphics.

Forgot to ask if Lazarus is able to read the dproj project file used
by Delphi XE5?


--
Bo Berglund
Developer in Sweden

_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: Migrate Delphi XE5 to FPC/Lazarus, any advice?

Mattias Gaertner
On Fri, 08 Jun 2018 09:04:57 +0200
Bo Berglund <[hidden email]> wrote:

> On Fri, 08 Jun 2018 07:25:21 +0200, Bo Berglund
> <[hidden email]> wrote:
>
> >I think I will change foot here and look at the 1D first since this is
> >a pure Delphi native application. Uses Delphi's own graphics.  
>
> Forgot to ask if Lazarus is able to read the dproj project file used
> by Delphi XE5?

Better ask such question on the Lazarus list or forum.

Mattias
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: Migrate Delphi XE5 to FPC/Lazarus, any advice?

Bo Berglund
On Fri, 8 Jun 2018 09:59:35 +0200, Mattias Gaertner
<[hidden email]> wrote:

>Better ask such question on the Lazarus list or forum
Sorry, I was using my newsreader in GMane and did not notice I was in
the wrong NG...

--
Bo Berglund
Developer in Sweden

_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal