cc3493
Summary: A utility for removing files based on when they were last accessed
cc3493
Name: tmpwatch
cc3493
Version: 2.11
80c008
Release: 6%{?dist}
80c008
URL: https://pagure.io/%{name}
80c008
Source0: https://releases.pagure.org/%{name}/%{name}-%{version}.tar.bz2
cc3493
License: GPLv2
cc3493
Group: System Environment/Base
cc3493
Requires: psmisc
cc3493
Provides: bundled(gnulib)
cc3493
# configure is looking for /sbin/fuser
cc3493
BuildRequires: psmisc
cc3493
cc3493
%description
cc3493
The tmpwatch utility recursively searches through specified
cc3493
directories and removes files which have not been accessed in a
cc3493
specified period of time.  Tmpwatch is normally used to clean up
cc3493
directories which are used for temporarily holding files (for example,
cc3493
/tmp).  Tmpwatch ignores symlinks, won't switch filesystems and only
cc3493
removes empty directories and regular files.
cc3493
cc3493
%prep
cc3493
%setup -q
cc3493
cc3493
%build
80c008
%configure --with-fuser=/usr/sbin/fuser
cc3493
make %{?_smp_mflags}
cc3493
cc3493
%install
cc3493
make DESTDIR=%{buildroot} INSTALL='install -p' install
cc3493
cc3493
mkdir -p %{buildroot}%{_bindir}
cc3493
# The $(...) computes /usr/bin => ../../
cc3493
ln -s $(echo %{_bindir} |sed 's,/[^/]\+,/..,g; s,^/,,')%{_sbindir}/tmpwatch \
cc3493
   %{buildroot}%{_bindir}/tmpwatch
cc3493
cc3493
%files
cc3493
%doc AUTHORS COPYING ChangeLog NEWS README
cc3493
%{_bindir}/tmpwatch
cc3493
%{_sbindir}/tmpwatch
cc3493
%{_mandir}/man8/tmpwatch.8*
cc3493
cc3493
%changelog
80c008
* Mon Feb 18 2019 Jiri Kucera <jkucera@redhat.com> - 2.11-6
80c008
- Added --fuser option support.
80c008
- Fixed bad URL, Source0, and bogus date in spec.
80c008
  Resolves: #1330328
80c008
6f9102
* Fri Jan 24 2014 Daniel Mach <dmach@redhat.com> - 2.11-5
6f9102
- Mass rebuild 2014-01-24
6f9102
6f9102
* Fri Dec 27 2013 Daniel Mach <dmach@redhat.com> - 2.11-4
6f9102
- Mass rebuild 2013-12-27
6f9102
cc3493
* Mon Feb 11 2013 Miloslav Trmač <mitr@redhat.com> - 2.11-3
cc3493
- Drop the cron.daily script, systemd default configuration handles the same
cc3493
  places.
cc3493
  Resolves: #906455
cc3493
cc3493
* Tue Aug 21 2012 Miloslav Trmač <mitr@redhat.com> - 2.11-3
cc3493
- Drop no longer necessary %%clean and %%defattr commands.
cc3493
cc3493
* Sat Jul 21 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.11-2
cc3493
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
cc3493
cc3493
* Fri May 25 2012 Miloslav Trmač <mitr@redhat.com> - 2.11-1
cc3493
- Update to tmpwatch-2.11.
cc3493
  Resolves: #694838
cc3493
cc3493
* Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.10.3-2
cc3493
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
cc3493
cc3493
* Tue Jul 19 2011 Miloslav Trmač <mitr@redhat.com> - 2.10.3-1
cc3493
- Update to tmpwatch-2.10.3.
cc3493
  Resolves: #722856
cc3493
cc3493
* Thu Mar 31 2011 Miloslav Trmač <mitr@redhat.com> - 2.10.2-1
cc3493
- Update to tmpwatch-2.10.2.
cc3493
  Resolves: #585216
