Recent

Author Topic: How can I uninstall the package without being able to enter the IDE?  (Read 4313 times)

xiyi0616

  • New Member
  • *
  • Posts: 44
I opened a pkocvWrapComp.lpk package for installation and recompiled Lazarus. However, I didn't configure the options for this package correctly, which resulted in a 'DLL not found' error after restarting Lazarus. Now I can't access the IDE. How can I uninstall the package without being able to enter the IDE?

Thaddy

  • Hero Member
  • *****
  • Posts: 18788
  • To Europe: simply sell USA bonds: dollar collapses
Re: How can I uninstall the package without being able to enter the IDE?
« Reply #1 on: July 17, 2025, 06:00:21 am »
I would simply recompile Lazarus.

pkocvWrapComp.lpk  should be fixed too, because it is a child's mistake to have your design time package depend on dll's on compile.
Then you get what you experienced: unusable IDE or worse.
The package should detect and gracefully recover if something is missing, offering configuration after load.
In that sense, you did nothing wrong but the package author did.
« Last Edit: July 17, 2025, 06:13:07 am by Thaddy »
If Europe sells their USA bonds the USD will collapse. Europe can affort that given average state debts. The USA can't affort that. Just an advice...

xiyi0616

  • New Member
  • *
  • Posts: 44
Re: How can I uninstall the package without being able to enter the IDE?
« Reply #2 on: July 17, 2025, 06:22:44 am »
Okay,  thanks Thaddy.
I'll try recompiling, but I'm not sure if this package will still be compiled in. I don't know where would the package configuration information be located. if I don't modify it...?

cheers,
xiyi0616

xiyi0616

  • New Member
  • *
  • Posts: 44
Re: How can I uninstall the package without being able to enter the IDE?
« Reply #3 on: July 17, 2025, 06:35:38 am »
I tried, but it still prompted that the corresponding DLL was not found.

xiyi0616

  • New Member
  • *
  • Posts: 44
Re: How can I uninstall the package without being able to enter the IDE?
« Reply #4 on: July 17, 2025, 06:40:55 am »
I tried putting the missing DLL file into the Lazarus directory, but it's still ineffective. I'm not sure what the default path is when loading packages.

CM630

  • Hero Member
  • *****
  • Posts: 1648
  • Не съм сигурен, че те разбирам.
    • http://sourceforge.net/u/cm630/profile/
Re: How can I uninstall the package without being able to enter the IDE?
« Reply #5 on: July 17, 2025, 08:49:31 am »
In the folder in which Lazarus is installed, there are two or more Lazarus executables.
In Windows they are lazarus.exe and lazarus.old.exe.
Delete or rename lazarus.exe to whatever you want. Then rename lazarus.old.exe to lazarus.exe and run it. This is the executable before (trying to) install(ing) the .lpks.
« Last Edit: July 17, 2025, 08:51:05 am by CM630 »
Лазар 4,4 32 bit (sometimes 64 bit); FPC3,2,2

xiyi0616

  • New Member
  • *
  • Posts: 44
Re: How can I uninstall the package without being able to enter the IDE?
« Reply #6 on: July 17, 2025, 08:54:35 am »
Hello, CM630

Unfortunately, I've only just realized this. When I tried previously, I probably replaced it again... The current "Old" is the lazarus.exe that was causing errors before the "Try".


Cheers,
xiyi0616

xiyi0616

  • New Member
  • *
  • Posts: 44
Re: How can I uninstall the package without being able to enter the IDE?
« Reply #7 on: July 17, 2025, 08:56:58 am »
I think deleting and reinstalling isn't difficult. My question is, if I've been using it for a long time and have a lot of configurations and customizations, how can I revert to a previous state if I install a problematic package?

wp

  • Hero Member
  • *****
  • Posts: 13415
Re: How can I uninstall the package without being able to enter the IDE?
« Reply #8 on: July 17, 2025, 11:18:31 am »
In such a case, when neither lazarus.exe nor lazarus.old.exe (nor lazarus.old2.exe etc) are working any more (I never had such a case) I would rebuild the IDE from source: "make clean bigide". Since I also have Delphi on the disk which uses its own make utility I call this from a batch file (in the lazarus root directory) which first sets the path to the fpc to be used:

