pentoo: fix makemo and improve flushchanges, tagged rc2 for pleasure

This commit is contained in:
Zero_Chaos 2012-03-04 05:35:45 +00:00
parent bd7dbeb28b
commit 3549d2a8f2
5 changed files with 445 additions and 0 deletions

View file

@ -1,9 +1,13 @@
AUX b43-commercial-2012.0 305 RMD160 03ed4dcfd834752f9b0cf7e236f198abb2c0ac19 SHA1 f6b7bbe95e6cbd437b4bcce81f244cf68b9959ff SHA256 b9a147fc4a41f4d45e5bd8dd790154293bb3a59fd8e9e560c9db5c5b54857ddc
AUX dokeybindings-2012.0 265 RMD160 4e6c969ac3414972fcab9ac70386be7f933e63ff SHA1 6fa70fafe3e3c4955c4ff39fc574b0ca6bd9471f SHA256 ea323401cfaf10a37f04771541390b1c037a255c5583a5030ea6acbce5b5a409
AUX flushchanges-2012.0 1424 RMD160 00b36188d577bd7d9cd01e4f04fb392bb78d0018 SHA1 101231419456cc7714e8915a9ad50cce53774591 SHA256 7bec75c6e79f752720d64903fb56983e60b6f47ba518f283e1b0529f4ba08e05
AUX flushchanges-2012.1 1433 RMD160 4a638348ce051b7be4aaa24fe7d06df8c5f2fbac SHA1 5134820243d79c6bc630cdd732a1d03470cae6c3 SHA256 399ed54ac270122befc234cb6338ecf2aacd34e9344f4fba9eef1f7eef1dcbc7
AUX layman-sync 46 RMD160 81839cda148d6f0d9fe22d45e238a802f7066c78 SHA1 aea582376c167b800bf0e79cb6270624cda7e2da SHA256 7e2e82525f67d87d86a003fbefe4865aee05f8ff355aff999d6b4124d6d9ea81
AUX makemo-2012.0 1117 RMD160 491f716140c08fd9bd7ee5fedf521743b605ea47 SHA1 371bae739e8a2f2065fa1420f6b5cc2cf5ed1911 SHA256 aa05be5c1d624a04d2608cffbf494d6c0b85fb45df3ac9046e1b684543dddffd
AUX makemo-2012.1 1129 RMD160 a5e654ba476b839fba8bea986fae6dbc346d86a0 SHA1 3b54fac55be0e94f6ebbd5db6d0f0ccb1202e966 SHA256 66627b86025b97d1b534deb8b51510492f1ce064c8af984d3dc2001d3eb36581
AUX motd-2012.0 1604 RMD160 79cf8ae8027a6540f09f728c1b1f9a6fbe456a56 SHA1 0a105f87de6a500bcbc37f1a63fb567ea8366df4 SHA256 16e77a7a38d9a77222814cfdae4abaced9f82f6a0b8688a5d29ee36f5de6beb7
AUX pentoo-release-2012.0-rc1 34 RMD160 420510bde0142884e09a62290ba4e4687c043c02 SHA1 80262e01eabe90fd180efd61dcf540854ae619bd SHA256 b5fccfee32ec866977c035d4d9869aae225de9de860516b4fb53c116d800762f
AUX pentoo-release-2012.1-rc2 34 RMD160 68cf0901aef7d92ddf14dae52c60760a2f716278 SHA1 f9c11d3344a74f2b6ab9f621c710f74a99ef751e SHA256 31e6bd2df90dca4c5483de8ce197bbf39a6581792e07dd4a6b8b884dd780949c
AUX pentoo.xpm.gz 59047 RMD160 c0f486fafba5397ae7f894c609643709a5701545 SHA1 6f585ad36306c3794134dc5f7ab7db75e589c8cd SHA256 4adb6d0d305b599e35bed9a835b6aa3531cce71c0b05e293adb3197cac4c09e0
EBUILD pentoo-2012.0.ebuild 8901 RMD160 b6a116cb572560f83fe71ca62b9e3059d42c1b81 SHA1 95d1f8bcd12b7f965e81c315202678bf95cbdfd0 SHA256 8b7e7c4ccbcf9e76a2406464cd33184d2e6d551ff12ef706ab0a19d7d307b542
EBUILD pentoo-2012.1.ebuild 8901 RMD160 e76b017b7aa6425f7f2796aa4472df2009b43dac SHA1 0145fb9ef372c107b7ad0ae13bb3be0e74eec2b9 SHA256 3b417e6042b68002139b3490d7e91838569e14cfb1ff07cf4edd2e0308d8872d

