sys-block/zram-init - 11.1 (mva)

Search

Install

Install this version:

emerge -a =sys-block/zram-init-11.1

If this version is masked, you can unmask it using the autounmask tool or standard emerge options:

autounmask =sys-block/zram-init-11.1

Or alternatively:

emerge --autounmask-write -a =sys-block/zram-init-11.1

Package Information

Description:
Scripts to support compressed swap devices or ramdisks with zram
Homepage:
https://github.com/vaeth/zram-init/
License:
GPL-2

Ebuild Details

Version EAPI Keywords Slot
11.1 8 ~amd64 ~arm64 ~ppc ~ppc64 ~x86 0
View Raw Ebuild
# Copyright 2026 mva
# Distributed under the terms of the Public Domain or CC0 License

EAPI=8
inherit readme.gentoo-r1 systemd patches shell-completion

DESCRIPTION="Scripts to support compressed swap devices or ramdisks with zram"
HOMEPAGE="https://github.com/vaeth/zram-init/"

if [[ "${PV}" == *9999* ]]; then
	inherit git-r3
	EGIT_REPO_URI="https://github.com/vaeth/${PN}"
else
	SRC_URI="https://github.com/vaeth/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
	KEYWORDS="~amd64 ~arm64 ~ppc ~ppc64 ~x86"
fi

LICENSE="GPL-2"
SLOT="0"

RDEPEND="
	app-shells/push
	sys-apps/openrc
"

DISABLE_AUTOFORMATTING="true"
DOC_CONTENTS="To use zram, activate it in your kernel and add it to default runlevel:
	rc-config add zram default
If you use systemd enable zram_swap, tmp, and/or var_tmp with systemctl.
You might need to modify /etc/modprobe.d/zram.conf"

src_prepare() {
	use prefix || sed -i \
		-e '1s"^#!/usr/bin/env sh$"#!'"${EPREFIX}/bin/sh"'"' \
		-- sbin/* || die
	default
}

src_install() {
	doinitd openrc/init.d/*
	doconfd openrc/conf.d/*
	systemd_dounit systemd/system/*
	insinto /etc/modprobe.d
	doins modprobe.d/*
	dozshcomp zsh/*
	dodoc AUTHORS ChangeLog README.md
	readme.gentoo_create_doc
	into /
	dosbin sbin/*
}

pkg_postinst() {
	readme.gentoo_print_elog
}

Inherited Eclasses

Dependencies

RDEPEND

	app-shells/push
	sys-apps/openrc

Manifest for 11.1

Type File Size Source URLs
DIST zram-init-11.1.tar.gz 21117 bytes https://github.com/vaeth/zram-init/archive/v11.1.tar.gz