Code: [Select]
set path=C:\Lazarus\fpc-3.2.2\bin\i386-win32
make clean bigide

This builds an IDE which contains only the "bigide" packages, i.e. the ones which are included in a fresh installation. Nothing in the user settings is touched, all your settings are left unchanged, except for the packages which are remembered but not compiled into the IDE, i.e. will be inactive. When you start this IDE for the first time, it will be reported that expected packages are not found - just ignore it. Then go to "Package" > "Install/uninstall packages", select the defective package in the left "Install" list, and click "Uninstall selection" and finally "Rebuild IDE". This will recompile the IDE again, but now such that all your previously available packages are included - except for the removed defective package, and you should be able to continue working again.

xiyi0616

  • New Member
  • *
  • Posts: 44
Re: How can I uninstall the package without being able to enter the IDE?
« Reply #9 on: July 17, 2025, 11:30:39 am »
Hey, wp

thank you for your time.

I tried your method, but encountered an error. Please see the attachment for details. I should also clarify that I installed Lazarus 4.0 using fpcupdeluxe. The FPC directory and Lazarus installation paths are different from the default ones. Please refer to the attachment for more information.

Cheers,
xiyi0616

wp

  • Hero Member
  • *****
  • Posts: 13415
Re: How can I uninstall the package without being able to enter the IDE?
« Reply #10 on: July 17, 2025, 11:44:59 am »
You must call the "make clean bigide" from the "root" directory of the lazarus installation (the directory which contains lazarus.exe).

CM630

  • Hero Member
  • *****
  • Posts: 1648
  • Не съм сигурен, че те разбирам.
    • http://sourceforge.net/u/cm630/profile/
Re: How can I uninstall the package without being able to enter the IDE?
« Reply #11 on: July 17, 2025, 12:57:50 pm »
I think deleting and reinstalling isn't difficult. My question is, if I've been using it for a long time and have a lot of configurations and customizations, how can I revert to a previous state if I install a problematic package?
What is your OS?
On Windows, when you run the installer again, it will ask you if you want to Uninstall. Answer “Yes”.
Then, during the installation, you will be asked if you want the older configuration removed. Answer “No”.
Then, when Lazarus runs for the first time after reinstallation, select Main menu — Tools — Build Lazarus with profile: Normal IDE
Maybe you should remove the .lpk, which causes the problems from the installed packages list.

Or if you want to be absolutely sure, instead of running the installer:
  Download the Lazarus installer for your version.
  Unpack it with https://innounp.sourceforge.net
  Copy the unpacked Lazarus.exe and nothing else into the folder where you have Lazarus installed.
Лазар 4,4 32 bit (sometimes 64 bit); FPC3,2,2

xiyi0616

  • New Member
  • *
  • Posts: 44
Re: How can I uninstall the package without being able to enter the IDE?
« Reply #12 on: July 17, 2025, 01:59:17 pm »
Hey CM630

Yes, I'm using Windows. I'm using fpcupdeluxe to install and manage different platform compilers and settings because I'm not very familiar with the process yet. I'm not sure if it's the right tool for this particular installation, but that's not a major concern right now. My main question is how to handle situations like this, where I have many customized settings and encounter a problem after using the setup for long time.

xiyi0616

  • New Member
  • *
  • Posts: 44
Re: How can I uninstall the package without being able to enter the IDE?
« Reply #13 on: July 17, 2025, 02:00:32 pm »
OK, wp

I'll try it again later.

tks

xiyi0616

Thaddy

  • Hero Member
  • *****
  • Posts: 18788
  • To Europe: simply sell USA bonds: dollar collapses
Re: How can I uninstall the package without being able to enter the IDE?
« Reply #14 on: July 17, 2025, 02:41:16 pm »
Note be careful with that particular package, because - as I explained - it does not behave very well and you may get into trouble again.
The package maintainer should fix it first. That is not your fault. The fault is in the package.
Another example of that is the old sqlite3 component (the sqldb version is correct) That fails too if it can not find the dll in exactly the same way.
Packages should not crash the IDE.
« Last Edit: July 17, 2025, 02:46:03 pm by Thaddy »
If Europe sells their USA bonds the USD will collapse. Europe can affort that given average state debts. The USA can't affort that. Just an advice...

 

TinyPortal © 2005-2018