View file

@ -0,0 +1,72 @@
#!/bin/sh
# This script allows flushing of the permanent storage to a .lzm file,
# allowing for some more space
DST="/mnt/cdrom/modules"
CHANGESDIR="/.unions/memory/aufs_changes/default/"
[ -e /lib/rc/sh/functions.sh ] && . /lib/rc/sh/functions.sh
usage ()
{
echo
echo " Usage : flushchanges [dest]"
echo " Where [dest] is the modules storage directory"
echo " defaulting to /mnt/cdrom/modules"
echo
}
squash ()
{
if [ ! -e $CHANGESDIR ]
then
eerror "It appears that you're not using unionfs"
return 1
else
mksquashfs $CHANGESDIR $1 -b 1048576 -comp xz
return 0
fi
}
if [ ! -z $1 ]
then
DST=$1
fi
echo "Using $DST for module storage"
if [ ! -e /mnt/cdrom/modules ]
then
ewarn "Unable to find module dir in /mnt/cdrom/"
usage
else
index=0
while [ 1 ]
do
index=$(($index + 1))
# echo $index
if [ ! -f "${DST}/z_changes-${index}" ]
then
squash ${DST}/z_changes-${index}.lzm
if [ $? -eq 0 ]
then
einfo "$DST/z_changes-$index.lzm created successfully"
break
else
ewarn "Unable to create $DST/z_changes-$index.lzm"
break
fi
fi
done
if [ -f "${DST}/z_changes-${index}.lzm" ]
then
ewarn "The changesfile will be cleared a next reboot"
if [ -e /usr/sbin/doclean.sh ]
then
cp -a /usr/sbin/doclean.sh /.unions/memory/.doclean.sh
else
eerror "Unable to find /usr/sbin/doclean.sh"
eerror "Your changesfile will not be cleared at reboot"
fi
fi
fi

View file

