blob: 1ab9e7cf9e39b54adfa74108cd42ee3f693c42c9 [file] [log] [blame]
Patrick Williamsb48b7b42016-08-17 15:04:38 -05001SUMMARY = "Monitor for system resources and process activity"
2DESCRIPTION = "Atop is an ASCII full-screen performance monitor for Linux that \
3is capable of reporting the activity of all processes (even if processes have \
4finished during the interval), daily logging of system and process activity for \
5long-term analysis, highlighting overloaded system resources by using colors, \
6etc. At regular intervals, it shows system-level activity related to the CPU, \
7memory, swap, disks (including LVM) and network layers, and for every process \
8(and thread) it shows e.g. the CPU utilization, memory growth, disk \
9utilization, priority, username, state, and exit code."
10HOMEPAGE = "http://www.atoptool.nl"
11SECTION = "console/utils"
12
13LICENSE = "GPLv2"
14LIC_FILES_CHKSUM = "file://COPYING;md5=393a5ca445f6965873eca0259a17f833"
15
16DEPENDS = "ncurses zlib"
17
Brad Bishop6e60e8b2018-02-01 10:27:11 -050018ATOP_VER = "${@'-'.join(d.getVar('PV').rsplit('.', 1))}"
Patrick Williamsb48b7b42016-08-17 15:04:38 -050019
20SRC_URI = " \
21 http://www.atoptool.nl/download/${BPN}-${ATOP_VER}.tar.gz \
22 ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'file://volatiles.atop.conf', 'file://volatiles.99_atop', d)} \
Brad Bishop6e60e8b2018-02-01 10:27:11 -050023 file://0001-include-missing-header-files.patch \
Patrick Williamsb48b7b42016-08-17 15:04:38 -050024 file://remove-bashisms.patch \
25 file://fix-permissions.patch \
26 file://sysvinit-implement-status.patch \
27"
28
29SRC_URI[md5sum] = "034dc1544f2ec4e4d2c739d320dc326d"
30SRC_URI[sha256sum] = "c785b8a2355be28b3de6b58a8ea4c4fcab8fadeaa57a99afeb03c66fac8e055d"
31
32S = "${WORKDIR}/${BPN}-${ATOP_VER}"
33
34do_compile() {
35 oe_runmake all
36}
37
38do_install() {
39 if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
40 make DESTDIR=${D} VERS=${ATOP_VER} SYSDPATH=${systemd_system_unitdir} \
41 PMPATHD=${systemd_unitdir}/system-sleep systemdinstall
42 install -d ${D}${sysconfdir}/tmpfiles.d
43 install -m 644 ${WORKDIR}/volatiles.atop.conf ${D}${sysconfdir}/tmpfiles.d/atop.conf
44 rm -f ${D}${systemd_system_unitdir}/atopacct.service
45 else
46 make DESTDIR=${D} VERS=${ATOP_VER} sysvinstall
47 install -d ${D}${sysconfdir}/default/volatiles
48 install -m 644 ${WORKDIR}/volatiles.99_atop ${D}${sysconfdir}/default/volatiles/99_atop
49 rm -f ${D}${sysconfdir}/init.d/atopacct
50 fi
51
52 # remove atopacct related files
53 rm -rf ${D}${sbindir} ${D}${mandir}/man8
54}
55
56inherit systemd
57
58SYSTEMD_SERVICE_${PN} = "atop.service"
59SYSTEMD_AUTO_ENABLE = "disable"
60
61FILES_${PN} += "${systemd_unitdir}/system-sleep"
62
63RDEPENDS_${PN} = "procps"