From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from pigeon.gentoo.org ([208.92.234.80] helo=lists.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1QFgjR-0000QF-S9 for garchives@archives.gentoo.org; Fri, 29 Apr 2011 05:59:14 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id BE2CB1C039; Fri, 29 Apr 2011 05:59:04 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) by pigeon.gentoo.org (Postfix) with ESMTP id D1E3E1C009 for ; Fri, 29 Apr 2011 05:58:37 +0000 (UTC) Received: from pomiocik.lan (87-205-68-234.adsl.inetia.pl [87.205.68.234]) (using TLSv1 with cipher DHE-RSA-AES128-SHA (128/128 bits)) (No client certificate requested) (Authenticated sender: mgorny) by smtp.gentoo.org (Postfix) with ESMTPSA id 7008A1B4061; Fri, 29 Apr 2011 05:58:36 +0000 (UTC) Date: Fri, 29 Apr 2011 07:58:41 +0200 From: =?UTF-8?B?TWljaGHFgiBHw7Nybnk=?= To: gentoo-dev@lists.gentoo.org Subject: [gentoo-dev] Review for initial systemd.eclass Message-ID: <20110429075841.65303f29@pomiocik.lan> Organization: Gentoo X-Mailer: Claws Mail 3.7.9 (GTK+ 2.24.3; x86_64-pc-linux-gnu) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-dev@lists.gentoo.org Reply-to: gentoo-dev@lists.gentoo.org Mime-Version: 1.0 Content-Type: multipart/signed; micalg=PGP-SHA1; boundary="Sig_/UtcbEjw=+jeASP/Nd1YZddF"; protocol="application/pgp-signature" X-Archives-Salt: X-Archives-Hash: 81a63f84640de8de42f49287aabc62bf --Sig_/UtcbEjw=+jeASP/Nd1YZddF Content-Type: multipart/mixed; boundary="MP_/gZqEug1N1YSe_8wi7rdsMvt" --MP_/gZqEug1N1YSe_8wi7rdsMvt Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Hello, I'd like to submit an initial version of systemd.eclass, providing helper functions for packages installing systemd unit files. Such an eclass would be pushed to gx86 before first systemd packages to control the packages installing upstream systemd units. The eclass currently provides four functions: - systemd_get_unitdir() which simply outputs the unitdir (for insinto), - systemd_dounit() which installs the specified units into unitdir, - systemd_enable_service() which symlinks service ${2} into target ${1}, creating that target if necessary, - systemd_with_unitdir() which outputs the '--with-systemdsystemunitdir' option as expected by systemd-capable configure scripts. The eclass currently assumes the following: - systemd units are installed into /$(get_libdir)/systemd/system, - systemd units are installed unconditionally. Though it should be possible to change that behaviour within the eclass without modifying the ebuild files. I'm attaching the eclass file. It is also available in my devoverlay [1]. [1] http://git.overlays.gentoo.org/gitweb/?p=3Ddev/mgorny.git;a=3Dblob;f=3D= eclass/systemd.eclass --=20 Best regards, Micha=C5=82 G=C3=B3rny --MP_/gZqEug1N1YSe_8wi7rdsMvt Content-Type: application/octet-stream; name=systemd.eclass Content-Transfer-Encoding: base64 Content-Disposition: attachment; filename=systemd.eclass IyBDb3B5cmlnaHQgMTk5OS0yMDExIEdlbnRvbyBGb3VuZGF0aW9uCiMgRGlzdHJpYnV0ZWQgdW5k ZXIgdGhlIHRlcm1zIG9mIHRoZSBHTlUgR2VuZXJhbCBQdWJsaWMgTGljZW5zZSB2MgojICRIZWFk ZXI6ICQKCiMgQEVDTEFTUzogc3lzdGVtZC5lY2xhc3MKIyBATUFJTlRBSU5FUjoKIyBtZ29ybnlA Z2VudG9vLm9yZwojIEBCTFVSQjogaGVscGVyIGZ1bmN0aW9ucyB0byBpbnN0YWxsIHN5c3RlbWQg dW5pdHMKIyBAREVTQ1JJUFRJT046CiMgVGhpcyBlY2xhc3MgcHJvdmlkZXMgYSBzZXQgb2YgZnVu Y3Rpb25zIHRvIGluc3RhbGwgdW5pdCBmaWxlcyBmb3IKIyBzeXMtYXBwcy9zeXN0ZW1kIHdpdGhp biBlYnVpbGRzLgoKaW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CB1ZD0kKHN5c3RlbWRfZ2V0X3VuaXRkaXIpCgoJZG9kaXIgIiR7dWR9Ii8iJHt0YXJnZXR9 Ii53YW50cyAmJiBcCglkb3N5bSAuLi8iJHtzZXJ2aWNlfSIgIiR7dWR9Ii8iJHt0YXJnZXR9Ii53 YW50cwp9CgojIEBGVU5DVElPTjogc3lzdGVtZF93aXRoX3VuaXRkaXIKIyBAREVTQ1JJUFRJT046 CiMgT3V0cHV0ICctLXdpdGgtc3lzdGVtZHN5c3RlbXVuaXRkaXInIGFzIGV4cGVjdGVkIGJ5IHN5 c3RlbWQtYXdhcmUgY29uZmlndXJlCiMgc2NyaXB0cy4Kc3lzdGVtZF93aXRoX3VuaXRkaXIoKSB7 CglkZWJ1Zy1wcmludC1mdW5jdGlvbiAke0ZVTkNOQU1FfSAiJHtAfSIKCgllY2hvIC1uIC0td2l0 aC1zeXN0ZW1kc3lzdGVtdW5pdGRpcj0iJChzeXN0ZW1kX2dldF91bml0ZGlyKSIKfQo= --MP_/gZqEug1N1YSe_8wi7rdsMvt-- --Sig_/UtcbEjw=+jeASP/Nd1YZddF Content-Type: application/pgp-signature; name=signature.asc Content-Disposition: attachment; filename=signature.asc -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.17 (GNU/Linux) iEYEARECAAYFAk26U5QACgkQnGSe5QXeB7s1IACfZIiouilvUoNsoLj3bQgBqSHO zqAAnRUMRE6myf2H2z3ok3ER5gZs6HCF =TFBD -----END PGP SIGNATURE----- --Sig_/UtcbEjw=+jeASP/Nd1YZddF--