build: ensure sys/select.h is included
[coreutils.git] / TODO
blob205acf6bb54ade3a6be3bb824281a70e50993d95
1 If you're interested in helping, here are some tasks that we've considered
2 over the years.  Beware: some are quite old and no longer valid.  To avoid
3 wasting your time by duplicating work or by working on a task that is no
4 longer pertinent, please search the mailing list and post your intent
5 before embarking on a big project.
7 ==================================================
8 Modify chmod so that it does not change an inode's st_ctime
9   when the selected operation would have no other effect.
10   First suggested by Hans Ecke <https://hans.ecke.ws> in
11     https://lists.gnu.org/r/bug-coreutils/2004-09/msg00145.html
12   Discussed more recently on <https://bugs.debian.org/497514>.
14 document the following in coreutils.texi:
15   [
16   pinky
18 Suggestion from Paul Eggert:
19   More generally, there's not that much use for imaxtostr nowadays,
20   since the inttypes module and newer versions of gettext allow things
21   like _("truncating %s at %" PRIdMAX " bytes") to work portably.
22   I suspect that (if someone cares to take the time) we can remove
23   all instances of imaxtostr and umaxtostr in coreutils and gnulib.
25 cp --recursive: use fts and *at functions to perform directory traversals
26   in source and destination hierarchy rather than forming full file names.
27   The latter (current) approach fails unnecessarily when the names
28   become very long, and requires space and time that is quadratic in the
29   depth of the hierarchy.  [Bo Borgerson is working on this]
31 printf:
32   Now that gnulib supports *printf("%a"), import one of the
33   *printf-posix modules so that printf(1) will support %a even on
34   platforms where the native *printf(3) is deficient.
35   Suggestion from Eric Blake.
37 consider adding some implementation of the "col" utility
38   Suggested by Karl Berry.
40 doc/coreutils.texi:
41   Address this comment: FIXME: mv's behavior in this case is system-dependent
42   Better still: fix the code so it's *not* system-dependent.
44 ls: add --format=FORMAT option that controls how each line is printed.
46 copy.c: Address the FIXME-maybe comment in copy_internal.
47 And once that's done, add an exclusion so that 'cp --link'
48 no longer incurs the overhead of saving src. dev/ino and dest. filename
49 in the hash table.
51 Write an autoconf test to work around build failure in HPUX's 64-bit mode.
52 See notes in README -- and remove them once there's a work-around.
54 Integrate use of sendfile, suggested here:
55   https://lists.gnu.org/r/bug-fileutils/2003-03/msg00030.html
56 I don't plan to do that, since a few tests demonstrate no significant benefit.
58 printf: consider adapting builtins/printf.def from bash
60 tail: don't use xlseek; it *exits*.
61   Instead, maybe use a macro and return nonzero.
63 tr: support nontrivial equivalence classes, e.g. [=e=] with LC_COLLATE=fr_FR
65 lib/strftime.c: Since %N is the only format that we need but that
66   glibc's strftime doesn't support, consider using a wrapper that
67   would expand /%(-_)?\d*N/ to the desired string and then pass the
68   resulting string to glibc's strftime.
70 sort: Investigate better sorting algorithms; see Knuth vol. 3.
72   We tried list merge sort, but it was about 50% slower than the
73   recursive algorithm currently used by sortlines, and it used more
74   comparisons.  We're not sure why this was, as the theory suggests it
75   should do fewer comparisons, so perhaps this should be revisited.
76   List merge sort was implemented in the style of Knuth algorithm
77   5.2.4L, with the optimization suggested by exercise 5.2.4-22.  The
78   test case was 140,213,394 bytes, 426,4424 lines, text taken from the
79   GCC 3.3 distribution, sort.c compiled with GCC 2.95.4 and running on
80   Debian 3.0r1 GNU/Linux, 2.4GHz Pentium 4, single pass with no
81   temporary files and plenty of RAM.
83   Since comparisons seem to be the bottleneck, perhaps the best
84   algorithm to try next should be merge insertion.  See Knuth section
85   5.3.1, who credits Lester Ford, Jr. and Selmer Johnson, American
86   Mathematical Monthly 66 (1959), 387-389.
88 shred: Update shred as described here to conform to DoD 5220 rules:
89 https://lists.gnu.org/r/bug-coreutils/2007-05/msg00075.html
91 Remove suspicious uses of alloca (ones that may allocate more than
92    about 4k)
94 Improve test coverage.
95   See HACKING for instructions on generating an html test coverage report.
96   Find a program that has poor coverage and improve.
98 Changes expected to go in, someday.
99 ======================================
101   dd patch from Olivier Delhomme
103   test/mv/*: clean up $other_partition_tmpdir in all cases
105   ls: when both -l and --dereference-command-line-symlink-to-dir are
106   specified, consider whether to let the latter select whether to
107   dereference command line symlinks to directories.  Since -l has
108   an implicit --NO-dereference-command-line-symlink-to-dir meaning.
109   Pointed out by Karl Berry.
111   Pending copyright papers:
112   ------------------------
113   getpwnam from Bruce Korb
115   pb (progress bar) from Miika Pekkarinen
117   ------------------------------
119 Remove long-deprecated options.  Search case-insensitive for
120 'deprecated' and 'remove in '.  Automate this.
122 Add a distcheck-time test to ensure that every distributed
123 file is either read-only(indicating generated) or is
124 version-controlled and up to date.
126 remove all uses of the 'register' keyword: Done.  add a maint.mk rule
127   for this, too.
129 remove or adjust chown's --changes option, since it
130   can't always do what it currently says it does.
132 Support arbitrary-precision arithmetic in those tools for which it
133 makes sense.  Factor and expr already support this via libgmp.
134 The "test" program is covered via its string-based comparison of
135 integers.  To be converted: seq.
137 Adapt tools like wc, tr, fmt, etc. (most of the textutils) to be
138   multibyte aware.  The problem is that I want to avoid duplicating
139   significant blocks of logic, yet I also want to incur only minimal
140   (preferably 'no') cost when operating in single-byte mode.
142 pr's use of nstrftime can make it malloc a very large (up to SIZE_MAX) buffer
144 -----
146 Copyright (C) 2002-2019 Free Software Foundation, Inc.
148 This program is free software: you can redistribute it and/or modify
149 it under the terms of the GNU General Public License as published by
150 the Free Software Foundation, either version 3 of the License, or
151 (at your option) any later version.
153 This program is distributed in the hope that it will be useful,
154 but WITHOUT ANY WARRANTY; without even the implied warranty of
155 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
156 GNU General Public License for more details.
158 You should have received a copy of the GNU General Public License
159 along with this program.  If not, see <https://www.gnu.org/licenses/>.