cc3493
cc3493
* Wed Feb 09 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.10-4
cc3493
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
cc3493
cc3493
* Fri Feb  4 2011 Miloslav Trmač <mitr@redhat.com> - 2.10-3
cc3493
- Add Provides: bundled(gnulib)
cc3493
cc3493
* Sat Aug  7 2010 Miloslav Trmač <mitr@redhat.com> - 2.10-2
cc3493
- Document --exclude-pattern in more places
cc3493
  Related: #527425
cc3493
cc3493
* Tue Mar 23 2010 Miloslav Trmač <mitr@redhat.com> - 2.10-1
cc3493
- Update to tmpwatch-2.10.
cc3493
- Drop no longer neceessary references to BuildRoot:
cc3493
cc3493
* Mon Feb  1 2010 Miloslav Trmač <mitr@redhat.com> - 2.9.17-2
cc3493
- Ship COPYING
cc3493
  Resolves: #560690
cc3493
cc3493
* Tue Dec 22 2009 Miloslav Trmač <mitr@redhat.com> - 2.9.17-1
cc3493
- Update to tmpwatch-2.9.17.
cc3493
  Resolves: #548932
cc3493
cc3493
* Thu Oct 15 2009 Miloslav Trmač <mitr@redhat.com> - 2.9.16-1
cc3493
- Update to tmpwatch-2.9.16.
cc3493
- Exclude /tmp/hsperfdata_*.
cc3493
  Resolves: #527425
cc3493
- Preserve timestamps where possible.
cc3493
cc3493
* Sun Jul 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.9.15-2
cc3493
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
cc3493
cc3493
* Fri May 22 2009 Miloslav Trmač <mitr@redhat.com> - 2.9.15-1
cc3493
- Update to tmpwatch-2.9.15.
cc3493
- Add a symlink to %%{_bindir}.
cc3493
  Resolves: #494239
cc3493
cc3493
* Mon Mar 23 2009 Miloslav Trmač <mitr@redhat.com> - 2.9.14-1
cc3493
- Update to tmpwatch-2.9.14.
cc3493
cc3493
* Wed Feb 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.9.13-3
cc3493
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
cc3493
cc3493
* Sat Feb 23 2008 Miloslav Trmač <mitr@redhat.com> - 2.9.13-2
cc3493
- Package the new documentation files.
cc3493
cc3493
* Sat Feb 23 2008 Miloslav Trmač <mitr@redhat.com> - 2.9.13-1
cc3493
- New home page at https://fedorahosted.org/tmpwatch/ .
cc3493
- tmpwatch is now licensed under GPLv2.
cc3493
- Address issues from reviews by Adel Gadllah and Jason Tibbitts:
cc3493
  - Run (make) with %%{?_smp_mflags}
cc3493
  - Add a comment describing the origin of the tarball to the spec file
cc3493
  - Use a better BuildRoot:
cc3493
cc3493
* Tue Feb 19 2008 Fedora Release Engineering <rel-eng@fedoraproject.org> - 2.9.12-3
cc3493
- Autorebuild for GCC 4.3
cc3493
cc3493
* Fri Dec 14 2007 Miloslav Trmač <mitr@redhat.com> - 2.9.12-2
cc3493
- --atime is -u.  Doh.
cc3493
cc3493
* Fri Dec 14 2007 Miloslav Trmač <mitr@redhat.com> - 2.9.12-1
cc3493
- Fix --nosymlinks description in the man page
cc3493
- Use the maximum of atime, mtime and ctime when checking whether a file is
cc3493
  obsolete
cc3493
  Resolves: #373301
cc3493
cc3493
* Tue Oct 16 2007 Miloslav Trmač <mitr@redhat.com> - 2.9.11-2
cc3493
- Update License:
cc3493
cc3493
* Sat Mar 31 2007 Miloslav Trmac <mitr@redhat.com> - 2.9.11-1
cc3493
- Fix a misleading message in --test
cc3493
  Resolves: 234596
