From mboxrd@z Thu Jan 1 00:00:00 1970 From: Efraim Flashner Subject: bug#30228: desktop files embedding full path Date: Sun, 18 Feb 2018 21:03:38 +0200 Message-ID: <20180218190338.GA30140@macbook41> References: <20180123110012.GB16202@macbook41> <87o9ljxpzo.fsf@gnu.org> <20180129193946.GD17751@macbook41> <87r2q7393h.fsf@gnu.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="bp/iNruPH9dso1Pn" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:45388) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1enUFp-0002tz-UQ for bug-guix@gnu.org; Sun, 18 Feb 2018 14:04:07 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1enUFm-0002Jw-NV for bug-guix@gnu.org; Sun, 18 Feb 2018 14:04:05 -0500 Received: from debbugs.gnu.org ([208.118.235.43]:42246) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1enUFm-0002Jo-Ji for bug-guix@gnu.org; Sun, 18 Feb 2018 14:04:02 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1enUFm-0001it-BA for bug-guix@gnu.org; Sun, 18 Feb 2018 14:04:02 -0500 Sender: "Debbugs-submit" Resent-Message-ID: Content-Disposition: inline In-Reply-To: <87r2q7393h.fsf@gnu.org> List-Id: Bug reports for GNU Guix List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guix-bounces+gcggb-bug-guix=m.gmane.org@gnu.org Sender: "bug-Guix" To: Ludovic =?UTF-8?Q?Court=C3=A8s?= Cc: 30228@debbugs.gnu.org --bp/iNruPH9dso1Pn Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Jan 30, 2018 at 12:00:02PM +0100, Ludovic Court=C3=A8s wrote: > Hello, >=20 > Efraim Flashner skribis: >=20 > > On Wed, Jan 24, 2018 at 03:58:51PM +0100, Ludovic Court=C3=A8s wrote: > >> Hi, > >>=20 > >> Efraim Flashner skribis: > >>=20 > >> > the owncloud-client package includes an option to add a .desktop ent= ry > >> > to $HOME/.configure/autostart/, which allows it to autostart when you > >> > log in to your desktop environment. Because the full path of the bin= ary > >> > is in the .desktop file, it will always start THAT copy of > >> > owncloud-client, even if it is garbage collected. > >>=20 > >> I think you shouldn=E2=80=99t copy manually the .desktop file to > >> ~/.configure/autostart, precisely because of that. > >>=20 > >> Instead this should be done via in indirect GC root (as in =E2=80=9Cgu= ix build > >> -r the-root owncloud-client=E2=80=9D) or, ideally, by having it GuixSD= -managed. > >>=20 > >> Thoughts? > >>=20 > >> Ludo=E2=80=99. > > > > I agree it shouldn't copy a .desktop file into .config/autostart/. In > > this case, the offending code is here=C2=B9, so there's not much that c= an be > > done about it. In mine I've changed the Exec line to > > /var/guix/profiles/per-user/... so it'll work as expected. In this case > > the code generates a desktop file on the fly, so modifying the .desktop > > file shipping with applications wouldn't even help here. > > > > > > =C2=B9 https://github.com/owncloud/client/blob/f326bf371d690f1929f7c5c0= 6aebf53c7255daa6/src/common/utility_unix.cpp#L73 >=20 > What do you think should be done on the Guix side? We could patch the > code above to not install the .desktop file in ~/.config, for instance. >=20 > Thanks, > Ludo=E2=80=99. I've been thinking about it and it would also just be possible to patch the exec line there to only have the binary name. As an unintended consquence, if you did add the desktop entry to .config/autostart/ and the exec was only 'owncloud-client' then we would match the other distros' behaviors of not running uninstalled programs, if you were to later uninstall owncloud-client from your profile. I bet the reason it is coded this way is to allow for /usr/bin/owncloud-client or /usr/local/bin/owncloud-client, but just 'owncloud-client' will pick up the executable if it is in the runpath. I think that's the best option, to change the 'exec' line to just 'owncloud-client'. --=20 Efraim Flashner =D7=90=D7=A4=D7=A8=D7=99=D7=9D = =D7=A4=D7=9C=D7=A9=D7=A0=D7=A8 GPG key =3D A28B F40C 3E55 1372 662D 14F7 41AA E7DC CA3D 8351 Confidentiality cannot be guaranteed on emails sent or received unencrypted --bp/iNruPH9dso1Pn Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAEBCgAdFiEEoov0DD5VE3JmLRT3Qarn3Mo9g1EFAlqJzgYACgkQQarn3Mo9 g1G9FQ/+NQB4l5KXxZcnAtX5+rvb+JrbMEVC2/OT//0Ls116atz3W8pW4BnOCUW1 vGdtMyiIZtgbkMPRrwxpNhe05K4CbwrcQ5YuSrwC62SdGyFyIshEV+ngjHmo7pVd CJEpYMgeflYum112FmMGOCDrtHOxARf4lr8dFzjkhIRx8C8S3TtBHTIW9JOZWQEv OSsrDRXTpBZJPA6/I/yaD7dTRfF0qOoksOz83/lByO0L5sfaSd7IONnTNMVktsQ/ 4Eby8xHYiYxBn9GpzyfzXh7lfcK+lUTfyGtjaaDd5u0n7nyfdJxC+BqHFmbnI9iS r7A9MXzWLKSJHKOSYX4FY3ZjoK9tXI5CNZl+V4JEA4whKVcpywbdoaaJy2uLwDjb Yk4HYsk37MefCN7OIcmodvxQIORRRP9+vhWtop1qMoiUzVc26ObX7oqLKThAo0tJ X45lEt8spvSW8TskmY+bWMipY8VS7IUrPdMYsGkchsFhjeREz7gspXdzKuuUd/zR sJXPj/6qgN4uBr60tXAMBdxX3MuH4NN5xUifcSJoRVrStsJAn7V5L8klK6Wbznf3 nipH7M80GJ7PoPUuSdqvOWGJUNcsPo3vYW4vVs83H3M9eSoxwdlbLsAuaDdlI/yT xsYc0R8F14Tz22usDu6UwIjWAI+cwXiMYEWN6+vbBv7rNSDBf8I= =NndT -----END PGP SIGNATURE----- --bp/iNruPH9dso1Pn--