summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobin H. Johnson <robbat2@gentoo.org>2015-08-08 13:49:04 -0700
committerRobin H. Johnson <robbat2@gentoo.org>2015-08-08 17:38:18 -0700
commit56bd759df1d0c750a065b8c845e93d5dfa6b549d (patch)
tree3f91093cdb475e565ae857f1c5a7fd339e2d781e /sys-apps/linux-misc-apps
downloadgentoo-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-apps/linux-misc-apps')
-rw-r--r--sys-apps/linux-misc-apps/Manifest2
-rw-r--r--sys-apps/linux-misc-apps/files/freefall.confd6
-rw-r--r--sys-apps/linux-misc-apps/files/freefall.initd45
-rw-r--r--sys-apps/linux-misc-apps/files/hpfall.confd6
-rw-r--r--sys-apps/linux-misc-apps/files/hpfall.initd45
-rw-r--r--sys-apps/linux-misc-apps/linux-misc-apps-3.18.ebuild165
-rw-r--r--sys-apps/linux-misc-apps/linux-misc-apps-3.6-r2.ebuild185
-rw-r--r--sys-apps/linux-misc-apps/metadata.xml7
8 files changed, 461 insertions, 0 deletions
diff --git a/sys-apps/linux-misc-apps/Manifest b/sys-apps/linux-misc-apps/Manifest
new file mode 100644
index 000000000000..a0a0e4d17c67
--- /dev/null
+++ b/sys-apps/linux-misc-apps/Manifest
@@ -0,0 +1,2 @@
+DIST linux-3.18.tar.xz 80934708 SHA256 becc413cc9e6d7f5cc52a3ce66d65c3725bc1d1cc1001f4ce6c32b69eb188cbd SHA512 2f0b72466e9bc538a675738aa416573d41bbbd7e3e2ffd5b5b127afde609ebc278cec5a3c37e73479607e957c13f1b4ed9782a3795e0dcc2cf8e550228594009 WHIRLPOOL 81634af631b7d30ccd1f4798f96f44d9aa0ba6609b73f2747eb6aebaf7a99487fb2dbd45767605186182533cb222bfd9236e8dd5e11a04fdb67c211e4e0a91d6
+DIST linux-3.6.tar.bz2 82296001 SHA256 88ae0a20fd39ecae79db0ce8f9397922fae33c8b06a54ed2c883c861126c9771 SHA512 cbaefc2c4c8ab2251c3345b7b2c88d55a49e3468d8b177b05dd6d96a802efa9a052b1a1ecab8b71298bac97f45259516d88253838332b4fdb4307780ebcddce9 WHIRLPOOL e17e3800951f0c3af21015d1a1c99698d0ef70815bd4f131dd60b30baef70d4c255988857533a9a7c058388c2febfcf02d12cde2a7ed46b24fa85aeb260c0251
diff --git a/sys-apps/linux-misc-apps/files/freefall.confd b/sys-apps/linux-misc-apps/files/freefall.confd
new file mode 100644
index 000000000000..c082615cbcac
--- /dev/null
+++ b/sys-apps/linux-misc-apps/files/freefall.confd
@@ -0,0 +1,6 @@
+# /etc/conf.d/freefall
+
+# The name of the disk device that hpfall should protect.
+# Usually this is 'sda' or 'hda' the primary master.
+
+DISK="sda"
diff --git a/sys-apps/linux-misc-apps/files/freefall.initd b/sys-apps/linux-misc-apps/files/freefall.initd
new file mode 100644
index 000000000000..1df5294534e9
--- /dev/null
+++ b/sys-apps/linux-misc-apps/files/freefall.initd
@@ -0,0 +1,45 @@
+#!/sbin/runscript
+# Copyright 2012-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+checkconfig() {
+ if [ -z "$DISK" ] ; then
+ eerror "You need to setup DISK in /etc/conf.d/freefall first"
+ return 1
+ fi
+
+ if [ ! -b /dev/${DISK} ]; then
+ eerror "Could not find disk /dev/${DISK}!"
+ eerror "Adjust the DISK setting in /etc/conf.d/freefall"
+ return 1
+ fi
+
+ if [ ! -e /sys/block/${DISK}/device/unload_heads ] ; then
+ eerror "No protect entry for ${DISK}!"
+ eerror "Kernel 2.6.28 and above is required"
+ return 1
+ fi
+
+ if [ ! -c /dev/freefall ]; then
+ ebegin "Loading hp_accel module"
+ modprobe hp_accel
+ eend $? || return 1
+ fi
+}
+
+start () {
+ checkconfig || return 1
+
+ ebegin "Starting active hard-drive protection daemon"
+ start-stop-daemon --start --quiet \
+ --exec /usr/sbin/freefall /dev/${DISK}
+ eend $?
+}
+
+stop() {
+ ebegin "Stopping active hard-drive protection daemon"
+ start-stop-daemon --stop --quiet \
+ --exec /usr/sbin/freefall
+ eend $?
+}
diff --git a/sys-apps/linux-misc-apps/files/hpfall.confd b/sys-apps/linux-misc-apps/files/hpfall.confd
new file mode 100644
index 000000000000..4f3451b0bff6
--- /dev/null
+++ b/sys-apps/linux-misc-apps/files/hpfall.confd
@@ -0,0 +1,6 @@
+# /etc/conf.d/hpfall
+
+# The name of the disk device that hpfall should protect.
+# Usually this is 'sda' or 'hda' the primary master.
+
+DISK="sda" \ No newline at end of file
diff --git a/sys-apps/linux-misc-apps/files/hpfall.initd b/sys-apps/linux-misc-apps/files/hpfall.initd
new file mode 100644
index 000000000000..5b9a55ba5a8f
--- /dev/null
+++ b/sys-apps/linux-misc-apps/files/hpfall.initd
@@ -0,0 +1,45 @@
+#!/sbin/runscript
+# Copyright 2012 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+checkconfig() {
+ if [ -z "$DISK" ] ; then
+ eerror "You need to setup DISK in /etc/conf.d/hpfall first"
+ return 1
+ fi
+
+ if [ ! -b /dev/${DISK} ]; then
+ eerror "Could not find disk /dev/${DISK}!"
+ eerror "Adjust the DISK setting in /etc/conf.d/hpfall"
+ return 1
+ fi
+
+ if [ ! -e /sys/block/${DISK}/device/unload_heads ] ; then
+ eerror "No protect entry for ${DISK}!"
+ eerror "Kernel 2.6.28 and above is required"
+ return 1
+ fi
+
+ if [ ! -c /dev/freefall ]; then
+ ebegin "Loading hp_accel module"
+ modprobe hp_accel
+ eend $? || return 1
+ fi
+}
+
+start () {
+ checkconfig || return 1
+
+ ebegin "Starting active hard-drive protection daemon"
+ start-stop-daemon --start --quiet \
+ --exec /usr/sbin/hpfall /dev/${DISK}
+ eend $?
+}
+
+stop() {
+ ebegin "Stopping active hard-drive protection daemon"
+ start-stop-daemon --stop --quiet \
+ --exec /usr/sbin/hpfall
+ eend $?
+}
diff --git a/sys-apps/linux-misc-apps/linux-misc-apps-3.18.ebuild b/sys-apps/linux-misc-apps/linux-misc-apps-3.18.ebuild
new file mode 100644
index 000000000000..be86d16228a7
--- /dev/null
+++ b/sys-apps/linux-misc-apps/linux-misc-apps-3.18.ebuild
@@ -0,0 +1,165 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit versionator eutils toolchain-funcs linux-info autotools flag-o-matic
+
+DESCRIPTION="Misc tools bundled with kernel sources"
+HOMEPAGE="http://kernel.org/"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc ~x86"
+IUSE="static-libs tcpd"
+
+MY_PV="${PV/_/-}"
+MY_PV="${MY_PV/-pre/-git}"
+
+LINUX_V=$(get_version_component_range 1-2)
+
+if [ ${PV/_rc} != ${PV} ]; then
+ LINUX_VER=$(get_version_component_range 1-2).$(($(get_version_component_range 3)-1))
+ PATCH_VERSION=$(get_version_component_range 1-3)
+ LINUX_PATCH=patch-${PV//_/-}.xz
+ SRC_URI="mirror://kernel/linux/kernel/v3.x/testing/${LINUX_PATCH}
+ mirror://kernel/linux/kernel/v3.x/testing/v${PATCH_VERSION}/${LINUX_PATCH}"
+elif [ $(get_version_component_count) == 4 ]; then
+ # stable-release series
+ LINUX_VER=$(get_version_component_range 1-3)
+ LINUX_PATCH=patch-${PV}.xz
+ SRC_URI="mirror://kernel/linux/kernel/v3.x/${LINUX_PATCH}"
+else
+ LINUX_VER=${PV}
+fi
+
+LINUX_SOURCES=linux-${LINUX_VER}.tar.xz
+SRC_URI="${SRC_URI} mirror://kernel/linux/kernel/v3.x/${LINUX_SOURCES}"
+
+# pmtools also provides turbostat
+# usbip available in seperate package now
+RDEPEND="sys-apps/hwids
+ >=dev-libs/glib-2.6
+ tcpd? ( sys-apps/tcp-wrappers )
+ !sys-power/pmtools"
+DEPEND="${RDEPEND}
+ virtual/pkgconfig"
+
+S="${WORKDIR}/linux-${LINUX_VER}"
+
+# All of these are integrated with the kernel build system,
+# No make install, and ideally build with with the root Makefile
+TARGETS_SIMPLE=(
+ Documentation/accounting/getdelays.c
+ tools/cgroup/cgroup_event_listener.c
+ Documentation/laptops/dslm.c
+ Documentation/laptops/freefall.c
+ Documentation/networking/timestamping/timestamping.c
+ Documentation/watchdog/src/watchdog-simple.c
+ tools/lguest/lguest.c
+ tools/vm/slabinfo.c
+ usr/gen_init_cpio.c
+)
+# tools/vm/page-types.c - broken, header path issue
+# tools/hv/hv_kvp_daemon.c - broken in 3.7 by missing linux/hyperv.h userspace
+# Documentation/networking/ifenslave.c - obsolete
+# Documentation/ptp/testptp.c - pending linux-headers-3.0
+
+# These have a broken make install, no DESTDIR
+TARGET_MAKE_SIMPLE=(
+ tools/firewire:nosy-dump
+ tools/power/x86/turbostat:../../../../turbostat
+ tools/power/x86/x86_energy_perf_policy:x86_energy_perf_policy
+ Documentation/misc-devices/mei:mei-amt-version
+)
+# tools/perf - covered by dev-utils/perf
+# tools/usb - testcases only
+# tools/virtio - testcaes only
+
+ #for _pattern in {Documentation,scripts,tools,usr,include,lib,"arch/*/include",Makefile,Kbuild,Kconfig}; do
+src_unpack() {
+ unpack ${LINUX_SOURCES}
+
+ MY_A=
+ for _AFILE in ${A}; do
+ [[ ${_AFILE} == ${LINUX_SOURCES} ]] && continue
+ [[ ${_AFILE} == ${LINUX_PATCH} ]] && continue
+ MY_A="${MY_A} ${_AFILE}"
+ done
+ [[ -n ${MY_A} ]] && unpack ${MY_A}
+}
+
+src_prepare() {
+ if [[ -n ${LINUX_PATCH} ]]; then
+ epatch "${DISTDIR}"/${LINUX_PATCH}
+ fi
+
+ sed -i \
+ -e '/^nosy-dump.*LDFLAGS/d' \
+ -e '/^nosy-dump.*CFLAGS/d' \
+ -e '/^nosy-dump.*CPPFLAGS/s,CPPFLAGS =,CPPFLAGS +=,g' \
+ "${S}"/tools/firewire/Makefile
+}
+
+kernel_asm_arch() {
+ a="${1:${ARCH}}"
+ case ${a} in
+ # Merged arches
+ x86|amd64) echo x86 ;;
+ ppc*) echo powerpc ;;
+ # Non-merged
+ alpha|arm|ia64|m68k|mips|sh|sparc*) echo ${1} ;;
+ *) die "TODO: Update the code for your asm-ARCH symlink" ;;
+ esac
+}
+
+src_configure() {
+ :
+}
+
+src_compile() {
+ local karch=$(kernel_asm_arch "${ARCH}")
+ # This is the minimal amount needed to start building host binaries.
+ #emake allmodconfig ARCH=${karch}
+ #emake prepare modules_prepare ARCH=${karch}
+ #touch Module.symvers
+
+ # Now we can start building
+ for s in ${TARGETS_SIMPLE[@]} ; do
+ dir=$(dirname $s) src=$(basename $s) bin=${src%.c}
+ einfo "Building $s => $bin"
+ emake -f /dev/null M=${dir} ARCH=${karch} ${s%.c}
+ done
+
+ for t in ${TARGET_MAKE_SIMPLE[@]} ; do
+ dir=${t/:*} target=${t/*:}
+ einfo "Building $dir => $target"
+ emake -C $dir ARCH=${karch} $target
+ done
+}
+
+src_install() {
+ into /usr
+ for s in ${TARGETS_SIMPLE[@]} ; do
+ dir=$(dirname $s) src=$(basename $s) bin=${src%.c}
+ einfo "Installing $s => $bin"
+ dosbin ${dir}/${bin}
+ done
+
+ for t in ${TARGET_MAKE_SIMPLE[@]} ; do
+ dir=${t/:*} target=${t/*:}
+ einfo "Installing $dir => $target"
+ dosbin ${dir}/${target}
+ done
+
+ newconfd "${FILESDIR}"/freefall.confd freefall
+ newinitd "${FILESDIR}"/freefall.initd freefall
+ prune_libtool_files
+}
+
+pkg_postinst() {
+ echo
+ elog "The cpupower utility is maintained separately at sys-power/cpupower"
+ elog "The usbip utility is maintained separately at net-misc/usbip"
+}
diff --git a/sys-apps/linux-misc-apps/linux-misc-apps-3.6-r2.ebuild b/sys-apps/linux-misc-apps/linux-misc-apps-3.6-r2.ebuild
new file mode 100644
index 000000000000..3e02a428b973
--- /dev/null
+++ b/sys-apps/linux-misc-apps/linux-misc-apps-3.6-r2.ebuild
@@ -0,0 +1,185 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit versionator eutils toolchain-funcs linux-info autotools flag-o-matic
+
+DESCRIPTION="Misc tools bundled with kernel sources"
+HOMEPAGE="http://kernel.org/"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc ~x86"
+IUSE="static-libs tcpd"
+
+MY_PV="${PV/_/-}"
+MY_PV="${MY_PV/-pre/-git}"
+
+LINUX_V=$(get_version_component_range 1-2)
+
+if [ ${PV/_rc} != ${PV} ]; then
+ LINUX_VER=$(get_version_component_range 1-2).$(($(get_version_component_range 3)-1))
+ PATCH_VERSION=$(get_version_component_range 1-3)
+ LINUX_PATCH=patch-${PV//_/-}.bz2
+ SRC_URI="mirror://kernel/linux/kernel/v${LINUX_V}/testing/${LINUX_PATCH}
+ mirror://kernel/linux/kernel/v${LINUX_V}/testing/v${PATCH_VERSION}/${LINUX_PATCH}"
+elif [ $(get_version_component_count) == 4 ]; then
+ # stable-release series
+ LINUX_VER=$(get_version_component_range 1-3)
+ LINUX_PATCH=patch-${PV}.bz2
+ SRC_URI="mirror://kernel/linux/kernel/v${LINUX_V}/${LINUX_PATCH}"
+else
+ LINUX_VER=${PV}
+fi
+
+LINUX_SOURCES=linux-${LINUX_VER}.tar.bz2
+SRC_URI="${SRC_URI} mirror://kernel/linux/kernel/v${LINUX_V}/${LINUX_SOURCES}"
+
+# pmtools also provides turbostat
+# sysfsutils and glib for usbip - remove sysfsutils in 3.7 or 3.8
+RDEPEND="sys-apps/hwids
+ >=sys-fs/sysfsutils-2
+ >=dev-libs/glib-2.6
+ tcpd? ( sys-apps/tcp-wrappers )
+ !sys-power/pmtools
+ !net-misc/usbip"
+DEPEND="${RDEPEND}
+ virtual/pkgconfig"
+
+S="${WORKDIR}/linux-${LINUX_VER}"
+
+# All of these are integrated with the kernel build system,
+# No make install, and ideally build with with the root Makefile
+TARGETS_SIMPLE=(
+ Documentation/accounting/getdelays.c
+ Documentation/cgroups/cgroup_event_listener.c
+ Documentation/laptops/dslm.c
+ Documentation/laptops/hpfall.c
+ Documentation/networking/timestamping/timestamping.c
+ Documentation/watchdog/src/watchdog-simple.c
+ tools/lguest/lguest.c
+ tools/vm/page-types.c
+ tools/vm/slabinfo.c
+ usr/gen_init_cpio.c
+)
+# tools/hv/hv_kvp_daemon.c - broken in 3.7 by missing linux/hyperv.h userspace
+# Documentation/networking/ifenslave.c - obsolete
+# Documentation/ptp/testptp.c - pending linux-headers-3.0
+
+# These have a broken make install, no DESTDIR
+TARGET_MAKE_SIMPLE=(
+ tools/firewire:nosy-dump
+ tools/power/x86/turbostat:turbostat
+ tools/power/x86/x86_energy_perf_policy:x86_energy_perf_policy
+ Documentation/misc-devices/mei:mei-amt-version
+)
+# tools/perf - covered by dev-utils/perf
+# tools/usb - testcases only
+# tools/virtio - testcaes only
+
+ #for _pattern in {Documentation,scripts,tools,usr,include,lib,"arch/*/include",Makefile,Kbuild,Kconfig}; do
+src_unpack() {
+ unpack ${LINUX_SOURCES}
+
+ MY_A=
+ for _AFILE in ${A}; do
+ [[ ${_AFILE} == ${LINUX_SOURCES} ]] && continue
+ [[ ${_AFILE} == ${LINUX_PATCH} ]] && continue
+ MY_A="${MY_A} ${_AFILE}"
+ done
+ [[ -n ${MY_A} ]] && unpack ${MY_A}
+}
+
+src_prepare() {
+ if [[ -n ${LINUX_PATCH} ]]; then
+ epatch "${DISTDIR}"/${LINUX_PATCH}
+ fi
+
+ pushd drivers/staging/usbip/userspace >/dev/null &&
+ eautoreconf -i -f -v &&
+ popd >/dev/null || die "usbip"
+
+ sed -i \
+ -e '/^nosy-dump.*LDFLAGS/d' \
+ -e '/^nosy-dump.*CFLAGS/d' \
+ -e '/^nosy-dump.*CPPFLAGS/s,CPPFLAGS =,CPPFLAGS +=,g' \
+ "${S}"/tools/firewire/Makefile
+}
+
+kernel_asm_arch() {
+ a="${1:${ARCH}}"
+ case ${a} in
+ # Merged arches
+ x86|amd64) echo x86 ;;
+ ppc*) echo powerpc ;;
+ # Non-merged
+ alpha|arm|ia64|m68k|mips|sh|sparc*) echo ${1} ;;
+ *) die "TODO: Update the code for your asm-ARCH symlink" ;;
+ esac
+}
+
+src_configure() {
+ cd drivers/staging/usbip/userspace && \
+ econf \
+ $(use_enable static-libs static) \
+ $(use tcpd || echo --without-tcp-wrappers) \
+ --with-usbids-dir=/usr/share/misc
+}
+
+src_compile() {
+ local karch=$(kernel_asm_arch "${ARCH}")
+ # This is the minimal amount needed to start building host binaries.
+ #emake allmodconfig ARCH=${karch}
+ #emake prepare modules_prepare ARCH=${karch}
+ #touch Module.symvers
+
+ # Now we can start building
+ for s in ${TARGETS_SIMPLE[@]} ; do
+ dir=$(dirname $s) src=$(basename $s) bin=${src%.c}
+ einfo "Building $s => $bin"
+ emake -f /dev/null M=${dir} ARCH=${karch} ${s%.c}
+ done
+
+ for t in ${TARGET_MAKE_SIMPLE[@]} ; do
+ dir=${t/:*} target=${t/*:}
+ einfo "Building $dir => $target"
+ emake -C $dir ARCH=${karch} $target
+ done
+
+ emake -C drivers/staging/usbip/userspace
+}
+
+src_install() {
+ into /usr
+ for s in ${TARGETS_SIMPLE[@]} ; do
+ dir=$(dirname $s) src=$(basename $s) bin=${src%.c}
+ einfo "Installing $s => $bin"
+ dosbin ${dir}/${bin}
+ done
+
+ for t in ${TARGET_MAKE_SIMPLE[@]} ; do
+ dir=${t/:*} target=${t/*:}
+ einfo "Installing $dir => $target"
+ dosbin ${dir}/${target}
+ done
+
+ pushd drivers/staging/usbip/userspace >/dev/null \
+ || die "Missing usbip/userspace"
+ emake DESTDIR="${D}" install
+
+ newdoc README README.usbip
+ newdoc AUTHORS AUTHORS.usbip
+ dodoc ../usbip_protocol.txt
+ popd >/dev/null
+
+ newconfd "${FILESDIR}"/hpfall.confd hpfall
+ newinitd "${FILESDIR}"/hpfall.initd hpfall
+ prune_libtool_files
+}
+
+pkg_postinst() {
+ echo
+ elog "The cpupower utility is maintained separately at sys-power/cpupower"
+}
diff --git a/sys-apps/linux-misc-apps/metadata.xml b/sys-apps/linux-misc-apps/metadata.xml
new file mode 100644
index 000000000000..c6d862855eb5
--- /dev/null
+++ b/sys-apps/linux-misc-apps/metadata.xml
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<maintainer>
+ <email>robbat2@gentoo.org</email>
+</maintainer>
+</pkgmetadata>