Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame^] | 1 | SUMMARY = "a utility to add users/groups to the system" |
| 2 | DESCRIPTION = "adduser, addgroup - add a user or group to the system" |
| 3 | HOMEPAGE = "http://alioth.debian.org/projects/adduser/" |
| 4 | SECTION = "base/utils" |
| 5 | |
| 6 | LICENSE = "GPLv2" |
| 7 | LIC_FILES_CHKSUM = "file://debian/copyright;md5=caed49ab166f22ef31bf1127f558d0ef" |
| 8 | |
| 9 | SRC_URI = "http://ftp.de.debian.org/debian/pool/main/a/${BPN}/${BPN}_${PV}.tar.xz \ |
| 10 | file://adduser-add-M-option-for-useradd-when-no-create-home.patch \ |
| 11 | " |
| 12 | |
| 13 | SRC_URI[md5sum] = "3a079dd4e41d5a1fbaccaab03aacd881" |
| 14 | SRC_URI[sha256sum] = "693b45bb0d27938fff2ecee5442ea2ac1b8804472ff0bb8faffd39616e58211f" |
| 15 | |
| 16 | inherit cpan-base update-alternatives |
| 17 | |
| 18 | S = "${WORKDIR}/${BPN}-3.113+nmu4" |
| 19 | |
| 20 | do_install() { |
| 21 | install -d ${D}${sbindir} |
| 22 | install -m 0755 ${S}/adduser ${D}${sbindir} |
| 23 | install -m 0755 ${S}/deluser ${D}${sbindir} |
| 24 | |
| 25 | install -d ${D}${libdir}/perl/${PERLVERSION}/Debian |
| 26 | install -m 0644 ${S}/AdduserCommon.pm ${D}${libdir}/perl/${PERLVERSION}/Debian |
| 27 | sed -i -e "s/VERSION/${PV}/" ${D}${sbindir}/* |
| 28 | |
| 29 | install -d ${D}/${sysconfdir} |
| 30 | install -m 0644 ${S}/*.conf ${D}/${sysconfdir} |
| 31 | |
| 32 | install -d ${D}${mandir}/man5 |
| 33 | install -m 0644 ${S}/doc/*.conf.5 ${D}${mandir}/man5 |
| 34 | install -d ${D}${mandir}/man8 |
| 35 | install -m 0644 ${S}/doc/*.8 ${D}${mandir}/man8 |
| 36 | install -d ${D}${docdir}/${BPN} |
| 37 | cp -rf ${S}/examples ${D}${docdir}/${BPN} |
| 38 | } |
| 39 | |
| 40 | RDEPENDS_${PN} += "\ |
| 41 | shadow \ |
| 42 | perl-module-getopt-long \ |
| 43 | perl-module-overloading \ |
| 44 | perl-module-file-find \ |
| 45 | perl-module-file-temp \ |
| 46 | " |
| 47 | |
| 48 | ALTERNATIVE_${PN} = "adduser deluser addgroup delgroup" |
| 49 | ALTERNATIVE_PRIORITY = "60" |
| 50 | ALTERNATIVE_LINK_NAME[adduser] = "${sbindir}/adduser" |
| 51 | ALTERNATIVE_LINK_NAME[deluser] = "${sbindir}/deluser" |
| 52 | ALTERNATIVE_LINK_NAME[addgroup] = "${sbindir}/addgroup" |
| 53 | ALTERNATIVE_LINK_NAME[delgroup] = "${sbindir}/delgroup" |
| 54 | ALTERNATIVE_TARGET[addgroup] = "${sbindir}/adduser.${BPN}" |
| 55 | ALTERNATIVE_TARGET[delgroup] = "${sbindir}/deluser.${BPN}" |