@ -0,0 +1,44 @@
#!/bin/sh
source /lib/rc/sh/functions.sh
mkdir -p /modules/
TMPDIR="/tmp/rootfs-$$"
DEPS=$(emerge -pv $@)
PKG=`echo "${DEPS}" | grep -e ".*/.*" | sed -e 's/.*] //g' -e 's/ .*//g' | grep -v ^/`
[[ -z $1 ]] && eerror "Nothing to emerge!" && exit 1
einfo "Here are the dependencies :"
echo "${DEPS}"
read -p "Proceed with the merging? [y]/n " ASK
if [ "${ASK}" == "n" ]; then
exit 0
fi
if [ ! -e /mnt/cdrom/modules ]
then
ewarn "Unable to find module dir in /mnt/cdrom/"
ewarn "Are you using Pentoo live or installed?"
else
einfo "Preparing to merge all required packages"
for x in "${PKG}"
do
emerge -1b "=${x}"
mkdir -p "${TMPDIR}"
[[ ! -e /usr/portage/packages/"${x}".tbz2 ]] && eerror "Build failed" && exit 1
tar -jxf /usr/portage/packages/"${x}".tbz2 -C "${TMPDIR}"
mkdir -p "${TMPDIR}"/var/db/pkg/"${x}"
cp -a /var/db/pkg/"${x}"/* "${TMPDIR}"/var/db/pkg/"${x}"/
MOFILE=`echo $x | sed -e 's/.*\///g'`
einfo "Building module for $MOFILE"
mksquashfs "${TMPDIR}" /mnt/cdrom/modules/"${MOFILE}".lzm -b 1048576 -comp xz
einfo "Module now available in /modules/$MOFILE.lzm"
rm -rf "${TMPDIR}"
done
fi

View file

@ -0,0 +1 @@
Pentoo 2012.1 release candidate 2

View file

@ -0,0 +1,324 @@
# Copyright 1999-2010 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $
EAPI="2"
KEYWORDS="-*"
DESCRIPTION="Pentoo meta ebuild to install all apps"
HOMEPAGE="http://www.pentoo.ch"
SLOT="0"
LICENSE="GPL"
IUSE="livecd hardened dwm +analyzer +bluetooth +cracking +database enlightenment +exploit +footprint +forensics +forging +fuzzers kde +mitm +proxies qemu gnome qt4 +rce +scanner +voip +wireless +xfce"
DEPEND="hardened? ( >=sys-apps/sandbox-2.4
sys-apps/paxctl
app-misc/pax-utils )"
#main atoms
RDEPEND="sys-kernel/pentoo-sources"
# Will get merged by fsscript
# pentoo/pentoo-etc-portage
#System apps
RDEPEND="${RDEPEND}
livecd? ( pentoo/pentoo-installer )
sys-apps/openrc[pentoo]
dev-util/lafilefixer
app-arch/sharutils
app-crypt/gnupg[static]
sys-apps/hdparm
sys-fs/cryptsetup
dev-libs/icu"
#window makers
RDEPEND="${RDEPEND}
dwm? ( x11-wm/dwm )
kde? ( kde-base/kde-meta )
gnome? ( pentoo/pentoo-gnome )
xfce? ( xfce-base/xfce4-meta
app-editors/leafpad
app-cdr/xfburn
xfce-base/thunar
xfce-extra/xfce4-screenshooter
xfce-extra/xfce4-power-manager
xfce-extra/thunar-volman
xfce-extra/tumbler
x11-themes/tango-icon-theme
x11-apps/xrandr
media-gfx/geeqie )"
# enlightenment
RDEPEND="${RDEPEND}
enlightenment? ( =app-misc/exchange-9999
=dev-libs/eet-9999
=dev-libs/eeze-9999
=dev-libs/eina-9999
=dev-libs/embryo-9999
=dev-libs/efreet-9999
=dev-libs/e_dbus-9999
=dev-libs/ecore-9999
=media-libs/edje-9999
=media-libs/emotion-9999
=media-libs/evas-9999
=x11-plugins/e_modules-tclock-9999
=x11-plugins/e_modules-engage-9999
=x11-plugins/extramenu-9999
=x11-wm/enlightenment-9999
x11-apps/xrandr )"
#X windows stuff
RDEPEND="${RDEPEND}
livecd? ( x11-drivers/xf86-input-keyboard
x11-drivers/xf86-input-mouse
x11-drivers/xf86-video-apm
x11-drivers/xf86-video-ark
x11-drivers/xf86-video-ati
x11-drivers/xf86-video-chips
x11-drivers/xf86-video-cirrus
x11-drivers/xf86-video-fbdev
x11-drivers/xf86-video-glint
x11-drivers/xf86-video-i128
x11-drivers/xf86-video-intel
x11-drivers/xf86-video-mach64
x11-drivers/xf86-video-mga
x11-drivers/xf86-video-neomagic
x11-drivers/xf86-video-nv
x11-drivers/xf86-video-nouveau
x11-drivers/xf86-video-rendition
x11-drivers/xf86-video-s3
x11-drivers/xf86-video-s3virge
x11-drivers/xf86-video-savage
x11-drivers/xf86-video-siliconmotion
x11-drivers/xf86-video-sis
x11-drivers/xf86-video-tdfx
x11-drivers/xf86-video-trident
x11-drivers/xf86-video-vesa
x11-drivers/xf86-video-vmware
x11-drivers/xf86-video-voodoo )
x11-libs/gksu
x11-proto/dri2proto
x11-terms/rxvt-unicode
x11-terms/terminal
x11-themes/gtk-chtheme"
#basic systems
RDEPEND="${RDEPEND}
livecd? ( <=app-misc/livecd-tools-2.0.0
virtual/eject
sys-apps/hwsetup
sys-block/disktype
x11-misc/mkxf86config )
qemu? ( app-emulation/virt-manager
app-emulation/qemu-kvm )
x86? ( mail-client/thunderbird-bin
www-client/firefox-bin )
amd64? ( <=www-client/firefox-bin-4.0.0
app-emulation/emul-linux-x86-java )
dev-java/sun-jdk
|| ( sys-boot/grub
sys-boot/grub-static )
app-admin/genmenu
app-admin/localepurge
app-arch/unrar
app-arch/unzip
app-editors/ghex
app-editors/hexedit
app-editors/nano
app-editors/gedit
app-editors/vim
app-misc/screen
app-portage/eix
app-portage/gentoolkit
app-portage/layman
app-portage/smart-live-rebuild
app-text/dos2unix
app-text/evince
app-text/wgetpaste
dev-libs/libxslt
dev-vcs/subversion
gnome-base/gnome-menus
media-fonts/dejavu
media-fonts/font-misc-misc
media-gfx/fbgrab
media-gfx/scrot
media-sound/alsamixergui
media-sound/alsa-utils
media-sound/audacious
media-sound/sox
media-sound/pulseaudio
media-video/vlc
media-video/xine-ui
net-dialup/lrzsz
net-dialup/minicom
net-dialup/ppp
net-dialup/wvdial
net-dns/bind-tools
|| ( net-fs/mount-cifs
net-fs/samba )
net-fs/nfs-utils
net-ftp/ftp
net-ftp/gproftpd
net-ftp/oftpd
net-im/pidgin
net-irc/irssi
net-irc/xchat
net-misc/axel
net-misc/curl
net-misc/dhcp
net-misc/dhcpcd
net-misc/grdesktop
net-misc/iputils
net-misc/netkit-fingerd
net-misc/netkit-rsh
net-misc/netsed
net-misc/ntp
net-misc/openssh
net-misc/openvpn
net-misc/rdesktop
net-misc/stunnel
net-misc/tcpick
net-misc/telnet-bsd
net-misc/tightvnc
net-misc/vconfig
net-misc/vpnc
net-misc/whois
net-misc/wicd
net-misc/wlan2eth
sys-apps/ethtool
sys-apps/fbset
sys-apps/iproute2
sys-apps/microcode-ctl
sys-apps/microcode-data
sys-apps/pciutils
sys-apps/mlocate
sys-apps/sysvinit
sys-block/gparted
sys-boot/syslinux
sys-devel/crossdev
sys-devel/gettext
sys-fs/jfsutils
sys-fs/reiser4progs
sys-fs/reiserfsprogs
sys-fs/squashfs-tools
sys-fs/sshfs-fuse
sys-libs/gpm
sys-power/acpid[pentoo]
sys-power/acpitool
sys-power/cpufrequtils
sys-power/hibernate-script
sys-power/powertop
sys-process/htop
sys-process/iotop
www-client/links
www-plugins/adobe-flash
www-servers/lighttpd
www-plugins/firecat
x11-apps/setxkbmap
x11-apps/xinit"
# FAils:
# net-dialup/linux-atm
# Either links or lynx
# www-client/lynx
# qt4? ( net-firewall/fwbuilder )
# Only in stage2!!!
# sys-apps/v86d
# sys-fs/cdfs
RDEPEND="${RDEPEND}
net-analyzer/tcpreplay"
#things needed for a running system and not for livecd
RDEPEND="${RDEPEND}
!livecd? ( app-portage/portage-utils
app-admin/syslog-ng )"
RDEPEND="${RDEPEND}
app-crypt/openvpn-blacklist
app-misc/dradis
amd64? ( net-analyzer/arpantispoofer )
net-analyzer/netcat6
net-analyzer/netdiscover
net-analyzer/ngrep
net-analyzer/snort
net-analyzer/tcpdump
net-analyzer/traceroute
net-analyzer/wireshark"
# Fails:
# net-analyzer/packet-o-matic
#TODO: explain why these aren't included?
#net-wireless/waveselect
#dev-db/absinthe very old crap
#net-analyzer/hydra medus is better
#bug #333099
# net-analyzer/honeyd
#the tools
RDEPEND="${RDEPEND}
analyzer? ( pentoo/pentoo-analyzer )
bluetooth? ( pentoo/pentoo-bluetooth )
cracking? ( pentoo/pentoo-cracking )
database? ( pentoo/pentoo-database )
exploit? ( pentoo/pentoo-exploit )
footprint? ( pentoo/pentoo-footprint )
forensics? ( pentoo/pentoo-forensics )
forging? ( pentoo/pentoo-forging )
fuzzers? ( pentoo/pentoo-fuzzers )
mitm? ( pentoo/pentoo-mitm )
proxies? ( pentoo/pentoo-proxies )
rce? ( pentoo/pentoo-rce )
scanner? ( pentoo/pentoo-scanner )
voip? ( pentoo/pentoo-voip )
wireless? ( pentoo/pentoo-wireless )"
pkg_setup() {
#pam_pwdb and pam_console are no longer supported
grep -v pam_console "${ROOT}"/etc/pam.d/entrance > "${T}"/entrance
local grepret=$?
[ ${grepret} -ge 2 ] && [ -f "${ROOT}"/etc/pam.d/entrance ] && die "Tried to grep the pam files and got an error."
[ ${grepret} == 0 ] && einfo "pam_console has been purged from /etc/pam.d/entrance. It's a good thing."
[ ${grepret} == 1 ] && einfo "pam_console was not found in /etc/pam.d/entrance. It's a good thing"
mv "${T}"/entrance "${ROOT}"/etc/pam.d/entrance
grep pam_console "${ROOT}/etc/pam.d/*"
local grepret=$?
[ ${grepret} == 0 ] && die "pam_console still exists in /etc/pam.d/ and is no longer supported. Please remove all instances of pam_console."
[ ${grepret} == 1 ] && einfo "pam_console no longer exists in /etc/pam.d. It's a good thing."
grep pam_pwdb "${ROOT}/etc/pam.d/*"
local grepret=$?
[ ${grepret} == 0 ] && die "pam_pwdb still exists in /etc/pam.d/ and is no longer supported. Please remove all instances of pam_pwdb."
[ ${grepret} == 1 ] && einfo "pam_pwdb no longer exists in /etc/pam.d. It's a good thing."
}
src_install() {
##here is where we merge in things from root_overlay which make sense
exeinto /root
newexe "${FILESDIR}"/b43-commercial-${PV} b43-commercial || die "b43-commercial failed"
insinto /root
newins "${FILESDIR}"/motd-${PV} motd || die "motd failed"
#/usr/bin
newbin "${FILESDIR}"/dokeybindings-${PV} dokeybindings || die "dokeybindings failed"
#/usr/sbin
newsbin "${FILESDIR}"/flushchanges-${PV} flushchanges || die "flushchanges failed"
newsbin "${FILESDIR}"/makemo-${PV} makemo || "makemo failed"
#/etc
insinto /etc
newins "${FILESDIR}/pentoo-release-${PV}-rc2" pentoo-release || die "pentoo-release versioning failed"
exeinto /etc/portage/postsync.d
doexe "${FILESDIR}"/layman-sync || die "/etc/portage/postsync.d failure"
}
pkg_postinst() {
elog "This ebuild is a meta ebuild to handle all the pentoo specific things which"
elog "we can't figure out how to handle cleanly. This will allow us our very own"
elog "meta-package which can be used to make sure the installed users can be"
elog "updated when we make fairly major changes. This may not handle everything,"
elog "but it is a start..."
ewarn "Significant changes have been made to your system, you must type 'etc-update'."
ewarn "This command will help you merge the changed configuration files onto your system."
epause "Seriously, stop what you are doing now and run 'etc-update'"
}