Recent

Author Topic: [Solve] Unit project  (Read 18561 times)

ginoo

  • Full Member
  • ***
  • Posts: 113
[Solve] Unit project
« on: April 03, 2024, 09:41:33 am »
Hi, I have a problem with a component that worked well until Lazarus 2.2.4 (the one I used first), then I switched to Lazarus 3.2 but it no longer compiles it for me, stopping in this line

uses
  Classes, SysUtils, Controls, Forms, Dialogs,
  LazIDEIntf, ProjectIntf, FormEditingIntf, Project, ModeMatrixOpts, 

I solved ModeMatrixopts, but I can't make the Project unit work which should be the one present in lazarus/ide/

I don't understand what path I should include.

Thank you.

« Last Edit: April 03, 2024, 07:13:33 pm by ginoo »

rvk

  • Hero Member
  • *****
  • Posts: 6749
Re: Unit project
« Reply #1 on: April 03, 2024, 10:01:11 am »
I don't understand what path I should include.
Maybe you should add the package requirements to which that project.pp belongs to.
Then the path gets added automatically.

The same goes for the ModeMatrixOpts which is part of a package (idedebugger? Or ideconfig?)

ginoo

  • Full Member
  • ***
  • Posts: 113
Re: Unit project
« Reply #2 on: April 03, 2024, 10:16:00 am »
"project.pp" is in the lazarus_2_2_4/lazarus/ide/ folder but in 3.2 I don't understand it is no longer compiled.
The requirements taken in lazarus 2.2.4 are LazDebugDGBmi, LCL, IDEIntef but I don't think anything has changed with lazarus 3.2
As for ModeMatrixopts, the folder has actually changed, it is now /ide/packages/ideconfig/lib/
Something has changed but I have to resolve that project.pp present in /lazarus/ide/

wp

  • Hero Member
  • *****
  • Posts: 12859
Re: Unit project
« Reply #3 on: April 03, 2024, 11:24:22 am »
uses
  Classes, SysUtils, Controls, Forms, Dialogs,
  LazIDEIntf, ProjectIntf, FormEditingIntf, Project, ModeMatrixOpts, 
Is there something following after ModeMatrixOpts? I am asking because you show a comma at the end, but there should be a semicolon then.

ginoo

  • Full Member
  • ***
  • Posts: 113
Re: Unit project
« Reply #4 on: April 03, 2024, 11:34:43 am »
Yes there is another unit on the next line, but that's not a problem.

rvk

  • Hero Member
  • *****
  • Posts: 6749
Re: Unit project
« Reply #5 on: April 03, 2024, 12:12:55 pm »
As for ModeMatrixopts, the folder has actually changed, it is now /ide/packages/ideconfig/lib/
Something has changed but I have to resolve that project.pp present in /lazarus/ide/
How did you solve this for ModeMatrixopts ?? You should NOT add the path to it manually.
For ModeMatrixopts you should just add ideconfig to the requirements of your project (not a path !!).

But I'm not sure to which package project.pp belongs.

ginoo

  • Full Member
  • ***
  • Posts: 113
Re: Unit project
« Reply #6 on: April 03, 2024, 02:51:19 pm »
ok, you're right, I had entered the path manually. Now I removed and put the dependency on ideconfig and it works. But what do I do about the dependency at lazarus_2_2_4/lazarus/ide/Project.pp?

rvk

  • Hero Member
  • *****
  • Posts: 6749
Re: Unit project
« Reply #7 on: April 03, 2024, 04:01:29 pm »
ok, you're right, I had entered the path manually. Now I removed and put the dependency on ideconfig and it works. But what do I do about the dependency at lazarus_2_2_4/lazarus/ide/Project.pp?
I'm not sure what project.pp is for.
It doesn't seem to be part of a separate package but just a source file for the complete Lazarus ide itself.

You can open the lazarus.lpi and see that the search directory is
frames;..\converter;..\debugger;..\debugger\frames;..\packager;..\designer;..\packager\frames;..\ide
and the include path is include.


ginoo

  • Full Member
  • ***
  • Posts: 113
Re: Unit project
« Reply #8 on: April 03, 2024, 04:31:53 pm »
It is used to create a wizard for creating a project template, this is the reference code

  TProject(AProject).UseAppBundle := False;
  TProject(AProject).ProjResources.XPManifest.UseManifest := False;
  TProject(AProject).ProjResources.ProjectIcon.SetStream(nil);     

and it doesn't find tproject.

The strange thing is that everything worked in lazarus 1.6, 1.8, 2, 2.2.4, 2.2.6 and doesn't work in 3.2.

bobby100

  • Sr. Member
  • ****
  • Posts: 281
    • Malzilla
Re: Unit project
« Reply #9 on: April 03, 2024, 04:40:05 pm »
Project.pp is used in projtemplates.lpk

ginoo

  • Full Member
  • ***
  • Posts: 113
Re: Unit project
« Reply #10 on: April 03, 2024, 04:46:04 pm »
Project.pp is used in projtemplates.lpk

I went to look at the sources but didn't see it, then tell me where did you see it?

bobby100

  • Sr. Member
  • ****
  • Posts: 281
    • Malzilla
Re: Unit project
« Reply #11 on: April 03, 2024, 04:50:13 pm »
Project.pp is used in projtemplates.lpk

I went to look at the sources but didn't see it, then tell me where did you see it?
I did a quick text search on my Lazarus folder (screenshot in attachment).

rvk

  • Hero Member
  • *****
  • Posts: 6749
Re: Unit project
« Reply #12 on: April 03, 2024, 04:54:56 pm »
Project.pp is used in projtemplates.lpk

I went to look at the sources but didn't see it, then tell me where did you see it?
I did a quick text search on my Lazarus folder (screenshot in attachment).
And you didn't look further  ;)

The text in that component is idetemplateproject.pp. Not project.pp.

Project.pp is part of lazarus.lpi.

ginoo

  • Full Member
  • ***
  • Posts: 113
Re: Unit project
« Reply #13 on: April 03, 2024, 04:58:24 pm »
Project.pp is used in projtemplates.lpk

I went to look at the sources but didn't see it, then tell me where did you see it?
I did a quick text search on my Lazarus folder (screenshot in attachment).

If you mean the position of project.pp I already wrote it at the beginning of the post. What I can't do is find the dependency for the package. I repeat it worked with lazarus 1.6, 1.8, 2, 2.2.4, 2.2.6, but it no longer works with lazarus 3.2


bobby100

  • Sr. Member
  • ****
  • Posts: 281
    • Malzilla
Re: Unit project
« Reply #14 on: April 03, 2024, 04:59:22 pm »
Sorry, my bad. The search found all the *project.pp strings, inclusive demoproject.pp, idetemplateproject.pp etc.
It doesn't seem to be included in any component package.

 

TinyPortal © 2005-2018