Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / lazarus / 2018-12

Exception=Unable to create file "/etc/fppkg/default"

6 messages · 3 people · –

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Vojtěch Čihák

Hi,
 
Lazarus(SVN) at startup tries to write at /etc/fppkg/ where it has no rights. The same file exists /home/$USERNAME/.fppkg/  
Revision 59930 works well yet, revisions 59936 and 59940 are affected.  
[v1 at nb-msi lazarus]$ ./startlazarus
is a file
TLazarusManager.Run starting /home/v1/Lazarus_Qt/lazarus/lazarus ... Hint: (lazarus) [TMainIDE.ParseCmdLineOptions] PrimaryConfigPath="/home/ v1/.lazarus"
Hint: (lazarus) [TMainIDE.ParseCmdLineOptions] SecondaryConfigPath="/etc /lazarus"
Hint: (lazarus) [TBuildManager.SetBuildTarget] Old=x86_64-linux-gtk2 New =x86_64-linux-gtk2 FPC=True LCL=False
Hint: (lazarus) [TMainIDE.Destroy] B  -> inherited Destroy... TMainIDE Hint: (lazarus) [TMainIDE.Destroy] END
[FORMS.PP] ExceptionOccurred  
 Sender=EFCreateError
 Exception=Unable to create file "/etc/fppkg/default"  Stack trace:
 $000000000051EBA2
 $000000000051E9F3
 $0000000000E15EFC
 $0000000000FA97CF  INSTANCE,  line 85 of ../packager/fppkghelper.pas  $0000000000AA7DA4  OPENDEPENDENCY,  line 5838 of ../packager/packagesy stem.pas
 $0000000000A94277  ADDPACKAGE,  line 2122 of ../packager/packagesystem .pas
 $0000000000A8F8BE  OPENDEPENDENCYWITHPACKAGELINK,  line 998 of ../pack ager/packagesystem.pas
 $0000000000AA78A0  OPENDEPENDENCY,  line 5785 of ../packager/packagesy stem.pas
 $0000000000AA8B2B  OPENINSTALLEDDEPENDENCY,  line 5995 of ../packager/ packagesystem.pas
 $0000000000A949FE  LOADLAZARUSBASEPACKAGE,  line 2213 of ../packager/p ackagesystem.pas
 $0000000000A9486F  LOADSTATICBASEPACKAGES,  line 2217 of ../packager/p ackagesystem.pas
 $0000000000AB46C6  LOADINSTALLEDPACKAGES,  line 3086 of ../packager/pk gmanager.pas
 $00000000004A8683  CREATE,  line 1590 of main.pp  $000000000041ECE6  main,  line 140 of lazarus.pp TApplication.HandleException: EFCreateError
Unable to create file "/etc/fppkg/default"
 Stack trace:
 $000000000051EBA2
 $000000000051E9F3
 $0000000000E15EFC
 $0000000000FA97CF  INSTANCE,  line 85 of ../packager/fppkghelper.pas  $0000000000AA7DA4  OPENDEPENDENCY,  line 5838 of ../packager/packagesy stem.pas
 $0000000000A94277  ADDPACKAGE,  line 2122 of ../packager/packagesystem .pas
 $0000000000A8F8BE  OPENDEPENDENCYWITHPACKAGELINK,  line 998 of ../pack ager/packagesystem.pas
 $0000000000AA78A0  OPENDEPENDENCY,  line 5785 of ../packager/packagesy stem.pas
 $0000000000AA8B2B  OPENINSTALLEDDEPENDENCY,  line 5995 of ../packager/ packagesystem.pas
 $0000000000A949FE  LOADLAZARUSBASEPACKAGE,  line 2213 of ../packager/p ackagesystem.pas
 $0000000000A9486F  LOADSTATICBASEPACKAGES,  line 2217 of ../packager/p ackagesystem.pas
 $0000000000AB46C6  LOADINSTALLEDPACKAGES,  line 3086 of ../packager/pk gmanager.pas
 $00000000004A8683  CREATE,  line 1590 of main.pp  $000000000041ECE6  main,  line 140 of lazarus.pp  [v1 at nb-msi lazarus]$

 
