debian/0000755000000000000000000000000011761217016007170 5ustar debian/source/0000755000000000000000000000000011761215632010472 5ustar debian/source/format0000644000000000000000000000001411761215632011700 0ustar 3.0 (quilt) debian/compat0000644000000000000000000000000211221603752010363 0ustar 6 debian/rules0000755000000000000000000000160611761210132010243 0ustar #!/usr/bin/make -f DEB_DH_INSTALLINIT_ARGS := -- defaults 95 5 DEB_BUILD_PARALLEL=yes include /usr/share/cdbs/1/rules/autoreconf.mk include /usr/share/cdbs/1/class/autotools.mk include /usr/share/cdbs/1/rules/debhelper.mk clean:: rm -f src/preload.8 # generated at build time by help2man rm -f config.log binary-post-install/preload:: # Looks like Redhat to me. Done our way elsewhere. rm -r debian/preload/etc/rc.d debian/preload/etc/sysconfig # Hmm. Why? rm debian/preload/var/log/preload.log # Thanks but no thanks. rm -fr debian/preload/usr/share/doc/preload-* # Install and compress it manually, to be safe rm -f debian/preload/usr/share/man/man8/preload.8.gz cp src/preload.8 debian/preload/usr/share/man/man8/ gzip -9 debian/preload/usr/share/man/man8/preload.8 # Don't put files that are modified at run time to the binary package rm debian/preload/var/lib/preload/preload.state debian/docs0000644000000000000000000000002111221603752010031 0ustar doc/proposal.txt debian/preload.default0000644000000000000000000000042611222077737012174 0ustar # Default settings for preload init.d script # sourced by /etc/init.d/preload # Use Idle scheduling class (see start-stop-daemon(8), ionice(1) and # ioprio_set(2)). PRELOAD_IOSCHED="--iosched idle" # Enabling this should lead to lower disk activity. # OPTIONS="-l /dev/null" debian/patches/0000755000000000000000000000000011761216526010624 5ustar debian/patches/series0000644000000000000000000000002111761216044012025 0ustar logrotate_619384 debian/patches/logrotate_6193840000644000000000000000000000074611761216526013414 0ustar Index: preload-0.6.4/preload.logrotate.in =================================================================== --- preload-0.6.4.orig/preload.logrotate.in 2008-10-23 04:08:20.000000000 +0300 +++ preload-0.6.4/preload.logrotate.in 2012-05-29 22:02:42.136714774 +0300 @@ -4,6 +4,6 @@ size=64k compress postrotate - /bin/kill -HUP `/sbin/pidof preload 2>/dev/null` 2> /dev/null || true + /bin/kill -HUP `/bin/pidof preload 2>/dev/null` 2> /dev/null || true endscript } debian/postrm0000644000000000000000000000050211221603752010431 0ustar #! /bin/sh # postrm script for preload set -e case "$1" in purge) rm /var/log/preload.* || true rm -r /var/lib/preload/ || true ;; remove|upgrade|failed-upgrade|abort-install|abort-upgrade|disappear) ;; *) echo "postrm called with unknown argument \`$1'" >&2 exit 1 esac #DEBHELPER# exit 0 debian/control0000644000000000000000000000133011761216721010572 0ustar Source: preload Section: misc Priority: optional Maintainer: Kari Pahula Build-Depends: cdbs, debhelper (>= 6), libglib2.0-dev (>= 2.14), help2man, dh-autoreconf, lsb-base Standards-Version: 3.9.3 Homepage: http://sourceforge.net/projects/preload Package: preload Architecture: any Depends: ${shlibs:Depends}, ${misc:Depends} Description: adaptive readahead daemon preload monitors applications that users run, and by analyzing this data, predicts what applications users might run, and fetches those binaries and their dependencies into memory for faster startup times. . Note that installing preload will not make your system boot faster and that preload is a daemon that runs with root priviledges. debian/dirs0000644000000000000000000000002111221603752010042 0ustar /var/lib/preload debian/changelog0000644000000000000000000001047411761216132011046 0ustar preload (0.6.4-2) unstable; urgency=low * Use dh-autoreconf. * Standards-Version: 3.9.3 (no changes necessary). * Use source format 3.0 (quilt). * Use LSB log_ functions. (Closes: #673372) * Add init.d status support. (Closes: #645156) * Fix sending HUP in preload's logrotate. (Closes: #619384) -- Kari Pahula Tue, 29 May 2012 21:58:33 +0300 preload (0.6.4-1) unstable; urgency=low * New upstream release (Closes: #495549) * Improve argument handling (Closes: #508809) * Use start-stop-daemon's --iosched option to set idle IO priority, don't patch preload itself to offer an option to use it. * No more patches applied; quilt dropped as a build dep. * Removed code from postinst that used to clean up state file from under /var/cache/. * Standards-Version: 3.8.2 (no changes necessary). -- Kari Pahula Mon, 29 Jun 2009 12:48:22 +0300 preload (0.4-5) unstable; urgency=low * Use quilt patch system. * Patched the source to call ioprio_set. (Closes: #439901) * Install and compress the man page explicitly in debian/rules, to be safe. (Closes: #471623) -- Kari Pahula Wed, 19 Mar 2008 21:42:05 +0200 preload (0.4-4) unstable; urgency=medium * Close the file descriptor when writing state to a file in src/state.c, preload_state_save() (Closes: #415595) -- Kari Pahula Tue, 20 Mar 2007 19:22:06 +0200 preload (0.4-3) unstable; urgency=low * Parse the dev field in /proc/%d/maps as hexadecimal, not as unsigned integer. Thanks to Johan Kiviniemi for the patch. * Sort the readahead file list by device, block and inode and not file path to reduce seeking. Adapted by Johan from a patch for readahead by Scott James Remnant. -- Kari Pahula Fri, 29 Sep 2006 18:02:37 +0300 preload (0.4-2) unstable; urgency=low * Don't include /var/lib/preload/preload.state in the binary package (Closes: #385419) * Use --signal 1 (SIGHUP) to restart the dameon instead of --signal 0 (Closes: #384249) -- Kari Pahula Sun, 10 Sep 2006 12:20:27 +0300 preload (0.4-1) unstable; urgency=low * New upstream release (Closes: #375474) -- Kari Pahula Sat, 5 Aug 2006 03:24:50 +0300 preload (0.2-8) unstable; urgency=low * Removed bashism from debian/rules (Closes: #378357) -- Kari Pahula Mon, 24 Jul 2006 03:26:47 +0300 preload (0.2-7) unstable; urgency=low * Fail successfully with a warning if daemon is already running on init.d start or stopped on init.d stop. (Closes: #368113) * Remove /var/lib/preload/ in postrm purge. (Closes: #368115) -- Kari Pahula Thu, 25 May 2006 02:10:56 +0300 preload (0.2-6) unstable; urgency=low * Remove extra newline from top of postinst (Closes: #363010) -- Kari Pahula Mon, 17 Apr 2006 09:32:50 +0300 preload (0.2-5) unstable; urgency=low * Quote $2 in postinst (Closes: #345776) * Add more information to debian/copyright file (Closes: #362582) * rm depends: sysv-rc | file-rc (silly me). -- Kari Pahula Fri, 14 Apr 2006 15:04:21 +0300 preload (0.2-4) unstable; urgency=low * s/depends: sysv-rc/depends: sysv-rc | file-rc/. The dependency is required because the logrotate script uses invoke-rc.d. (Closes: #344111) -- Kari Pahula Tue, 20 Dec 2005 07:47:38 +0200 preload (0.2-3) unstable; urgency=low * Using s-s-d without its path in logrotate didn't work and just broke it even further. Calling invoke-rc.d preload reload now instead. (Closes: #340983) * s/start-stop-daemon -u 1/start-stop-daemon -u 0/ (argh). -- Kari Pahula Fri, 9 Dec 2005 12:49:08 +0200 preload (0.2-2) unstable; urgency=low * Moved /var/cache/preload.state to /var/lib/preload/preload.state since it's supposed to be persistent. * Use s-s-d without a pidfile in init.d, use s-s-d in logrotate too. Hopefully this will take care of #340983, not closing it yet, though. * Changed most of g_assert calls to g_return_if_fail or g_return_val_if_fail calls, as done in CVS version (Closes: #339644) -- Kari Pahula Tue, 29 Nov 2005 18:11:06 +0200 preload (0.2-1) unstable; urgency=low * Initial release Closes: #337573 -- Kari Pahula Fri, 11 Nov 2005 03:14:33 +0200 debian/copyright0000644000000000000000000000222411222111307011107 0ustar This package was debianized by Kari Pahula on Fri, 11 Nov 2005 02:23:02 +0200. It was downloaded from http://sourceforge.net/projects/preload Copyright (C) 2005-2009 Behdad Esfahbod 2004 Soeren Sandmann 2000 Andrew Henroid 2001 Sun Microsystems License: This package is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This package is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this package; if not, write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA On Debian systems, the complete text of the GNU General Public License can be found in `/usr/share/common-licenses/GPL'. debian/init.d0000644000000000000000000000376611761215507010317 0ustar #! /bin/sh # # preload init.d script ### BEGIN INIT INFO # Provides: preload.sourceforge.net # Required-Start: $local_fs $remote_fs $time # Required-Stop: $local_fs $remote_fs $time # Default-Start: 2 3 4 5 # Default-Stop: 0 1 6 # Short-Description: Adaptive readahead daemon # Description: Analyzes what applications users run and tries to predict # what they would like to run and loads them into memory # beforehand. ### END INIT INFO PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin DAEMON=/usr/sbin/preload NAME=preload DESC="Adaptive readahead daemon" DAEMON_OPTS="-s /var/lib/preload/preload.state $DAEMON_OPTS" . /lib/lsb/init-functions # Include preload defaults if available if [ -f /etc/default/preload ] ; then . /etc/default/preload fi DAEMON_OPTS="$DAEMON_OPTS $OPTIONS" test -x $DAEMON || exit 0 set -e ret=0 case "$1" in start) log_daemon_msg "Starting $DESC" "$NAME" start-stop-daemon --start --quiet -u 0 $PRELOAD_IOSCHED --exec $DAEMON -- $DAEMON_OPTS || ret=$? if [ "$ret" = 1 ]; then log_progress_msg "already running" ret=0 fi log_end_msg $ret ;; stop) log_daemon_msg "Stopping $DESC" "$NAME" start-stop-daemon --stop --retry 1 --quiet -u 0 --exec $DAEMON || ret=$? if [ "$ret" = 1 ]; then log_progress_msg "not running" ret=0 fi log_end_msg $ret ;; reload|force-reload) log_daemon_msg "$DESC" "Reloading configuration files" start-stop-daemon --stop $PRELOAD_IOSCHED --signal 1 --quiet -u 0 --exec $DAEMON || ret=$? log_end_msg $ret ;; restart) log_daemon_msg "Restarting $DESC" "$NAME" start-stop-daemon --stop --oknodo --retry 1 --quiet -u 0 --exec $DAEMON && \ start-stop-daemon --start --quiet -u 0 $PRELOAD_IOSCHED --exec $DAEMON -- $DAEMON_OPTS || ret=$? log_end_msg $ret ;; status) status_of_proc "$DAEMON" "$NAME" && exit 0 || exit $? ;; *) N=/etc/init.d/$NAME log_success_msg "Usage: $N {start|stop|restart|reload|force-reload|status}" >&2 exit 1 ;; esac exit 0