diff options
author | Robin H. Johnson <robbat2@gentoo.org> | 2015-08-08 13:49:04 -0700 |
---|---|---|
committer | Robin H. Johnson <robbat2@gentoo.org> | 2015-08-08 17:38:18 -0700 |
commit | 56bd759df1d0c750a065b8c845e93d5dfa6b549d (patch) | |
tree | 3f91093cdb475e565ae857f1c5a7fd339e2d781e /sys-process/unixtop | |
download | gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.gz gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.bz2 gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.zip |
proj/gentoo: Initial commit
This commit represents a new era for Gentoo:
Storing the gentoo-x86 tree in Git, as converted from CVS.
This commit is the start of the NEW history.
Any historical data is intended to be grafted onto this point.
Creation process:
1. Take final CVS checkout snapshot
2. Remove ALL ChangeLog* files
3. Transform all Manifests to thin
4. Remove empty Manifests
5. Convert all stale $Header$/$Id$ CVS keywords to non-expanded Git $Id$
5.1. Do not touch files with -kb/-ko keyword flags.
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
X-Thanks: Alec Warner <antarus@gentoo.org> - did the GSoC 2006 migration tests
X-Thanks: Robin H. Johnson <robbat2@gentoo.org> - infra guy, herding this project
X-Thanks: Nguyen Thai Ngoc Duy <pclouds@gentoo.org> - Former Gentoo developer, wrote Git features for the migration
X-Thanks: Brian Harring <ferringb@gentoo.org> - wrote much python to improve cvs2svn
X-Thanks: Rich Freeman <rich0@gentoo.org> - validation scripts
X-Thanks: Patrick Lauer <patrick@gentoo.org> - Gentoo dev, running new 2014 work in migration
X-Thanks: Michał Górny <mgorny@gentoo.org> - scripts, QA, nagging
X-Thanks: All of other Gentoo developers - many ideas and lots of paint on the bikeshed
Diffstat (limited to 'sys-process/unixtop')
10 files changed, 285 insertions, 0 deletions
diff --git a/sys-process/unixtop/Manifest b/sys-process/unixtop/Manifest new file mode 100644 index 000000000000..8d0a2ea74f4b --- /dev/null +++ b/sys-process/unixtop/Manifest @@ -0,0 +1 @@ +DIST top-3.8beta1.tar.bz2 233880 SHA256 1b5281071a4fcc132205e643fb2fe196cf839555874aaee507a7d07aa0076cda SHA512 c66d786e34070afd00dc2225ce4cddcf0fdaee0e2a6c6e2dfadadcd97bbe84c6668041ff5b075137630b99240c711fbfda8b85fb09c6a39e3067798cbe612671 WHIRLPOOL 1a51c53494d8128fd6ff8bcbfea54efbacf0d7af3e78a492ca29d5bf276ca639d403273f03e49536e7168122bc6002cd1fb1c0c84cd322d691b41032ed766842 diff --git a/sys-process/unixtop/files/unixtop-3.8_beta1-high-threadid-crash.patch b/sys-process/unixtop/files/unixtop-3.8_beta1-high-threadid-crash.patch new file mode 100644 index 000000000000..a5a3bc58546d --- /dev/null +++ b/sys-process/unixtop/files/unixtop-3.8_beta1-high-threadid-crash.patch @@ -0,0 +1,75 @@ +http://sourceforge.net/tracker/index.php?func=detail&aid=2815842&group_id=72892&atid=536042 + +*** hash.c-old Thu Jul 2 15:30:55 2009 +--- hash.c Thu Jul 2 15:48:39 2009 +*************** +*** 1354,1360 **** + hi->value = value; + + /* hash to the bucket */ +! bucket = &(ht->buckets[((key.k_thr * 10000 + key.k_pid) % ht->num_buckets)]); + + /* walk the list to make sure we do not have a duplicate */ + ll = &(bucket->list); +--- 1354,1360 ---- + hi->value = value; + + /* hash to the bucket */ +! bucket = &(ht->buckets[(((unsigned long)(key.k_thr) * 10000U + (unsigned long)(key.k_pid)) % ht->num_buckets)]); + + /* walk the list to make sure we do not have a duplicate */ + ll = &(bucket->list); +*************** +*** 1408,1414 **** + pidthr_t k1; + + /* find the bucket */ +! bucket = &(ht->buckets[((key.k_thr * 10000 + key.k_pid) % ht->num_buckets)]); + + /* walk the list until we find the existing item */ + ll = &(bucket->list); +--- 1408,1414 ---- + pidthr_t k1; + + /* find the bucket */ +! bucket = &(ht->buckets[(((unsigned long)(key.k_thr) * 10000U + (unsigned long)(key.k_pid)) % ht->num_buckets)]); + + /* walk the list until we find the existing item */ + ll = &(bucket->list); +*************** +*** 1460,1466 **** + pidthr_t k1; + + result = NULL; +! if ((bucket = &(ht->buckets[((key.k_thr * 10000 + key.k_pid) % ht->num_buckets)])) != NULL) + { + ll = &(bucket->list); + li = LL_FIRST(ll); +--- 1460,1466 ---- + pidthr_t k1; + + result = NULL; +! if ((bucket = &(ht->buckets[(((unsigned long)(key.k_thr) * 10000U + (unsigned long)(key.k_pid)) % ht->num_buckets)])) != NULL) + { + ll = &(bucket->list); + li = LL_FIRST(ll); +*************** +*** 1499,1505 **** + pidthr_t k1; + + result = NULL; +! if ((bucket = &(ht->buckets[((key.k_thr * 10000 + key.k_pid) % ht->num_buckets)])) != NULL) + { + ll = &(bucket->list); + li = LL_FIRST(ll); +--- 1499,1505 ---- + pidthr_t k1; + + result = NULL; +! if ((bucket = &(ht->buckets[(((unsigned long)(key.k_thr) * 10000U + (unsigned long)(key.k_pid)) % ht->num_buckets)])) != NULL) + { + ll = &(bucket->list); + li = LL_FIRST(ll); + + + diff --git a/sys-process/unixtop/files/unixtop-3.8_beta1-memleak-fix-v2.patch b/sys-process/unixtop/files/unixtop-3.8_beta1-memleak-fix-v2.patch new file mode 100644 index 000000000000..76042bb4c1a6 --- /dev/null +++ b/sys-process/unixtop/files/unixtop-3.8_beta1-memleak-fix-v2.patch @@ -0,0 +1,44 @@ +https://hg.openindiana.org/upstream/oracle/userland-gate/raw-file/23c55a2f8a8e/components/top/patches/03.sunos5.patch + +*** top-3.8beta1/machine/m_sunos5.c.orig Wed Aug 31 05:23:52 2011 +--- top-3.8beta1/machine/m_sunos5.c Wed Aug 31 05:25:25 2011 +*************** +*** 2064,2070 **** + + /* read the whole file */ + p = malloc(st.st_size); +! (void)pread(fd, p, st.st_size, 0); + + /* cache the file descriptor if we can */ + if (fd < maxfiles) +--- 2064,2076 ---- + + /* read the whole file */ + p = malloc(st.st_size); +! if (pread(fd, p, st.st_size, 0) != st.st_size) +! { +! (void) close(fd); +! op->fd_lpsinfo = -1; +! free(p); +! continue; +! } + + /* cache the file descriptor if we can */ + if (fd < maxfiles) +*************** +*** 2148,2154 **** + op->oldtime = TIMESPEC_TO_DOUBLE(lwpp->pr_time); + op->seen = 1; + } +! free(p); + } + #endif + +--- 2154,2160 ---- + op->oldtime = TIMESPEC_TO_DOUBLE(lwpp->pr_time); + op->seen = 1; + } +! free(prp); + } + #endif + diff --git a/sys-process/unixtop/files/unixtop-3.8_beta1-memleak-fix.patch b/sys-process/unixtop/files/unixtop-3.8_beta1-memleak-fix.patch new file mode 100644 index 000000000000..d8c6e556e197 --- /dev/null +++ b/sys-process/unixtop/files/unixtop-3.8_beta1-memleak-fix.patch @@ -0,0 +1,28 @@ +http://defect.opensolaris.org/bz/show_bug.cgi?id=5482 +http://sourceforge.net/tracker/?func=detail&aid=2593511&group_id=72892&atid=536042 + +--- top-3.8beta1/machine/m_sunos5.c ++++ top-3.8beta1/machine/m_sunos5.c +@@ -2059,11 +2059,11 @@ + /* make sure we have a valid descriptor and the file's current size */ + if (fd >= 0 && fstat(fd, &st) != -1) + { +- char *p; ++ char *p, *p0; + int i; + + /* read the whole file */ +- p = malloc(st.st_size); ++ p = p0 = malloc(st.st_size); + (void)pread(fd, p, st.st_size, 0); + + /* cache the file descriptor if we can */ +@@ -2148,7 +2148,7 @@ + op->oldtime = TIMESPEC_TO_DOUBLE(lwpp->pr_time); + op->seen = 1; + } +- free(p); ++ free(p0); + } + #endif + diff --git a/sys-process/unixtop/files/unixtop-3.8_beta1-ncurses.patch b/sys-process/unixtop/files/unixtop-3.8_beta1-ncurses.patch new file mode 100644 index 000000000000..73cd88b72826 --- /dev/null +++ b/sys-process/unixtop/files/unixtop-3.8_beta1-ncurses.patch @@ -0,0 +1,14 @@ +* check ncurses first, such that we only link agains (system) termcap if + necessary (never the case in prefix) -- grobian@gentoo.org + +--- configure.ac ++++ configure.ac +@@ -174,7 +174,7 @@ + AC_CHECK_LIB(kvm, kvm_open) + # -lmld -lmach + AC_CHECK_LIB(mach, vm_statistics) +-AC_SEARCH_LIBS(tgetent, termcap curses ncurses) ++AC_SEARCH_LIBS(tgetent, ncurses curses termcap) + AC_CHECK_LIB(m, exp) + + # check for libraries required by extension diff --git a/sys-process/unixtop/files/unixtop-3.8_beta1-no-AX-macros.patch b/sys-process/unixtop/files/unixtop-3.8_beta1-no-AX-macros.patch new file mode 100644 index 000000000000..f5d34a4a9ae9 --- /dev/null +++ b/sys-process/unixtop/files/unixtop-3.8_beta1-no-AX-macros.patch @@ -0,0 +1,22 @@ +* no idea where these macros are, but we can surely do without this, for + now -- grobian@gentoo.org + +--- configure.ac ++++ configure.ac +@@ -504,16 +504,6 @@ + + AC_MSG_RESULT($result) + +-# add extra cflags if the compiler accepts them +-AX_CFLAGS_WARN_ALL +-MODULE_CFLAGS="" +-if test "$ax_cv_c_compiler_vendor" = "gnu"; then +- AX_CFLAGS_GCC_OPTION([-fno-strict-aliasing], [MODULE_CFLAGS]) +- if test "$target_cpu" = "alpha"; then +- AX_CFLAGS_GCC_OPTION([-mfp-trap-mode=sui -mtrap-precision=i]) +- fi +-fi +- + # Define man page supplement + MAN_SUPPLEMENT=machine/m_$MODULE.man + AC_SUBST_FILE(MAN_SUPPLEMENT) diff --git a/sys-process/unixtop/files/unixtop-3.8_beta1-percent-cpu.patch b/sys-process/unixtop/files/unixtop-3.8_beta1-percent-cpu.patch new file mode 100644 index 000000000000..503ed3576a70 --- /dev/null +++ b/sys-process/unixtop/files/unixtop-3.8_beta1-percent-cpu.patch @@ -0,0 +1,23 @@ +https://hg.openindiana.org/upstream/oracle/userland-gate/file/23c55a2f8a8e/components/top/patches/04.percent_cpu.patch + +--- top-3.8beta1/machine/m_sunos5.c.orig Tue Nov 8 11:23:08 2011 ++++ top-3.8beta1/machine/m_sunos5.c Tue Nov 8 11:23:11 2011 +@@ -152,8 +152,17 @@ + * one of the spare slots in the prinfo structure. + */ + +-#define percent_cpu(pp) (*(double *)dbl_align(&pp->pr_filler[0])) ++#if OSREV > 59 ++/* ++ * on Solaris 10, psinfo.pr_filler is 4 bytes and not double-aligned, so we must * move our scratch space to the larger pr.lwp_pr_filler which is 20 bytes ++ * XXX this is a time bomb and will likely break in future Solaris releases. ++ */ ++#define percent_cpu(pp) (*(double *)dbl_align(&pp->pr_lwp.pr_filler[0])) ++#else ++#define percent_cpu(pp) (*(double *)dbl_align(&pp->pr_filler[0])) ++#endif + ++ + /* definitions for indices in the nlist array */ + #define X_V 0 + #define X_MPID 1 diff --git a/sys-process/unixtop/files/unixtop-3.8_beta1-renice-segfault.patch b/sys-process/unixtop/files/unixtop-3.8_beta1-renice-segfault.patch new file mode 100644 index 000000000000..afea694b59ad --- /dev/null +++ b/sys-process/unixtop/files/unixtop-3.8_beta1-renice-segfault.patch @@ -0,0 +1,21 @@ +http://defect.opensolaris.org/bz/show_bug.cgi?id=6580 + +--- top-3.8beta1/commands.c ++++ top-3.8beta1/commands.c +@@ -501,13 +501,15 @@ + if (procnum == -1 || prio < PRIO_MIN || prio > PRIO_MAX) + { + message_error(" renice: bad priority value"); ++ return; + } + #endif + + /* move to the first process number */ + if ((str = next_field(str)) == NULL) + { +- message_error(" remice: no processes specified"); ++ message_error(" renice: no processes specified"); ++ return; + } + + #ifdef HAVE_SETPRIORITY diff --git a/sys-process/unixtop/metadata.xml b/sys-process/unixtop/metadata.xml new file mode 100644 index 000000000000..f5e4e79522ea --- /dev/null +++ b/sys-process/unixtop/metadata.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <herd>prefix</herd> + <upstream> + <remote-id type="sourceforge">unixtop</remote-id> + </upstream> +</pkgmetadata> diff --git a/sys-process/unixtop/unixtop-3.8_beta1-r3.ebuild b/sys-process/unixtop/unixtop-3.8_beta1-r3.ebuild new file mode 100644 index 000000000000..062e6f5abdf8 --- /dev/null +++ b/sys-process/unixtop/unixtop-3.8_beta1-r3.ebuild @@ -0,0 +1,49 @@ +# Copyright 1999-2014 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +inherit eutils autotools + +DESCRIPTION="top for UNIX systems" +HOMEPAGE="http://unixtop.sourceforge.net/" +SRC_URI="mirror://sourceforge/unixtop/top-${PV/_/}.tar.bz2" + +LICENSE="BSD" +SLOT="0" +KEYWORDS="~amd64-linux ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" +IUSE="" + +RDEPEND="sys-libs/ncurses" +DEPEND="${RDEPEND}" + +S=${WORKDIR}/top-${PV/_/} + +src_unpack() { + unpack ${A} + cd "${S}" + epatch "${FILESDIR}"/${P}-ncurses.patch + epatch "${FILESDIR}"/${P}-no-AX-macros.patch + epatch "${FILESDIR}"/${P}-renice-segfault.patch + epatch "${FILESDIR}"/${P}-memleak-fix-v2.patch + epatch "${FILESDIR}"/${P}-high-threadid-crash.patch + epatch "${FILESDIR}"/${P}-percent-cpu.patch + eautoreconf +} + +src_compile() { + local myconf= + + # don't do bi-arch cruft on hosts that support that, such as Solaris + export enable_dualarch=no + + # configure demands an override because on OSX this is "experimental" + [[ ${CHOST} == *-darwin* ]] && myconf="${myconf} --with-module=macosx" + + econf ${myconf} || die + emake || die +} + +src_install() { + emake DESTDIR="${D}" install + dodoc README FAQ Y2K +} |