V.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lazarus-ide.org/pipermail/lazarus/attachments/20181230/5038aff7/attachment.html>

Reply by email

Joost van der Sluis
to Bart

Op 30-12-18 om 15:16 schreef Bart via lazarus:

On Sun, Dec 30, 2018 at 2:42 PM Vojtěch Čihák via lazarus wrote: > Lazarus(SVN) at startup tries to write at /etc/fppkg/ where it has no rights. The same file exists /home/$USERNAME/.fppkg/

That ain't good.

There are more issues with r59933: see https://bugs.freepascal.org/view.php?id=34780

This basically means that your fpc is not properly configured. I'll have to add a check somewhere (startup) for these settings.

And maybe suppress these messages, as long as a user does not use this functionality.

It could be useful to know the revision that introduced this behavior. It is probably not r59933, could it be r59934?

Regards,

Joost.

Reply by email

Vojtěch Čihák
to Bart: On Sun, Dec 30, 2018 at 2:42 PM Vojtěch Čihák via lazarus There are more issues with…

What config file?
 
My /etc/fppkg.cfg is:
[Defaults]
ConfigVersion=4
LocalRepository={UserDir}.fppkg/
BuildDir={LocalRepository}build/
ArchivesDir={LocalRepository}archives/
CompilerConfigDir=/etc/fppkg
RemoteMirrors=https://www.freepascal.org/repository/mirrors.xml RemoteRepository=auto
CompilerConfig=default
FPMakeCompilerConfig=default
Downloader=FPC 
 
so there are both pathes.
 
The only mention of fppkg in /etc/fpc.cfg is:
# searchpath for fppkg user-specific packages
-Fu~/.fppkg/lib/fpc/$fpcversion/units/$FPCTARGET/*   
However, it worked before, both configs are date 8-12-2017.  
V.
______________________________________________________________

Show quoted text 5 lines
Od: "Joost van der Sluis via lazarus" Komu: Datum: 30.12.2018 17:19 Předmět: Re: [Lazarus] Exception=Unable to create file "/etc/fppkg/default"

Op 30-12-18 om 15:16 schreef Bart via lazarus:

On Sun, Dec 30, 2018 at 2:42 PM Vojtěch Čihák via lazarus wrote: > Lazarus(SVN) at startup tries to write at /etc/fppkg/ where it has no rights. The same file exists /home/$USERNAME/.fppkg/

That ain't good.

This basically means that your fpc is not properly configured. I'll have to add a check somewhere (startup) for these settings.

And maybe suppress these messages, as long as a user does not use this functionality.

It could be useful to know the revision that introduced this behavior. It is probably not r59933, could it be r59934?

Regards,

Joost.

Reply by email

Joost van der Sluis
to Vojtěch Čihák

Op 30-12-18 om 18:17 schreef Vojtěch Čihák via lazarus:

Show quoted text 15 lines
What config file? My /etc/fppkg.cfg is: [Defaults] ConfigVersion=4 LocalRepository={UserDir}.fppkg/ BuildDir={LocalRepository}build/ ArchivesDir={LocalRepository}archives/ CompilerConfigDir=/etc/fppkg RemoteMirrors=https://www.freepascal.org/repository/mirrors.xml RemoteRepository=auto CompilerConfig=default FPMakeCompilerConfig=default Downloader=FPC

This is really strange, I would like to know how you've got into this situation.

There are two configuration-files for fppkg, the 'normal' configuration-file fppkg.cfg and the compiler-configuration file, normally called 'default'. The fppkf.cfg file has a reference to the location of the compiler-configuration files.

In your case you do have a fppkg.cfg file in /etc, but you do not have the corresponding compiler-configuration file /etc/fppkg/default. It must have been deleted or never been made?

Just remove /etc/fppkg.cfg. In that case a new file will be created automatically in your user-profile.

It is this automatic creation of those files that bites you. Normally it only creates files in /etc when you are root. But because there is a /etc/fppkg.cfg file, you get into trouble. I'll try to fix that.

Regards,

Joost.

Reply by email