cc3493
- Compress the tarball using bzip2
cc3493
- Move the cron.daily script to a separate source file
cc3493
cc3493
* Sun Nov  5 2006 Miloslav Trmac <mitr@redhat.com> - 2.9.10-1
cc3493
- Reallow --exclude with nonexistent paths
cc3493
  Resolves: 214034
cc3493
cc3493
* Thu Nov  2 2006 Miloslav Trmac <mitr@redhat.com> - 2.9.9-1
cc3493
- Exclude aquota.group and aquota.user files
cc3493
  Resolves: 206258
cc3493
- Don't require the user-specified paths to be absolute
cc3493
cc3493
* Wed Nov  1 2006 Miloslav Trmac <mitr@redhat.com> - 2.9.8-1
cc3493
- Add optional unit suffix to the "hours" (now "time") parameter (original
cc3493
  patch by Alan J Rosenthal <flaps@dgp.toronto.edu>)
cc3493
- Fix some format string vs. arguments mismatches
cc3493
- Fix some rpmlint warnings
cc3493
cc3493
* Wed Jul 12 2006 Jesse Keating <jkeating@redhat.com> - 2.9.7-1.1
cc3493
- rebuild
cc3493
cc3493
* Sat May  6 2006 Miloslav Trmac <mitr@redhat.com> - 2.9.7-1
cc3493
- Add --nosymlinks (#190691)
cc3493
cc3493
* Fri Feb 10 2006 Jesse Keating <jkeating@redhat.com> - 2.9.6-1.2.1
cc3493
- bump again for double-long bug on ppc(64)
cc3493
cc3493
* Tue Feb 07 2006 Jesse Keating <jkeating@redhat.com> - 2.9.6-1.2
cc3493
- rebuilt for new gcc4.1 snapshot and glibc changes
cc3493
cc3493
* Fri Dec 09 2005 Jesse Keating <jkeating@redhat.com>
cc3493
- rebuilt
cc3493
cc3493
* Tue Nov 29 2005 Miloslav Trmac <mitr@redhat.com> - 2.9.6-1
cc3493
- Add --exclude-user (original patch by Brett Pemberton)
cc3493
- Fix too long line in /etc/cron.daily/tmpwatch
cc3493
cc3493
* Fri Nov 11 2005 Miloslav Trmac <mitr@redhat.com> - 2.9.5-1
cc3493
- Fix GPL reference in usage message (#163531, patch by Ville Skyttä)
cc3493
- Convert changelog to UTF-8
cc3493
cc3493
* Mon Jun 20 2005 Miloslav Trmac <mitr@redhat.com> - 2.9.4-1
cc3493
- Add --dirmtime (#91096)
cc3493
- Handle fchdir () failures
cc3493
cc3493
* Sat Apr 16 2005 Miloslav Trmac <mitr@redhat.com> - 2.9.3-1
cc3493
- Silently ignore ENOENT if somebody removes files faster than us (#154960)
cc3493
- Handle failures to exec fuser
cc3493
- Fix check for negative grace periods
cc3493
cc3493
* Sat Mar  5 2005 Miloslav Trmac <mitr@redhat.com> - 2.9.2-2
cc3493
- Rebuild with gcc 4
cc3493
cc3493
* Wed Dec 22 2004 Miloslav Trmac <mitr@redhat.com> - 2.9.2-1
cc3493
- Mention skipping of lost+found in the man page (#143526)
cc3493
cc3493
* Sat Aug 14 2004 Miloslav Trmac <mitr@redhat.com> - 2.9.1-1
cc3493
- Add --exclude, use it to preserve X socket directories (#107069)
cc3493
- Allow multiple directory arguments with relative paths (#91097)
cc3493
- Don't manually strip the binary
cc3493
cc3493
* Fri May 30 2003 Mike A. Harris <mharris@redhat.com> 2.9.0-1
cc3493
- Added Solaris/HPUX support to tmpwatch via patch from Paul Gear (#71288)
cc3493
- Rebuild in rawhide as 2.9.0-1
cc3493
cc3493
* Mon Feb 10 2003 Nalin Dahyabhai <nalin@redhat.com> 2.8.4-5
cc3493
- rebuild
cc3493
cc3493
* Fri Feb  7 2003 Nalin Dahyabhai <nalin@redhat.com> 2.8.4-2
cc3493
- rebuild
cc3493
cc3493
* Tue Oct  8 2002 Mike A. Harris <mharris@redhat.com> 2.8.4-4
cc3493
- All-arch rebuild
cc3493
cc3493
* Fri Jun 21 2002 Tim Powers <timp@redhat.com>
cc3493
- automated rebuild
cc3493
cc3493
* Sun May 26 2002 Tim Powers <timp@redhat.com>
cc3493
- automated rebuild
cc3493
cc3493
* Tue May 21 2002 Mike A. Harris <mharris@redhat.com> 2.8.4-1
cc3493
- Bump release and rebuild in new environment
cc3493
80c008
* Sat Apr 13 2002 Mike A. Harris <mharris@redhat.com> 2.8.3-1
cc3493
- Added support for large files with 64bit offsets by adding to CFLAGS
cc3493
  -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 bug (#56961)
cc3493
cc3493
* Sun Jan 27 2002 Mike A. Harris <mharris@redhat.com> 2.8.2-1
cc3493
- Added newlines to logfile messages as per bug #58912
cc3493
cc3493
* Thu Nov  8 2001 Preston Brown <pbrown@redhat.com>
cc3493
- define default SBINDIR in Makefile
cc3493
- incorrect boolean comparison fix
cc3493
cc3493
* Wed Aug 29 2001 Preston Brown <pbrown@redhat.com>
cc3493
- cron script fix (#52785)
cc3493
cc3493
* Tue Aug 28 2001 Preston Brown <pbrown@redhat.com>
cc3493
- rebuild for 5.x, 6.x, 7.x errata
cc3493
cc3493
* Mon Aug 27 2001 Preston Brown <pbrown@redhat.com>
cc3493
- noreplace /etc/cron.daily/tmpwatch
cc3493
cc3493
* Mon Aug  6 2001 Preston Brown <pbrown@redhat.com> 2.8-1
cc3493
- added a "nodirs" option which inhibits removal of empty directories.
cc3493
- Integrated race condition fixes from Martin Macok (#50148)
cc3493
- do not try to remove ext3 journal files (#50522)
cc3493
cc3493
* Tue Jul  3 2001 Preston Brown <pbrown@redhat.com> 2.7.4-1
cc3493
- fix typo in cron script
cc3493
cc3493
* Mon Jul  2 2001 Preston Brown <pbrown@redhat.com>
cc3493
- better checking for directory existence cleaning man cache dirs (#44117)
cc3493
cc3493
* Fri May 11 2001 Trond Eivind Glomsrød <teg@redhat.com>
cc3493
- Handle directories with large files
cc3493
- fix some warnings during compilation
cc3493
cc3493
* Thu Mar 29 2001 Preston Brown <pbrown@redhat.com>
cc3493
- fixed longstanding bug where directories removed while in test mode.
cc3493
cc3493
* Fri Mar  9 2001 Preston Brown <pbrown@redhat.com>
cc3493
- Patch from enrico.scholz@informatik.tu-chemnitz.de allows concurrent 
cc3493
  usage of mtime, ctime, and atime checking (#19550).
cc3493
cc3493
* Fri Jan 05 2001 Preston Brown <pbrown@redhat.com>
cc3493
- increased interval for removal to 30 days for /var/tmp per FHS (#19951)
cc3493
cc3493
* Tue Sep 12 2000 Nalin Dahyabhai <nalin@redhat.com>
cc3493
- use execle() instead of system() to get the correct return code, fixes from
cc3493
  Jeremy Katz <katzj@linuxpower.org>
cc3493
cc3493
* Thu Sep  7 2000 Nalin Dahyabhai <nalin@redhat.com>
cc3493
- rework to not have to fork() (#17286)
cc3493
- set utime() after we're done reading a directory
cc3493
cc3493
* Sat Jun 17 2000 Matt Wilson <msw@redhat.com>
cc3493
- defattr
cc3493
cc3493
* Tue Jun 13 2000 Preston Brown <pbrown@redhat.com>
cc3493
- FHS compliance
cc3493
cc3493
* Thu May 18 2000 Preston Brown <pbrown@redhat.com>
cc3493
- don't complain about failure to remove non-empty directories.
cc3493
- fix man page path
cc3493
cc3493
* Wed May 17 2000 Preston Brown <pbrown@redhat.com>
cc3493
- support /var/cache/man and /var/catman (FHS 2.1 compliance).
cc3493
cc3493
* Fri May 05 2000 Preston Brown <pbrown@redhat.com>
cc3493
- support for CTIME from jik@kamens.brookline.ma.us
cc3493
- fixes for fuser checks from Ian Burrell <iburrell@digital-integrity.com>.
cc3493
- remove directories when empty without --all flag, to be consistent w/docs.
cc3493
cc3493
* Mon Feb 14 2000 Preston Brown <pbrown@redhat.com>
cc3493
- option to use fuser to see if file in use before removing
cc3493
cc3493
* Wed Feb 02 2000 Cristian Gafton <gafton@redhat.com>
cc3493
- fix description
cc3493
- man pages are compressed
cc3493
cc3493
* Tue Jan 18 2000 Preston Brown <pbrown@redhat.com>
cc3493
- null terminal opt struct (#7836)
cc3493
- test flag implies verbose (#2383)
cc3493
cc3493
* Wed Jan 12 2000 Paul Gear <paulgear@bigfoot.com>
cc3493
- HP-UX port (including doco update)
cc3493
- Tweaked Makefile to allow installation into different base directory
cc3493
- Got rid of GETOPT_... defines which didn't do anything, so that short
cc3493
  equivalents for all long options could be defined.
cc3493
- Fixed bug in message() where 'where' file handle was set but unused
cc3493
- Changed most fprintf() calls to message()
cc3493
cc3493
* Mon Aug 30 1999 Preston Brown <pbrown@redhat.com>
cc3493
- skip lost+found directories
cc3493
- option to use file's atime instead of mtime (# 4178)
cc3493
cc3493
* Mon Jun  7 1999 Jeff Johnson <jbj@redhat.com>
cc3493
- cleanup more man pages, this time adding in cvs (#224).
cc3493
cc3493
* Thu Apr 08 1999 Preston Brown <pbrown@redhat.com>
cc3493
- I am the new maintainer
cc3493
- fixed cleanup of directories
cc3493
- added --quiet flag
cc3493
- freshen manpage
cc3493
- nice patch from Kevin Vajk <kvajk@ricochet.net> integrated
cc3493
cc3493
* Wed Jun 10 1998 Erik Troan <ewt@redhat.com>
cc3493
- make /etc/cron.daily/tmpwatch executable
cc3493
cc3493
* Tue Jan 13 1998 Erik Troan <ewt@redhat.com>
cc3493
- version 1.5
cc3493
- fixed flags passing
cc3493
- cleaned up message()
cc3493
cc3493
* Wed Oct 22 1997 Erik Troan <ewt@redhat.com>
cc3493
- added man page to package
cc3493
- uses a buildroot and %%attr
cc3493
- fixed error message generation for directories
cc3493
- fixed flag propagation
cc3493
cc3493
* Mon Mar 24 1997 Erik Troan <ewt@redhat.com>
cc3493
- Don't follow symlinks which are specified on the command line
cc3493
- Added a man page
cc3493
cc3493
* Sun Mar 09 1997 Erik Troan <ewt@redhat.com>
cc3493
- Rebuilt to get right permissions on the Alpha (though I have no idea
cc3493
  how they ended up wrong).