summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTomáš Chvátal <tomas.chvatal@gmail.com>2014-12-01 14:21:06 +0100
committerJan Kara <jack@suse.cz>2014-12-02 14:21:56 +0100
commitbab3fa397dd3f6c932a272cedde79d175c667910 (patch)
tree6062cf2122f5b469bc7174abaaa29f0e8c6d9a01
parent204620858132006a77ba8df1bff04861b058b31b (diff)
downloadlinuxquota-bab3fa397dd3f6c932a272cedde79d175c667910.tar.gz
Create new autotools buildsystem
Reflect what was done before and try to mimic it Remove ChangeLog, now autogenerated for dist target Remove confusing gettext README and try to add new approach for translations [JK: Fixed build without RPC support] Signed-off-by: Tomáš Chvátal <tchvatal@suse.cz> Signed-off-by: Jan Kara <jack@suse.cz>
-rw-r--r--.gitignore43
-rw-r--r--Changelog956
-rw-r--r--Makefile.am262
-rw-r--r--Makefile.in165
-rw-r--r--README.gettext21
-rwxr-xr-xautogen.sh2
-rw-r--r--common.c2
-rw-r--r--common.h2
-rw-r--r--config.h.in34
-rw-r--r--configure.ac273
-rw-r--r--configure.in253
-rw-r--r--convertquota.c2
-rw-r--r--edquota.c2
-rwxr-xr-xinstall-sh251
-rw-r--r--po/.gitignore13
-rw-r--r--po/LINGUAS1
-rw-r--r--po/Makevars41
-rw-r--r--pot.c4
-rw-r--r--quota.c2
-rw-r--r--quotacheck.c4
-rw-r--r--quotasync.c3
-rw-r--r--repquota.c2
-rw-r--r--setquota.c2
-rw-r--r--warnquota.c34
24 files changed, 675 insertions, 1699 deletions
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 0000000..940fd41
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,43 @@
+m4/
+aclocal.m4
+ar-lib
+autom4te.cache/
+compile
+configure
+install-sh
+missing
+*~
+*.bak
+config.h
+config.log
+config.guess
+config.rpath
+config.sub
+config.status
+mkinstalldirs
+ABOUT-NLS
+depcomp
+*.in
+Makefile
+stamp-h1
+.deps
+ChangeLog
+rquota.c
+rquota.h
+*.o
+rquota_clnt.c
+convertquota
+edquota
+quot
+quota
+quotacheck
+quotaon
+quotastats
+quotasync
+repquota
+rpc.rquotad
+setquota
+warnquota
+xqmstats
+libquota.a
+librpcclient.a
diff --git a/Changelog b/Changelog
deleted file mode 100644
index b4356b0..0000000
--- a/Changelog
+++ /dev/null
@@ -1,956 +0,0 @@
-Changes in quota-tools from 4.01 to 4.02
-* Remove KERN_KNOWN_QUOTA_VERSION (Jan Kara)
-* Skip NFS mounts without rquotad RPC service silently (Petr Písař)
-* Fix handling of space and inode values (Jan Kara)
-* Update polish translation (Jakub Bogusz)
-* warnquota: Use LDAP for looking up CC value as well (Jan Kara)
-* Prevent from grace period overflow in RPC transport (Petr Písař)
-* Do not document location of quotaon and quotaoff (Petr Písař)
-* Properly handle signed space and inode values (Jan Kara)
-* respect CFLAGS in linking command wrt #446281 (Julian Ospald)
-* Explain in quota(1) manpage what 'blocks' in the output mean (Jan Kara)
-* __cpu_to_le16 --> htole16 (Cristian Rodríguez)
-* Use libc byteswapping routines not kernel ones (Cristian Rodríguez)
-* quota_nld: Fix compilation warning (Jan Kara)
-* quota_nld: Fix usage of netlink multicast groups (Jan Kara)
-* Improve rpc.rquota(8) manual page (Petr Písař)
-* Add warnquota.conf(5) manual page (Petr Písař)
-* Add quotatab(5) manual page (Petr Písař)
-* Add quotagrpadmins(5) manual page (Petr Písař)
-* Silent a set-but-not-used warning about sbflags (Petr Písař)
-* Add support for CVS and XML output formats to repquota(8) (Jan Kara)
-* Remove installation of manpages into section 2 (Carsten Grohmann)
-* Close FILE handles on error (Petr Písař)
-* Add AC_PREREQ to configure.in (Theodore Ts'o)
-* Fix various usage mistakes (Petr Písař)
-* Correct quotasync exit code (Petr Písař)
-* Complete quotasync usage (Petr Písař)
-* Add quotasync(1) manual page (Petr Písař)
-* quotacheck: Make sure -d provides at least as much information as -v (Jan Kara)
-* Do not fiddle with quota files on XFS and GFS (Petr Písař)
-* Recognize units at inode limits by edquota (Petr Písař)
-* Recognize units at inode limits by setquota (Petr Písař)
-* Recognize units at block limits by edquota (Petr Písař)
-* Recognize block limit units on setquota standard input (Petr Písař)
-* Recognize units at block limits by setquota (Petr Písař)
-* Fix compilation without RPC support (Jan Kara)
-* Make group warning message more official (Petr Písař)
-* Updated Czech translation (Petr Písař)
-* warnquota: Use current locale as default charset (Jan Kara)
-* warnquota: Add MIME-Version header (Jan Kara)
-
-Changes in quota-tools from 4.00 to 4.01
-* fix compilation failure with --enable-bsd_behaviour=no (Jan Kara)
-* fix quota(1) for NFS mountpoints (Jan Kara)
-* fix reporting of huge quota limits over rpc (Jan Kara)
-* fix repquota to report all users on XFS (Jan Kara)
-* fixed edquota(8) for more users (Jan Kara)
-* remove fixed limit on number of autofs mount points (Jan Kara)
-* add quota type names to message catalogue (Jan Kara)
-* typo fixes, message changes for easier i18n (Jan Kara)
-* created Czech translation (Petr Pisar)
-* store PID of quota_nld into lock file (Petr Pisar)
-* warnquota: Fix manpage formatting (Jan Kara)
-* warnquota: Allow specifying of filesystems to check (Jan Kara)
-* add support for quotas on ext4 in system files (Jan Kara)
-* quotaon: Remove duplicated check for hasquota() (Jan Kara)
-* quotacheck: Fix warning about journaled quota for 3.0 and newer kernels (Jan Kara)
-* edquota: Fix localication of time units (Jan Kara)
-* rip out ALTFORMAT config option (Jan Kara)
-* add support for dynamic RPC block to support larger quotas (Petr Pisar)
-* check set limits fit into the range supported by RPC transport (Petr Pisar)
-* do not report missing utmp record to syslog (Petr Pisar)
-
-Changes in quota-tools from 4.00-pre1 to 4.00
-* get_qf_name() does not check quota file presence (Petr Pisar)
-* report quotacheck failures by return code (Petr Pisar)
-* make global symbols static as possible (Petr Pisar)
-* implement repquota for filesystems without quota files (Jan Kara)
-* initialize v2r1 ddquot padding in dump (Jan Kara)
-* fix ddquot buffer leak (Petr Pisar)
-* fix check in setgraces() in setquota.c (Petr Pisar)
-* forbid grace time setting over RPC (Jan Kara)
-* fix synopsis and properly report errors during remote grace period setting (Jan Kara)
-* do not use real domains in warnquota example (Petr Pisar)
-* make RPC handle properly host names with colons (Jan Kara)
-* explain meaning of the second column in repquota output (Jan Kara)
-* initialize vfsold block and inode value boundaries for new quota file (Petr Pisar)
-* setquota manpage typo fix (John Bradshaw)
-* implement quotacheck for GFS2 (Abhijith Das)
-* add quotasync tool (Abhijith Das)
-* correct --no-mixed-pathnames documentation (Petr Pisar)
-* allow admin to not strip quota binaries while installing them (Jan Kara)
-* document --always-resolve at edquota and setquota (Petr Pisar)
-* comment example quotatab to silent warnquota (Petr Pisar)
-* improve comments in warnquota.conf (Ondrej Vasik)
-* fix help text for quotaoff (Ondrej Vasik)
-* make quota, setquota, and edquota recognize -h option (Ondrej Vasik)
-* check whether set limits fit into range supported by quota format (Jan Kara)
-* add next3 support (Amir G)
-* remove checking of filesystem type from hasquota() (Jan Kara)
-* create quota-nfs.sh script for nicer quota(1) output formatting on some NFS clients (Jan Kara)
-* add options for quota(1) modifying formatting of filesystem identificaion (Jan Kara)
-* minor updates of manpages (Jan Kara)
-* quotactl manpage was moved to man-pages package (Jan Kara)
-* fix quotaon to work properly with XFS filesystems (Eric Sandeen, Jan Kara)
-* fix quotaon to print all informational messages only in verbose mode (Jan Kara)
-* fix warnquota manpage to not speak about RPC (Jan Kara)
-* fix repquota to get latest quota info header (Jan Kara)
-* do not count system inodes into quota for ext[234] (Jan Kara)
-* improve detection of XFS kernel quota interface (Jan Kara)
-* support of GFS2 filesystem (Christoph Hellwig)
-* avoid memory corruption of NULL address (Petr Pisar)
-* fixup typos in manpages (Michael Meskes)
-* added german translation (Michael Bunk)
-* added --enable-static-link configure option (Jan Kara)
-
-Changes in quota-tools from 3.17 to 4.00-pre1
-* don't try to set inode flags when getting them failed (Michalski Wojciech)
-* added liblber to the list of libraries needed for LDAP support (Michael Meskes)
-* Rewritten configuration script to create config.h (Jan Kara)
-* Use /proc/mounts for mountpoint scanning (Jan Kara)
-* Removed use of reserved identifiers (Jan Kara)
-* Improved manpage of quota_nld (Eddie Eyles)
-* Fixed long option handling of quota_nld (Jan Kara)
-* Fixed error reporting when rpc format specified on command line (Jan Kara)
-* Convert quota limits using rq_bsize from RPC request (Jan Kara)
-* Added noreturn attribute to die to avoid false warnings (Jan Kara)
-* 64-bit quota support, rewritten some code to allow clean integration (Jan Kara)
-* Improved header of quota an repquota output when -s option is used (Jan Kara)
-* Fixed mountpoint scanning when NFS mountpoint is specified on command line (Jan Kara)
-* Updated manpage of quotactl(2) (Jan Kara)
-
-Changes in quota-tools from 3.16 to 3.17
-* Updated quotactl(2) manpage to mention possible ERANGE error (Jan Kara)
-* Fix hostname checking of rpc.rquotad. It could allow access even though hostname was in /etc/hosts.deny (Jan Kara)
-* do not allow setting of user's grace time when softlimit is not exceeded (Jan Kara)
-* fix reference to rpc manpage (anonymous reporter)
-* add EXT4 (not only EXT4DEV) to the list of supported filesystems (Mingming Cao)
-* fix setting of more than 31-bit block and inode limits (Gui Xiaohua)
-* fixed bug in error reporting when quota reading fails (Jan Kara)
-* added support for quota formats with hidden quota files (Jan Kara)
-* remove IMMUTABLE flag from quota file in quotacheck (Jan Kara)
-* fix bug in warnquota which could result in bogus hostname and domainname (anonymous reporter)
-* implemented writing of messages that user got below hard/soft limits to quota_nld (Jan Kara)
-* use PKG_CHECK_MODULES to check for DBUS (Ladislav Michnovic)
-* Implement setting of charset for emails sent by warnquota (Michael Meskes)
-* Added quota_nld to the list of installed programs (Jan Kara)
-* some typos fixes (Matthew Boyle)
-* fixed possible segfault when unpriviledged user run edquota (Matthew Boyle)
-* fixed format strings to use "%llu" and "%lld" instead of "%Lu" and "%Ld" (Ladislav Michnovic)
-* removed ssl, resolv, lber from the list of LDAP libraries since we don't need them directly (Jan Kara)
-* added limits.h include to quota_nld (Jan Kara)
-* fixed repquota to work with limits over 4 TB (Jan Kara, Michael Meier)
-
-Changes in quota-tools from 3.15 to 3.16
-* added information message about journaled quota to quotacheck (Jan Kara, Alex Tomas)
-* added pointers to quota_nld and warnquota to some manpages (Jan Kara)
-* ported quota_nld to libnl-1.1 (Jan Kara)
-* let setquota batch mode accept comments and blank lines, add -c option (Jacky Bruno, Jan Kara)
-* print more verbose list of compile options when --version specified (Jan Kara)
-* quotaon(8) should work only on local filesystems (Ladislav Michnovic)
-* made possible to use quota rpc in mixed NFSv3 and NFSv4 environments (Jan Kara)
-* fixed compilation with openLDAP library versions 2.1 and 2.2 (Jan Kara)
-* always define allow_severity and deny_severity for older versions of libwrap (Martin Jacobs)
-* cleaned up host_access() handling (Jan Kara)
-* configure script now correctly reports checking of libwrap (Jan Kara)
-* added MPFS to the list of supported filesystems (Dave Boone)
-* all binaries are now stripped during installation (Jan Kara)
-* updated Polish translations (Jakub Bogusz)
-* fixed typo in a quotaon message (Jakub Bogusz)
-* fixed warnquota to check URI only if LDAP enabled (Michael Meskes)
-
-Changes in quota-tools from 3.14 to 3.15
-* added a wrapper script around setquota which also updates LDAP (Stefan Adams)
-* implemented quota netlink daemon to listen to kernel netlink messages and send them
- to DBUS and / or write them to the console (Jan Kara)
-* modified configure scripts and warnquota to check for new LDAP library and allow use of URI (Jan Kara)
-* fix LDAP scripts to set VISUAL instead of EDITOR (Michael Meskes)
-* added ext4 filesystem to the list of supported filesystems (Jan Kara)
-* pot.o is now compiled with CFLAGS (Ladislav Michnovic)
-* use -fPIE for compilation when available (Jan Kara, Ladislav Michnovic)
-* fixed some more problems XFS quotaon (Kouta Ooizumi, Jan Kara)
-* fixed two mistakes in quotaon(8) manpage (Utako Kusaka)
-* added option -A to quota(1) to report all NFS mountpoints (Jan Kara)
-* fixed XFS handling to work with loopback mounted devices (Jan Kara)
-* fixed mountpoints scanning to make XFS -x delete command work (Jan Kara)
-* fixes of signed vs unsigned int issues (Jan Kara)
-* fixed a format string bug in reporting of raw grace times in repquota (Jan Kara)
-* added repquota(8) and quota(1) option for better parsable output (Jan Kara)
-* fixed error handling in edquota(8) when creating tmp file (Jan Kara)
-
-Changes in quota-tools from 3.13 to 3.14
-* updated Polish translations (Jakub Bogusz)
-* print user/group names in error messages when cannot get quota information (Michal Marek, Jan Kara)
-* added option --always-resolve to force resolving even names with digits only (Jan Kara)
-* minor language corrections in manpages (Jan Kara)
-* implemented long options parsing for all quota tools (Jan Kara)
-* quota(1) has -f option to specify filesystem list (Jan Kara)
-* corrected some informal language in messages (Jan Kara)
-* we cannot even stat NFS mounts in local mode as server may be unreachable (Jan Kara)
-* fixed error messages in getprivs() (Jan Kara, Brian Morris)
-* made UID/GID prints unsigned (Matthew Kent)
-* fixed very verbose printing for quotacheck (Jan Kara)
-* fixed off-by-one bug in mount options parsing (Jan Kara)
-* implemented nicer message formatting for warnquota(8) (Jan Kara)
-* quota(1) has -w option to supress line wrapping for long device names (Jan Kara)
-* quota(1) prints grace time even if hard limit is reached (Jan Kara)
-* fixed journaled quota format detection in quotacheck (Jan Kara)
-
-Changes in quota-tools from 3.12 to 3.13
-* fixed mistakes in several error messages, improved error reporting functions
- (Dmitry V. Levin)
-* volume label and UUID support for reiserfs (Jan Kara)
-* support for LABEL= and UUID= on a command line (Jan Kara)
-* parse NFSD export table to find pseudofilesystem root for NFSv4 (Jan Kara)
-* handle better when quota file should become empty (Niu YaWei)
-* minor manpage and help-text fixes (Jan Kara)
-* fixed quotacheck(8) to check each block only once (Jan Kara)
-* fixed quotacheck(8) messages about corrupted blocks (Jan Kara)
-* fixed quotacheck(8) to rename quota files after turning quotas off (Jan Kara)
-* added sanity check to quota reporting (Jan Kara)
-* fixed check for illegal references in quotacheck(8) (Jan Kara)
-* added NFSv4 to the list of supported fs types (Jan Kara)
-* updating of progress is now less frequent - should speedup quotacheck -v a bit (Jan Kara)
-* added printing of directories to quotacheck(8) (Jan Kara, Jan Engelhardt)
-* added dynamic mountpoint array allocation (Jan Kara)
-* made quotacheck(8) more friendly to journaled quota (Jan Kara)
-* changed configure to detect whether nls is needed (Tomasz Kloczko, Jan Kara)
-* added JFS into a set of supported filesystems (David Kleikamp)
-* added French translation (Jerome Schell)
-* fixed quota tools to set of grace time only after exceeding soft limit, not
- at reaching (Jan Kara)
-* fixed exit codes of setquota(8) and edquota(8) (Jan Kara)
-* updated Polish translations (Jakub Bogusz)
-* fixed "bashism" is Makefile (Michael Meskes)
-
-Changes in quota-tools from 3.11 to 3.12
-* fixed bug in quotaon(8) reporting (Paul Szabo)
-* added manpages for xqmstats & quotastats (Max Vozeler)
-* fixed a few memleaks (Jan Kara)
-* fixed bug when root had no usage and limits (Jan Kara)
-* added a few perl wrappers for LDAP (Stefan Adams)
-* added note about availability of -r option to manpages (Jan Kara)
-* maximal number of groups is now got via sysconf (Nathan Scott)
-* added batch mode to the setquota(8) (Jan Kara)
-* added reference to setquota(8) to manpages of other tools (Jan Kara)
-* fixed bug in --port option of rquotad (Max Kalika)
-* updated quota documentation (Jan Kara)
-* disabling nls via configure (Jan Kara)
-* fixed warning when gettext not used (Peter Breitenlohner)
-* fixed typo in rquotad.8 (Peter Breitenlohner)
-* fixed compiler warning in quotacheck.c (Peter Breitenlohner)
-* added config option for putting some important binaries to /sbin regardless
- $(prefix) (Jan Kara)
-* added config option to warnquota(8) for CCing admin only specified amount of
- time before grace time runs out (Jan Kara)
-
-Changes in quota-tools from 3.10 to 3.11
-* quota-tools should again use old RPC protocol when needed (Jan Kara)
-* add FIOQSIZE for x84_64 architecture (Jan Kara)
-* quotacheck(8) does not count quota files to usage (Jan Kara)
-* tools now honor journalled quota mount options (Jan Kara)
-* manpage of repquota(8) stated falsely that repquota works over RPC (Jan Kara)
-* added -T flag to quot(8) to avoid truncation of names (Andre Nathan)
-* added -q flag to quot(8) to avoid sorting of names (Andre Nathan)
-* added #include <paths.h> in quotasys.c to avoid compile problems on some systems (Jan Kara)
-* changed detection of filesystem to be able to parse comma separated list (Jan Kara)
-* fixed bug in quotacheck(8) which counted wrongly files larger than 2GB (Posta Zoltan)
-* fixed compile problem with quotacheck and new kernels (Michael Meskes, Jan Kara)
-* fixed typo in quotacheck manpage (Noel Koethe)
-* warnquota(8) can get mail addresses via LDAP (James Bourne)
-* warnquota(8) can avoid sending e-mail when user is over quota on mail partition (James Bourne)
-* fixed bug in quotacheck(8) which counted directories twice sometimes (Jan Kara)
-* edquota(8) now allows parameters in VISUAL/EDITOR env. params (Jan Kara)
-* reverted changes in detection of kernel from 3.10 - interface obsoleted in 2.6 kernel (Jan Kara)
-
-Changes in quota-tools from 3.09 to 3.10
-* alternative port can be specified to rpc.rquotad by -p option (Jan Kara)
-* Fixed processing of device-backed loop mounts (Jari Ruusu)
-* Fixed fake error messages from rpc.rquotad (Jan Kara)
-* quota(1) now does not print info for NFS filesystems without quotas (Jan Kara)
-* XFS roothack option disabled by default (Nathan Scott)
-* added option to warnquota(8) to supress details of report (Marco van Wieringen)
-* fixed problems with multiple lines values in warnquota(8) (F. Depke)
-* changed detection of kernel interface so that it works even without /proc (Jan Kara, Johan Ekenberg)
-* updated Polish messages (Jakub Bogusz)
-* updated quotactl(2) manpage (Jan Kara)
-* fixed bug in -f option of edquota(8) (Jan Kara)
-* fixed formatting bug in warnquota(8) (Jan Kara)
-* added option -s (choice of more appropriate units) to warnquota(8) (Jan Kara)
-
-Changes in quota-tools from 3.08 to 3.09
-* minor update of quota(1) manpage (Jan Kara)
-* quotacheck(8) now remembers only hardlinked files and not all inodes with
- n_link > 1 (Jan Kara, Jan Kasprzak)
-* quotacheck(8) doesn't store structures for all users in old quota format (Jan Kasprzak)
-* fixed minor bug in documentation (Jan Kara, Lucas Brasilino)
-* repquota(8) handles multiple entries in /etc/passwd better (Jan Kara)
-* made tools not to touch mountpoints mounted without quota options (Jan Kara)
-* added option for ignoring autofs mountpoints to quota(1), quot(8), repquota(8) and rpc.rquotad(8) (Jan Kara, Paul Szabo)
-* updated xqmstats (Nathan Scott)
-
-Changes in quota-tools from 3.07 to 3.08
-* Fixed infinite loop in quotacheck under RH7.1 (?)
-* Made quota tools aware of /etc/services (H. J. Lu)
-* Updated edquota(8) and setquota(8) to allow setting of individual grace time (Jan Kara)
-* Fixed bug in convertquota(8) when quota was turned on during converting (Jan Kara)
-* Add support for XFS filesystems without root special casing (Christoph Hellwig)
-* XFS documentation updates (Nathan Scott)
-
-Changes in quota-tools from 3.06 to 3.07
-* Added creation of bin and sbin dir during make install; removed hardcoded
- /sbin directory for some utilities. (Jan Kara)
-* Add support for 32 bit uid's and gid's when using EXT2_DIRECT. (Michael Meskes)
-* updated manpage of rpc.rquotad (Jan Kara)
-* setquota is disabled by default in rpc.rquotad (Jan Kara)
-* setquota using RPC is disabled by default in configure (Jan Kara)
-* rised maximal number of mountpoint to 256 (Jan Kara)
-* small fix in configure (Nathan Scott)
-* small fix in quotacheck(8) docs (Jan Kara)
-* fixed quotacheck(8) to continue when old quota files were not found (Jan Kara)
-* quota(1) now doesn't report failure to connect to rpc.rquotad server when -Q specified (Jan Kara)
-* add quota(1) option -l (report only local filesystems) (Jan Kara)
-* warnquota(8) now also mails specified member of the group about violation of the group quotas
- when -g option is specified (Jan Kara)
-* added options by which user can specify whether repquota(8) should translate names in
- big chunks by scanning all users or individually. Added automagic detection using nsswitch.conf
- which behaviour should lead to faster translating. (Jan Kara)
-
-Changes in quota-tools from 3.05 to 3.06
-* fixed caching of libwrap configure result (Jan Kara)
-* fixed copying of quotafile name from mtab (?)
-* warnquota.conf is now installed in config dir (Jan Kara)
-* updated format detection to reflect changes in kernel interface in 2.5.18 (Jan Kara)
-* fixed scanning of non-mountpoint directories (Jan Kara)
-* fixed detection of XFS format (Jan Kara)
-* fixed printing of 'over softlimit sign' in quota(1) (Jan Kara)
-
-Changes in quota-tools from 3.04 to 3.05
-* quota tools should honour 'noquota' mount option (Jan Kara)
-* fixes in manpages (Arkadiusz Miskiewicz)
-* fixed detection of libwrap in configure (Arkadiusz Miskiewicz)
-* added forgotten ROOTDIR to path to gettext catalogs (Arkadiusz Miskiewicz)
-* quotacheck uses newest format supported by kernel when creating new quota files (Jan Kara)
-* fixed bug in IO initialization when -F xfs was given (Jan Kara)
-* added support for quota 6.5.1 (Jan Kara)
-* quotaon(8) now can get format parameter (Jan Kara)
-* fixed bad return value of quota(1) (Jan Kara)
-* fixed bug in quota format format detection (Jan Kara)
-
-Changes in quota-tools from 3.03 to 3.04
-* added -D_FILE_OFFSET_BITS=64 to Makefile - fixes problems with large files with some libcs (Michael Meskes)
-* added -p (print state) to quotaon (Vladimir Linek, Jan Kara)
-* made quotaon(8) write better error messages (Jan Kara)
-* make install now creates man directories (Jan Kara)
-* added -q <quotatab> and -c <configfile> options to warnquota(8) (Jan Kara)
-* added some notes about quotatab to warnquota manpage (Jan Kara)
-* fixed bug in options parsing of warnquota(8) (Michael Meskes)
-* ignore automount mountpoints (Philippe Troin)
-* fixed minor bug in printing grace times (Jan Kara)
-* fixed quotaon(8) behaviour when it sees newer kernel then it's able to handle (Jan Kara)
-* minor formatting change in quotactl(2) manpage (Nathan Scott)
-* init_io() is now more paranoid about quota turned on in kernel (Jan Kara)
-
-Changes in quota-tools from 3.02 to 3.03
-
-* added -f <filesystem> option (perform operation only for given filesystem) for edquota (Jan Kara)
-* quotacheck now skips quota file scanning when file not found (Jan Kara)
-* repquota shouldn't show grace times when softlimit is not exceeded (Jan Kara)
-* removed bogus error message in mountpoint scanning (Jan Kara)
-* fixed mountpoint scanning initialization (solved rpc.rquotad SEGFAULT) (Jan Kara)
-* rpc.rquotad now doesn't need mountpoint for quota operations (Jan Kara)
-* fixed compilation on sparc (Michael Meskes, Jan Kara)
-
-Changes in quota-tools from 3.01 to 3.02
-
-* added -n option (don't resolve names) to repquota (Jan Kara)
-* quota tools now correctly handle zero grace times in old format (Jan Kara)
-* edquota, setquota commit just grace times and flags - fixed possible races
- when used on live filesystem (Jan Kara)
-* another fix to quotastats (Jan Kara)
-* added check to format detection for bad endianity (Jan Kara)
-* implemented conversion of files with bad endianity (Jan Kara)
-* fixes in warnquota, warnquota now allows line splitting by '\', text of mail
- can be specified in config file (Jan Kara)
-
-Changes in quota-tools from 3.01-final to 3.01
-
-* quotastats should now work better on old kernels (Jan Kara)
-* quotacheck is more strict in checking it's arguments (Jan Kara)
-* edquota and setquota should be now save to run for working user
- (number of used blocks and inodes could be wrong in previous versions)
- (Jan Kara)
-
-Changes in quota-tools from 3.01-pre9 to 3.01-final
-
-* quotacheck is using ext2_ino_t if defined (Jani Jaakkola, Jan Kara)
-* rpc.rquotad now closes stdin, stdout unless run on foreground (Jani Jaakkola)
-* setquota can be disabled in rpc.rquotad by commandline option (Jani Jaakkola)
-* quota-tools should now work well also on RH 7.1 (Anders Blomdell, Jan Kara)
-* quotacheck makes backup files only when told by option (Preston Brown)
-* quotacheck now uses vfsv0 format when no quotafile is found (Jan Kara)
-* fixed mountpoint scanning bug when bad mountpoint was specified (Jan Kara)
-* fixed bug when device was specified instead of mountpoint (Preston Brown)
-* fixed bug when scanning mountpoint NFS mounted filesystem (Jan Kara)
-* repquota now resolves more names at once which makes it
- a lot faster (Jan Kara)
-
-
-Changes in quota-tools from 3.01-pre8 to 3.01-pre9
-
-* Improved host access handling (Jan Kara)
-* Improved RPC error reporting (Jan Kara)
-* Fixed bug in quotaon when run of kernel with XFS (Jan Kara)
-* Implemented new mtab scanning with fallback to fstab when mtab not
- found (Jan Kara)
-* Improved speed of repquota for old quota format (Jan Kara)
-* New Makefile style (Jan Kara)
-* Fixed bug in configure in detecting of e2fslib (Jan Kara)
-* Implemented automatic choice of units in quota(1) and repquota(8) (Jan Kara)
-
-
-Changes in quota-tools from 3.01-pre7 to 3.01-pre8
-
-* Fixed typo in option in convertquota. (Jan Kara)
-* Grace times are updated when quota limits are set. (Jan Kara)
-* Fixed possible segfault in rpc.rquotad when no filesystems with quota
- were found. (Jan Kara)
-
-
-Changes in quota-tools from 3.01-pre6 to 3.01-pre7
-
-* Fixed a bug in quotacheck (SEGFAULT on -aR) (Jan Kara)
-* Fixed bug in rquota (grace times) (Jan Kara)
-
-
-Changes in quota-tools from 3.01-pre5 to 3.01-pre6
-
-* Fixed bug in quotacheck for new quota format (it created corrupted quota
- files). (Jan Kara)
-* Fixed bug in version reporting for quot. (Jan Kara)
-* repquota now has -t option - when specified it will be truncating names so
- output will be nicer (Jan Kara)
-
-
-Changes in quota-tools from 3.01-pre2 to 3.01-pre5
-
-* Fixed endian bug in the ext2 mount by LABEL or by UUID handling code, and
- added XFS support to this code also. (Nathan Scott)
-
-* Fix bug in handling of multiple mount points sharing the same device.
- (Jan Kara)
-
-* Fix warnquota output for devices with long names. (Jan Kara)
-
-* Updated man pages. (Jan Kara, Nathan Scott)
-
-* Added a port of the BSD quot(8) utility, with XFS support. (Nathan Scott)
-
-* Added xqmstats(8) utility for reporting activity statistics for the XFS
- Quota Manager - XQM. (Nathan Scott)
-
-* Fix up numerous compiler warnings and all the minor problems that revealed -
- package now compiled with -Wall by default. (Jan Kara, Nathan Scott)
-
-* Rewrote the error output handler (now uses errstr function) which also
- displays the correct programname of the program issueing the error.
-
-* Additional configure option BSD_BEHAVIOUR for more the old BSD behaviour
- as wanted by some people.
-
-* EOF -> -1, sprintf -> snprintf fixes
-
-* Don't turn quotas on on NFS
-
-* Fixed quota format detection, related bugs in quotaon
-
-* IO code now allows readonly access, doesn't open quotafile when not needed
-
-* Fixed bug in old quotaformat initialization
-
-* quota(1) now exits with nonzero exitcode when over quota
-
-* Manpage cleanup
-
-
-Changes in quota-tools from 2.00 to 3.01-pre2
-
-* This is a complete rewrite of the quota package, most importantly adding
- support for the new Linux quota format and also support for XFS quota.
-
-* The internal data structures and algorithms were redesigned and rewritten by
- Jan Kara (jack@ucw.cz) so that different versions and different types of
- quota can be used with these tools.
-
-* Support for XFS quota has been added by Nathan Scott (nathans@sgi.com).
-
-* Add options like RPC, ALT_FORMAT, RPC_SETQUOTA, EXT2_DIRECT to configure.
- (Jan Kara)
-
-* Fix atoi() -> strtol() and detect mistakes in numeric input. (Jan Kara)
-
-* Add '-V' option to all tools to display the version. (Jan Kara)
-
-* Reworked time conversion routines. (Jan Kara)
-
-* setquota - added -t parameter and allow variable number of filesystems to
- be specified. (Jan Kara)
-
-
-Changes in quota-tools from 1.70 to 2.00
-
-* Added patches from Steven Walker <smw8923@cmsu2.cmsu.edu> for supporting
- rpc_setquota call and tcp-wrappers check in rquotad.
-
-* Splited quota manipulation from setquota, edquota, quota etc. to quotaops.c
- so things are coded only once. Also added support for remote quota editing
- and setting using rquota extensions.
-
-* Fixed problems with parsing of /etc/fstab in hasquota.c (incorrectly
- assumed that it was the only option followed by an '='). Patch by
- Simon Huggins <huggie@earth.li>.
-
-* Extracted quota-io into quotaio.c so we only need to update repquota.c and
- quotaio.c when we change the way quotas are stored in the quotafile for bigger
- uids and gids.
-
-* Added prototype user copying to setquota ala edquota -p only this
- time only for a specific filesystem.
-
-* Fixed quota tools for quotas bigger then 4 Gb.
- Patch by Stephen C. Tweedie <sct@redhat.com>
-
-* Changed rpc.rquotad to scan all device entries in /dev to support also devfs
- systems and systems with special hardware RAID controllers.
-
-* Added autoconf support to the quota-utils.
- Patches by Andreas Gruenbacher <a.gruenbacher@bestbits.at>
-
-* Added extra filesystem types to mntent to reflect the current linux filesystems
-
-* Rewrote hasquota.c to check for the MNTOPT_QUOTA option.
- (Request from Phil Stracchino <alaric@babcom.com>)
-
-* Removed searching of /dev dir from rquota_server. Only lookup mounted filesystems.
- (Patch by Roman Kagan <Roman.Kagan@itep.ru>)
-
-* Added gettext NLS support all credits go to the guys named in the
- README.gettext.
-
-* Added the redhat patches to the standard tree.
- * blocksize patch
- * fhs patch
- * hjl patch
- * label patch
- * SPARC patch
-
-* Changed Q_SETQUOTA to Q_SETQLIM in quotaops.c for the putprivs function. This fixed
- a problem where we restore bogos usage info by edquota etc. when a user resets its
- quota usage while running for example edquota. We should only change the limits
- because thats the only things we can change using these kind of tools.
- (Bug report by Dr. Michael Meskes <michael@fam-meskes.de> from the Debian bug-archive)
-
-* Added numeric option to quota and setquota to allow to set quota for users/groups not
- in the localy known through name-services.
- (Modified the patches send by Oscar Martín <oscar@cdrtcampos.es>)
-
-Changes in quota-tools from 1.65 to 1.70
-
-* Fixed problems when turning off one type of quota taking offline the
- other type too.
-
-* Fixed bugs as reported on bugtraq for negative ids and problems
- with usernames with only digits.
-
-* Added setquota (to se quotas from the commandline) as send to me by
- Martin Bene <mb@sime.com>
-
-Changes in quota-tools from 1.60 to 1.65
-
-* Created new diffs again for the newer kernel (2.1.[78]x).
-
-* Added sample program that copies quota-settings from one user
- to an other.
-
-* Added /etc/quotatab support as developed by Jon Lewis
- <jlewis@inorganic5.fdt.net>
-
-* Added some changes to /usr/src/linux/fs/nfsd/vfs.c to support quotas
- for the kernel-nfsd too. (Most other filesystems are gone and the ones
- remaining either don't need quotas or are not used by big groups of users.)
-
-Changes in quota-tools from 1.55 to 1.60
-
-* Added new option to kernel root_squash which means when that option is
- set the kernel system treats root as any normal user and he cannot
- write to any file anymore without obeing the quota limits.
-
-* Added support for root_squash to quotaon and quotaoff using the new
- rsquash option in mntent. In the run also rewrote the hasquota function.
-
-* Added patches to Makefile.std which should make it more FSSTND compliant.
-
-* Added extra check to rpc.rquotad to check the special device type when
- scanning the /dev dir for the right device.
-
-Changes in quota-tools from 1.52 to 1.55
-
-* Added all patches and enhancements I collected the last few months.
- (As always some have undergone some rewriting and are only a special
- option. But they are in)
-
-* Changed check on ruid in edquota to an access-check on the quota-files.
- If you have write permissions on the quota-files as a group its probably
- ok to allow you to change the quotas. If not the system operator should
- take apropriate actions. Install edquota SUID-root if you want people
- who are able to write to your quotafiles to change quotas. If you don't
- install it SUID root it will only update the files which can give strange
- problems with the kernel overwriting your updates.
-
-* Added the EPS-file of the sheets from Remy Card which he used at the
- Berlin Linux seminar. And because they describe everything in detail
- its a nice enhancement to the current HTML docs.
-
-Changes in quota-tools from 1.50 to 1.52
-
-* Hopefully fixed some problems with makefiles and the like.
-
-* Did some rewrite on the mountlist handling, removed limit on number of
- superblocks by allocating them within the mountlist.
- (This code is not available within the standard kernel. Until I find the
- time and feel like it I will put all my new enhancements in my very own
- (just a bit different) kernel sourcetree back into the mainstream kernels.)
-
-Changes in quota-tools from 1.34 to 1.50
-
-* Wrote some new docs, right into html use Mosaic, Netscape or lynx or
- whatever HTML-browser to see whats in. Also did the manual-pages,
- its just a quick hack hope this helps people using quota.
-
-* Added DIRECT EXT2 access to quotacheck which should make scanning ext2
- disks quite some faster. On the other hand you now need the ext2fs
- libs to compile the quotacheck program. (Enhancement by Edvard Tuinder)
-
-* Added dquot_operations to include/linux/fs.h
-
-* Changed include/linux/quota.h according to new standard.
-
-* Changed fs/dquot.c according to new standard.
-
-* Added support to quotaon-systemcall for initializing the superblock
- with a pointer to the dquot operations.
-
-* Remove fs/fileio.c and include/linux/fileio.h including all references to it.
-
-* Added support to the different filesystems to call the new dquot_alloc and
- dquot_free functions on block/inode allocation or freeing. (currently ext2)
-
-* People can add support to any filesystem if they want, for now I have been
- lazy and only implemented it for ext2-fs. Which by the way is probably
- the most difficult of all the filesystems. If one feels up to it you can
- try adding it to your favorit filesystem. I will accept patches, and
- include them with or without changes.
-
-* Added some patches for dynamic allocation of quotafilenames in hasquota.
- (patches by Remy Card)
-
-* Rewrote quota_transfer again, as a never ending story...
-
-* A new run off cleanups have been taking place, removed the QF_OPENING and
- QF_CLOSING flags because we don't need them anymore. The new code uses dquot
- pointers. If we initialize the dquot pointer after we have setup everything
- we don't have do be afraid that we get dqget calls while we don't want them.
-
-* Fixed some bugs with not dropping dquot pointers which lead to memory leaks
- in the long run because dquots kept being hold because the kernel thought
- it was still being used.
-
-* Added some stats to the code which can be viewed with quotastats. Not real
- interesting at the user level but quite handy debugging the quota system.
-
-Changes in quota-tooles from 1.33 to 1.34
-
-* Changed hasquota.c to not insert a slash when the mnt->mnt_dir already ends
- with a slash. So something like //quota.user shouldn't happen anymore.
-
-* Cleaned up fs/fileio.c, removed some unneeded dummy_inodes in unlink and
- rmdir vfs functions. Now rely on incrementing i_count when deleting a
- dir or file and release it when I iput the inode. Should work because when
- a executable is running when it gets deleted this also happens. Also
- renamed and cleanup the rest of the funtions. vfs_rename function should
- now also work for a hardlinked file.
-
-* Changed vfs_chown functions to reset SUID and SGID on a chown because the
- new kernel wants that.
-
-* Changed locking on I/O to use semaphores instead off the mnt_flags
- used before. The old stuff could lock quota easily probably because
- the operation wasn't atomic. This should now be fixed.
-
-* Fixed check_bdq to only give back a available blocks when the current
- number of blocks are below the hardlimit. There was a bugfix for this
- one so I applied that.
-
-* Changed has_quota funtion to use a static buffer instead of mallocing
- one everytime it needs one. Hope this helps with the reported memory
- leak on the rquotad.
-
-* Fixed some little bugs in dquot.c with the setting of the QF_OPENING
- flag and not resseting it on failure of opening the quotafile.
-
-* Added changes needed because the VFS-layer changed to use iattr structs
- for the notify_change function.
-
-* Fixed quota_transfer to work again with the new iattr structs, hopefully
- it works ok now. It was brought to my attension that it wasn't working
- the way it should in the old version. So I first checked out the fix that
- I received, but that didn't solve the problem either so I fixed it myself.
-
-* Combined the new writeaccess stuff with the stuff I already had. Also
- cleaned up vfs layer some more because of the use of the new
- vfs_getwriteaccess and vfs_putwriteaccess functions. This also involved
- the quotaon function that should now return a propper errno on failure and
- not the standard EIO that it was in earlier versions.
-
-Changes in quota-tools from 1.32 to 1.33
-
-* Ported the stuff back to the normal kernel to make a diff-file quite easy.
-
-* Fixed some typos that could trigger a kernel panic because the locking gets
- killed when a quota is exeeded.
-
-* Fixed the stuff to work with the the new-tty-drivers.
-
-* This patches aren't that well tested on the machines I use because I use a
- complete different kernel over here. But thats why this is called BETA
- software. The bigfiles in this package are copies of the files used in my
- kernel so some thing are tested more then others.
-
-* Fixed quotacheck not to memset the whole quota when there are no blocks
- allocated by this user.
-
-Changes in quota-tools from 1.31 to 1.32
-
-* Fixed diff-files, the are now made as unified diffs.
-
-* Checked the specifications for the rquota service, I was correct we only need
- to respond to udp connections.
-
-Changes in quota-tools from 1.3 to 1.31
-
-* Changed quotacheck program to stuff directories it encounters on a
- directory stack and check them later on. This way there is at any
- time one directory opened for reading. In the old situation it could
- happen that more then one directory were open at the same time and
- with nasty directory structures this could give to much open directories
- at ones, leading to an error by the O.S.
-
-* Added some hooks for debugging the memory usage by the program, and make
- the stdout used for the -v flag non-buffered for more speed.
-
-* Added variabele to mountstruct for flags, now we can mask when we are
- opening or closeing a quotafile, when we are we may not give out
- pointers with the dq_get function, otherwise we run into problems
- later on.
-
-* Ok updated fs/*.c missed patch to fs/inode.c that solves a race condition.
-
-* Added vfs_rename function that takes care of renaming files on top of already
- existing files. We were missing those ones, thanks to David Black for
- reporting this. If there are still problems I will hear so and try to fix them
- as soon as I can.
-
-Changes in quota-tools from 1.2 to 1.3
-
-* We only reply to rpc_quota_request made to the udp port of the
- rquotad, I just removed support for the TCP service, I don't
- think it's needed to have the TCP service for just exchanging
- about 40 bytes of data. Too much overhead setting up a TCP connection.
-
-* Changed vfs_write function within fileio.h to be a bit smarter. If
- the fileposition + number of bytes to be written is less then the
- current size of the file we should even bother checking it. And if
- the number of wanted_blocks equals to 0 why even bother checking
- the quota no changes are made anyway.
-
-* Rewrote the quota stuff to be much more flexible, we now use pointers
- that are located within the inode for fast lookup. This is a bit more
- to setup but is much faster when used over and over again. Its based
- on the setup used for inode caching and is mostly rewritten code with
- some extensions that were needed for the dquot structs. And of course
- a lot extra because dquot aren't exactly inodes.
-
-* Ok file is called dquot.c again because it specific to diskquotas. If
- we ever get process quota, we have to move the system-call interface to
- the kernel dir.
-
-* splitted fileio header into fileio.c and fileio.h. Fileio.c contains
- the code for all the functions, fileio.h contains the prototypes for
- the functions when quota is enabled and defines to the the default
- inode operations if it is disabled.
-
-* Moved device management code to the file fs/super.c and made it a
- bit more general. The stuff now can also be used for other purposes.
- For now it contains the devicename, the directory the filesystem is
- mounted on, a pointer to the superblock and the quota expire times
- and filepointers, this can be extended in the future and this can be
- used for other purposes then only quota. Its in super.c because it
- is related to mounting a filesystem. The rootfilesystem is a special
- case for which I don't have a nice solution right now.
-
-* Cleaned up the file file_table.c and renamed it to file.c, otherwise
- we should call inode.c inode_table.c etc. More is static now, the
- file_table isn't accesable anymore from everywhere, and the functions
- that need the info within file.c should be located within that file.
- A good example is the function used by the vhangup code, it now calls
- a routine within file.c and so we don't have export any data anymore.
-
-* changed decrement quota to reset the DQ_INODES and DQ_BLKS flag on
- a decrement of a quota. It seems that we should bark again when one
- goes over his quota after he removed something, ok should work this
- way.
-
-* changed set_dqblk to set the grace period when a new usage is set
- and one exceeds his softlimit by that operation. Better then just
- setting the graceperiod when he allocates any more inodes or blocks.
- Only can give surprises when logging in but who cares they can ask
- the sysadmin to give them a hand with cleaning there dirs.
-
-* quotaoff is very simple now just reset all the pointers that point
- to a dquot and trash the cache for all dquots that are related to
- the device being turned of. This way the next time you put it on the
- stuff get read again from disk and not from the cache.
-
-* changed most of the file structs to be a filepointer and request it
- with get_empty_filp. This way we allocate it from the file_table which
- is more the way it should be, Ok I know the dummy_inodes isn't that
- nice either, but for that we don't have an other choice. Also it makes
- live much easier this way. See the core dump stuff.
-
-* used some more constants for setting up the file pointers, this should
- make it easier to read. So ok Edvard ?
-
-* rewrote most functions such as quota_alloc, quota_remove and quota_transfer
- to use a for loop which counts from 0 to the number of quotas -1. This way
- it should be easy to extend the quota stuff to maintain even more types of
- quota. (At the moment I can think of one more, what about quotas for a
- processgroups) :-)
-
-* rewrote quota_transfer, its still the most complicated function of the
- three manipulate functions, but it looks much cleaner then the one we
- had.
-
-* changed the system-call interface again this should be the last time,
- hope to have it made more intelligent now, most of the calls are quite
- the same, so just set flags and call one functions. Saves some functions.
-
-* And more cleanups to the vfs-layer. Did a kind of indent on all the sources
- in the fs-dir by hand. All references to file pointers are now done by a
- variable that is called filp. This is done to be a bit more consistent all
- through the code. Before is was called file, filp, f etc.
-
-* As of the indent I changed all tabs to be 3 spaces this makes it a bit
- larger but much better to read.
-
-* Someone reported that there are problems with fstab when you use something
- like usrquota=/usr/adm/quota.user,grpquota=/usr/adm/quota.grp. I don't know
- if the problems is also in the new libs, if so I have a replacement here for
- the entire mntent stuff. I wrote this way back and it work ok so if you
- have problems mail me and I will send you the sources. For now I didn't
- include it yet in the standard mainline distribution.
-
-* Ok added hooks to the fork code forgot that, ok this has cost me some
- searching. We must doe an vfs_open_filp when a process forks and the
- filepointers are copied or incremented.
-
-Changes in quota-tools from 1.1 to 1.2
-
-* Changed repquota.c to display at max 8 chars of username.
-
-* Changed rquota_svc.c and rquota_server.c to handle both version 1
- and 2 requests. Now we should be able to communicate with sun systems.
- SUN systems send out version 1 request which we can handle now.
-
-* Changed quota.c to first send out a version 2 rquota request and if
- that fails to try it with a version 1 request. Now we should be able to
- query a rquotad on a sun-server exporting a NFS disk.
-
-* Changed kernel diffs, now use a header file fileio.h with vfs functions
- for writing, truncating, creating files/nodes. This cleaned up the
- kernel diffs quite a bit. (Should have done this way back, but it is
- done now)
-
-* Fixed some small bugs with handling graceperiods again. Changed the code
- in the systemcall interface all bugs should be gone now there.
-
-* Wrote a new program warnquota. No manpage yet but it has no flags so
- that's simple. You can run this from your crontab just like you run
- quotacheck every night from cron. This program mails a message to all
- users that violated the quota system.
-
-* Changed fileio.h with unlinking and rmdir to make a copy of the inode.
- Hope this fixes some problems we have seen with xiafs. It isn't to bad
- either should have been this way from the beginning. A pointer to a
- inode that is removed is a bit to tricky a copy in local memory is much
- saver.
-
-* Changed fs/quota.c to not check if the quotafile is on the same device
- as the device for which it contains info. Found that in a document but
- it's silly and so it's removed now. Who cares where you put it as long
- the kernel can find it and it is the right format.
- (Now something like usrquota="/var/adm/quota_src.user" should work :-))
-
-* Changed edquota behaviour with -p flag. It now copies the current
- usage to the new situation.
-
-Changes in quota-tools from 1.0 to 1.1
-
-* Moved check to test on quota on a certain filesystem to seperate file
- hasquota.c
-
-* Changed hasquota.c to use quotafile given in fstab file instead
- of the default name of a quotafile. We now can define ourself where
- to put our quotafile. Something like "usrquota=/usr/adm/quotasrc.user"
-
-* Changed graceperiod counting was doing it the wrong way around. Now we
- add the expiretime to the current time and that is the grace-period a user
- has before we see a softlimit as a hardlimit.
-
-* Changed allocation when not enough blocks can be allocated from ones quota.
- Now you get as many blocks as you can affort yourself and not as in the
- earlier version, nothing. This was a bit of a bitch to tackle but it seems
- to work ok now for regular files and core-files.
-
-* Changed the quota.h file to include a prototype for a new function
- blocks_to_isize that calculates the maximum isize for a file when allocating
- less blocks than requested. Also included macro's for min() and max().
-
-* Added rquotad program for own convinience, this was build from scratch with
- only the rquota.x file. It seems to work quite nice between LINUX machines
- don't have the resources to test it with other then LINUX machines.
- We probably need a new version number for this type of rquota.
- Something like rquota version 2 or something like that.
-
-* Changed quota program to use a rpc-call to the rquotad on one of you
- disk server machines. See #ifdef RPC in quota.c. Use small timeout because
- I don't wanna wait to long when a machine is down. Increase it when you have
- problems with slow hosts.
-
-* Rewrite of quotacheck program. This one is much faster, about 60%. Thanks
- to Edvard for this big improvement.
-
-* Changed namei.c to iput the inode of a dir when doing a remove of a dir.
- I never had problems with it but it seems that ext2 doesn't care to much when
- you unlink a dir while you have the inode still open. Fixed it and it works
- now ok also on xiafs which had problems with it, and of course the fragment
- should have give this error because you have to iput the dir before you remove
- it.
-
-* Changed source of quotacheck to create new quotafile with at least the
- gracetimes. Now there should never be a problem when turning on quota with
- the quotactl systemcall after one has run quotacheck to create the correct
- quotafiles.
-
-* Changed code of quota.c to read MOUNTED(mtab) instead of FSTAB(fstab) when
- showing quotainfo.
diff --git a/Makefile.am b/Makefile.am
new file mode 100644
index 0000000..f113562
--- /dev/null
+++ b/Makefile.am
@@ -0,0 +1,262 @@
+ACLOCAL_AMFLAGS = -I m4
+
+docdir = $(datadir)/doc/@PACKAGE@
+doc_DATA = \
+ README.mailserver \
+ README.ldap-support \
+ doc/quotadoc.sgml \
+ doc/quotas.ms \
+ doc/quotas.preformated \
+ doc/quotas-1.eps
+
+rpcsvcdir = $(includedir)/rpcsvc
+rpcsvc_DATA = \
+ rquota.h \
+ rquota.x
+
+sysconf_DATA = \
+ warnquota.conf \
+ quotatab \
+ quotagrpadmins
+
+man_MANS = \
+ convertquota.8 \
+ edquota.8 \
+ quotagrpadmins.5 \
+ quotacheck.8 \
+ quota_nld.8 \
+ quotaon.8 \
+ quotastats.8 \
+ quotasync.1 \
+ quotatab.5 \
+ quota.1 \
+ quot.8 \
+ repquota.8 \
+ rpc.rquotad.8 \
+ rquota.3 \
+ setquota.8 \
+ warnquota.conf.5 \
+ warnquota.8 \
+ xqmstats.8
+
+CLEANFILES = rquota.c rquota.h rquota_clnt.c
+
+SUBDIRS = po
+
+EXTRA_DIST = \
+ $(sysconf_DATA) \
+ $(doc_DATA) \
+ $(man_MANS) \
+ $(rpcsvc_DATA) \
+ autogen.sh
+
+noinst_LIBRARIES = \
+ libquota.a \
+ librpcclient.a
+
+librpcclient_a_SOURCES = \
+ rquota.c \
+ rquota.h \
+ rquota_client.c \
+ rquota_client.h \
+ rquota_clnt.c
+librpcclient_a_CFLAGS = -Wno-unused
+
+if WITH_RPC
+RPCLIBS = librpcclient.a
+endif
+
+libquota_a_SOURCES = \
+ dqblk_rpc.h \
+ dqblk_v1.h \
+ dqblk_v2.h \
+ dqblk_xfs.h \
+ quotaio.c \
+ quotaio.h \
+ quotaio_v1.c \
+ quotaio_v1.h \
+ quotaio_v2.c \
+ quotaio_v2.h \
+ quotaio_tree.c \
+ quotaio_rpc.c \
+ quotaio_xfs.c \
+ quotaio_xfs.h \
+ quotaio_meta.c \
+ quotaio_generic.c \
+ quotaio_generic.h \
+ bylabel.c \
+ bylabel.h \
+ common.c \
+ config.h \
+ common.h \
+ quotasys.c \
+ quotasys.h \
+ mntopt.h \
+ pot.c \
+ pot.h
+libquota_a_LIBADD = \
+ $(RPCLIBS)
+
+bin_PROGRAMS = \
+ quota \
+ quotasync
+
+sbin_PROGRAMS = \
+ quotacheck \
+ quotaon \
+ quot \
+ repquota \
+ warnquota \
+ quotastats \
+ xqmstats \
+ edquota \
+ setquota \
+ convertquota \
+ rpc.rquotad
+if WITH_NETLINK
+sbin_PROGRAMS += \
+ quota_nld
+endif
+
+quotaon_SOURCES = \
+ quotaon.c \
+ quotaon.h \
+ quotaon_xfs.c
+quotaon_LDADD = \
+ libquota.a \
+ $(RPCLIBS)
+
+quotacheck_SOURCES = \
+ quotacheck.c \
+ quotacheck.h \
+ quotacheck_v1.c \
+ quotacheck_v2.c \
+ quota_tree.h \
+ quotaops.c
+quotacheck_CFLAGS = \
+ $(EXT2FS_CFLAGS) \
+ $(COM_ERR_CFLAGS)
+quotacheck_LDADD = \
+ libquota.a \
+ $(EXT2FS_LIBS) \
+ $(COM_ERR_LIBS) \
+ $(RPCLIBS)
+
+quota_SOURCES = \
+ quota.c \
+ quota.h \
+ quotaops.c \
+ quotaops.h
+quota_LDADD = \
+ libquota.a \
+ $(RPCLIBS)
+
+quotasync_SOURCES = quotasync.c
+quotasync_LDADD = \
+ libquota.a \
+ $(RPCLIBS)
+
+quot_SOURCES = \
+ quot.c \
+ quot.h
+quot_LDADD = \
+ libquota.a \
+ $(RPCLIBS)
+
+repquota_SOURCES = repquota.c
+repquota_LDADD = \
+ libquota.a \
+ $(RPCLIBS)
+
+warnquota_SOURCES = warnquota.c
+warnquota_LDADD = \
+ libquota.a \
+ $(LDAP_LIBS) \
+ $(RPCLIBS)
+
+quotastats_SOURCES = \
+ quotastats.c \
+ common.c \
+ common.h \
+ pot.c \
+ pot.h
+
+xqmstats_SOURCES = \
+ xqmstats.c \
+ common.c \
+ common.h \
+ pot.c \
+ pot.h
+
+edquota_SOURCES = \
+ edquota.c \
+ quotaops.c \
+ quotaops.h
+edquota_LDADD = \
+ libquota.a \
+ $(RPCLIBS)
+
+setquota_SOURCES = \
+ setquota.c \
+ quotaops.c \
+ quotaops.h
+setquota_LDADD = \
+ libquota.a \
+ $(RPCLIBS)
+
+convertquota_SOURCES = convertquota.c
+convertquota_LDADD = \
+ libquota.a \
+ $(RPCLIBS)
+
+rpc_rquotad_SOURCES = \
+ rquota_server.c \
+ rquota_svc.c \
+ svc_socket.c
+rpc_rquotad_LDADD = \
+ libquota.a \
+ $(WRAP_LIBS) \
+ $(RPCLIBS)
+
+quota_nld_SOURCES = quota_nld.c
+quota_nld_CFLAGS = \
+ $(DBUS_CFLAGS) \
+ $(LIBNL3_CFLAGS)
+quota_nld_LDADD = \
+ libquota.a
+ $(DBUS_LIBS) \
+ $(LIBNL3_LIBS)
+
+# ------------------
+# Rpcgen conversions
+# ------------------
+%.h: %.x
+ @rm -f $@
+ @$(RPCGEN) -h -o $@ $^
+
+%.c: %.x
+ @rm -f $@
+ @$(RPCGEN) -c -o $@ $^
+
+rquota_clnt.c: rquota.x
+ @rm -f $@
+ @$(RPCGEN) -l -o $@ $<
+
+# --------
+# Quotaoff
+# --------
+
+install-exec-hook:
+ @$(LN_S) quotaon $(DESTDIR)$(sbindir)/quotaoff
+
+install-data-hook:
+ @$(LN_S) quotaon.8 $(DESTDIR)$(mandir)/man8/quotaoff.8
+
+# -------------
+# Extra options
+# -------------
+distclean-local:
+ rm -rf *.cache *~
+
+dist-hook:
+ git log --date=short --pretty="format:@%cd %an <%ae> [%H]%n%n%s%n%n%e%b" | sed -e "s|^\([^@]\)|\t\1|" -e "s|^@||" >$(distdir)/ChangeLog
diff --git a/Makefile.in b/Makefile.in
deleted file mode 100644
index 7d25930..0000000
--- a/Makefile.in
+++ /dev/null
@@ -1,165 +0,0 @@
-PROGS = quotacheck quotaon quota quot repquota warnquota quotastats xqmstats edquota setquota convertquota rpc.rquotad quotasync @QUOTA_NETLINK_PROG@
-SOURCES = bylabel.c common.c convertquota.c edquota.c pot.c quot.c quota.c quotacheck.c quotacheck_v1.c quotacheck_v2.c quotaio.c quotaio_rpc.c quotaio_v1.c quotaio_v2.c quotaio_tree.c quotaio_xfs.c quotaio_meta.c quotaio_generic.c quotaon.c quotaon_xfs.c quotaops.c quotastats.c quotasys.c repquota.c rquota_client.c rquota_server.c rquota_svc.c setquota.c warnquota.c xqmstats.c svc_socket.c quotasync.c
-CFLAGS = @CFLAGS@ -D_GNU_SOURCE -Wall -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64
-CPPFLAGS = @CPPFLAGS@
-EXT2LIBS = @EXT2LIBS@
-NETLINKLIBS = @NETLINKLIBS@
-RPCSRC = rquota.h rquota_xdr.c rquota_clnt.c
-LIBS = @LIBS@
-LDFLAGS = @LDFLAGS@
-LDAPLIBS = @LDAPLIBS@
-
-INSTALL = @INSTALL@
-STRIP = @STRIP@
-LN = ln -sf
-ROOTDIR =
-SUPER_OWNER = root
-BIN_OWNER = bin
-BIN_GROUP = bin
-DEF_SUID_MODE = 4511
-DEF_BIN_MODE = 555
-DEF_SBIN_MODE = 555
-DEF_MAN_MODE = 444
-DEF_CONF_MODE = 644
-RPCGEN = rpcgen
-
-prefix = @prefix@
-bindir = $(prefix)/bin
-sbindir = $(prefix)/sbin
-root_sbindir = @ROOTSBIN@
-mandir = @mandir@
-includedir = $(prefix)/include
-locale_dir = $(prefix)/share/locale
-sysconfdir = @sysconfdir@
-datarootdir = @datarootdir@
-
-RPCCLNTOBJS = rquota_xdr.o rquota_client.o rquota_clnt.o
-IOOBJS = quotaio.o quotaio_v1.o quotaio_v2.o quotaio_tree.o quotaio_rpc.o quotaio_xfs.o quotaio_meta.o quotaio_generic.o
-IOOBJS += $(RPCCLNTOBJS)
-LIBOBJS = bylabel.o common.o quotasys.o pot.o $(IOOBJS)
-LIBOBJS += @LIBMALLOC@
-
-.PHONY: all clean clobber realclean pot mo inst_mo
-
-.%.d: %.c
- set -e; $(CC) -MM -MG $(CPPFLAGS) $(CFLAGS) $< | \
- sed 's/\($*\)\.o[ :]*/\1.o $@ : /g' > $@; \
- [ -s $@ ] || rm -f $@
-
-all: $(PROGS)
-
-clean:
- -rm -f core *.o .*.d
-
-clobber: clean
- -rm -f $(PROGS) Makefile config.status config.cache config.log config.h
-
-realclean: clobber
- -rm -f $(RPCSRC) po/*.mo *.rej *.orig *~
-
-pot:
- xgettext -k_ -kN_ -d pot *.c *.h
-
-mo: po
- for n in $(shell ls po/*.po); do \
- msgfmt -o po/`basename $$n .po`.mo $$n; \
- done
-
-inst_mo: mo
- mkdir -p $(ROOTDIR)$(locale_dir)
- for n in $(shell ls po/*.po | sed 's/\.po/\.mo/'); do \
- l=`basename $$n .mo`; \
- $(INSTALL) -m 755 -d $(ROOTDIR)$(locale_dir)/$$l; \
- $(INSTALL) -m 755 -d $(ROOTDIR)$(locale_dir)/$$l/LC_MESSAGES; \
- $(INSTALL) -m 644 $$n $(ROOTDIR)$(locale_dir)/$$l/LC_MESSAGES/quota.mo; \
- done
-
-install: all @INSTMO@
- -mkdir -p $(ROOTDIR)$(sbindir)
- -mkdir -p $(ROOTDIR)$(bindir)
- -mkdir -p $(ROOTDIR)$(root_sbindir)
- -$(INSTALL) $(STRIP) -m $(DEF_SBIN_MODE) \
- quotacheck quotaon $(ROOTDIR)$(root_sbindir)
- -$(LN) quotaon $(ROOTDIR)$(root_sbindir)/quotaoff
- -$(INSTALL) $(STRIP) -m $(DEF_SBIN_MODE) \
- edquota repquota warnquota quotastats setquota quot xqmstats \
- convertquota $(ROOTDIR)$(sbindir)
- -mkdir -p $(ROOTDIR)$(sysconfdir)
- -$(INSTALL) -m $(DEF_CONF_MODE) warnquota.conf $(ROOTDIR)$(sysconfdir)
- -$(INSTALL) -m $(DEF_CONF_MODE) quotatab $(ROOTDIR)$(sysconfdir)
- -$(INSTALL) -m $(DEF_CONF_MODE) quotagrpadmins $(ROOTDIR)$(sysconfdir)
- -mkdir -p $(ROOTDIR)$(mandir)/man1
- -mkdir -p $(ROOTDIR)$(mandir)/man3
- -mkdir -p $(ROOTDIR)$(mandir)/man5
- -mkdir -p $(ROOTDIR)$(mandir)/man8
- -$(INSTALL) -m 755 -d $(ROOTDIR)$(includedir)/rpcsvc
- -$(INSTALL) -m 644 rquota.h rquota.x $(ROOTDIR)$(includedir)/rpcsvc
- -$(INSTALL) $(STRIP) -m $(DEF_SBIN_MODE) quota quotasync $(ROOTDIR)$(bindir)
- -$(INSTALL) $(STRIP) -m $(DEF_SBIN_MODE) rpc.rquotad $(ROOTDIR)$(sbindir)
-ifneq ($(NETLINKLIBS),)
- -$(INSTALL) $(STRIP) -m $(DEF_SBIN_MODE) quota_nld $(ROOTDIR)$(sbindir)
-endif
- -$(INSTALL) -m $(DEF_MAN_MODE) *.1 $(ROOTDIR)$(mandir)/man1
- -$(INSTALL) -m $(DEF_MAN_MODE) *.3 $(ROOTDIR)$(mandir)/man3
- -$(INSTALL) -m $(DEF_MAN_MODE) *.5 $(ROOTDIR)$(mandir)/man5
- -$(INSTALL) -m $(DEF_MAN_MODE) *.8 $(ROOTDIR)$(mandir)/man8
-
-quotaon: quotaon.o quotaon_xfs.o $(LIBOBJS)
- $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $^
-
-quotacheck: quotacheck.o quotacheck_v1.o quotacheck_v2.o quotaops.o $(LIBOBJS)
- $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $^ $(EXT2LIBS)
-
-quota: quota.o quotaops.o $(LIBOBJS)
- $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $^
-
-quotasync: quotasync.o $(LIBOBJS)
- $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $^
-
-quot: quot.o $(LIBOBJS)
- $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $^
-
-repquota: repquota.o $(LIBOBJS)
- $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $^
-
-warnquota: warnquota.o $(LIBOBJS)
- $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $^ $(LDAPLIBS)
-
-quotastats: quotastats.o common.o pot.o
- $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $^
-
-xqmstats: xqmstats.o common.o pot.o
- $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $^
-
-edquota: edquota.o quotaops.o $(LIBOBJS)
- $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $^
-
-setquota: setquota.o quotaops.o $(LIBOBJS)
- $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $^
-
-convertquota: convertquota.o $(LIBOBJS)
- $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $^
-
-rpc.rquotad: rquota_server.o rquota_svc.o svc_socket.o $(LIBOBJS)
- $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $^ $(LIBS)
-
-ifneq ($(NETLINKLIBS),)
-quota_nld: quota_nld.o $(LIBOBJS)
- $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $^ $(NETLINKLIBS)
-endif
-
-pot.o: pot.c pot.h
-
-rquota.h: rquota.x
- $(RPCGEN) -h -o $@ $<
-
-rquota_xdr.c: rquota.x
- $(RPCGEN) -c -o $@ $<
-
-rquota_xdr.o: rquota_xdr.c rquota.h
- $(CC) $(CFLAGS) -Wno-unused -c $<
-
-rquota_clnt.c: rquota.x
- $(RPCGEN) -l -o $@ $<
-
--include $(SOURCES:%.c=.%.d)
diff --git a/README.gettext b/README.gettext
deleted file mode 100644
index 6bcb14f..0000000
--- a/README.gettext
+++ /dev/null
@@ -1,21 +0,0 @@
-If you want to generate new po file: "make pot" and look for a file named
-pot.po. To generate mo files from po files: "make mo", it's also done when
-you "make install", if you want to install only mo files ( no programs )
-"make inst_mo", mo files will be copied to:
-/usr/share/locale/'languages names'/LC_MESSAGES/quota.mo.
-
-warnquota
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-this program was modifiated to be more configurable - you can now specify
-new warning message ( also sender, cc, etc. ) without recompiling the
-program. all you need is to edit pot.po ( make pot ), you will find
-in it mail message, and etc. - create new strings, make mo with msgfmt, and copy
-mo file to /usr/share/locale/'lang'/LC_MESSAGES/quota.mo. now you have new
-warning mail message.
-
-gettext support was added by Paul Niewiadomski <lilo@free.poltronic.net>, any
-questions, suggestions are welcome.
-
-thanks to
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-Roman_Kaminski@saba.com.pl \ No newline at end of file
diff --git a/autogen.sh b/autogen.sh
new file mode 100755
index 0000000..3ebda42
--- /dev/null
+++ b/autogen.sh
@@ -0,0 +1,2 @@
+#!/bin/sh
+autoreconf -fvi
diff --git a/common.c b/common.c
index 69e6178..8f87202 100644
--- a/common.c
+++ b/common.c
@@ -123,5 +123,5 @@ void version(void)
{
printf(_("Quota utilities version %s.\n"), PACKAGE_VERSION);
printf(_("Compiled with:%s\n"), COMPILE_OPTS);
- printf(_("Bugs to %s\n"), MY_EMAIL);
+ printf(_("Bugs to %s\n"), PACKAGE_BUGREPORT);
}
diff --git a/common.h b/common.h
index 8b04e55..a42812e 100644
--- a/common.h
+++ b/common.h
@@ -13,8 +13,6 @@
# endif
#endif
-#define MY_EMAIL "jack@suse.cz"
-
/* Name of current program for error reporting */
extern char *progname;
diff --git a/config.h.in b/config.h.in
index 97e23f1..ec8ea74 100644
--- a/config.h.in
+++ b/config.h.in
@@ -1,4 +1,4 @@
-/* config.h.in. Generated from configure.in by autoheader. */
+/* config.h.in. Generated from configure.ac by autoheader. */
/* File with mounted filesystems */
#undef ALT_MTAB
@@ -9,18 +9,35 @@
/* Configuration options */
#undef COMPILE_OPTS
+/* Define to 1 if translation of program messages to the user's native
+ language is requested. */
+#undef ENABLE_NLS
+
/* Scanning of ext? filesystems using e2fslib */
#undef EXT2_DIRECT
+/* Define if the GNU dcgettext() function is already present or preinstalled.
+ */
+#undef HAVE_DCGETTEXT
+
/* Header files for e2fslib */
#undef HAVE_EXT2_INCLUDE
/* ext2fs.h defines ext2_ino_t */
#undef HAVE_EXT2_INO_T
+/* Define if the GNU gettext() function is already present or preinstalled. */
+#undef HAVE_GETTEXT
+
+/* Define if you have the iconv() function. */
+#undef HAVE_ICONV
+
/* Define to 1 if you have the <inttypes.h> header file. */
#undef HAVE_INTTYPES_H
+/* Define to 1 if you have the `ldap' library (-lldap). */
+#undef HAVE_LIBLDAP
+
/* Define to 1 if you have the <memory.h> header file. */
#undef HAVE_MEMORY_H
@@ -48,12 +65,15 @@
/* Use hosts.allow and hosts.deny for access checking of rpc.rquotad */
#undef HOSTS_ACCESS
-/* ldap_perror function not declared */
-#undef NEED_LDAP_PERROR
+/* Name of package */
+#undef PACKAGE
/* Define to the address where bug reports for this package should be sent. */
#undef PACKAGE_BUGREPORT
+/* Locale-specific data directory */
+#undef PACKAGE_LOCALE_DIR
+
/* Define to the full name of this package. */
#undef PACKAGE_NAME
@@ -66,7 +86,7 @@
/* Define to the home page for this package. */
#undef PACKAGE_URL
-/* Version of quota tools */
+/* Define to the version of this package. */
#undef PACKAGE_VERSION
/* Support for RPC */
@@ -81,12 +101,12 @@
/* Use gettext to translate messages */
#undef USE_GETTEXT
-/* LDAP 2.3 or newer installed */
-#undef USE_LDAP_23
-
/* Lookup email address using LDAP */
#undef USE_LDAP_MAIL_LOOKUP
+/* Version number of package */
+#undef VERSION
+
/* Assume quota mount options for root filesystem */
#undef XFS_ROOTHACK
diff --git a/configure.ac b/configure.ac
new file mode 100644
index 0000000..a93cd9d
--- /dev/null
+++ b/configure.ac
@@ -0,0 +1,273 @@
+# Process this file with autoconf to create configure.
+
+AC_PREREQ([2.60])
+
+# ====================
+# Version informations
+# ====================
+m4_define([quota_version_major],[4])
+m4_define([quota_version_minor],[1])
+m4_define([quota_version_micro],[0])
+m4_define([quota_version],[quota_version_major.quota_version_minor.quota_version_micro])
+
+# =============
+# Automake init
+# =============
+AC_INIT([quota],[quota_version], [jack@suse.cz])
+AC_CONFIG_MACRO_DIR([m4])
+AC_CONFIG_HEADERS([config.h])
+AM_INIT_AUTOMAKE([1.11 foreign dist-xz dist-bzip2])
+m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
+AC_LANG([C])
+
+# ===========================
+# Find required base packages
+# ===========================
+m4_ifdef([AM_PROG_AR], [AM_PROG_AR])
+AC_PROG_CC([cc gcc clang])
+AC_PROG_RANLIB
+AC_PROG_INSTALL
+AC_PROG_LN_S
+AC_PROG_MAKE_SET
+PKG_PROG_PKG_CONFIG([0.20])
+
+AC_C_CONST
+AC_C_INLINE
+
+# ===============
+# Gettext support
+# ===============
+AM_GNU_GETTEXT([external])
+AM_GNU_GETTEXT_VERSION([0.12.1])
+
+AS_IF([test "$enable_nls" != "no"], [
+ enable_nls="yes"
+ AC_DEFINE([USE_GETTEXT], 1, [Use gettext to translate messages])
+])
+AS_IF([test "x${prefix}" = "xNONE"], [
+ AC_DEFINE_UNQUOTED(PACKAGE_LOCALE_DIR, "${ac_default_prefix}/share/locale", [Locale-specific data directory])
+], [
+ AC_DEFINE_UNQUOTED(PACKAGE_LOCALE_DIR, "${prefix}/share/locale", [Locale-specific data directory])
+])
+
+
+# ================
+# Check for cflags
+# ================
+CFLAGS="-D_GNU_SOURCE -Wall -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64"
+AC_ARG_ENABLE([werror],
+ [AS_HELP_STRING([--enable-werror], [Treat all warnings as errors, useful for development])],
+ [enable_werror="$enableval"],
+ [enable_werror=no]
+)
+AS_IF([test x"$enable_werror" != "xno"], [
+ CFLAGS="$CFLAGS -Werror"
+])
+
+# =========
+# Find ldap
+# =========
+AC_ARG_ENABLE([ldapmail],
+ [AS_HELP_STRING([--disable-ldapmail], [Do not use the ldap mail address lookups.])],
+ [enable_ldapmail="$enableval"],
+ [enable_ldapmail=auto]
+)
+AS_IF([test "x$enable_ldapmail" != "xno"], [
+ build_ldap="yes"
+ AC_CHECK_LIB([ldap], [ldap_initialize], [], [
+ build_ldap=no
+ AS_IF([test "x$enable_ldapmail" = "xyes"], [
+ AC_MSG_ERROR([LDAP support required but library not found.]);
+ ])
+ ])
+ AS_IF([test "x$build_ldap" = "xyes"], [
+ LDAP_LIBS="-lldap -llber"
+ AC_DEFINE([USE_LDAP_MAIL_LOOKUP], 1, [Lookup email address using LDAP])
+ COMPILE_OPTS="$COMPILE_OPTS USE_LDAP_MAIL_LOOKUP"
+ ])
+])
+AC_SUBST(LDAP_LIBS)
+
+# ===============
+# Find ext2direct
+# ===============
+AC_ARG_ENABLE([ext2direct],
+ [AS_HELP_STRING([--disable-ext2direct], [Disable scanning of EXT2/EXT3 filesystem using e2fslib.])],
+ [enable_ext2direct="$enableval"],
+ [enable_ext2direct=auto]
+)
+AS_IF([test "x$enable_ext2direct" != "xno"], [
+ build_ext2direct="yes"
+ PKG_CHECK_MODULES([COM_ERR],[com_err], [], [
+ build_ext2direct="no"
+ AS_IF([test "x$enable_ext2direct" = "xyes"], [
+ AC_MSG_ERROR([Ext2direct requested but required com_err library not found])
+ ])
+ ])
+ PKG_CHECK_MODULES([EXT2FS],[ext2fs], [], [
+ build_ext2direct="no"
+ AS_IF([test "x$enable_ext2direct" = "xyes"], [
+ AC_MSG_ERROR([Ext2direct requested but required ext2fs library not found])
+ ])
+ ])
+ AS_IF([test "x$build_ext2direct" != "xno"], [
+ AC_DEFINE([HAVE_EXT2_INO_T], 1, [ext2fs.h defines ext2_ino_t])
+ AC_DEFINE([HAVE_EXT2_INCLUDE], 1, [Header files for e2fslib])
+ AC_DEFINE([EXT2_DIRECT], 1, [Scanning of ext? filesystems using e2fslib])
+ COMPILE_OPTS="$COMPILE_OPTS EXT2_DIRECT"
+ ])
+])
+AC_SUBST(EXT2FS_CFLAGS)
+AC_SUBST(EXT2FS_LIBS)
+AC_SUBST(COM_ERR_CFLAGS)
+AC_SUBST(COM_ERR_LIBS)
+
+# ==================
+# Netlink enablement
+# ==================
+AC_ARG_ENABLE([netlink],
+ [AS_HELP_STRING([--disable-netlink], [Do not compile daemon receiving quota messages via netlink.])],
+ [enable_netlink="$enableval"],
+ [enable_netlink=auto]
+)
+AS_IF([test "x$enable_netlink" != "xno"], [
+ build_netlink="yes"
+ PKG_CHECK_MODULES([DBUS], [dbus-1], [], [
+ build_netlink="no"
+ AS_IF([test "x$enable_netlink" = "xyes"] , [
+ AC_MSG_ERROR([Required dbus libraries for quota netlink daemon not found.])
+ ])
+ ])
+ PKG_CHECK_MODULES([LIBNL3], [libnl-3.0 >= 3.1 libnl-genl-3.0], [], [
+ build_netlink="no"
+ AS_IF([test "x$enable_netlink" = "xyes"] , [
+ AC_MSG_ERROR([Required libnl3 libraries for quota netlink daemon not found.])
+ ])
+ ])
+])
+AM_CONDITIONAL([WITH_NETLINK], [test "x$build_netlink" != "xno"])
+AC_SUBST(DBUS_CFLAGS)
+AC_SUBST(DBUS_LIBS)
+AC_SUBST(LIBNL3_CFLAGS)
+AC_SUBST(LIBNL3_LIBS)
+
+# =============
+# libwrap usage
+# =============
+AC_ARG_ENABLE([libwrap],
+ [AS_HELP_STRING([--disable-libwrap], [Do not use hosts.* for access checking on rpc.quotad.])],
+ [enable_libwrap="$enableval"],
+ [enable_libwrap=auto]
+)
+AS_IF([test "x$enable_libwrap" != "xno"], [
+ build_libwrap="yes"
+ AC_CHECK_HEADER([tcpd.h],[], [
+ build_libwrap="no"
+ AS_IF([test "x$enable_libwrap" = "xyes"] , [
+ AC_MSG_ERROR([tcpd.h not found and requested])
+ ], [
+ AC_MSG_WARN([tcpd.h not found])
+ ])
+ ])
+ AS_IF([test "x$build_libwrap" != "xno"], [
+ WRAP_LIBS="-lwrap"
+ AC_DEFINE([HOSTS_ACCESS], 1, [Use hosts.allow and hosts.deny for access checking of rpc.rquotad])
+ COMPILE_OPTS="$COMPILE_OPTS HOSTS_ACCESS"
+ ])
+])
+AC_SUBST(WRAP_LIBS)
+
+# =====================
+# various build options
+# =====================
+AC_ARG_ENABLE([rpc],
+ [AS_HELP_STRING([--disable-rpc], [Disable RPC support])],
+ [enable_rpc="$enableval"],
+ [enable_rpc=auto]
+)
+AS_IF([test x"$enable_rpc" != "xno"], [
+ AC_PATH_PROG([RPCGEN], [rpcgen])
+ AC_ARG_VAR([RPCGEN], [RPC compiler command])
+ build_rpc="yes"
+ AS_IF([test x"$RPCGEN" = "x"], [
+ AS_IF([test x"$enable_rpc" = "xyes"], [
+ AC_MSG_ERROR([could not locate required rpcgen])
+ ], [
+ AC_MSG_WARN([rpcgen not found])
+ ])
+ build_rpc="no"
+ ])
+
+ AS_IF([test x"$build_rpc" != "xno"], [
+ AC_DEFINE([RPC], 1, [Support for RPC])
+ COMPILE_OPTS="$COMPILE_OPTS RPC"
+ ])
+])
+AM_CONDITIONAL([WITH_RPC], [test x"$build_rpc" != "xno"])
+
+AC_ARG_ENABLE([rpcsetquota],
+ [AS_HELP_STRING([--enable-rpcsetquota], [Use RPC for setting quotas])],
+ [enable_rpcsetquota="$enableval"],
+ [enable_rpcsetquota=no]
+)
+AS_IF([test x"$enable_rpcsetquota" = "xyes"], [
+ AC_DEFINE([RPC_SETQUOTA], 1, [Allow setting of quotas over RPC])
+ COMPILE_OPTS="$COMPILE_OPTS RPC_SETQUOTA"
+])
+
+AC_ARG_ENABLE([xfs-roothack],
+ [AS_HELP_STRING([--enable-xfs-roothack], [Support old XFS root filesystems.])],
+ [enable_xfs_roothack="$enableval"],
+ [enable_xfs_roothack=no]
+)
+AS_IF([test x"$enable_xfs_roothack" = "xyes"], [
+ AC_DEFINE([XFS_ROOTHACK], 1, [Assume quota mount options for root filesystem])
+ COMPILE_OPTS="$COMPILE_OPTS XFS_ROOTHACK"
+])
+
+AC_ARG_ENABLE([bsd-behaviour],
+ [AS_HELP_STRING([--disable-bsd-behaviour], [Mimic BSD behaviour])],
+ [enable_bsd_behaviour="$enableval"],
+ [enable_bsd_behaviour=yes]
+)
+AS_IF([test x"$enable_bsd_behaviour" != "xno"], [
+ AC_DEFINE([BSD_BEHAVIOUR], 1, [Check rights to query / set quotas before calling quotactl])
+ COMPILE_OPTS="$COMPILE_OPTS BSD_BEHAVIOUR"
+])
+
+AC_ARG_WITH([proc-mounts],
+ [AS_HELP_STRING([--with-proc-mounts], [Use alternate mtab file instead of /proc/mounts])],
+ [with_proc_mounts="$withval"],
+ [with_proc_mounts="/proc/mounts"]
+)
+AS_IF([test "$with_proc_mounts" != "no"], [
+ AC_DEFINE_UNQUOTED([ALT_MTAB], ["$with_proc_mounts"], [File with mounted filesystems])
+])
+
+AC_DEFINE_UNQUOTED([COMPILE_OPTS], ["$COMPILE_OPTS"], [Configuration options])
+
+AC_CONFIG_FILES([
+Makefile
+po/Makefile.in
+])
+AC_OUTPUT
+
+# ==============================================
+# Display final informations about configuration
+# ==============================================
+AC_MSG_NOTICE([
+==============================================================================
+Build configuration:
+ bsd-behaviour: ${enable_bsd_behaviour}
+ ext2-direct: ${build_ext2direct}
+ ldap-mail: ${build_ldap}
+ libwrap: ${build_libwrap}
+ netlink: ${build_netlink}
+ nls: ${enable_nls}
+ proc-mounts: ${with_proc_mounts}
+ rpc: ${build_rpc}
+ rpcsetquota: ${enable_rpcsetquota}
+ xfs-roothack: ${enable_xfs_roothack}
+ werror: ${enable_werror}
+==============================================================================
+])
diff --git a/configure.in b/configure.in
deleted file mode 100644
index a83c1e1..0000000
--- a/configure.in
+++ /dev/null
@@ -1,253 +0,0 @@
-dnl Process this file with autoconf to produce a configure script.
-AC_INIT(quota.c)
-AC_PREREQ(2.50)
-AC_CONFIG_HEADERS([config.h])
-
-dnl Checks for programs.
-AC_PROG_CC
-AC_HEADER_STDC
-AC_PROG_INSTALL
-
-dnl Check for compiler options
-AC_ARG_ENABLE(static-link, [ --enable-static-link=[yes/no] Link all binaries statically [default=no].],
- ,
- enable_static_link="no")
-if test "x$enable_static_link" != "xyes"; then
- AC_MSG_CHECKING(whether compiler supports PIE)
- oldCFLAGS="$CFLAGS"
- CFLAGS="$CFLAGS -fPIE"
- oldLDFLAGS="$LDFLAGS"
- LDFLAGS="$LDFLAGS -pie"
- AC_LINK_IFELSE([AC_LANG_PROGRAM([[]])], compilepie="yes")
- if test "x$compilepie" != "xyes"; then
- CFLAGS="$oldCFLAGS"
- LDFLAGS="$oldLDFLAGS"
- AC_MSG_RESULT(no)
- else
- AC_MSG_RESULT(yes)
- fi
-else
- CFLAGS="$CFLAGS -static"
- LDFLAGS="$LDFLAGS -static"
-fi
-
-dnl Strip binaries before installation
-AC_ARG_ENABLE(strip-binaries, [ --enable-strip-binaries=[yes/no] Strip binaries while installing them [default=yes].],
- ,
- enable_strip="yes")
-if test "x$enable_strip" = "xyes"; then
- STRIP="-s"
-else
- STRIP=""
-fi
-
-dnl Checks for libraries.
-AC_ARG_ENABLE(ldapmail, [ --enable-ldapmail=[yes/no/try] Enable ldap mail address lookups [default=no].],
- ,
- enable_ldapmail="no")
-if test "x$enable_ldapmail" != "xno"; then
- have_new_ldap="no"
- have_old_ldap="no"
- AC_CHECK_LIB(ldap, ldap_initialize, have_new_ldap="yes", AC_CHECK_LIB(ldap, ldap_init, have_old_ldap="yes"))
- if test "x$have_new_ldap" != "xno" -o "x$have_old_ldap" != "xno"; then
- LDAPLIBS="-L/usr/lib -lldap -llber"
- AC_DEFINE([USE_LDAP_MAIL_LOOKUP], 1, [Lookup email address using LDAP])
- COMPILE_OPTS="$COMPILE_OPTS USE_LDAP_MAIL_LOOKUP"
- if test "x$have_new_ldap" = "xyes"; then
- AC_DEFINE([USE_LDAP_23], 1, [LDAP 2.3 or newer installed])
- AC_CHECK_DECL(ldap_perror, ,
- AC_DEFINE([NEED_LDAP_PERROR], 1, [ldap_perror function not declared]),
- [#include <ldap.h>])
- fi
- else
- if test "x$enable_ldapmail" = "xyes"; then
- AC_MSG_ERROR([LDAP support required but library not found.]);
- fi
- fi
-fi
-AC_SUBST(LDAPLIBS)
-
-
-AC_CHECK_HEADER(ext2fs/ext2fs.h,ext2fshead="yes")
-if test "x$ext2fshead" = "xyes"; then
- AC_DEFINE([HAVE_EXT2_INCLUDE], 1, [Header files for e2fslib])
- AC_MSG_CHECKING([for ext2_ino_t])
- have_ext2_ino_t="no"
- AC_EGREP_HEADER(ext2_ino_t, ext2fs/ext2fs.h, have_ext2_ino_t="yes")
- if test "x$have_ext2_ino_t" != "xyes"; then
- AC_MSG_RESULT([not found])
- else
- AC_MSG_RESULT([found])
- AC_DEFINE([HAVE_EXT2_INO_T], 1, [ext2fs.h defines ext2_ino_t])
- fi
-fi
-
-AC_ARG_ENABLE(ext2direct,
- [ --enable-ext2direct=[yes/no/try] Enable scanning of EXT2/EXT3 filesystem using e2fslib [default=try].],
- ,
- enable_ext2direct="try")
-if test "x$enable_ext2direct" != "xno"; then
- AC_CHECK_LIB(com_err, com_err, EXT2LIBS="-lcom_err $EXT2LIBS")
- AC_CHECK_LIB(ext2fs, ext2fs_initialize, EXT2LIBS="-lext2fs $EXT2LIBS",, "-lcom_err")
- if test "${ac_cv_lib_com_err_com_err}" != "yes" -o "${ac_cv_lib_ext2fs_ext2fs_initialize}" != "yes"; then
- if test "x$enable_ext2direct" = "xyes"; then
- AC_MSG_ERROR([Ext2 direct support required but libraries not found.])
- else
- AC_MSG_WARN([Ext2 direct support won't be compiled. Libraries not found.])
- fi
- enable_ext2direct="no"
- EXT2LIBS=""
- else
- if test "x$ext2fshead" != "xyes"; then
- if test "x$enable_ext2direct" = "xyes"; then
- AC_MSG_ERROR([Ext2 direct support required but header files not found.])
- else
- AC_MSG_WARN([Ext2 direct support won't be compiled. Header files not found.])
- fi
- enable_ext2direct="no"
- EXT2LIBS=""
- else
- enable_ext2direct="yes"
- fi
- fi
- if test "x$enable_ext2direct" = "xyes"; then
- AC_DEFINE([EXT2_DIRECT], 1, [Scanning of ext? filesystems using e2fslib])
- COMPILE_OPTS="$COMPILE_OPTS EXT2_DIRECT"
- fi
-fi
-AC_SUBST(EXT2LIBS)
-
-AC_ARG_ENABLE(netlink,
- [ --enable-netlink=[yes/no/try] Compile daemon receiving quota messages via netlink [default=no].],
- ,
- enable_netlink="no")
-if test "x$enable_netlink" != "xno"; then
- PKG_CHECK_MODULES([DBUS], [dbus-1])
-
- PKG_CHECK_MODULES([LIBNL3], [libnl-3.0 >= 3.1 libnl-genl-3.0])
-
- if test -z "$LIBNL3_LIBS" -o -z "$DBUS_LIBS"; then
- if test "x$enable_netlink" = "xyes"; then
- AC_MSG_ERROR([Required libraries for quota netlink daemon not found.])
- else
- AC_MSG_WARN([Quota netlink daemon won't be compiled. Required libraries not found.])
- fi
- enable_netlink="no"
- NETLINKLIBS=""
- else
- CPPFLAGS="$LIBNL3_CFLAGS $DBUS_CFLAGS $CPPFLAGS"
- NETLINKLIBS="$DBUS_LIBS $LIBNL3_LIBS"
- QUOTA_NETLINK_PROG=quota_nld
- fi
-fi
-AC_SUBST(QUOTA_NETLINK_PROG)
-AC_SUBST(NETLINKLIBS)
-
-AC_SEARCH_LIBS(gethostbyname, nsl)
-AC_MSG_CHECKING(for host_access in -lwrap)
-AC_CACHE_VAL(ac_cv_lib_wrap_main,
- saved_LIBS="$LIBS"
- LIBS="$LIBS -lwrap"
- [AC_LINK_IFELSE([AC_LANG_PROGRAM([[
- #include <stdio.h>
- #include <sys/types.h>
- #include <sys/socket.h>
- #include <netinet/in.h>
- #include <tcpd.h>
- struct request_info request;
- int deny_severity, allow_severity;]],[[hosts_access(&request);]])],
- dnl We always restore LIBS as we add -lwrap in the next check
- [ac_cv_lib_wrap_main=yes; LIBS="$saved_LIBS"; AC_MSG_RESULT(yes)],
- [ac_cv_lib_wrap_main=no; LIBS="$saved_LIBS"; AC_MSG_RESULT(no)])
- ])
-
-if test ${ac_cv_lib_wrap_main} = yes; then
- AC_CHECK_HEADER(tcpd.h,, [
- echo 'ERROR: could not find tcpd.h - missing TCP wrappers package'
- exit 1
- ])
- LIBS="$LIBS -lwrap"
- AC_DEFINE([HOSTS_ACCESS], 1, [Use hosts.allow and hosts.deny for access checking of rpc.rquotad])
- COMPILE_OPTS="$COMPILE_OPTS HOSTS_ACCESS"
-fi
-
-dnl Checks for typedefs, structures, and compiler characteristics.
-AC_C_CONST
-AC_C_INLINE
-
-AC_ARG_ENABLE(rpc,
- [ --enable-rpc=[yes/no] Enable RPC support [default=yes].],
- ,
- enable_rpc="yes")
-AC_ARG_ENABLE(rpcsetquota,
- [ --enable-rpcsetquota=[yes/no] Use RPC for setting quotas [default=no].],
- ,
- enable_rpcsetquota="no")
-AC_ARG_ENABLE(xfs_roothack,
- [ --enable-xfs_roothack=[yes/no] Support old XFS root filesystems [default=no].],
- ,
- enable_xfs_roothack="no")
-AC_ARG_ENABLE(bsd_behaviour,
- [ --enable-bsd_behaviour=[yes/no] Mimic BSD behaviour [default=yes].],
- ,
- enable_bsd_behaviour="yes")
-AC_ARG_ENABLE(libefence,
- [ --enable-libefence=[yes/no] Use Electric Fence memory checks [default=no].],
- ,
- enable_libefence="no")
-
-AC_ARG_ENABLE(nls,
- [ --enable-nls=[yes/no] Enable gettext [default=yes].],
- ,
- enable_nls="yes")
-AC_ARG_ENABLE(rootsbin,
- [ --enable-rootsbin=[yes/no] Use /sbin for some important binaries regardless $prefix [default=no].],
- ,
- enable_rootsbin="no")
-AC_ARG_ENABLE(proc-mounts,
- [ --enable-proc-mounts=[path] Use alternate file instead of /etc/mtab [default=/proc/mounts].],
- ,
- enable_proc_mounts="/proc/mounts")
-
-if test "$enable_rpc" = "yes" ; then
- AC_DEFINE([RPC], 1, [Support for RPC])
- COMPILE_OPTS="$COMPILE_OPTS RPC"
-fi
-if test "$enable_rpcsetquota" = "yes" ; then
- AC_DEFINE([RPC_SETQUOTA], 1, [Allow setting of quotas over RPC])
- COMPILE_OPTS="$COMPILE_OPTS RPC_SETQUOTA"
-fi
-if test "$enable_xfs_roothack" = "yes" ; then
- AC_DEFINE([XFS_ROOTHACK], 1, [Assume quota mount options for root filesystem])
- COMPILE_OPTS="$COMPILE_OPTS XFS_ROOTHACK"
-fi
-if test "$enable_bsd_behaviour" = "yes" ; then
- AC_DEFINE([BSD_BEHAVIOUR], 1, [Check rights to query / set quotas before calling quotactl])
- COMPILE_OPTS="$COMPILE_OPTS BSD_BEHAVIOUR"
-fi
-if test "$enable_libefence" = "yes" ; then
- LIBMALLOC="/usr/lib/libefence.a"
-fi
-if test "$enable_nls" = "yes" ; then
- AC_DEFINE([USE_GETTEXT], 1, [Use gettext to translate messages])
- INSTMO="inst_mo"
-fi
-if test "$enable_proc_mounts" != "no"; then
- AC_DEFINE_UNQUOTED([ALT_MTAB], ["$enable_proc_mounts"], [File with mounted filesystems])
-fi
-if test "$enable_rootsbin" = "yes" ; then
- ROOTSBIN="/sbin"
-else
- ROOTSBIN='$(prefix)/sbin'
-fi
-
-AC_DEFINE_UNQUOTED([COMPILE_OPTS], ["$COMPILE_OPTS"], [Configuration options])
-AC_DEFINE([PACKAGE_VERSION], ["4.02"], [Version of quota tools])
-
-AC_SUBST(LIBMALLOC)
-AC_SUBST(INSTMO)
-AC_SUBST(ROOTSBIN)
-AC_SUBST(CPPFLAGS)
-AC_SUBST(STRIP)
-
-AC_OUTPUT(Makefile)
diff --git a/convertquota.c b/convertquota.c
index 76bd1e8..d913e05 100644
--- a/convertquota.c
+++ b/convertquota.c
@@ -45,7 +45,7 @@ static void usage(void)
-f, --convert-format oldfmt,newfmt convert from old to VFSv0 quota format\n\
-h, --help show this help text and exit\n\
-V, --version output version information and exit\n\n"), progname);
- errstr(_("Bugs to %s\n"), MY_EMAIL);
+ errstr(_("Bugs to %s\n"), PACKAGE_BUGREPORT);
exit(1);
}
diff --git a/edquota.c b/edquota.c
index f433417..872e642 100644
--- a/edquota.c
+++ b/edquota.c
@@ -98,7 +98,7 @@ static void usage(void)
-T, --edit-times edit grace time of a user/group\n\
-h, --help display this help text and exit\n\
-V, --version display version information and exit\n\n"), stderr);
- fprintf(stderr, _("Bugs to: %s\n"), MY_EMAIL);
+ fprintf(stderr, _("Bugs to: %s\n"), PACKAGE_BUGREPORT);
exit(1);
}
diff --git a/install-sh b/install-sh
deleted file mode 100755
index e9de238..0000000
--- a/install-sh
+++ /dev/null
@@ -1,251 +0,0 @@
-#!/bin/sh
-#
-# install - install a program, script, or datafile
-# This comes from X11R5 (mit/util/scripts/install.sh).
-#
-# Copyright 1991 by the Massachusetts Institute of Technology
-#
-# Permission to use, copy, modify, distribute, and sell this software and its
-# documentation for any purpose is hereby granted without fee, provided that
-# the above copyright notice appear in all copies and that both that
-# copyright notice and this permission notice appear in supporting
-# documentation, and that the name of M.I.T. not be used in advertising or
-# publicity pertaining to distribution of the software without specific,
-# written prior permission. M.I.T. makes no representations about the
-# suitability of this software for any purpose. It is provided "as is"
-# without express or implied warranty.
-#
-# Calling this script install-sh is preferred over install.sh, to prevent
-# `make' implicit rules from creating a file called install from it
-# when there is no Makefile.
-#
-# This script is compatible with the BSD install script, but was written
-# from scratch. It can only install one file at a time, a restriction
-# shared with many OS's install programs.
-
-
-# set DOITPROG to echo to test this script
-
-# Don't use :- since 4.3BSD and earlier shells don't like it.
-doit="${DOITPROG-}"
-
-
-# put in absolute paths if you don't have them in your path; or use env. vars.
-
-mvprog="${MVPROG-mv}"
-cpprog="${CPPROG-cp}"
-chmodprog="${CHMODPROG-chmod}"
-chownprog="${CHOWNPROG-chown}"
-chgrpprog="${CHGRPPROG-chgrp}"
-stripprog="${STRIPPROG-strip}"
-rmprog="${RMPROG-rm}"
-mkdirprog="${MKDIRPROG-mkdir}"
-
-transformbasename=""
-transform_arg=""
-instcmd="$mvprog"
-chmodcmd="$chmodprog 0755"
-chowncmd=""
-chgrpcmd=""
-stripcmd=""
-rmcmd="$rmprog -f"
-mvcmd="$mvprog"
-src=""
-dst=""
-dir_arg=""
-
-while [ x"$1" != x ]; do
- case $1 in
- -c) instcmd="$cpprog"
- shift
- continue;;
-
- -d) dir_arg=true
- shift
- continue;;
-
- -m) chmodcmd="$chmodprog $2"
- shift
- shift
- continue;;
-
- -o) chowncmd="$chownprog $2"
- shift
- shift
- continue;;
-
- -g) chgrpcmd="$chgrpprog $2"
- shift
- shift
- continue;;
-
- -s) stripcmd="$stripprog"
- shift
- continue;;
-
- -t=*) transformarg=`echo $1 | sed 's/-t=//'`
- shift
- continue;;
-
- -b=*) transformbasename=`echo $1 | sed 's/-b=//'`
- shift
- continue;;
-
- *) if [ x"$src" = x ]
- then
- src=$1
- else
- # this colon is to work around a 386BSD /bin/sh bug
- :
- dst=$1
- fi
- shift
- continue;;
- esac
-done
-
-if [ x"$src" = x ]
-then
- echo "install: no input file specified"
- exit 1
-else
- true
-fi
-
-if [ x"$dir_arg" != x ]; then
- dst=$src
- src=""
-
- if [ -d $dst ]; then
- instcmd=:
- chmodcmd=""
- else
- instcmd=mkdir
- fi
-else
-
-# Waiting for this to be detected by the "$instcmd $src $dsttmp" command
-# might cause directories to be created, which would be especially bad
-# if $src (and thus $dsttmp) contains '*'.
-
- if [ -f $src -o -d $src ]
- then
- true
- else
- echo "install: $src does not exist"
- exit 1
- fi
-
- if [ x"$dst" = x ]
- then
- echo "install: no destination specified"
- exit 1
- else
- true
- fi
-
-# If destination is a directory, append the input filename; if your system
-# does not like double slashes in filenames, you may need to add some logic
-
- if [ -d $dst ]
- then
- dst="$dst"/`basename $src`
- else
- true
- fi
-fi
-
-## this sed command emulates the dirname command
-dstdir=`echo $dst | sed -e 's,[^/]*$,,;s,/$,,;s,^$,.,'`
-
-# Make sure that the destination directory exists.
-# this part is taken from Noah Friedman's mkinstalldirs script
-
-# Skip lots of stat calls in the usual case.
-if [ ! -d "$dstdir" ]; then
-defaultIFS='
-'
-IFS="${IFS-${defaultIFS}}"
-
-oIFS="${IFS}"
-# Some sh's can't handle IFS=/ for some reason.
-IFS='%'
-set - `echo ${dstdir} | sed -e 's@/@%@g' -e 's@^%@/@'`
-IFS="${oIFS}"
-
-pathcomp=''
-
-while [ $# -ne 0 ] ; do
- pathcomp="${pathcomp}${1}"
- shift
-
- if [ ! -d "${pathcomp}" ] ;
- then
- $mkdirprog "${pathcomp}"
- else
- true
- fi
-
- pathcomp="${pathcomp}/"
-done
-fi
-
-if [ x"$dir_arg" != x ]
-then
- $doit $instcmd $dst &&
-
- if [ x"$chowncmd" != x ]; then $doit $chowncmd $dst; else true ; fi &&
- if [ x"$chgrpcmd" != x ]; then $doit $chgrpcmd $dst; else true ; fi &&
- if [ x"$stripcmd" != x ]; then $doit $stripcmd $dst; else true ; fi &&
- if [ x"$chmodcmd" != x ]; then $doit $chmodcmd $dst; else true ; fi
-else
-
-# If we're going to rename the final executable, determine the name now.
-
- if [ x"$transformarg" = x ]
- then
- dstfile=`basename $dst`
- else
- dstfile=`basename $dst $transformbasename |
- sed $transformarg`$transformbasename
- fi
-
-# don't allow the sed command to completely eliminate the filename
-
- if [ x"$dstfile" = x ]
- then
- dstfile=`basename $dst`
- else
- true
- fi
-
-# Make a temp file name in the proper directory.
-
- dsttmp=$dstdir/#inst.$$#
-
-# Move or copy the file name to the temp name
-
- $doit $instcmd $src $dsttmp &&
-
- trap "rm -f ${dsttmp}" 0 &&
-
-# and set any options; do chmod last to preserve setuid bits
-
-# If any of these fail, we abort the whole thing. If we want to
-# ignore errors from any of these, just make sure not to ignore
-# errors from the above "$doit $instcmd $src $dsttmp" command.
-
- if [ x"$chowncmd" != x ]; then $doit $chowncmd $dsttmp; else true;fi &&
- if [ x"$chgrpcmd" != x ]; then $doit $chgrpcmd $dsttmp; else true;fi &&
- if [ x"$stripcmd" != x ]; then $doit $stripcmd $dsttmp; else true;fi &&
- if [ x"$chmodcmd" != x ]; then $doit $chmodcmd $dsttmp; else true;fi &&
-
-# Now rename the file to the real destination.
-
- $doit $rmcmd -f $dstdir/$dstfile &&
- $doit $mvcmd $dsttmp $dstdir/$dstfile
-
-fi &&
-
-
-exit 0
diff --git a/po/.gitignore b/po/.gitignore
new file mode 100644
index 0000000..9bc1415
--- /dev/null
+++ b/po/.gitignore
@@ -0,0 +1,13 @@
+POTFILES
+Makevars.template
+Rules-quot
+boldquot.sed
+en@boldquot.header
+en@quot.header
+insert-header.sin
+quot.sed
+remove-potcdate.sin
+*.pot
+*.gmo
+remove-potcdate.sed
+stamp-po
diff --git a/po/LINGUAS b/po/LINGUAS
new file mode 100644
index 0000000..bcf2e83
--- /dev/null
+++ b/po/LINGUAS
@@ -0,0 +1 @@
+cs de fr pl
diff --git a/po/Makevars b/po/Makevars
new file mode 100644
index 0000000..38237ed
--- /dev/null
+++ b/po/Makevars
@@ -0,0 +1,41 @@
+# Makefile variables for PO directory in any package using GNU gettext.
+
+# Usually the message domain is the same as the package name.
+DOMAIN = $(PACKAGE)
+
+# These two variables depend on the location of this directory.
+subdir = po
+top_builddir = ..
+
+# These options get passed to xgettext.
+XGETTEXT_OPTIONS = --keyword=_ --keyword=N_
+
+# This is the copyright holder that gets inserted into the header of the
+# $(DOMAIN).pot file. Set this to the copyright holder of the surrounding
+# package. (Note that the msgstr strings, extracted from the package's
+# sources, belong to the copyright holder of the package.) Translators are
+# expected to transfer the copyright for their translations to this person
+# or entity, or to disclaim their copyright. The empty string stands for
+# the public domain; in this case the translators are expected to disclaim
+# their copyright.
+COPYRIGHT_HOLDER =
+
+# This is the email address or URL to which the translators shall report
+# bugs in the untranslated strings:
+# - Strings which are not entire sentences, see the maintainer guidelines
+# in the GNU gettext documentation, section 'Preparing Strings'.
+# - Strings which use unclear terms or require additional context to be
+# understood.
+# - Strings which make invalid assumptions about notation of date, time or
+# money.
+# - Pluralisation problems.
+# - Incorrect English spelling.
+# - Incorrect formatting.
+# It can be your email address, or a mailing list address where translators
+# can write to without being subscribed, or the URL of a web page through
+# which the translators can contact you.
+MSGID_BUGS_ADDRESS = jack@suse.cz
+
+# This is the list of locale categories, beyond LC_MESSAGES, for which the
+# message catalogs shall be used. It is usually empty.
+EXTRA_LOCALE_CATEGORIES =
diff --git a/pot.c b/pot.c
index e5a1e1d..6d9108d 100644
--- a/pot.c
+++ b/pot.c
@@ -10,7 +10,7 @@ void gettexton(void)
{
#ifdef USE_GETTEXT
setlocale(LC_ALL, "");
- bindtextdomain("quota", "/usr/share/locale");
- textdomain("quota");
+ bindtextdomain(PACKAGE, PACKAGE_LOCALE_DIR);
+ textdomain(PACKAGE);
#endif
}
diff --git a/quota.c b/quota.c
index 1befbde..049dac4 100644
--- a/quota.c
+++ b/quota.c
@@ -108,7 +108,7 @@ static void usage(void)
--hide-device do not show file system device in output\n\
-h, --help display this help message and exit\n\
-V, --version display version information and exit\n\n"));
- fprintf(stderr, _("Bugs to: %s\n"), MY_EMAIL);
+ fprintf(stderr, _("Bugs to: %s\n"), PACKAGE_BUGREPORT);
exit(1);
}
diff --git a/quotacheck.c b/quotacheck.c
index e62c3a7..3cf87e0 100644
--- a/quotacheck.c
+++ b/quotacheck.c
@@ -315,7 +315,7 @@ static void usage(void)
-a, --all check all filesystems\n\
-h, --help display this message and exit\n\
-V, --version display version information and exit\n\n"), progname);
- printf(_("Bugs to %s\n"), MY_EMAIL);
+ printf(_("Bugs to %s\n"), PACKAGE_BUGREPORT);
exit(1);
}
@@ -736,7 +736,7 @@ static int rename_files(struct mount_entry *mnt, int type)
/* Make backingup safe */
sstrncat(newfilename, "~", PATH_MAX);
if (newfilename[strlen(newfilename) - 1] != '~')
- die(8, _("Name of quota file too long. Contact %s.\n"), MY_EMAIL);
+ die(8, _("Name of quota file too long. Contact %s.\n"), PACKAGE_BUGREPORT);
if (rename(filename, newfilename) < 0) {
errstr(_("Cannot rename old quotafile %s to %s: %s\n"),
filename, newfilename, strerror(errno));
diff --git a/quotasync.c b/quotasync.c
index cfc3f2d..99bb3a0 100644
--- a/quotasync.c
+++ b/quotasync.c
@@ -7,6 +7,7 @@
#include <getopt.h>
#include "pot.h"
+#include "config.h"
#include "common.h"
#include "quotasys.h"
#include "quotaio.h"
@@ -38,7 +39,7 @@ static void usage(int status)
"-V, --version display version information and exit\n"
"\n"
));
- printf(_("Report bugs to <%s>.\n"), MY_EMAIL);
+ printf(_("Report bugs to <%s>.\n"), PACKAGE_BUGREPORT);
exit(status);
}
diff --git a/repquota.c b/repquota.c
index cce017a..744af70 100644
--- a/repquota.c
+++ b/repquota.c
@@ -63,7 +63,7 @@ static void usage(void)
-a, --all report information for all mount points with quotas\n\
-h, --help display this help message and exit\n\
-V, --version display version information and exit\n\n"), progname);
- fprintf(stderr, _("Bugs to %s\n"), MY_EMAIL);
+ fprintf(stderr, _("Bugs to %s\n"), PACKAGE_BUGREPORT);
exit(1);
}
diff --git a/setquota.c b/setquota.c
index cc5fee8..51d7b3c 100644
--- a/setquota.c
+++ b/setquota.c
@@ -76,7 +76,7 @@ static void usage(void)
-T, --edit-times edit grace times for user/group\n\
-h, --help display this help text and exit\n\
-V, --version display version information and exit\n\n"), stderr);
- fprintf(stderr, _("Bugs to: %s\n"), MY_EMAIL);
+ fprintf(stderr, _("Bugs to: %s\n"), PACKAGE_BUGREPORT);
exit(1);
}
diff --git a/warnquota.c b/warnquota.c
index 009d9e9..7ce61cc 100644
--- a/warnquota.c
+++ b/warnquota.c
@@ -165,50 +165,26 @@ static void wc_exit(int ex_stat)
{
#ifdef USE_LDAP_MAIL_LOOKUP
if(ldapconn != NULL)
-#ifdef USE_LDAP_23
ldap_unbind_ext(ldapconn, NULL, NULL);
-#else
- ldap_unbind(ldapconn);
-#endif
#endif
exit(ex_stat);
}
#ifdef USE_LDAP_MAIL_LOOKUP
-#ifdef NEED_LDAP_PERROR
-static void ldap_perror(LDAP *ld, LDAP_CONST char *s)
-{
- int err;
-
- ldap_get_option(ld, LDAP_OPT_RESULT_CODE, &err);
- errstr(_("%s: %s\n"), s, ldap_err2string(err));
-}
-#endif
-
static int setup_ldap(struct configparams *config)
{
int ret;
-#ifdef USE_LDAP_23
struct berval cred = { .bv_val = config->ldap_bindpw,
.bv_len = strlen(config->ldap_bindpw) };
-#endif
-#ifdef USE_LDAP_23
ldap_initialize(&ldapconn, config->ldap_uri);
-#else
- ldapconn = ldap_init(config->ldap_host, config->ldap_port);
-#endif
if(ldapconn == NULL) {
ldap_perror(ldapconn, "ldap_init");
return -1;
}
-#ifdef USE_LDAP_23
ret = ldap_sasl_bind_s(ldapconn, config->ldap_binddn, LDAP_SASL_SIMPLE, &cred, NULL, NULL, NULL);
-#else
- ret = ldap_bind_s(ldapconn, config->ldap_binddn, config->ldap_bindpw, LDAP_AUTH_SIMPLE);
-#endif
if(ret < 0) {
ldap_perror(ldapconn, "ldap_bind");
return -1;
@@ -424,9 +400,6 @@ static char *lookup_user(struct configparams *config, char *user)
searchbuf, NULL, 0, NULL, NULL, NULL,
0, &result);
- ret = ldap_search_s(ldapconn, config->ldap_basedn, LDAP_SCOPE_SUBTREE,
- searchbuf, NULL, 0, &result);
-
if (ret < 0) {
errstr(_("Error with %s.\n"), user);
ldap_perror(ldapconn, "ldap_search");
@@ -872,15 +845,10 @@ cc_parse_err:
#ifdef USE_LDAP_MAIL_LOOKUP
if (config->use_ldap_mail)
{
-#ifdef USE_LDAP_23
if (!config->ldap_uri[0]) {
snprintf(config->ldap_uri, CNF_BUFFER, "ldap://%s:%d", config->ldap_host, config->ldap_port);
errstr(_("LDAP library version >= 2.3 detected. Please use LDAP_URI instead of hostname and port.\nGenerated URI %s\n"), config->ldap_uri);
}
-#else
- if (config->ldap_uri[0])
- die(1, _("LDAP library does not support ldap_initialize() but URI is specified."));
-#endif
}
#endif
fclose(fp);
@@ -1010,7 +978,7 @@ static void usage(void)
-a, --admins-file=admins-file non-default admins file\n\
-h, --help display this help message and exit\n\
-v, --version display version information and exit\n\n"));
- fprintf(stderr, _("Bugs to %s\n"), MY_EMAIL);
+ fprintf(stderr, _("Bugs to %s\n"), PACKAGE_BUGREPORT);
wc_exit(1);
}