mirror of
https://git.savannah.gnu.org/git/coreutils.git
synced 2025-09-10 07:59:52 +02:00
Compare commits
598 Commits
FILEUTILS-
...
FILEUTILS-
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
6b3f36f935 | ||
|
|
1010c1f580 | ||
|
|
7490632078 | ||
|
|
537381d409 | ||
|
|
3a01be66d4 | ||
|
|
8a87c1a169 | ||
|
|
07b07ca07c | ||
|
|
26a10a8026 | ||
|
|
072c1efe39 | ||
|
|
c38939be8e | ||
|
|
e48314ac1b | ||
|
|
7c94dda02d | ||
|
|
fe6c711f48 | ||
|
|
2c7c121c13 | ||
|
|
7a8b837062 | ||
|
|
25eb22e88f | ||
|
|
7f798f5f4f | ||
|
|
9d502e7240 | ||
|
|
c1ecd3afea | ||
|
|
a95088a5ea | ||
|
|
fb43ebcbae | ||
|
|
73ed11f2b7 | ||
|
|
6390686aab | ||
|
|
3e0c759c3a | ||
|
|
10f565971b | ||
|
|
e1ea22da05 | ||
|
|
1e71247ea0 | ||
|
|
46f650f6b0 | ||
|
|
74bca24efe | ||
|
|
e385fd1e4c | ||
|
|
239899ae58 | ||
|
|
2a3863e2b8 | ||
|
|
bd30083472 | ||
|
|
01839f9f82 | ||
|
|
6f807a8598 | ||
|
|
94439345f5 | ||
|
|
e9dc554349 | ||
|
|
68ed0308cf | ||
|
|
fb04070061 | ||
|
|
9200311684 | ||
|
|
dd374cd779 | ||
|
|
71076df2d8 | ||
|
|
a1a27df129 | ||
|
|
fd685e41d6 | ||
|
|
c672fc6df6 | ||
|
|
0a735b7b9e | ||
|
|
5aaadded9d | ||
|
|
a8bcd782c4 | ||
|
|
2be7ff8311 | ||
|
|
0894db7b3f | ||
|
|
d58a074dea | ||
|
|
d73bc3ca57 | ||
|
|
186d893f27 | ||
|
|
edeada009c | ||
|
|
18195dd699 | ||
|
|
338b31ba60 | ||
|
|
562eb3d16d | ||
|
|
175fb661e0 | ||
|
|
50c04a9d3e | ||
|
|
8a66d0dd57 | ||
|
|
1f678023d5 | ||
|
|
b66a30133f | ||
|
|
598a7bda46 | ||
|
|
0800b55642 | ||
|
|
5ac433d292 | ||
|
|
b22469537b | ||
|
|
591844b387 | ||
|
|
2611844743 | ||
|
|
c04fc60484 | ||
|
|
ffb626613a | ||
|
|
3452006a53 | ||
|
|
161422b9b2 | ||
|
|
2091adbbb1 | ||
|
|
ccbf5f37f1 | ||
|
|
ef2b6836fd | ||
|
|
44386ac6ff | ||
|
|
5c7e1b6bee | ||
|
|
3266134b2a | ||
|
|
63571532a2 | ||
|
|
82b01ee905 | ||
|
|
48569d6b98 | ||
|
|
211fe36692 | ||
|
|
8dd8bb78b1 | ||
|
|
d64cc3c1ef | ||
|
|
db7201835d | ||
|
|
74cb2ee314 | ||
|
|
6d24eee926 | ||
|
|
aeb7c0bc47 | ||
|
|
940f23f4a4 | ||
|
|
f3f1cae097 | ||
|
|
fbe50426e2 | ||
|
|
8011a147de | ||
|
|
3cca257a3b | ||
|
|
de96d28c57 | ||
|
|
783fb6b2a6 | ||
|
|
b969dad022 | ||
|
|
c1db691c12 | ||
|
|
5f9c33edfe | ||
|
|
10d7644859 | ||
|
|
6cb5a99aa7 | ||
|
|
f696bb6737 | ||
|
|
8a9acec293 | ||
|
|
7eeedf8385 | ||
|
|
4c066c3552 | ||
|
|
6e5149f0ab | ||
|
|
af12dd6260 | ||
|
|
f8e40348be | ||
|
|
be8f2b0de2 | ||
|
|
279f065a06 | ||
|
|
c7837e95d2 | ||
|
|
9130f4b9d2 | ||
|
|
5aa14aeef0 | ||
|
|
61976fe88d | ||
|
|
0868a7d0bd | ||
|
|
48be557ad6 | ||
|
|
371f45401c | ||
|
|
9b9213f122 | ||
|
|
4c3d7d6a8b | ||
|
|
720d1c1c5e | ||
|
|
0dac1e107c | ||
|
|
31a8ced738 | ||
|
|
eb07a88b9e | ||
|
|
0503b28076 | ||
|
|
f45eaa5782 | ||
|
|
2f00343264 | ||
|
|
323c9cfee7 | ||
|
|
676a608318 | ||
|
|
39d1a08208 | ||
|
|
9ca6f19a2d | ||
|
|
0acd885d83 | ||
|
|
9110853f39 | ||
|
|
4ffe108e39 | ||
|
|
7290a43da9 | ||
|
|
9cfc701536 | ||
|
|
b0a020d50b | ||
|
|
36942690e1 | ||
|
|
afda328772 | ||
|
|
8a752e8696 | ||
|
|
8bd5d9e607 | ||
|
|
6885aee87b | ||
|
|
e4c57a939b | ||
|
|
b802aa3f55 | ||
|
|
8f915aadf8 | ||
|
|
662e8b4a03 | ||
|
|
3dd86270c6 | ||
|
|
ce7c0d5468 | ||
|
|
9ae64058d2 | ||
|
|
92de89ed2c | ||
|
|
5f0b9f1d99 | ||
|
|
8ebfd37293 | ||
|
|
cb6351aa82 | ||
|
|
a518e28429 | ||
|
|
7de0d8e233 | ||
|
|
839c312d49 | ||
|
|
783bace690 | ||
|
|
31d836282b | ||
|
|
bc73cf3351 | ||
|
|
731cbc77fb | ||
|
|
2bd16e646e | ||
|
|
7f2c13e703 | ||
|
|
635a7c3186 | ||
|
|
42d1927306 | ||
|
|
ba246b0f36 | ||
|
|
13ff080b78 | ||
|
|
06a5782edd | ||
|
|
12f377da25 | ||
|
|
c423a2d74a | ||
|
|
04a1a572f4 | ||
|
|
1ba3bd3896 | ||
|
|
fb59a28b16 | ||
|
|
ab48b17dca | ||
|
|
d2ca2163c6 | ||
|
|
5ae342e1a9 | ||
|
|
6c635d1f27 | ||
|
|
42640f71df | ||
|
|
0b83b3090b | ||
|
|
4b583d1691 | ||
|
|
a182aa4e5a | ||
|
|
22ca9b17a5 | ||
|
|
04916b80de | ||
|
|
d7d7ae76b2 | ||
|
|
da7809f65c | ||
|
|
b7d3a68ce5 | ||
|
|
8794c292e7 | ||
|
|
ece3b1d144 | ||
|
|
8087dd5668 | ||
|
|
1a622aa2d9 | ||
|
|
1ea9952168 | ||
|
|
4df74fe308 | ||
|
|
68545c98ed | ||
|
|
4650315342 | ||
|
|
fbfde91f6a | ||
|
|
e3f1d80dd9 | ||
|
|
5e58599e6e | ||
|
|
c22036ab86 | ||
|
|
34ffd87f30 | ||
|
|
cea704d6da | ||
|
|
ddf8459662 | ||
|
|
8320e65164 | ||
|
|
f42460fb09 | ||
|
|
24a118665e | ||
|
|
3bcffe04d7 | ||
|
|
79523152dd | ||
|
|
35aaa568cd | ||
|
|
85da146bd2 | ||
|
|
ae8ee650ea | ||
|
|
4a11d01711 | ||
|
|
f76a4b618e | ||
|
|
c8c91b5e20 | ||
|
|
70155d8013 | ||
|
|
af14a04c19 | ||
|
|
6e62afaaed | ||
|
|
9190f77006 | ||
|
|
5d845a1678 | ||
|
|
f6c32178c7 | ||
|
|
ff5cd3f6a3 | ||
|
|
b3d8117527 | ||
|
|
103713c42b | ||
|
|
c84fb64144 | ||
|
|
8e02fb10ab | ||
|
|
1b47ed2714 | ||
|
|
dcd02c8008 | ||
|
|
a80c49322b | ||
|
|
3982e9cdf8 | ||
|
|
a5b6fae599 | ||
|
|
b660d78cf5 | ||
|
|
c86883a62a | ||
|
|
e36197cd8f | ||
|
|
2185c1f3d8 | ||
|
|
48a76e855c | ||
|
|
19b5a4f761 | ||
|
|
9dbd283b1e | ||
|
|
4376f9f2ce | ||
|
|
37fea371b7 | ||
|
|
bb02f48670 | ||
|
|
64cd458e0a | ||
|
|
bc9aded4b9 | ||
|
|
a611c6cbf6 | ||
|
|
68c33eea03 | ||
|
|
fec6a430da | ||
|
|
1266fc26ee | ||
|
|
41a41dd48e | ||
|
|
e59e2e803c | ||
|
|
52c7e3147e | ||
|
|
8829551700 | ||
|
|
e95fe088e1 | ||
|
|
e13281014a | ||
|
|
aac56cabe4 | ||
|
|
df5f33a5bf | ||
|
|
0799786a33 | ||
|
|
6621f0a9a9 | ||
|
|
d5b9b29ac6 | ||
|
|
022a19b21f | ||
|
|
12133d7f01 | ||
|
|
58dfd6b442 | ||
|
|
5fc47138b1 | ||
|
|
4a2b289e7c | ||
|
|
bab072f3aa | ||
|
|
8679e372cd | ||
|
|
b0690ba414 | ||
|
|
ed354b6490 | ||
|
|
81d1fa5cb6 | ||
|
|
421e75544b | ||
|
|
7466f41075 | ||
|
|
1e7d4b9c70 | ||
|
|
6a13b75511 | ||
|
|
ebefd435aa | ||
|
|
b3335ab809 | ||
|
|
d293e5f03c | ||
|
|
0a470f01de | ||
|
|
b181d31372 | ||
|
|
b3a49ee8d0 | ||
|
|
35b886ad7b | ||
|
|
cecde31171 | ||
|
|
ae6c43a3ab | ||
|
|
17432bd066 | ||
|
|
c835f92a61 | ||
|
|
89b765e32c | ||
|
|
3752e13942 | ||
|
|
858afc04d2 | ||
|
|
5fecd9e4d5 | ||
|
|
ae5ee331f1 | ||
|
|
954c7bc4cc | ||
|
|
625dc74361 | ||
|
|
b26beb4996 | ||
|
|
0b3d661480 | ||
|
|
33448d128a | ||
|
|
b3ef6f599d | ||
|
|
72f95044eb | ||
|
|
859f8587f8 | ||
|
|
24e15328df | ||
|
|
357c53621f | ||
|
|
fd688bcc5f | ||
|
|
e8c6c8175b | ||
|
|
561e4c139e | ||
|
|
507288d2c7 | ||
|
|
6c47524481 | ||
|
|
300c151b8b | ||
|
|
3c7e9fec08 | ||
|
|
7235fb47cc | ||
|
|
8ef2abf7e9 | ||
|
|
5e55e49972 | ||
|
|
48a255beb0 | ||
|
|
17a2ec94a8 | ||
|
|
e7f8503138 | ||
|
|
f789ddbdda | ||
|
|
1f1bd53b86 | ||
|
|
3a2afe3311 | ||
|
|
20b960db10 | ||
|
|
8fd3e8664b | ||
|
|
1b25f1c2cd | ||
|
|
8569e32ec8 | ||
|
|
1321f30e73 | ||
|
|
290ee99712 | ||
|
|
3008ad90f4 | ||
|
|
8c5b30bc1e | ||
|
|
f0fa287b4f | ||
|
|
4ecb3b28f1 | ||
|
|
ea93e0b7ad | ||
|
|
7603401c86 | ||
|
|
90d97b9703 | ||
|
|
4091022393 | ||
|
|
338061e307 | ||
|
|
6a99b4cc40 | ||
|
|
86d6c36d09 | ||
|
|
a7f5043de8 | ||
|
|
5110583f3e | ||
|
|
813c8e8bb6 | ||
|
|
7d72c942bb | ||
|
|
f17cc2e29c | ||
|
|
4f4111709c | ||
|
|
beed39a03c | ||
|
|
d5f09a0fd1 | ||
|
|
3692f57123 | ||
|
|
d3d5565035 | ||
|
|
3e39947b49 | ||
|
|
c8a3fc9bed | ||
|
|
d43b4dcaf8 | ||
|
|
54f9b87874 | ||
|
|
1c28626053 | ||
|
|
6c674869b3 | ||
|
|
888a5250a5 | ||
|
|
d468c227b0 | ||
|
|
52314f2cd8 | ||
|
|
8d2b4f9786 | ||
|
|
b44299cfd7 | ||
|
|
5ea5ea9d2c | ||
|
|
7d21f2f4d0 | ||
|
|
73db5c12b9 | ||
|
|
53ac4c028b | ||
|
|
916a46a980 | ||
|
|
8b59538e69 | ||
|
|
eb34cbfc13 | ||
|
|
4360d0f52d | ||
|
|
e74a22ebb7 | ||
|
|
fcc65666b5 | ||
|
|
a16b0a142f | ||
|
|
5c39a3b65b | ||
|
|
4885753994 | ||
|
|
156de2ae7a | ||
|
|
40f8a7ad2b | ||
|
|
8f477a9072 | ||
|
|
d5ce3b1c3c | ||
|
|
54d0c0bb5a | ||
|
|
09c73133aa | ||
|
|
17fe725ebb | ||
|
|
c02f8ed500 | ||
|
|
90b901cd1c | ||
|
|
73c7efa3ee | ||
|
|
e155f4bf01 | ||
|
|
1d3c57118b | ||
|
|
195b5ebbe7 | ||
|
|
ba788477a8 | ||
|
|
6846ffa9d9 | ||
|
|
4fb3a6f765 | ||
|
|
5460d4a9c8 | ||
|
|
7f5d303c61 | ||
|
|
a65bae921e | ||
|
|
89cf1fc2cf | ||
|
|
a13947a7a3 | ||
|
|
ddc2531899 | ||
|
|
80729c5841 | ||
|
|
83ada8596c | ||
|
|
2a1d6f9b5f | ||
|
|
f2ac53d4ea | ||
|
|
f31b9b9fee | ||
|
|
acc8601b65 | ||
|
|
8dd5415e02 | ||
|
|
8a4da0e3ff | ||
|
|
95f9b268e9 | ||
|
|
d2ad9d8cf4 | ||
|
|
0ccd71dd94 | ||
|
|
1c7be9d1bb | ||
|
|
c9893d18e3 | ||
|
|
fb1f09c76e | ||
|
|
b1cc662215 | ||
|
|
f86a3c16d3 | ||
|
|
6d244887aa | ||
|
|
f86df3250c | ||
|
|
65a915647c | ||
|
|
2882d4477d | ||
|
|
2793223907 | ||
|
|
a5937bbc71 | ||
|
|
d0cac59c72 | ||
|
|
ed0923a11c | ||
|
|
42096600e3 | ||
|
|
523fb680f6 | ||
|
|
3f36b30756 | ||
|
|
4a1512e4b2 | ||
|
|
ad44ac84c8 | ||
|
|
c7975ba578 | ||
|
|
62a92dec57 | ||
|
|
a37e7e6b78 | ||
|
|
d5718682cc | ||
|
|
81e3dc9283 | ||
|
|
daa3f22091 | ||
|
|
b87899c834 | ||
|
|
4accfeb4e0 | ||
|
|
377b0c7942 | ||
|
|
4331f5f978 | ||
|
|
fb19eec511 | ||
|
|
b712dcba25 | ||
|
|
caad57f5d0 | ||
|
|
807b8b05c2 | ||
|
|
5f3fa7a284 | ||
|
|
c1032f08e5 | ||
|
|
0aa0b007b0 | ||
|
|
c6973beeec | ||
|
|
d99d106c55 | ||
|
|
61f8fa059c | ||
|
|
9279ffdf29 | ||
|
|
0682a5efe9 | ||
|
|
dc68073b21 | ||
|
|
78c6df8fb8 | ||
|
|
f03282e857 | ||
|
|
7e9e29f392 | ||
|
|
28f8f53bb6 | ||
|
|
ab8182fa71 | ||
|
|
d740a98d4a | ||
|
|
40e0727bed | ||
|
|
a387531246 | ||
|
|
be44044a29 | ||
|
|
ae9d905134 | ||
|
|
bcb8610977 | ||
|
|
ac66871c65 | ||
|
|
3fa102417e | ||
|
|
59b58a58f6 | ||
|
|
f46bcc918b | ||
|
|
784928401d | ||
|
|
1a62ae1a5c | ||
|
|
952a4436eb | ||
|
|
a098f5b9b6 | ||
|
|
5d691b7b74 | ||
|
|
84ee79c745 | ||
|
|
4b091b8a14 | ||
|
|
c51d0a5a9b | ||
|
|
29ea1d5db9 | ||
|
|
b910477e63 | ||
|
|
2f74178b8b | ||
|
|
fe171f7d8f | ||
|
|
b0244698f9 | ||
|
|
7c0ec3e569 | ||
|
|
4677a7e42f | ||
|
|
520f4efee9 | ||
|
|
0d43bad18e | ||
|
|
0dd914edd1 | ||
|
|
161db26bd1 | ||
|
|
a992c841ae | ||
|
|
9299cf1e78 | ||
|
|
970083559f | ||
|
|
459453639e | ||
|
|
0e0ae2b348 | ||
|
|
cb7fcc32ff | ||
|
|
d7e8ccb6f3 | ||
|
|
a811674834 | ||
|
|
fa9f16326a | ||
|
|
c13ff9b8bc | ||
|
|
bded355394 | ||
|
|
f43bd3fafc | ||
|
|
e298f1f300 | ||
|
|
8102404465 | ||
|
|
bef51e36a4 | ||
|
|
5425625fb3 | ||
|
|
94d1ea4fa9 | ||
|
|
9645d076db | ||
|
|
b683d9194f | ||
|
|
38da840313 | ||
|
|
b36e061e8a | ||
|
|
0d3f6a6665 | ||
|
|
aa00ea2e88 | ||
|
|
aad274a82b | ||
|
|
fc949b713e | ||
|
|
fbc246ca8f | ||
|
|
789a8aa03a | ||
|
|
179a2c3034 | ||
|
|
a27d168615 | ||
|
|
29fa517ae4 | ||
|
|
4b7c7e9d33 | ||
|
|
daf9bddd16 | ||
|
|
9b3733bd9a | ||
|
|
a4f0dde547 | ||
|
|
e604ed756f | ||
|
|
1cf3018183 | ||
|
|
138d155fb8 | ||
|
|
4d091498a4 | ||
|
|
1e3de0b6d9 | ||
|
|
25a9b70b2e | ||
|
|
45bf8ec9d0 | ||
|
|
4a253e5be0 | ||
|
|
71a04268b5 | ||
|
|
6c6ea1a14d | ||
|
|
9691c2050b | ||
|
|
2876587b55 | ||
|
|
1eb3a8c9ba | ||
|
|
39fd156a8e | ||
|
|
f137758903 | ||
|
|
895c2213db | ||
|
|
50720fb367 | ||
|
|
f6516b6dd3 | ||
|
|
564001a9e7 | ||
|
|
25abc2a9b4 | ||
|
|
70196747af | ||
|
|
04e102f64f | ||
|
|
432ebf7912 | ||
|
|
84b3a78396 | ||
|
|
9eb9f31c3a | ||
|
|
7f82c56f15 | ||
|
|
5582e6dad3 | ||
|
|
2e55854100 | ||
|
|
8114f3fcdb | ||
|
|
45c541daa1 | ||
|
|
17c0c658f1 | ||
|
|
b8e689dc67 | ||
|
|
87b19e8a11 | ||
|
|
a1c6ed64c0 | ||
|
|
f2c14100c3 | ||
|
|
1a58046071 | ||
|
|
b3b3cf98c6 | ||
|
|
30bf49ce02 | ||
|
|
a5ecd84c1f | ||
|
|
9b29731f08 | ||
|
|
a140942848 | ||
|
|
1291b1652a | ||
|
|
1b5b75d13e | ||
|
|
f1af346ad5 | ||
|
|
431bbb9c57 | ||
|
|
7d62b5ce1c | ||
|
|
a345a56001 | ||
|
|
b5f8cdecfb | ||
|
|
fa53b43c97 | ||
|
|
23bce5b115 | ||
|
|
da952f6227 | ||
|
|
31926f3a37 | ||
|
|
a71e22991b | ||
|
|
d74d789bea | ||
|
|
950325ee23 | ||
|
|
c941e1742d | ||
|
|
0bd1289ad1 | ||
|
|
febf70b73f | ||
|
|
b5a71af82a | ||
|
|
876c63c92f | ||
|
|
b3ca6696cd | ||
|
|
24e88142ba | ||
|
|
f9cd2cf6e2 | ||
|
|
0a1ac00ad6 | ||
|
|
e5947e883e | ||
|
|
679918ec84 | ||
|
|
a9b6fe5c83 | ||
|
|
8619a0d598 | ||
|
|
d34e6897d8 | ||
|
|
55681891e5 | ||
|
|
3772a9e885 | ||
|
|
1220685f78 | ||
|
|
f3129d9b19 | ||
|
|
b0fd7c9185 | ||
|
|
7d70c26629 | ||
|
|
ac96de6db4 | ||
|
|
1f49981a1f | ||
|
|
d09ffcb711 | ||
|
|
33b2a8a1ae | ||
|
|
32969f8571 | ||
|
|
4abe75d3b1 | ||
|
|
e623bf9a03 | ||
|
|
0815914f28 | ||
|
|
70cf07775b | ||
|
|
06382a007d | ||
|
|
d7749da3e9 | ||
|
|
84b8cf9fcf | ||
|
|
c673119b0b | ||
|
|
45d223328e | ||
|
|
b8ad9be908 | ||
|
|
2be918d5cd | ||
|
|
db69dbe9ab | ||
|
|
4215f6b53a | ||
|
|
e1298617bf | ||
|
|
720341312b | ||
|
|
ed44302c4a | ||
|
|
c3b3d48cd4 |
55
ABOUT-NLS
55
ABOUT-NLS
@@ -134,7 +134,8 @@ Each translation team has its own mailing list, courtesy of Linux
|
||||
International. You may reach your translation team at the address
|
||||
`LL@li.org', replacing LL by the two-letter ISO 639 code for your
|
||||
language. Language codes are *not* the same as the country codes given
|
||||
in ISO 3166. The following translation teams exist, as of August 1996:
|
||||
in ISO 3166. The following translation teams exist, as of December
|
||||
1996:
|
||||
|
||||
Arabic `ar', Chinese `zh', Czech `cs', Danish `da', Dutch `nl',
|
||||
English `en', Esperanto `eo', Finnish `fi', French `fr', German
|
||||
@@ -172,40 +173,42 @@ Available Packages
|
||||
|
||||
Languages are not equally supported in all GNU packages. The
|
||||
following matrix shows the current state of GNU internationalization,
|
||||
as of August 1996. The matrix shows, in regard of each package, for
|
||||
as of December 1996. The matrix shows, in regard of each package, for
|
||||
which languages PO files have been submitted to translation
|
||||
coordination.
|
||||
|
||||
cs de en es fi fr ja ko nl no pl pt sl sv
|
||||
Ready PO files cs de en es fi fr ja ko nl no pl pt sl sv
|
||||
.-------------------------------------------.
|
||||
bash | [] [] | 2
|
||||
bison | [] [] | 2
|
||||
bash | [] [] [] | 3
|
||||
bison | [] [] [] | 3
|
||||
clisp | [] [] [] | 3
|
||||
cpio | [] [] [] | 3
|
||||
diffutils | [] [] [] | 3
|
||||
cpio | [] [] [] [] | 4
|
||||
diffutils | [] [] [] [] | 4
|
||||
enscript | [] [] [] [] [] | 5
|
||||
fileutils | [] [] [] [] [] [] | 6
|
||||
findutils | [] [] [] [] [] | 5
|
||||
flex | [] | 1
|
||||
gcal | [] | 1
|
||||
gettext | [] [] [] [] [] [] [] [] [] | 10
|
||||
glibc | [] [] [] | 3
|
||||
grep | [] [] [] [] [] [] [] | 7
|
||||
hello | [] [] [] [] [] [] [] [] | 8
|
||||
fileutils | [] [] [] [] [] [] [] [] | 8
|
||||
findutils | [] [] [] [] [] [] | 6
|
||||
flex | [] [] | 2
|
||||
gcal | [] [] [] | 3
|
||||
gettext | [] [] [] [] [] [] [] [] [] [] | 11
|
||||
grep | [] [] [] [] [] [] [] [] | 8
|
||||
hello | [] [] [] [] [] [] [] [] [] [] | 10
|
||||
id-utils | [] [] | 2
|
||||
indent | | 0
|
||||
libc | [] [] [] [] [] [] | 6
|
||||
m4 | [] [] [] [] [] | 5
|
||||
make | [] [] | 2
|
||||
mkid | [] [] | 2
|
||||
make | [] [] [] [] [] | 5
|
||||
music | [] | 1
|
||||
ptx | [] [] [] [] [] | 5
|
||||
ptx | [] [] [] [] [] [] [] [] | 8
|
||||
recode | [] [] [] [] [] [] [] | 7
|
||||
sh-utils | [] [] | 2
|
||||
sh-utils | [] [] [] [] [] | 5
|
||||
sharutils | [] [] [] [] | 4
|
||||
tar | [] [] [] [] [] [] [] [] | 8
|
||||
textutils | [] [] [] [] [] | 5
|
||||
wdiff | [] [] [] [] [] | 5
|
||||
tar | [] [] [] [] [] [] [] [] [] | 9
|
||||
texinfo | | 0
|
||||
textutils | [] [] [] [] [] [] | 6
|
||||
wdiff | [] [] [] [] [] [] [] [] | 8
|
||||
`-------------------------------------------'
|
||||
cs de en es fi fr ja ko nl no pl pt sl sv
|
||||
1 18 1 4 1 22 1 7 16 3 10 3 6 12 105
|
||||
14 languages cs de en es fi fr ja ko nl no pl pt sl sv
|
||||
27 packages 1 21 1 11 1 24 1 8 20 7 14 6 7 14 136
|
||||
|
||||
Some counters in the preceding matrix are higher than the number of
|
||||
visible blocks let us expect. This is because a few extra PO files are
|
||||
@@ -218,6 +221,6 @@ distributed as such by its maintainer. There might be an observable
|
||||
lag between the mere existence a PO file and its wide availability in a
|
||||
GNU distribution.
|
||||
|
||||
If August 1996 seems to be old, you may fetch a more recent copy of
|
||||
this `ABOUT-NLS' file on most GNU archive sites.
|
||||
If December 1996 seems to be old, you may fetch a more recent copy
|
||||
of this `ABOUT-NLS' file on most GNU archive sites.
|
||||
|
||||
|
||||
21
THANKS
21
THANKS
@@ -0,0 +1,21 @@
|
||||
This is just a start at listing e-mail addresses of contributors.
|
||||
The rest of the addresses are still in the ChangeLog.
|
||||
|
||||
Arne Henrik Juul arnej@imf.unit.no
|
||||
Bauke Jan Douma: bjdouma@xs4all.nl
|
||||
Charles Karney: karney@pppl.gov
|
||||
Eirik Fuller: eirik@netcom.com
|
||||
Emile LeBlanc: leblanc@math.toronto.edu
|
||||
Galen Hazelwood: galenh@micron.net
|
||||
James Antill: jmanti%essex.ac.uk@seralph21.essex.ac.uk
|
||||
Jesse Thilo: jgt2@eecs.lehigh.edu
|
||||
Joakim Rosqvist: dvljrt@cs.umu.se
|
||||
Marcus Daniels: marcus@sysc.pdx.edu
|
||||
Mark A. Thomas: thommark@access.digex.net
|
||||
Miles Bader: miles@gnu.ai.mit.edu
|
||||
Peter Eriksson: peter@ifm.liu.se
|
||||
Ross Ridge: rridge@calum.csclub.uwaterloo.ca
|
||||
Santiago Vila Doncel: sanvila@ctv.es
|
||||
Thomas Bushnell, n/BSG: thomas@gnu.ai.mit.edu
|
||||
Tony Leneis: tony@plaza.ds.adp.com
|
||||
Wayne Stewart: wstewa@atl.com
|
||||
|
||||
@@ -4,3 +4,9 @@ info_TEXINFOS = fileutils.texi
|
||||
# FIXME: remove texinfo.tex when automake has been fixed to include it
|
||||
# automatically
|
||||
EXTRA_DIST = perm.texi getdate.texi texinfo.tex
|
||||
|
||||
# Tell makeinfo to put everything in a single info file: sh-utils.info.
|
||||
# Otherwise, it would also generate files with names like sh-utils.info-[123],
|
||||
# and those names all map to one 14-byte name (sh-utils.info-) on some crufty
|
||||
# old systems.
|
||||
MAKEINFO = makeinfo --no-split
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Makefile.in generated automatically by automake 1.1f from Makefile.am
|
||||
# Makefile.in generated automatically by automake 1.1l from Makefile.am
|
||||
|
||||
# Copyright (C) 1994, 1995, 1996 Free Software Foundation, Inc.
|
||||
# This Makefile.in is free software; the Free Software Foundation
|
||||
@@ -37,19 +37,31 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@
|
||||
INSTALL_DATA = @INSTALL_DATA@
|
||||
INSTALL_SCRIPT = @INSTALL_SCRIPT@
|
||||
transform = @program_transform_name@
|
||||
YACC = @YACC@
|
||||
GENCAT = @GENCAT@
|
||||
PERL = @PERL@
|
||||
MV = @MV@
|
||||
GMSGFMT = @GMSGFMT@
|
||||
CC = @CC@
|
||||
RANLIB = @RANLIB@
|
||||
LN = @LN@
|
||||
RM = @RM@
|
||||
|
||||
info_TEXINFOS = fileutils.texi
|
||||
|
||||
# FIXME: remove texinfo.tex when automake has been fixed to include it
|
||||
# automatically
|
||||
EXTRA_DIST = perm.texi getdate.texi texinfo.tex
|
||||
mkinstalldirs = $(top_srcdir)/mkinstalldirs
|
||||
|
||||
# Tell makeinfo to put everything in a single info file: sh-utils.info.
|
||||
# Otherwise, it would also generate files with names like sh-utils.info-[123],
|
||||
# and those names all map to one 14-byte name (sh-utils.info-) on some crufty
|
||||
# old systems.
|
||||
MAKEINFO = makeinfo --no-split
|
||||
mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
|
||||
CONFIG_HEADER = ../config.h
|
||||
CONFIG_CLEAN_FILES =
|
||||
|
||||
MAKEINFO = makeinfo
|
||||
TEXI2DVI = texi2dvi
|
||||
INFOS = fileutils.info fileutils.info[-0-9]*
|
||||
INFO_DEPS = fileutils.info
|
||||
DVIS = fileutils.dvi
|
||||
TEXINFOS = fileutils.texi
|
||||
@@ -61,19 +73,20 @@ PACKAGE = @PACKAGE@
|
||||
VERSION = @VERSION@
|
||||
|
||||
DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) \
|
||||
$(TEXINFOS) $(INFOS) $(MANS) $(EXTRA_DIST)
|
||||
DEP_DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) \
|
||||
$(TEXINFOS) $(INFO_DEPS) $(MANS) $(EXTRA_DIST)
|
||||
$(TEXINFOS) $(MANS) $(EXTRA_DIST)
|
||||
|
||||
TAR = tar
|
||||
default: all
|
||||
|
||||
.SUFFIXES:
|
||||
.SUFFIXES: .texi .texinfo .info .dvi .ps
|
||||
$(srcdir)/Makefile.in: @MAINT@ Makefile.am $(top_srcdir)/configure.in $(ACLOCAL)
|
||||
cd $(top_srcdir) && automake --gnu doc/Makefile
|
||||
|
||||
$(srcdir)/Makefile.in: @MAINT@Makefile.am $(top_srcdir)/configure.in
|
||||
cd $(top_srcdir) && automake $(subdir)/Makefile
|
||||
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status $(BUILT_SOURCES)
|
||||
cd $(top_builddir) \
|
||||
&& CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status
|
||||
|
||||
Makefile: $(top_builddir)/config.status $(srcdir)/Makefile.in $(BUILT_SOURCES)
|
||||
cd $(top_builddir) && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= ./config.status
|
||||
|
||||
version.texi: @MAINT@stamp-vti
|
||||
|
||||
@@ -100,12 +113,15 @@ fileutils.info: fileutils.texi version.texi
|
||||
fileutils.dvi: fileutils.texi version.texi
|
||||
|
||||
|
||||
DVIPS = dvips
|
||||
|
||||
.texi.info:
|
||||
cd $(srcdir) \
|
||||
&& $(MAKEINFO) `echo $< | sed 's,.*/,,'`
|
||||
|
||||
.texi.dvi:
|
||||
TEXINPUTS=$(srcdir):$$TEXINPUTS $(TEXI2DVI) $<
|
||||
TEXINPUTS=$(srcdir):$$TEXINPUTS \
|
||||
MAKEINFO='$(MAKEINFO) -I $(srcdir)' $(TEXI2DVI) $<
|
||||
|
||||
.texinfo.info:
|
||||
cd $(srcdir) \
|
||||
@@ -113,21 +129,25 @@ fileutils.dvi: fileutils.texi version.texi
|
||||
|
||||
.texinfo.dvi:
|
||||
TEXINPUTS=$(srcdir):$$TEXINPUTS $(TEXI2DVI) $<
|
||||
.dvi.ps:
|
||||
$(DVIPS) $< -o $@
|
||||
|
||||
install-info: $(INFO_DEPS)
|
||||
install-info-am: $(INFO_DEPS)
|
||||
$(NORMAL_INSTALL)
|
||||
$(mkinstalldirs) $(infodir)
|
||||
for file in $(INFO_DEPS); do \
|
||||
@for file in $(INFO_DEPS); do \
|
||||
for ifile in `cd $(srcdir) && echo $$file $$file-[0-9] $$file-[0-9][0-9]`; do \
|
||||
if test -f $(srcdir)/$$ifile; then \
|
||||
echo "$(INSTALL_DATA) $(srcdir)/$$ifile $(infodir)/$$ifile"; \
|
||||
$(INSTALL_DATA) $(srcdir)/$$ifile $(infodir)/$$ifile; \
|
||||
else : ; fi; \
|
||||
done; \
|
||||
done
|
||||
$(POST_INSTALL)
|
||||
if $(SHELL) -c 'install-info --version' >/dev/null 2>&1; then \
|
||||
@if $(SHELL) -c 'install-info --version' >/dev/null 2>&1; then \
|
||||
for file in $(INFO_DEPS); do \
|
||||
install-info --info-dir=$(infodir) $$file; :;\
|
||||
echo "install-info --info-dir=$(infodir) $(infodir)/$$file";\
|
||||
install-info --info-dir=$(infodir) $(infodir)/$$file; :;\
|
||||
done; \
|
||||
else : ; fi
|
||||
|
||||
@@ -140,6 +160,16 @@ uninstall-info:
|
||||
test -z $ii || install-info --info-dir=$(infodir) --remove $$file; \
|
||||
done
|
||||
|
||||
dist-info: $(INFO_DEPS)
|
||||
for base in $(INFO_DEPS); do \
|
||||
d=$(srcdir); \
|
||||
for file in `cd $$d && eval echo $$base*`; do \
|
||||
test -f $(distdir)/$$file \
|
||||
|| ln $$d/$$file $(distdir)/$$file 2> /dev/null \
|
||||
|| cp -p $$d/$$file $(distdir)/$$file; \
|
||||
done; \
|
||||
done
|
||||
|
||||
mostlyclean-info:
|
||||
rm -f fileutils.aux fileutils.cp fileutils.cps fileutils.dvi \
|
||||
fileutils.fn fileutils.fns fileutils.ky fileutils.log \
|
||||
@@ -151,7 +181,7 @@ clean-info:
|
||||
distclean-info:
|
||||
|
||||
maintainer-clean-info:
|
||||
rm -f $(INFOS)
|
||||
for i in $(INFO_DEPS); do rm -f `eval echo $$i*`; done
|
||||
tags: TAGS
|
||||
TAGS:
|
||||
|
||||
@@ -159,20 +189,23 @@ TAGS:
|
||||
distdir = $(top_builddir)/$(PACKAGE)-$(VERSION)/$(subdir)
|
||||
|
||||
subdir = doc
|
||||
distdir: $(DEP_DISTFILES)
|
||||
@for file in `cd $(srcdir) && echo $(DISTFILES)`; do \
|
||||
distdir: $(DISTFILES)
|
||||
@for file in $(DISTFILES); do \
|
||||
d=$(srcdir); \
|
||||
test -f $(distdir)/$$file \
|
||||
|| ln $(srcdir)/$$file $(distdir)/$$file 2> /dev/null \
|
||||
|| cp -p $(srcdir)/$$file $(distdir)/$$file; \
|
||||
|| ln $$d/$$file $(distdir)/$$file 2> /dev/null \
|
||||
|| cp -p $$d/$$file $(distdir)/$$file; \
|
||||
done
|
||||
$(MAKE) distdir="$(distdir)" dist-info
|
||||
info: $(INFO_DEPS)
|
||||
dvi: $(DVIS)
|
||||
check: all
|
||||
$(MAKE)
|
||||
installcheck:
|
||||
install-exec:
|
||||
$(NORMAL_INSTALL)
|
||||
|
||||
install-data: install-info
|
||||
install-data: install-info-am
|
||||
$(NORMAL_INSTALL)
|
||||
|
||||
install: install-exec install-data all
|
||||
@@ -204,25 +237,23 @@ maintainer-clean-generic:
|
||||
test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES)
|
||||
mostlyclean: mostlyclean-vti mostlyclean-info mostlyclean-generic
|
||||
|
||||
clean: clean-vti clean-info clean-generic mostlyclean
|
||||
clean: clean-vti clean-info clean-generic mostlyclean
|
||||
|
||||
distclean: distclean-vti distclean-info distclean-generic clean
|
||||
distclean: distclean-vti distclean-info distclean-generic clean
|
||||
rm -f config.status
|
||||
|
||||
maintainer-clean: maintainer-clean-vti maintainer-clean-info \
|
||||
maintainer-clean-generic distclean
|
||||
maintainer-clean-generic distclean
|
||||
@echo "This command is intended for maintainers to use;"
|
||||
@echo "it deletes files that may require special tools to rebuild."
|
||||
|
||||
.PHONY: default mostlyclean-vti distclean-vti clean-vti \
|
||||
maintainer-clean-vti install-info uninstall-info mostlyclean-info \
|
||||
maintainer-clean-vti install-info-am uninstall-info mostlyclean-info \
|
||||
distclean-info clean-info maintainer-clean-info tags distdir info dvi \
|
||||
check installcheck install-exec install-data install uninstall all \
|
||||
installcheck install-exec install-data install uninstall all \
|
||||
installdirs mostlyclean-generic distclean-generic clean-generic \
|
||||
maintainer-clean-generic clean mostlyclean distclean maintainer-clean
|
||||
|
||||
.SUFFIXES:
|
||||
.SUFFIXES: .texi .texinfo .info .dvi
|
||||
|
||||
# Tell versions [3.59,3.63) of GNU make to not export all variables.
|
||||
# Otherwise a system limit (for SysV at least) may be exceeded.
|
||||
|
||||
@@ -1,10 +1,3 @@
|
||||
@ifinfo
|
||||
@set Francois Franc,ois
|
||||
@end ifinfo
|
||||
@tex
|
||||
@set Francois Fran\noexpand\ptexc cois
|
||||
@end tex
|
||||
|
||||
@node Date input formats
|
||||
@chapter Date input formats
|
||||
|
||||
@@ -77,7 +70,7 @@ many flavors of items:
|
||||
@item time zone items
|
||||
@item day of the week items
|
||||
@item relative items
|
||||
@item pure numbers.
|
||||
@item pure numbers.
|
||||
@end itemize
|
||||
|
||||
@noindent We describe each of these item types in turn, below.
|
||||
@@ -113,7 +106,7 @@ zeros on numbers are ignored.
|
||||
|
||||
@cindex calendar date item
|
||||
|
||||
A @dfn{calendar date item} specifies a day of the year. It is
|
||||
A @dfn{calendar date item} specifies a day of the year. It is
|
||||
specified differently, depending on whether the month is specified
|
||||
numerically or literally. All these strings specify the same calendar date:
|
||||
|
||||
@@ -503,6 +496,6 @@ and others.
|
||||
|
||||
@cindex Pinard, F.
|
||||
@cindex Berry, K.
|
||||
This chapter was originally produced by @value{Francois} Pinard
|
||||
This chapter was originally produced by Fran@,{c}ois Pinard
|
||||
(@samp{pinard@@iro.umontreal.ca}) from the @file{getdate.y} source code,
|
||||
and then edited by K.@: Berry (@samp{kb@@cs.umb.edu}).
|
||||
|
||||
@@ -18,12 +18,7 @@
|
||||
@syncodeindex pg cp
|
||||
@syncodeindex vr cp
|
||||
|
||||
@ifinfo
|
||||
@set Francois Franc,ois
|
||||
@end ifinfo
|
||||
@tex
|
||||
@set Francois Fran\noexpand\ptexc cois
|
||||
@end tex
|
||||
@set Francois Fran@,{c}ois
|
||||
|
||||
@ifinfo
|
||||
@format
|
||||
@@ -172,7 +167,7 @@ The GNU shell utilities are mostly compatible with the POSIX.2 standard.
|
||||
@c This paragraph appears in all of fileutils.texi, textutils.texi, and
|
||||
@c sh-utils.texi too -- so be sure to keep them consistent.
|
||||
@cindex bugs, reporting
|
||||
Please report bugs to @samp{bug-gnu-utils@@prep.ai.mit.edu}. Remember
|
||||
Please report bugs to @samp{sh-utils-bugs@@gnu.ai.mit.edu}. Remember
|
||||
to include the version number, machine architecture, input files, and
|
||||
any other information needed to reproduce the bug: your input, what you
|
||||
expected, what you got, and why it is wrong. Diffs are welcome, but
|
||||
@@ -184,7 +179,7 @@ sometimes difficult to infer. @xref{Bugs, , , gcc, GNU CC}.
|
||||
@cindex Meyering, Jim
|
||||
@c Sorry, but the @value trick doesn't work with TeX in indexing
|
||||
@c commands, and I don't want to fix it right now. --karl.
|
||||
@cindex Pinard, Francois
|
||||
@cindex Pinard, @value{Francois}
|
||||
@cindex Berry, Karl
|
||||
@cindex Stallman, Richard
|
||||
This manual is based on the Unix man pages in the distribution, which
|
||||
@@ -724,7 +719,7 @@ Exit status:
|
||||
@menu
|
||||
* Relations for expr:: | & < <= = == != >= >
|
||||
* Numeric expressions:: + - * / %
|
||||
* String expressions:: : match substr index length
|
||||
* String expressions:: <colon> match substr index length
|
||||
* Examples of expr:: Examples.
|
||||
@end menu
|
||||
|
||||
@@ -2504,6 +2499,13 @@ Print the machine (hardware) type.
|
||||
@cindex network node name
|
||||
Print the machine's network node hostname.
|
||||
|
||||
@item -p
|
||||
@itemx --processor
|
||||
@opindex -p
|
||||
@opindex --processor
|
||||
@cindex host processor type
|
||||
Print the machine's processor type
|
||||
|
||||
@item -r
|
||||
@itemx --release
|
||||
@opindex -r
|
||||
|
||||
@@ -16,13 +16,6 @@
|
||||
@syncodeindex pg cp
|
||||
@syncodeindex vr cp
|
||||
|
||||
@ifinfo
|
||||
@set Francois Franc,ois
|
||||
@end ifinfo
|
||||
@tex
|
||||
@set Francois Fran\noexpand\ptexc cois
|
||||
@end tex
|
||||
|
||||
@ifinfo
|
||||
@format
|
||||
START-INFO-DIR-ENTRY
|
||||
@@ -150,7 +143,7 @@ The GNU text utilities are mostly compatible with the @sc{POSIX.2} standard.
|
||||
@c This paragraph appears in all of fileutils.texi, textutils.texi, and
|
||||
@c sh-utils.texi too -- so be sure to keep them consistent.
|
||||
@cindex bugs, reporting
|
||||
Please report bugs to @samp{bug-gnu-utils@@prep.ai.mit.edu}. Remember
|
||||
Please report bugs to @samp{textutils-bugs@@gnu.ai.mit.edu}. Remember
|
||||
to include the version number, machine architecture, input files, and
|
||||
any other information needed to reproduce the bug: your input, what you
|
||||
expected, what you got, and why it is wrong. Diffs are welcome, but
|
||||
@@ -160,7 +153,7 @@ sometimes difficult to infer. @xref{Bugs, , , gcc, GNU CC}.
|
||||
This manual is based on the Unix man pages in the distribution, which
|
||||
were originally written by David MacKenzie and updated by Jim Meyering.
|
||||
The original @code{fmt} man page was written by Ross Paterson.
|
||||
@value{Francois} Pinard did the initial conversion to Texinfo format.
|
||||
Fran@,{c}ois Pinard did the initial conversion to Texinfo format.
|
||||
Karl Berry did the indexing, some reorganization, and editing of the results.
|
||||
Richard Stallman contributed his usual invaluable insights to the
|
||||
overall process.
|
||||
@@ -841,10 +834,12 @@ leaving the code unchanged.
|
||||
@pindex pr
|
||||
@cindex printing, preparing files for
|
||||
@cindex multicolumn output, generating
|
||||
@cindex merging files in parallel
|
||||
|
||||
@code{pr} writes each @var{file} (@samp{-} means standard input), or
|
||||
standard input if none are given, to standard output, paginating and
|
||||
optionally outputting in multicolumn format. Synopsis:
|
||||
optionally outputting in multicolumn format; optionally merges all
|
||||
@var{file}s, printing all in parallel, one per column. Synopsis:
|
||||
|
||||
@example
|
||||
pr [@var{option}]@dots{} [@var{file}]@dots{}
|
||||
@@ -852,33 +847,50 @@ pr [@var{option}]@dots{} [@var{file}]@dots{}
|
||||
|
||||
By default, a 5-line header is printed: two blank lines; a line with the
|
||||
date, the file name, and the page count; and two more blank lines. A
|
||||
five line footer (entirely) is also printed.
|
||||
footer of five blank lines is also printed. With the @samp{-f} option, a
|
||||
3-line header is printed: the leading two blank lines are omitted; no
|
||||
footer used. The default @var{page_length} in both cases is 66 lines.
|
||||
The text line of the header takes up the full @var{page_width} in the
|
||||
form @samp{yy-mm-dd HH:MM string Page nnnn}. String is a centered
|
||||
string.
|
||||
|
||||
Form feeds in the input cause page breaks in the output.
|
||||
Form feeds in the input cause page breaks in the output. Multiple form
|
||||
feeds produce empty pages.
|
||||
|
||||
Columns have equal width, separated by an optional string (default
|
||||
space). Lines will always be truncated to line width (default 72),
|
||||
unless you use the @samp{-j} option. For single column output no line
|
||||
truncation occurs by default. Use @samp{-w} option to truncate lines
|
||||
in that case.
|
||||
|
||||
The program accepts the following options. Also see @ref{Common options}.
|
||||
|
||||
@table @samp
|
||||
|
||||
@item +@var{page}
|
||||
Begin printing with page @var{page}.
|
||||
@item +@var{first_page}[@var{:last_page}]
|
||||
@opindex +@var{first_page}[@var{:last_page}]
|
||||
Begin printing with page @var{first_page} and stop with
|
||||
@var{last_page}. Missing @samp{:LAST_PAGE} implies end of file. While
|
||||
estimating the number of skipped pages each form feed in the input file
|
||||
results in a new page. Page counting with and without
|
||||
@samp{+@var{first_page}} is identical. By default, it starts with the
|
||||
first page of input file (not first page printed). Page numbering may be
|
||||
altered by @samp{-N} option.
|
||||
|
||||
@item -@var{column}
|
||||
@opindex -@var{column}
|
||||
Produce @var{column}-column output and print columns down. The column
|
||||
width is automatically decreased as @var{column} increases; unless you
|
||||
use the @samp{-w} option to increase the page width as well, this option
|
||||
might well cause some input to be truncated.
|
||||
@cindex down columns
|
||||
With each single @var{file}, produce @var{column}-column output and
|
||||
print columns down. The column width is automatically estimated from
|
||||
@var{page_width}. This option might well cause some columns to be
|
||||
truncated. The number of lines in the columns on each page will be
|
||||
balanced. @samp{-@var{column}} may not be used with @samp{-m} option.
|
||||
|
||||
@item -a
|
||||
@opindex -a
|
||||
@cindex across columns
|
||||
Print columns across rather than down.
|
||||
|
||||
@item -b
|
||||
@opindex -b
|
||||
@cindex balancing columns
|
||||
Balance columns on the last page.
|
||||
With each single @var{file}, print columns across rather than down.
|
||||
@var{column} must be greater than one.
|
||||
|
||||
@item -c
|
||||
@opindex -c
|
||||
@@ -903,11 +915,19 @@ is 8).
|
||||
@itemx -F
|
||||
@opindex -F
|
||||
@opindex -f
|
||||
Use a formfeed instead of newlines to separate output pages.
|
||||
Use a form feed instead of newlines to separate output pages. Default
|
||||
page length of 66 lines is not altered. But the number of lines of text
|
||||
per page changes from 56 to 63 lines.
|
||||
|
||||
@item -h @var{header}
|
||||
|
||||
@item -h @var{HEADER}
|
||||
@opindex -h
|
||||
Replace the file name in the header with the string @var{header}.
|
||||
Replace the file name in the header with the centered string
|
||||
@var{header}. Left-hand-side truncation (marked by a @samp{*}) may occur
|
||||
if the total header line @samp{yy-mm-dd HH:MM HEADER Page nnnn}
|
||||
becomes larger than @var{page_width}. @samp{-h ""} prints a blank line
|
||||
header. Don't use @samp{-h""}. A space between the -h option and the
|
||||
argument is always peremptory.
|
||||
|
||||
@item -i[@var{out-tabchar}[@var{out-tabwidth}]]
|
||||
@opindex -i
|
||||
@@ -917,30 +937,54 @@ is the output tab character (default is @key{TAB}). Second optional
|
||||
argument @var{out-tabwidth} is the output tab character's width (default
|
||||
is 8).
|
||||
|
||||
@item -l @var{n}
|
||||
@item -j
|
||||
@opindex -j
|
||||
Merge lines of full length. Used together with the column options
|
||||
@samp{-@var{column}}, @samp{-a -@var{column}} or @samp{-m}. Turns off
|
||||
@samp{-w} line truncation; no column alignment used; may be used with
|
||||
@samp{-s[@var{separator}]}.
|
||||
|
||||
|
||||
@item -l @var{page_length}
|
||||
@opindex -l
|
||||
Set the page length to @var{n} (default 66) lines. If @var{n} is less
|
||||
than 10, the headers and footers are omitted, as if the @samp{-t} option
|
||||
had been given.
|
||||
Set the page length to @var{page_length} (default 66) lines. If
|
||||
@var{page_length} is less than or equal 10 (and <= 3 with @samp{-f}),
|
||||
the headers and footers are omitted, and all form feeds set in input
|
||||
files are eliminated, as if the @samp{-T} option had been given.
|
||||
|
||||
@item -m
|
||||
@opindex -m
|
||||
Print all files in parallel, one in each column.
|
||||
Merge and print all @var{file}s in parallel, one in each column. If a
|
||||
line is too long to fit in a column, it is truncated (but see
|
||||
@samp{-j}). @samp{-s[@var{separator}]} may be used. Empty pages in some
|
||||
@var{file}s (form feeds set) produce empty columns, still marked by
|
||||
@var{separator}. Completely empty common pages show no separators or
|
||||
line numbers. The default header becomes
|
||||
@samp{yy-mm-dd HH:MM <blanks> Page nnnn}; may be used with
|
||||
@samp{-h @var{header}} to fill up the middle part.
|
||||
|
||||
|
||||
@item -n[@var{number-separator}[@var{digits}]]
|
||||
@opindex -n
|
||||
Precede each column with a line number; with parallel files (@samp{-m}),
|
||||
precede each line with a line number. Optional argument
|
||||
Precede each column with a line number; with parallel @var{file}s
|
||||
(@samp{-m}), precede only each line with a line number. Optional argument
|
||||
@var{number-separator} is the character to print after each number
|
||||
(default is @key{TAB}). Optional argument @var{digits} is the number of
|
||||
digits per line number (default is 5).
|
||||
digits per line number (default is 5). Default line counting starts with
|
||||
first line of the input file (not with the first line printed, see
|
||||
@samp{-N}).
|
||||
|
||||
@item -N @var{line_number}
|
||||
@opindex -N
|
||||
Start line counting with no. @var{line_number} at first line of first
|
||||
page printed.
|
||||
|
||||
@item -o @var{n}
|
||||
@opindex -o
|
||||
@cindex indenting lines
|
||||
@cindex left margin
|
||||
Indent each line with @var{n} (default is zero) spaces wide, i.e., set
|
||||
the left margin. The total page width is @samp{n} plus the width set
|
||||
the left margin. The total page width is @var{n} plus the width set
|
||||
with the @samp{-w} option.
|
||||
|
||||
@item -r
|
||||
@@ -948,25 +992,44 @@ with the @samp{-w} option.
|
||||
Do not print a warning message when an argument @var{file} cannot be
|
||||
opened. (The exit status will still be nonzero, however.)
|
||||
|
||||
@item -s[@var{c}]
|
||||
@item -s[@var{separator}]
|
||||
@opindex -s
|
||||
Separate columns by the single character @var{c}. If @var{c} is
|
||||
omitted, the default is space; if this option is omitted altogether, the
|
||||
default is @key{TAB}.
|
||||
Separate columns by a string @var{separator}. Don't use
|
||||
@samp{-s @var{separator}}, no space between flag and argument. If this
|
||||
option is omitted altogether, the default is a space, same as
|
||||
@samp{-s" "}. With @samp{-s} only, no separator is used, same as
|
||||
@samp{-s""}. @samp{-s} does not affect line truncation or column
|
||||
alignment.
|
||||
|
||||
@item -t
|
||||
@opindex -t
|
||||
Do not print the usual 5-line header and the 5-line footer on each page,
|
||||
and do not fill out the bottoms of pages (with blank lines or
|
||||
formfeeds).
|
||||
Do not print the usual header [and footer] on each page, and do not fill
|
||||
out the bottoms of pages (with blank lines or a form feed). No page
|
||||
structure is produced, but retain form feeds set in the input files. The
|
||||
predefined page layout is not changed. @samp{-t} or @samp{-T} may be
|
||||
useful together with other options; e.g.: @samp{-t -e4}, expand
|
||||
@key{TAB} in the input file to 4 spaces but do not do any other changes.
|
||||
Use of @samp{-t} overrides @samp{-h}.
|
||||
|
||||
@item -T
|
||||
@opindex -T
|
||||
Do not print header [and footer]. In addition eliminate all form feeds
|
||||
set in the input files.
|
||||
|
||||
@item -v
|
||||
@opindex -v
|
||||
Print unprintable characters in octal backslash notation.
|
||||
|
||||
@item -w @var{n}
|
||||
@item -w @var{page_width}
|
||||
@opindex -w
|
||||
Set the page width to @var{n} (default is 72) columns.
|
||||
Set the page width to @var{page_width} (default 72) characters.
|
||||
With/without @samp{-w}, header lines are always truncated to
|
||||
@var{page_width} characters. With @samp{-w}, text lines are truncated,
|
||||
unless @samp{-j} is used. Without @samp{-w} together with one of the
|
||||
column options @samp{-@var{column}}, @samp{-a -@var{column}} or
|
||||
@samp{-m}, default truncation of text lines to 72 characters is used.
|
||||
Without @samp{-w} and without any of the column options, no line
|
||||
truncation is used. That's equivalent to @samp{-w 72 -j}.
|
||||
|
||||
@end table
|
||||
|
||||
@@ -1259,7 +1322,7 @@ less than @var{bytes} bytes of the line are left, then continue
|
||||
normally. @var{bytes} has the same format as for the @samp{--bytes}
|
||||
option.
|
||||
|
||||
@itemx --verbose=@var{bytes}
|
||||
@itemx --verbose
|
||||
@opindex --verbose
|
||||
Write a diagnostic to standard error just before each output file is opened.
|
||||
|
||||
|
||||
@@ -1,25 +1,25 @@
|
||||
## Process this file with automake to produce Makefile.in
|
||||
noinst_LIBRARIES = fu
|
||||
noinst_LIBRARIES = libfu.a
|
||||
|
||||
## FIXME: Remove mvdir.c, and rmdir.c when
|
||||
## automake is fixed -- probably for 1.1g
|
||||
EXTRA_DIST = mkdir.c rmdir.c
|
||||
EXTRA_DIST = mkdir.c rmdir.c getline.c mktime.c strftime.c getgroups.c
|
||||
|
||||
INCLUDES = -I.. -I$(srcdir) -I../intl
|
||||
|
||||
fu_SOURCES = getdate.y posixtm.y getopt.c getopt1.c \
|
||||
libfu_a_SOURCES = getdate.y posixtm.y getopt.c getopt1.c \
|
||||
argmatch.c backupfile.c dirname.c filemode.c \
|
||||
full-write.c getversion.c idcache.c \
|
||||
isdir.c long-options.c makepath.c modechange.c path-concat.c \
|
||||
safe-read.c save-cwd.c savedir.c stripslash.c userspec.c xgetcwd.c \
|
||||
xmalloc.c xstrdup.c xstrtol.c xstrtoul.c yesno.c
|
||||
|
||||
fu_LIBADD = @LIBOBJS@ @ALLOCA@
|
||||
fu_DEPENDENCIES = $(fu_LIBADD)
|
||||
libfu_a_LIBADD = @LIBOBJS@ @ALLOCA@
|
||||
libfu_a_DEPENDENCIES = $(libfu_a_LIBADD)
|
||||
|
||||
noinst_HEADERS = argmatch.h backupfile.h error.h fnmatch.h fsusage.h \
|
||||
getline.h getopt.h group-member.h long-options.h makepath.h modechange.h \
|
||||
mountlist.h path-concat.h pathmax.h \
|
||||
getdate.h getline.h getopt.h group-member.h long-options.h \
|
||||
makepath.h modechange.h mountlist.h path-concat.h pathmax.h \
|
||||
save-cwd.h xstrtol.h xstrtoul.h
|
||||
|
||||
BUILT_SOURCES = getdate.c posixtm.c
|
||||
|
||||
144
lib/Makefile.in
144
lib/Makefile.in
@@ -1,4 +1,4 @@
|
||||
# Makefile.in generated automatically by automake 1.1f from Makefile.am
|
||||
# Makefile.in generated automatically by automake 1.1l from Makefile.am
|
||||
|
||||
# Copyright (C) 1994, 1995, 1996 Free Software Foundation, Inc.
|
||||
# This Makefile.in is free software; the Free Software Foundation
|
||||
@@ -37,54 +37,56 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@
|
||||
INSTALL_DATA = @INSTALL_DATA@
|
||||
INSTALL_SCRIPT = @INSTALL_SCRIPT@
|
||||
transform = @program_transform_name@
|
||||
YACC = @YACC@
|
||||
GENCAT = @GENCAT@
|
||||
PERL = @PERL@
|
||||
MV = @MV@
|
||||
GMSGFMT = @GMSGFMT@
|
||||
CC = @CC@
|
||||
RANLIB = @RANLIB@
|
||||
LN = @LN@
|
||||
RM = @RM@
|
||||
|
||||
noinst_LIBRARIES = fu
|
||||
noinst_LIBRARIES = libfu.a
|
||||
|
||||
EXTRA_DIST = mkdir.c rmdir.c
|
||||
EXTRA_DIST = mkdir.c rmdir.c getline.c mktime.c strftime.c getgroups.c
|
||||
|
||||
INCLUDES = -I.. -I$(srcdir) -I../intl
|
||||
|
||||
fu_SOURCES = getdate.y posixtm.y getopt.c getopt1.c \
|
||||
libfu_a_SOURCES = getdate.y posixtm.y getopt.c getopt1.c \
|
||||
argmatch.c backupfile.c dirname.c filemode.c \
|
||||
full-write.c getversion.c idcache.c \
|
||||
isdir.c long-options.c makepath.c modechange.c path-concat.c \
|
||||
safe-read.c save-cwd.c savedir.c stripslash.c userspec.c xgetcwd.c \
|
||||
xmalloc.c xstrdup.c xstrtol.c xstrtoul.c yesno.c
|
||||
|
||||
fu_LIBADD = @LIBOBJS@ @ALLOCA@
|
||||
fu_DEPENDENCIES = $(fu_LIBADD)
|
||||
libfu_a_LIBADD = @LIBOBJS@ @ALLOCA@
|
||||
libfu_a_DEPENDENCIES = $(libfu_a_LIBADD)
|
||||
|
||||
noinst_HEADERS = argmatch.h backupfile.h error.h fnmatch.h fsusage.h \
|
||||
getline.h getopt.h group-member.h long-options.h makepath.h modechange.h \
|
||||
mountlist.h path-concat.h pathmax.h \
|
||||
getdate.h getline.h getopt.h group-member.h long-options.h \
|
||||
makepath.h modechange.h mountlist.h path-concat.h pathmax.h \
|
||||
save-cwd.h xstrtol.h xstrtoul.h
|
||||
|
||||
BUILT_SOURCES = getdate.c posixtm.c
|
||||
mkinstalldirs = $(top_srcdir)/mkinstalldirs
|
||||
mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
|
||||
CONFIG_HEADER = ../config.h
|
||||
CONFIG_CLEAN_FILES =
|
||||
LIBRARIES = $(noinst_LIBRARIES)
|
||||
|
||||
noinst_LIBFILES = libfu.a
|
||||
|
||||
DEFS = @DEFS@ -I. -I$(srcdir) -I..
|
||||
CPPFLAGS = @CPPFLAGS@
|
||||
LDFLAGS = @LDFLAGS@
|
||||
LIBS = @LIBS@
|
||||
fu_OBJECTS = getdate.o posixtm.o getopt.o getopt1.o argmatch.o \
|
||||
libfu_a_OBJECTS = getdate.o posixtm.o getopt.o getopt1.o argmatch.o \
|
||||
backupfile.o dirname.o filemode.o full-write.o getversion.o idcache.o \
|
||||
isdir.o long-options.o makepath.o modechange.o path-concat.o \
|
||||
safe-read.o save-cwd.o savedir.o stripslash.o userspec.o xgetcwd.o \
|
||||
xmalloc.o xstrdup.o xstrtol.o xstrtoul.o yesno.o
|
||||
EXTRA_fu_SOURCES =
|
||||
LIBFILES = $(pkglib_LIBFILES) $(noinst_LIBFILES) $(check_LIBFILES) \
|
||||
$(lib_LIBFILES)
|
||||
AR = ar
|
||||
RANLIB = @RANLIB@
|
||||
YACC = @YACC@
|
||||
INTERLOCK = ./interlock
|
||||
YLWRAP = ./ylwrap
|
||||
CC = @CC@
|
||||
CFLAGS = @CFLAGS@
|
||||
COMPILE = $(CC) $(DEFS) $(INCLUDES) $(CPPFLAGS) $(CFLAGS)
|
||||
LINK = $(CC) $(LDFLAGS) -o $@
|
||||
@@ -92,51 +94,54 @@ HEADERS = $(noinst_HEADERS)
|
||||
|
||||
DIST_COMMON = Makefile.am Makefile.in alloca.c basename.c error.c \
|
||||
error.h euidaccess.c fileblocks.c fnmatch.c fsusage.c ftruncate.c \
|
||||
getdate.c getline.c group_member.c interlock memcmp.c memcpy.c memset.c \
|
||||
mktime.c mountlist.c obstack.c obstack.h posixtm.c regex.c regex.h \
|
||||
rename.c rpmatch.c rx.c rx.h stpcpy.c strcasecmp.c strdup.c strndup.c \
|
||||
strstr.c strtol.c strtoul.c ylwrap
|
||||
getdate.c getgroups.c getline.c group-member.c interlock memcmp.c \
|
||||
memcpy.c memset.c mkdir.c mktime.c mountlist.c obstack.c obstack.h \
|
||||
posixtm.c regex.c regex.h rename.c rmdir.c rpmatch.c rx.c rx.h stpcpy.c \
|
||||
strcasecmp.c strdup.c strftime.c strndup.c strstr.c strtol.c strtoul.c \
|
||||
ylwrap
|
||||
|
||||
|
||||
PACKAGE = @PACKAGE@
|
||||
VERSION = @VERSION@
|
||||
|
||||
DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) \
|
||||
$(TEXINFOS) $(INFOS) $(MANS) $(EXTRA_DIST)
|
||||
DEP_DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) \
|
||||
$(TEXINFOS) $(INFO_DEPS) $(MANS) $(EXTRA_DIST)
|
||||
$(TEXINFOS) $(MANS) $(EXTRA_DIST)
|
||||
|
||||
TAR = tar
|
||||
DEP_FILES = .deps/alloca.P .deps/argmatch.P .deps/backupfile.P \
|
||||
.deps/basename.P .deps/dirname.P .deps/error.P .deps/euidaccess.P \
|
||||
.deps/fileblocks.P .deps/filemode.P .deps/fnmatch.P .deps/fsusage.P \
|
||||
.deps/ftruncate.P .deps/full-write.P .deps/getdate.P .deps/getline.P \
|
||||
.deps/getopt.P .deps/getopt1.P .deps/getversion.P .deps/group_member.P \
|
||||
.deps/idcache.P .deps/isdir.P .deps/long-options.P .deps/makepath.P \
|
||||
.deps/memcmp.P .deps/memcpy.P .deps/memset.P .deps/mktime.P \
|
||||
.deps/modechange.P .deps/mountlist.P .deps/obstack.P \
|
||||
.deps/path-concat.P .deps/posixtm.P .deps/regex.P .deps/rename.P \
|
||||
.deps/rpmatch.P .deps/rx.P .deps/safe-read.P .deps/save-cwd.P \
|
||||
.deps/savedir.P .deps/stpcpy.P .deps/strcasecmp.P .deps/strdup.P \
|
||||
.deps/stripslash.P .deps/strndup.P .deps/strstr.P .deps/strtol.P \
|
||||
.deps/strtoul.P .deps/userspec.P .deps/xgetcwd.P .deps/xmalloc.P \
|
||||
.deps/xstrdup.P .deps/xstrtol.P .deps/xstrtoul.P .deps/yesno.P
|
||||
SOURCES = $(fu_SOURCES)
|
||||
OBJECTS = $(fu_OBJECTS)
|
||||
.deps/ftruncate.P .deps/full-write.P .deps/getdate.P .deps/getgroups.P \
|
||||
.deps/getline.P .deps/getopt.P .deps/getopt1.P .deps/getversion.P \
|
||||
.deps/group-member.P .deps/idcache.P .deps/isdir.P .deps/long-options.P \
|
||||
.deps/makepath.P .deps/memcmp.P .deps/memcpy.P .deps/memset.P \
|
||||
.deps/mkdir.P .deps/mktime.P .deps/modechange.P .deps/mountlist.P \
|
||||
.deps/obstack.P .deps/path-concat.P .deps/posixtm.P .deps/regex.P \
|
||||
.deps/rename.P .deps/rmdir.P .deps/rpmatch.P .deps/rx.P \
|
||||
.deps/safe-read.P .deps/save-cwd.P .deps/savedir.P .deps/stpcpy.P \
|
||||
.deps/strcasecmp.P .deps/strdup.P .deps/strftime.P .deps/stripslash.P \
|
||||
.deps/strndup.P .deps/strstr.P .deps/strtol.P .deps/strtoul.P \
|
||||
.deps/userspec.P .deps/xgetcwd.P .deps/xmalloc.P .deps/xstrdup.P \
|
||||
.deps/xstrtol.P .deps/xstrtoul.P .deps/yesno.P
|
||||
SOURCES = $(libfu_a_SOURCES)
|
||||
OBJECTS = $(libfu_a_OBJECTS)
|
||||
|
||||
default: all
|
||||
|
||||
.SUFFIXES:
|
||||
.SUFFIXES: .c .o .y
|
||||
$(srcdir)/Makefile.in: @MAINT@ Makefile.am $(top_srcdir)/configure.in $(ACLOCAL)
|
||||
cd $(top_srcdir) && automake --gnu lib/Makefile
|
||||
|
||||
$(srcdir)/Makefile.in: @MAINT@Makefile.am $(top_srcdir)/configure.in
|
||||
cd $(top_srcdir) && automake $(subdir)/Makefile
|
||||
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status $(BUILT_SOURCES)
|
||||
cd $(top_builddir) \
|
||||
&& CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status
|
||||
|
||||
Makefile: $(top_builddir)/config.status $(srcdir)/Makefile.in $(BUILT_SOURCES)
|
||||
cd $(top_builddir) && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= ./config.status
|
||||
|
||||
mostlyclean-noinstLIBRARIES:
|
||||
|
||||
clean-noinstLIBRARIES:
|
||||
test -z "$(noinst_LIBFILES)" || rm -f $(noinst_LIBFILES)
|
||||
test -z "$(noinst_LIBRARIES)" || rm -f $(noinst_LIBRARIES)
|
||||
|
||||
distclean-noinstLIBRARIES:
|
||||
|
||||
@@ -154,22 +159,28 @@ distclean-compile:
|
||||
rm -f *.tab.c
|
||||
|
||||
maintainer-clean-compile:
|
||||
$(fu_OBJECTS): ../config.h
|
||||
$(libfu_a_OBJECTS): ../config.h
|
||||
|
||||
libfu.a: $(fu_OBJECTS) $(fu_DEPENDENCIES)
|
||||
libfu.a: $(libfu_a_OBJECTS) $(libfu_a_DEPENDENCIES)
|
||||
rm -f libfu.a
|
||||
$(AR) cru libfu.a $(fu_OBJECTS) $(fu_LIBADD)
|
||||
$(AR) cru libfu.a $(libfu_a_OBJECTS) $(libfu_a_LIBADD)
|
||||
$(RANLIB) libfu.a
|
||||
.y.c:
|
||||
$(INTERLOCK) =yacclockdir $(YLWRAP) "$(YACC)" y.tab.c $*.c y.tab.h $*.h -- $(YFLAGS) $<
|
||||
$(SHELL) $(INTERLOCK) =yacclockdir $(YLWRAP) "$(YACC)" y.tab.c $*.c y.tab.h $*.h -- $(YFLAGS) $<
|
||||
|
||||
tags: TAGS
|
||||
|
||||
ID: $(HEADERS) $(SOURCES)
|
||||
here=`pwd` && cd $(srcdir) && mkid -f$$here/ID $(SOURCES) $(HEADERS)
|
||||
|
||||
tags: TAGS
|
||||
|
||||
TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES)
|
||||
here=`pwd` && cd $(srcdir) && etags $(ETAGS_ARGS) $(SOURCES) $(HEADERS) -o $$here/TAGS
|
||||
TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES)
|
||||
tags=; \
|
||||
here=`pwd`; \
|
||||
list="$(SUBDIRS)"; for subdir in $$list; do \
|
||||
test -f $$subdir/TAGS && tags="$$tags -i $$here/$$subdir/TAGS"; \
|
||||
done; \
|
||||
test -z "$(ETAGS_ARGS)$(SOURCES)$(HEADERS)$$tags" \
|
||||
|| cd $(srcdir) && etags $(ETAGS_ARGS) $$tags $(SOURCES) $(HEADERS) -o $$here/TAGS
|
||||
|
||||
mostlyclean-tags:
|
||||
|
||||
@@ -183,11 +194,12 @@ maintainer-clean-tags:
|
||||
distdir = $(top_builddir)/$(PACKAGE)-$(VERSION)/$(subdir)
|
||||
|
||||
subdir = lib
|
||||
distdir: $(DEP_DISTFILES)
|
||||
@for file in `cd $(srcdir) && echo $(DISTFILES)`; do \
|
||||
distdir: $(DISTFILES)
|
||||
@for file in $(DISTFILES); do \
|
||||
d=$(srcdir); \
|
||||
test -f $(distdir)/$$file \
|
||||
|| ln $(srcdir)/$$file $(distdir)/$$file 2> /dev/null \
|
||||
|| cp -p $(srcdir)/$$file $(distdir)/$$file; \
|
||||
|| ln $$d/$$file $(distdir)/$$file 2> /dev/null \
|
||||
|| cp -p $$d/$$file $(distdir)/$$file; \
|
||||
done
|
||||
|
||||
MKDEP = gcc -M $(DEFS) $(INCLUDES) $(CPPFLAGS) $(CFLAGS)
|
||||
@@ -210,16 +222,14 @@ maintainer-clean-depend:
|
||||
rm -rf .deps
|
||||
|
||||
.deps/%.P: $(srcdir)/%.c
|
||||
$(MKDEP) $< > $@-tmp
|
||||
if test -n "$o"; then \
|
||||
sed 's/\.o:/$$o:/' $@-tmp > $@; \
|
||||
rm $@-tmp; \
|
||||
else \
|
||||
mv $@-tmp $@; \
|
||||
fi
|
||||
@echo "Computing dependencies for $<..."
|
||||
@o='o'; \
|
||||
test -n "$o" && o='$$o'; \
|
||||
$(MKDEP) $< | sed "s/^\(.*\)\.o:/\1.$$o \1.l$$o:/" > $@
|
||||
info:
|
||||
dvi:
|
||||
check: all
|
||||
$(MAKE)
|
||||
installcheck:
|
||||
install-exec:
|
||||
$(NORMAL_INSTALL)
|
||||
@@ -232,7 +242,7 @@ install: install-exec install-data all
|
||||
|
||||
uninstall:
|
||||
|
||||
all: $(LIBFILES) $(BUILT_SOURCES) $(HEADERS) Makefile
|
||||
all: $(LIBRARIES) $(BUILT_SOURCES) $(HEADERS) Makefile
|
||||
|
||||
install-strip:
|
||||
$(MAKE) INSTALL_PROGRAM='$(INSTALL_PROGRAM) -s' install
|
||||
@@ -257,16 +267,16 @@ mostlyclean: mostlyclean-noinstLIBRARIES mostlyclean-compile \
|
||||
mostlyclean-tags mostlyclean-depend mostlyclean-generic
|
||||
|
||||
clean: clean-noinstLIBRARIES clean-compile clean-tags clean-depend \
|
||||
clean-generic mostlyclean
|
||||
clean-generic mostlyclean
|
||||
|
||||
distclean: distclean-noinstLIBRARIES distclean-compile distclean-tags \
|
||||
distclean-depend distclean-generic clean
|
||||
distclean-depend distclean-generic clean
|
||||
rm -f config.status
|
||||
|
||||
maintainer-clean: maintainer-clean-noinstLIBRARIES \
|
||||
maintainer-clean-compile maintainer-clean-tags \
|
||||
maintainer-clean-depend maintainer-clean-generic \
|
||||
distclean
|
||||
distclean
|
||||
@echo "This command is intended for maintainers to use;"
|
||||
@echo "it deletes files that may require special tools to rebuild."
|
||||
|
||||
@@ -275,13 +285,11 @@ clean-noinstLIBRARIES maintainer-clean-noinstLIBRARIES \
|
||||
mostlyclean-compile distclean-compile clean-compile \
|
||||
maintainer-clean-compile tags mostlyclean-tags distclean-tags \
|
||||
clean-tags maintainer-clean-tags distdir mostlyclean-depend \
|
||||
distclean-depend clean-depend maintainer-clean-depend info dvi check \
|
||||
distclean-depend clean-depend maintainer-clean-depend info dvi \
|
||||
installcheck install-exec install-data install uninstall all \
|
||||
installdirs mostlyclean-generic distclean-generic clean-generic \
|
||||
maintainer-clean-generic clean mostlyclean distclean maintainer-clean
|
||||
|
||||
.SUFFIXES:
|
||||
.SUFFIXES: .c .o .y
|
||||
|
||||
# Tell versions [3.59,3.63) of GNU make to not export all variables.
|
||||
# Otherwise a system limit (for SysV at least) may be exceeded.
|
||||
|
||||
@@ -68,8 +68,17 @@ char *malloc ();
|
||||
# define IN_CTYPE_DOMAIN(c) isascii(c)
|
||||
#endif
|
||||
|
||||
#define ISDIGIT(c) (IN_CTYPE_DOMAIN ((unsigned char) (c)) \
|
||||
&& isdigit ((unsigned char) (c)))
|
||||
#define ISDIGIT_LOCALE(c) (IN_CTYPE_DOMAIN (c) && isdigit (c))
|
||||
|
||||
/* ISDIGIT differs from ISDIGIT_LOCALE, as follows:
|
||||
- Its arg may be any int or unsigned int; it need not be an unsigned char.
|
||||
- It's guaranteed to evaluate its argument exactly once.
|
||||
- It's typically faster.
|
||||
Posix 1003.2-1992 section 2.5.2.1 page 50 lines 1556-1558 says that
|
||||
only '0' through '9' are digits. Prefer ISDIGIT to ISDIGIT_LOCALE unless
|
||||
it's important to use the locale's definition of `digit' even when the
|
||||
host does not conform to Posix. */
|
||||
#define ISDIGIT(c) ((unsigned) (c) - '0' <= 9)
|
||||
|
||||
#if defined (HAVE_UNISTD_H)
|
||||
#include <unistd.h>
|
||||
|
||||
@@ -22,6 +22,7 @@
|
||||
# include <config.h>
|
||||
#endif
|
||||
|
||||
#include <sys/types.h>
|
||||
#ifdef HAVE_UNISTD_H
|
||||
# include <unistd.h>
|
||||
#endif
|
||||
|
||||
@@ -68,7 +68,7 @@ unsigned int error_message_count;
|
||||
# define program_name program_invocation_name
|
||||
# include <errno.h>
|
||||
|
||||
#else
|
||||
#else /* not _LIBC */
|
||||
|
||||
/* The calling program should define program_name and set it to the
|
||||
name of the executing program. */
|
||||
@@ -92,7 +92,7 @@ private_strerror (errnum)
|
||||
}
|
||||
# define strerror private_strerror
|
||||
# endif /* HAVE_STRERROR */
|
||||
#endif /* _LIBC */
|
||||
#endif /* not _LIBC */
|
||||
|
||||
/* Print the program name and error message MESSAGE, which is a printf-style
|
||||
format string with optional args.
|
||||
|
||||
@@ -15,8 +15,8 @@
|
||||
along with this program; if not, write to the Free Software Foundation,
|
||||
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
|
||||
|
||||
#ifndef _error_h_
|
||||
# define _error_h_
|
||||
#ifndef ERROR_H_
|
||||
# define ERROR_H_
|
||||
|
||||
# ifndef __attribute__
|
||||
/* This feature is available in gcc versions 2.5 and later. */
|
||||
@@ -62,4 +62,4 @@ extern unsigned int error_message_count;
|
||||
variable controls whether this mode is selected or not. */
|
||||
extern int error_one_per_line;
|
||||
|
||||
#endif /* not _error_h_ */
|
||||
#endif /* not ERROR_H_ */
|
||||
|
||||
@@ -1,30 +1,38 @@
|
||||
/* Copyright (C) 1991, 1992, 1993 Free Software Foundation, Inc.
|
||||
|
||||
NOTE: The canonical source of this file is maintained with the GNU C Library.
|
||||
Bugs can be reported to bug-glibc@prep.ai.mit.edu.
|
||||
NOTE: The canonical source of this file is maintained with the GNU C
|
||||
Library. Bugs can be reported to bug-glibc@prep.ai.mit.edu.
|
||||
|
||||
This program is free software; you can redistribute it and/or modify it
|
||||
under the terms of the GNU General Public License as published by the
|
||||
Free Software Foundation; either version 2, or (at your option) any
|
||||
later version.
|
||||
This program is free software; you can redistribute it and/or modify it
|
||||
under the terms of the GNU General Public License as published by the
|
||||
Free Software Foundation; either version 2, or (at your option) any
|
||||
later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software Foundation,
|
||||
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software Foundation,
|
||||
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include <config.h>
|
||||
#if HAVE_CONFIG_H
|
||||
# include <config.h>
|
||||
#endif
|
||||
|
||||
#include <errno.h>
|
||||
#include <fnmatch.h>
|
||||
#include <ctype.h>
|
||||
|
||||
#if defined (STDC_HEADERS) || !defined (isascii)
|
||||
# define ISASCII(c) 1
|
||||
#else
|
||||
# define ISASCII(c) isascii(c)
|
||||
#endif
|
||||
|
||||
#define ISUPPER(c) (ISASCII (c) && isupper (c))
|
||||
|
||||
|
||||
/* Comment out all this code if we are using the GNU C Library, and are not
|
||||
actually compiling the library itself. This code is part of the GNU C
|
||||
@@ -37,9 +45,9 @@ Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
|
||||
#if defined (_LIBC) || !defined (__GNU_LIBRARY__)
|
||||
|
||||
|
||||
#ifndef errno
|
||||
# ifndef errno
|
||||
extern int errno;
|
||||
#endif
|
||||
# endif
|
||||
|
||||
/* Match STRING against the filename pattern PATTERN, returning zero if
|
||||
it matches, nonzero if not. */
|
||||
@@ -53,7 +61,7 @@ fnmatch (pattern, string, flags)
|
||||
register char c;
|
||||
|
||||
/* Note that this evalutes C many times. */
|
||||
#define FOLD(c) ((flags & FNM_CASEFOLD) && isupper (c) ? tolower (c) : (c))
|
||||
# define FOLD(c) ((flags & FNM_CASEFOLD) && ISUPPER (c) ? tolower (c) : (c))
|
||||
|
||||
while ((c = *p++) != '\0')
|
||||
{
|
||||
@@ -197,6 +205,8 @@ fnmatch (pattern, string, flags)
|
||||
return 0;
|
||||
|
||||
return FNM_NOMATCH;
|
||||
|
||||
# undef FOLD
|
||||
}
|
||||
|
||||
#endif /* _LIBC or not __GNU_LIBRARY__. */
|
||||
|
||||
158
lib/fsusage.c
158
lib/fsusage.c
@@ -1,5 +1,5 @@
|
||||
/* fsusage.c -- return space usage of mounted filesystems
|
||||
Copyright (C) 1991, 1992 Free Software Foundation, Inc.
|
||||
Copyright (C) 1991, 1992, 1996 Free Software Foundation, Inc.
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
@@ -15,8 +15,8 @@
|
||||
along with this program; if not, write to the Free Software Foundation,
|
||||
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include <config.h>
|
||||
#if HAVE_CONFIG_H
|
||||
# include <config.h>
|
||||
#endif
|
||||
|
||||
#include <sys/types.h>
|
||||
@@ -25,40 +25,40 @@
|
||||
|
||||
int statfs ();
|
||||
|
||||
#ifdef HAVE_SYS_PARAM_H
|
||||
#include <sys/param.h>
|
||||
#if HAVE_SYS_PARAM_H
|
||||
# include <sys/param.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_SYS_MOUNT_H
|
||||
#include <sys/mount.h>
|
||||
#if HAVE_SYS_MOUNT_H
|
||||
# include <sys/mount.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_SYS_VFS_H
|
||||
#include <sys/vfs.h>
|
||||
#if HAVE_SYS_VFS_H
|
||||
# include <sys/vfs.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_SYS_FS_S5PARAM_H /* Fujitsu UXP/V */
|
||||
#include <sys/fs/s5param.h>
|
||||
#if HAVE_SYS_FS_S5PARAM_H /* Fujitsu UXP/V */
|
||||
# include <sys/fs/s5param.h>
|
||||
#endif
|
||||
|
||||
#if defined(HAVE_SYS_FILSYS_H) && !defined(_CRAY)
|
||||
#include <sys/filsys.h> /* SVR2. */
|
||||
#if defined (HAVE_SYS_FILSYS_H) && !defined (_CRAY)
|
||||
# include <sys/filsys.h> /* SVR2 */
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_FCNTL_H
|
||||
#include <fcntl.h>
|
||||
#if HAVE_FCNTL_H
|
||||
# include <fcntl.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_SYS_STATFS_H
|
||||
#include <sys/statfs.h>
|
||||
#if HAVE_SYS_STATFS_H
|
||||
# include <sys/statfs.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_DUSTAT_H /* AIX PS/2. */
|
||||
#include <sys/dustat.h>
|
||||
#if HAVE_DUSTAT_H /* AIX PS/2 */
|
||||
# include <sys/dustat.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_SYS_STATVFS_H /* SVR4. */
|
||||
#include <sys/statvfs.h>
|
||||
#if HAVE_SYS_STATVFS_H /* SVR4 */
|
||||
# include <sys/statvfs.h>
|
||||
int statvfs ();
|
||||
#endif
|
||||
|
||||
@@ -78,11 +78,11 @@ adjust_blocks (blocks, fromsize, tosize)
|
||||
if (fromsize <= 0)
|
||||
return -1;
|
||||
|
||||
if (fromsize == tosize) /* E.g., from 512 to 512. */
|
||||
if (fromsize == tosize) /* e.g., from 512 to 512 */
|
||||
return blocks;
|
||||
else if (fromsize > tosize) /* E.g., from 2048 to 512. */
|
||||
else if (fromsize > tosize) /* e.g., from 2048 to 512 */
|
||||
return blocks * (fromsize / tosize);
|
||||
else /* E.g., from 256 to 512. */
|
||||
else /* e.g., from 256 to 512 */
|
||||
return (blocks + (blocks < 0 ? -1 : 1)) / (tosize / fromsize);
|
||||
}
|
||||
|
||||
@@ -90,42 +90,56 @@ adjust_blocks (blocks, fromsize, tosize)
|
||||
the filesystem on which PATH resides.
|
||||
DISK is the device on which PATH is mounted, for space-getting
|
||||
methods that need to know it.
|
||||
Return 0 if successful, -1 if not. */
|
||||
|
||||
Return 0 if successful, -1 if not. When returning -1, ensure that
|
||||
ERRNO is either a system error value, or zero if DISK is NULL
|
||||
on a system that requires a non-NULL value. */
|
||||
int
|
||||
get_fs_usage (path, disk, fsp)
|
||||
const char *path;
|
||||
const char *disk;
|
||||
struct fs_usage *fsp;
|
||||
{
|
||||
#if defined (STAT_STATFS3_OSF1)
|
||||
#ifdef STAT_STATFS3_OSF1
|
||||
# define CONVERT_BLOCKS(B) adjust_blocks ((B), fsd.f_fsize, 512)
|
||||
|
||||
struct statfs fsd;
|
||||
|
||||
if (statfs (path, &fsd, sizeof (struct statfs)) != 0)
|
||||
return -1;
|
||||
#define CONVERT_BLOCKS(b) adjust_blocks ((b), fsd.f_fsize, 512)
|
||||
|
||||
#endif /* STAT_STATFS3_OSF1 */
|
||||
|
||||
#ifdef STAT_STATFS2_FS_DATA /* Ultrix. */
|
||||
#ifdef STAT_STATFS2_FS_DATA /* Ultrix */
|
||||
# define CONVERT_BLOCKS(B) adjust_blocks ((B), 1024, 512)
|
||||
|
||||
struct fs_data fsd;
|
||||
|
||||
if (statfs (path, &fsd) != 1)
|
||||
return -1;
|
||||
#define CONVERT_BLOCKS(b) adjust_blocks ((b), 1024, 512)
|
||||
fsp->fsu_blocks = CONVERT_BLOCKS (fsd.fd_req.btot);
|
||||
fsp->fsu_bfree = CONVERT_BLOCKS (fsd.fd_req.bfree);
|
||||
fsp->fsu_bavail = CONVERT_BLOCKS (fsd.fd_req.bfreen);
|
||||
fsp->fsu_files = fsd.fd_req.gtot;
|
||||
fsp->fsu_ffree = fsd.fd_req.gfree;
|
||||
#endif
|
||||
|
||||
#ifdef STAT_READ_FILSYS /* SVR2. */
|
||||
#ifndef SUPERBOFF
|
||||
#define SUPERBOFF (SUPERB * 512)
|
||||
#endif
|
||||
#endif /* STAT_STATFS2_FS_DATA */
|
||||
|
||||
#ifdef STAT_READ_FILSYS /* SVR2 */
|
||||
# ifndef SUPERBOFF
|
||||
# define SUPERBOFF (SUPERB * 512)
|
||||
# endif
|
||||
# define CONVERT_BLOCKS(B) \
|
||||
adjust_blocks ((B), (fsd.s_type == Fs2b ? 1024 : 512), 512)
|
||||
|
||||
struct filsys fsd;
|
||||
int fd;
|
||||
|
||||
if (! disk)
|
||||
{
|
||||
errno = 0;
|
||||
return -1;
|
||||
}
|
||||
|
||||
fd = open (disk, O_RDONLY);
|
||||
if (fd < 0)
|
||||
return -1;
|
||||
@@ -136,21 +150,24 @@ get_fs_usage (path, disk, fsp)
|
||||
return -1;
|
||||
}
|
||||
close (fd);
|
||||
#define CONVERT_BLOCKS(b) adjust_blocks ((b), (fsd.s_type == Fs2b ? 1024 : 512), 512)
|
||||
fsp->fsu_blocks = CONVERT_BLOCKS (fsd.s_fsize);
|
||||
fsp->fsu_bfree = CONVERT_BLOCKS (fsd.s_tfree);
|
||||
fsp->fsu_bavail = CONVERT_BLOCKS (fsd.s_tfree);
|
||||
fsp->fsu_files = (fsd.s_isize - 2) * INOPB * (fsd.s_type == Fs2b ? 2 : 1);
|
||||
fsp->fsu_ffree = fsd.s_tinode;
|
||||
#endif
|
||||
|
||||
#ifdef STAT_STATFS2_BSIZE /* 4.3BSD, SunOS 4, HP-UX, AIX. */
|
||||
#endif /* STAT_READ_FILSYS */
|
||||
|
||||
#ifdef STAT_STATFS2_BSIZE /* 4.3BSD, SunOS 4, HP-UX, AIX */
|
||||
# define CONVERT_BLOCKS(B) adjust_blocks ((B), fsd.f_bsize, 512)
|
||||
|
||||
struct statfs fsd;
|
||||
|
||||
if (statfs (path, &fsd) < 0)
|
||||
return -1;
|
||||
|
||||
#ifdef STATFS_TRUNCATES_BLOCK_COUNTS
|
||||
# ifdef STATFS_TRUNCATES_BLOCK_COUNTS
|
||||
|
||||
/* In SunOS 4.1.2, 4.1.3, and 4.1.3_U1, the block counts in the
|
||||
struct statfs are truncated to 2GB. These conditions detect that
|
||||
truncation, presumably without botching the 4.1.1 case, in which
|
||||
@@ -162,20 +179,35 @@ get_fs_usage (path, disk, fsp)
|
||||
fsd.f_bfree = fsd.f_spare[1];
|
||||
fsd.f_bavail = fsd.f_spare[2];
|
||||
}
|
||||
#endif /* STATFS_TRUNCATES_BLOCK_COUNTS */
|
||||
# endif /* STATFS_TRUNCATES_BLOCK_COUNTS */
|
||||
|
||||
#define CONVERT_BLOCKS(b) adjust_blocks ((b), fsd.f_bsize, 512)
|
||||
#endif
|
||||
#endif /* STAT_STATFS2_BSIZE */
|
||||
|
||||
#ifdef STAT_STATFS2_FSIZE /* 4.4BSD */
|
||||
# define CONVERT_BLOCKS(B) adjust_blocks ((B), fsd.f_fsize, 512)
|
||||
|
||||
#ifdef STAT_STATFS2_FSIZE /* 4.4BSD. */
|
||||
struct statfs fsd;
|
||||
|
||||
if (statfs (path, &fsd) < 0)
|
||||
return -1;
|
||||
#define CONVERT_BLOCKS(b) adjust_blocks ((b), fsd.f_fsize, 512)
|
||||
#endif
|
||||
|
||||
#ifdef STAT_STATFS4 /* SVR3, Dynix, Irix, AIX. */
|
||||
#endif /* STAT_STATFS2_FSIZE */
|
||||
|
||||
#ifdef STAT_STATFS4 /* SVR3, Dynix, Irix, AIX */
|
||||
# if _AIX || defined(_CRAY)
|
||||
# define CONVERT_BLOCKS(B) adjust_blocks ((B), fsd.f_bsize, 512)
|
||||
# ifdef _CRAY
|
||||
# define f_bavail f_bfree
|
||||
# endif
|
||||
# else
|
||||
# define CONVERT_BLOCKS(B) (B)
|
||||
# ifndef _SEQUENT_ /* _SEQUENT_ is DYNIX/ptx */
|
||||
# ifndef DOLPHIN /* DOLPHIN 3.8.alfa/7.18 has f_bavail */
|
||||
# define f_bavail f_bfree
|
||||
# endif
|
||||
# endif
|
||||
# endif
|
||||
|
||||
struct statfs fsd;
|
||||
|
||||
if (statfs (path, &fsd, sizeof fsd, 0) < 0)
|
||||
@@ -183,38 +215,31 @@ get_fs_usage (path, disk, fsp)
|
||||
/* Empirically, the block counts on most SVR3 and SVR3-derived
|
||||
systems seem to always be in terms of 512-byte blocks,
|
||||
no matter what value f_bsize has. */
|
||||
# if _AIX || defined(_CRAY)
|
||||
# define CONVERT_BLOCKS(b) adjust_blocks ((b), fsd.f_bsize, 512)
|
||||
# ifdef _CRAY
|
||||
# define f_bavail f_bfree
|
||||
# endif
|
||||
# else
|
||||
# define CONVERT_BLOCKS(b) (b)
|
||||
# ifndef _SEQUENT_ /* _SEQUENT_ is DYNIX/ptx. */
|
||||
# ifndef DOLPHIN /* DOLPHIN 3.8.alfa/7.18 has f_bavail */
|
||||
# define f_bavail f_bfree
|
||||
# endif
|
||||
# endif
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#ifdef STAT_STATVFS /* SVR4. */
|
||||
#endif /* STAT_STATFS4 */
|
||||
|
||||
#ifdef STAT_STATVFS /* SVR4 */
|
||||
# define CONVERT_BLOCKS(B) \
|
||||
adjust_blocks ((B), fsd.f_frsize ? fsd.f_frsize : fsd.f_bsize, 512)
|
||||
|
||||
struct statvfs fsd;
|
||||
|
||||
if (statvfs (path, &fsd) < 0)
|
||||
return -1;
|
||||
/* f_frsize isn't guaranteed to be supported. */
|
||||
#define CONVERT_BLOCKS(b) \
|
||||
adjust_blocks ((b), fsd.f_frsize ? fsd.f_frsize : fsd.f_bsize, 512)
|
||||
#endif
|
||||
|
||||
#if !defined(STAT_STATFS2_FS_DATA) && !defined(STAT_READ_FILSYS) /* !Ultrix && !SVR2. */
|
||||
#endif /* STAT_STATVFS */
|
||||
|
||||
#if !defined(STAT_STATFS2_FS_DATA) && !defined(STAT_READ_FILSYS)
|
||||
/* !Ultrix && !SVR2 */
|
||||
|
||||
fsp->fsu_blocks = CONVERT_BLOCKS (fsd.f_blocks);
|
||||
fsp->fsu_bfree = CONVERT_BLOCKS (fsd.f_bfree);
|
||||
fsp->fsu_bavail = CONVERT_BLOCKS (fsd.f_bavail);
|
||||
fsp->fsu_files = fsd.f_files;
|
||||
fsp->fsu_ffree = fsd.f_ffree;
|
||||
#endif
|
||||
|
||||
#endif /* not STAT_STATFS2_FS_DATA && not STAT_READ_FILSYS */
|
||||
|
||||
return 0;
|
||||
}
|
||||
@@ -245,4 +270,5 @@ statfs (path, fsb)
|
||||
fsb->f_fsid.val[1] = fsd.du_pckno;
|
||||
return 0;
|
||||
}
|
||||
|
||||
#endif /* _AIX && _I386 */
|
||||
|
||||
46
lib/getdate.h
Normal file
46
lib/getdate.h
Normal file
@@ -0,0 +1,46 @@
|
||||
/* Copyright (C) 1995 Free Software Foundation, Inc.
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation; either version 2, or (at your option)
|
||||
any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software Foundation,
|
||||
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
# include <config.h>
|
||||
#endif
|
||||
|
||||
# ifndef PARAMS
|
||||
# if defined (__GNUC__) || __STDC__
|
||||
# define PARAMS(args) args
|
||||
# else
|
||||
# define PARAMS(args) ()
|
||||
# endif
|
||||
# endif
|
||||
|
||||
#if defined (vms)
|
||||
# include <types.h>
|
||||
# include <time.h>
|
||||
#else
|
||||
# include <sys/types.h>
|
||||
# ifdef TIME_WITH_SYS_TIME
|
||||
# include <sys/time.h>
|
||||
# include <time.h>
|
||||
# else
|
||||
# ifdef HAVE_SYS_TIME_H
|
||||
# include <sys/time.h>
|
||||
# else
|
||||
# include <time.h>
|
||||
# endif
|
||||
# endif
|
||||
#endif /* defined (vms) */
|
||||
|
||||
time_t get_date PARAMS ((const char *p, const time_t *now));
|
||||
919
lib/getdate.y
919
lib/getdate.y
File diff suppressed because it is too large
Load Diff
59
lib/getgroups.c
Normal file
59
lib/getgroups.c
Normal file
@@ -0,0 +1,59 @@
|
||||
/* provide consistent interface to getgroups for systems that don't allow N==0
|
||||
Copyright (C) 1996 Free Software Foundation, Inc.
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation; either version 2, or (at your option)
|
||||
any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software Foundation,
|
||||
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
|
||||
|
||||
/* written by Jim Meyering */
|
||||
|
||||
#include <config.h>
|
||||
#include <stdio.h>
|
||||
#include <sys/types.h>
|
||||
|
||||
char *xmalloc ();
|
||||
|
||||
/* On at least Ultrix 4.3 and NextStep 3.2, getgroups (0, 0) always fails.
|
||||
On other systems, it returns the number of supplemental groups for the
|
||||
process is returned.
|
||||
This function handles that special case and lets the system-
|
||||
provided function handle all others. */
|
||||
|
||||
int
|
||||
getgroups (n, group)
|
||||
size_t n;
|
||||
GETGROUPS_T *group;
|
||||
{
|
||||
int n_groups;
|
||||
GETGROUPS_T *gbuf;
|
||||
|
||||
#undef getgroups
|
||||
|
||||
if (n != 0)
|
||||
return getgroups (n, group);
|
||||
|
||||
n = 20;
|
||||
gbuf = NULL;
|
||||
while (1)
|
||||
{
|
||||
gbuf = (GETGROUPS_T *) xrealloc (gbuf, n * sizeof (GETGROUPS_T));
|
||||
n_groups = getgroups (n, gbuf);
|
||||
if (n_groups < n)
|
||||
break;
|
||||
n += 10;
|
||||
}
|
||||
|
||||
free (gbuf);
|
||||
|
||||
return n_groups;
|
||||
}
|
||||
@@ -14,8 +14,8 @@ You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
|
||||
|
||||
#ifndef _getline_h_
|
||||
# define _getline_h_ 1
|
||||
#ifndef GETLINE_H_
|
||||
# define GETLINE_H_ 1
|
||||
|
||||
# include <stdio.h>
|
||||
|
||||
@@ -33,4 +33,4 @@ getline PARAMS ((char **_lineptr, size_t *_n, FILE *_stream));
|
||||
int
|
||||
getdelim PARAMS ((char **_lineptr, size_t *_n, int _delimiter, FILE *_stream));
|
||||
|
||||
#endif
|
||||
#endif /* not GETLINE_H_ */
|
||||
|
||||
766
lib/getloadavg.c
766
lib/getloadavg.c
File diff suppressed because it is too large
Load Diff
275
lib/getopt.c
275
lib/getopt.c
@@ -3,22 +3,26 @@
|
||||
"Keep this file name-space clean" means, talk to roland@gnu.ai.mit.edu
|
||||
before changing it!
|
||||
|
||||
Copyright (C) 1987, 88, 89, 90, 91, 92, 93, 94, 95, 1996
|
||||
Free Software Foundation, Inc.
|
||||
Copyright (C) 1987, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97
|
||||
Free Software Foundation, Inc.
|
||||
|
||||
This program is free software; you can redistribute it and/or modify it
|
||||
under the terms of the GNU General Public License as published by the
|
||||
Free Software Foundation; either version 2, or (at your option) any
|
||||
later version.
|
||||
This file is part of the GNU C Library. Its master source is NOT part of
|
||||
the C library, however. The master source lives in /gd/gnu/lib.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Library General Public License as
|
||||
published by the Free Software Foundation; either version 2 of the
|
||||
License, or (at your option) any later version.
|
||||
|
||||
The GNU C Library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Library General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
|
||||
You should have received a copy of the GNU Library General Public
|
||||
License along with the GNU C Library; see the file COPYING.LIB. If not,
|
||||
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
|
||||
Boston, MA 02111-1307, USA. */
|
||||
|
||||
/* This tells Alpha OSF/1 not to define a getopt prototype in <stdio.h>.
|
||||
Ditto for AIX 3.2 and <stdlib.h>. */
|
||||
@@ -48,18 +52,24 @@
|
||||
program understand `configure --with-gnu-libc' and omit the object files,
|
||||
it is simpler to just do this in the source for each such file. */
|
||||
|
||||
#if defined (_LIBC) || !defined (__GNU_LIBRARY__)
|
||||
#define GETOPT_INTERFACE_VERSION 2
|
||||
#if !defined (_LIBC) && defined (__GLIBC__) && __GLIBC__ >= 2
|
||||
#include <gnu-versions.h>
|
||||
#if _GNU_GETOPT_INTERFACE_VERSION == GETOPT_INTERFACE_VERSION
|
||||
#define ELIDE_CODE
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifndef ELIDE_CODE
|
||||
|
||||
|
||||
/* This needs to come after some library #include
|
||||
to get __GNU_LIBRARY__ defined. */
|
||||
#ifdef __GNU_LIBRARY__
|
||||
#ifdef __GNU_LIBRARY__
|
||||
/* Don't include stdlib.h for non-GNU C libraries because some of them
|
||||
contain conflicting prototypes for getopt. */
|
||||
#include <stdlib.h>
|
||||
#if defined (_LIBC) || defined (HAVE_UNISTD_H)
|
||||
#include <unistd.h>
|
||||
#endif
|
||||
#endif /* GNU C library. */
|
||||
|
||||
#ifdef VMS
|
||||
@@ -69,7 +79,7 @@
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifdef WIN32
|
||||
#if defined (WIN32) && !defined (__CYGWIN32__)
|
||||
/* It's not Unix, really. See? Capital letters. */
|
||||
#include <windows.h>
|
||||
#define getpid() GetCurrentProcessId()
|
||||
@@ -116,14 +126,20 @@ char *optarg = NULL;
|
||||
|
||||
On entry to `getopt', zero means this is the first call; initialize.
|
||||
|
||||
When `getopt' returns EOF, this is the index of the first of the
|
||||
When `getopt' returns -1, this is the index of the first of the
|
||||
non-option elements that the caller should itself scan.
|
||||
|
||||
Otherwise, `optind' communicates from one call to the next
|
||||
how much of ARGV has been scanned so far. */
|
||||
|
||||
/* XXX 1003.2 says this must be 1 before any call. */
|
||||
int optind = 0;
|
||||
/* 1003.2 says this must be 1 before any call. */
|
||||
int optind = 1;
|
||||
|
||||
/* Formerly, initialization of getopt depended on optind==0, which
|
||||
causes problems with re-calling getopt as programs generally don't
|
||||
know that. */
|
||||
|
||||
int __getopt_initialized = 0;
|
||||
|
||||
/* The next char to be scanned in the option-element
|
||||
in which the last option character we returned was found.
|
||||
@@ -172,7 +188,7 @@ int optopt = '?';
|
||||
|
||||
The special argument `--' forces an end of option-scanning regardless
|
||||
of the value of `ordering'. In the case of RETURN_IN_ORDER, only
|
||||
`--' can cause `getopt' to return EOF with `optind' != ARGC. */
|
||||
`--' can cause `getopt' to return -1 with `optind' != ARGC. */
|
||||
|
||||
static enum
|
||||
{
|
||||
@@ -182,7 +198,7 @@ static enum
|
||||
/* Value of POSIXLY_CORRECT environment variable. */
|
||||
static char *posixly_correct;
|
||||
|
||||
#ifdef __GNU_LIBRARY__
|
||||
#ifdef __GNU_LIBRARY__
|
||||
/* We want to avoid inclusion of string.h with non-GNU libraries
|
||||
because there are many ways it can cause trouble.
|
||||
On some systems, it contains special magic macros that don't work
|
||||
@@ -233,12 +249,31 @@ extern int strlen (const char *);
|
||||
static int first_nonopt;
|
||||
static int last_nonopt;
|
||||
|
||||
#ifdef _LIBC
|
||||
/* Bash 2.0 gives us an environment variable containing flags
|
||||
indicating ARGV elements that should not be considered arguments. */
|
||||
|
||||
static const char *nonoption_flags;
|
||||
static int nonoption_flags_len;
|
||||
|
||||
static int original_argc;
|
||||
static char *const *original_argv;
|
||||
|
||||
/* Make sure the environment variable bash 2.0 puts in the environment
|
||||
is valid for the getopt call we must make sure that the ARGV passed
|
||||
to getopt is that one passed to the process. */
|
||||
static void store_args (int argc, char *const *argv) __attribute__ ((unused));
|
||||
static void
|
||||
store_args (int argc, char *const *argv)
|
||||
{
|
||||
/* XXX This is no good solution. We should rather copy the args so
|
||||
that we can compare them later. But we must not use malloc(3). */
|
||||
original_argc = argc;
|
||||
original_argv = argv;
|
||||
}
|
||||
text_set_element (__libc_subinit, store_args);
|
||||
#endif
|
||||
|
||||
/* Exchange two adjacent subsequences of ARGV.
|
||||
One subsequence is elements [first_nonopt,last_nonopt)
|
||||
which contains all the non-options that have been skipped so far.
|
||||
@@ -311,10 +346,12 @@ exchange (argv)
|
||||
/* Initialize the internal data when the first call is made. */
|
||||
|
||||
#if defined (__STDC__) && __STDC__
|
||||
static const char *_getopt_initialize (const char *);
|
||||
static const char *_getopt_initialize (int, char *const *, const char *);
|
||||
#endif
|
||||
static const char *
|
||||
_getopt_initialize (optstring)
|
||||
_getopt_initialize (argc, argv, optstring)
|
||||
int argc;
|
||||
char *const *argv;
|
||||
const char *optstring;
|
||||
{
|
||||
/* Start processing options with ARGV-element 1 (since ARGV-element 0
|
||||
@@ -344,7 +381,9 @@ _getopt_initialize (optstring)
|
||||
else
|
||||
ordering = PERMUTE;
|
||||
|
||||
if (posixly_correct == NULL)
|
||||
#ifdef _LIBC
|
||||
if (posixly_correct == NULL
|
||||
&& argc == original_argc && argv == original_argv)
|
||||
{
|
||||
/* Bash 2.0 puts a special variable in the environment for each
|
||||
command it runs, specifying which ARGV elements are the results of
|
||||
@@ -358,6 +397,9 @@ _getopt_initialize (optstring)
|
||||
else
|
||||
nonoption_flags_len = strlen (nonoption_flags);
|
||||
}
|
||||
else
|
||||
nonoption_flags_len = 0;
|
||||
#endif
|
||||
|
||||
return optstring;
|
||||
}
|
||||
@@ -375,7 +417,7 @@ _getopt_initialize (optstring)
|
||||
updating `optind' and `nextchar' so that the next call to `getopt' can
|
||||
resume the scan with the following option character or ARGV-element.
|
||||
|
||||
If there are no more option characters, `getopt' returns `EOF'.
|
||||
If there are no more option characters, `getopt' returns -1.
|
||||
Then `optind' is the index in ARGV of the first ARGV-element
|
||||
that is not an option. (The ARGV-elements have been permuted
|
||||
so that those that are not options now come last.)
|
||||
@@ -429,18 +471,24 @@ _getopt_internal (argc, argv, optstring, longopts, longind, long_only)
|
||||
{
|
||||
optarg = NULL;
|
||||
|
||||
if (optind == 0)
|
||||
if (!__getopt_initialized || optind == 0)
|
||||
{
|
||||
optstring = _getopt_initialize (optstring);
|
||||
optstring = _getopt_initialize (argc, argv, optstring);
|
||||
optind = 1; /* Don't scan ARGV[0], the program name. */
|
||||
__getopt_initialized = 1;
|
||||
}
|
||||
|
||||
/* Test whether ARGV[optind] points to a non-option argument.
|
||||
Either it does not have option syntax, or there is an environment flag
|
||||
from the shell indicating it is not an option. */
|
||||
from the shell indicating it is not an option. The later information
|
||||
is only used when the used in the GNU libc. */
|
||||
#ifdef _LIBC
|
||||
#define NONOPTION_P (argv[optind][0] != '-' || argv[optind][1] == '\0' \
|
||||
|| (optind < nonoption_flags_len \
|
||||
&& nonoption_flags[optind] == '1'))
|
||||
#else
|
||||
#define NONOPTION_P (argv[optind][0] != '-' || argv[optind][1] == '\0')
|
||||
#endif
|
||||
|
||||
if (nextchar == NULL || *nextchar == '\0')
|
||||
{
|
||||
@@ -498,7 +546,7 @@ _getopt_internal (argc, argv, optstring, longopts, longind, long_only)
|
||||
that we previously skipped, so the caller will digest them. */
|
||||
if (first_nonopt != last_nonopt)
|
||||
optind = first_nonopt;
|
||||
return EOF;
|
||||
return -1;
|
||||
}
|
||||
|
||||
/* If we have come to a non-option and did not permute it,
|
||||
@@ -507,7 +555,7 @@ _getopt_internal (argc, argv, optstring, longopts, longind, long_only)
|
||||
if (NONOPTION_P)
|
||||
{
|
||||
if (ordering == REQUIRE_ORDER)
|
||||
return EOF;
|
||||
return -1;
|
||||
optarg = argv[optind++];
|
||||
return 1;
|
||||
}
|
||||
@@ -543,22 +591,19 @@ _getopt_internal (argc, argv, optstring, longopts, longind, long_only)
|
||||
const struct option *pfound = NULL;
|
||||
int exact = 0;
|
||||
int ambig = 0;
|
||||
int indfound;
|
||||
int indfound = -1;
|
||||
int option_index;
|
||||
|
||||
for (nameend = nextchar; *nameend && *nameend != '='; nameend++)
|
||||
/* Do nothing. */ ;
|
||||
|
||||
#ifdef lint /* Suppress `used before initialized' warning. */
|
||||
indfound = 0;
|
||||
#endif
|
||||
|
||||
/* Test all long options for either exact match
|
||||
or abbreviated matches. */
|
||||
for (p = longopts, option_index = 0; p->name; p++, option_index++)
|
||||
if (!strncmp (p->name, nextchar, nameend - nextchar))
|
||||
{
|
||||
if (nameend - nextchar == strlen (p->name))
|
||||
if ((unsigned int) (nameend - nextchar)
|
||||
== (unsigned int) strlen (p->name))
|
||||
{
|
||||
/* Exact match found. */
|
||||
pfound = p;
|
||||
@@ -601,16 +646,16 @@ _getopt_internal (argc, argv, optstring, longopts, longind, long_only)
|
||||
else
|
||||
{
|
||||
if (opterr)
|
||||
if (argv[optind - 1][1] == '-')
|
||||
/* --option */
|
||||
fprintf (stderr,
|
||||
_("%s: option `--%s' doesn't allow an argument\n"),
|
||||
argv[0], pfound->name);
|
||||
else
|
||||
/* +option or -option */
|
||||
fprintf (stderr,
|
||||
_("%s: option `%c%s' doesn't allow an argument\n"),
|
||||
argv[0], argv[optind - 1][0], pfound->name);
|
||||
if (argv[optind - 1][1] == '-')
|
||||
/* --option */
|
||||
fprintf (stderr,
|
||||
_("%s: option `--%s' doesn't allow an argument\n"),
|
||||
argv[0], pfound->name);
|
||||
else
|
||||
/* +option or -option */
|
||||
fprintf (stderr,
|
||||
_("%s: option `%c%s' doesn't allow an argument\n"),
|
||||
argv[0], argv[optind - 1][0], pfound->name);
|
||||
|
||||
nextchar += strlen (nextchar);
|
||||
|
||||
@@ -626,8 +671,8 @@ _getopt_internal (argc, argv, optstring, longopts, longind, long_only)
|
||||
{
|
||||
if (opterr)
|
||||
fprintf (stderr,
|
||||
_("%s: option `%s' requires an argument\n"),
|
||||
argv[0], argv[optind - 1]);
|
||||
_("%s: option `%s' requires an argument\n"),
|
||||
argv[0], argv[optind - 1]);
|
||||
nextchar += strlen (nextchar);
|
||||
optopt = pfound->val;
|
||||
return optstring[0] == ':' ? ':' : '?';
|
||||
@@ -694,6 +739,130 @@ _getopt_internal (argc, argv, optstring, longopts, longind, long_only)
|
||||
optopt = c;
|
||||
return '?';
|
||||
}
|
||||
/* Convenience. Treat POSIX -W foo same as long option --foo */
|
||||
if (temp[0] == 'W' && temp[1] == ';')
|
||||
{
|
||||
char *nameend;
|
||||
const struct option *p;
|
||||
const struct option *pfound = NULL;
|
||||
int exact = 0;
|
||||
int ambig = 0;
|
||||
int indfound = 0;
|
||||
int option_index;
|
||||
|
||||
/* This is an option that requires an argument. */
|
||||
if (*nextchar != '\0')
|
||||
{
|
||||
optarg = nextchar;
|
||||
/* If we end this ARGV-element by taking the rest as an arg,
|
||||
we must advance to the next element now. */
|
||||
optind++;
|
||||
}
|
||||
else if (optind == argc)
|
||||
{
|
||||
if (opterr)
|
||||
{
|
||||
/* 1003.2 specifies the format of this message. */
|
||||
fprintf (stderr, _("%s: option requires an argument -- %c\n"),
|
||||
argv[0], c);
|
||||
}
|
||||
optopt = c;
|
||||
if (optstring[0] == ':')
|
||||
c = ':';
|
||||
else
|
||||
c = '?';
|
||||
return c;
|
||||
}
|
||||
else
|
||||
/* We already incremented `optind' once;
|
||||
increment it again when taking next ARGV-elt as argument. */
|
||||
optarg = argv[optind++];
|
||||
|
||||
/* optarg is now the argument, see if it's in the
|
||||
table of longopts. */
|
||||
|
||||
for (nextchar = nameend = optarg; *nameend && *nameend != '='; nameend++)
|
||||
/* Do nothing. */ ;
|
||||
|
||||
/* Test all long options for either exact match
|
||||
or abbreviated matches. */
|
||||
for (p = longopts, option_index = 0; p->name; p++, option_index++)
|
||||
if (!strncmp (p->name, nextchar, nameend - nextchar))
|
||||
{
|
||||
if ((unsigned int) (nameend - nextchar) == strlen (p->name))
|
||||
{
|
||||
/* Exact match found. */
|
||||
pfound = p;
|
||||
indfound = option_index;
|
||||
exact = 1;
|
||||
break;
|
||||
}
|
||||
else if (pfound == NULL)
|
||||
{
|
||||
/* First nonexact match found. */
|
||||
pfound = p;
|
||||
indfound = option_index;
|
||||
}
|
||||
else
|
||||
/* Second or later nonexact match found. */
|
||||
ambig = 1;
|
||||
}
|
||||
if (ambig && !exact)
|
||||
{
|
||||
if (opterr)
|
||||
fprintf (stderr, _("%s: option `-W %s' is ambiguous\n"),
|
||||
argv[0], argv[optind]);
|
||||
nextchar += strlen (nextchar);
|
||||
optind++;
|
||||
return '?';
|
||||
}
|
||||
if (pfound != NULL)
|
||||
{
|
||||
option_index = indfound;
|
||||
if (*nameend)
|
||||
{
|
||||
/* Don't test has_arg with >, because some C compilers don't
|
||||
allow it to be used on enums. */
|
||||
if (pfound->has_arg)
|
||||
optarg = nameend + 1;
|
||||
else
|
||||
{
|
||||
if (opterr)
|
||||
fprintf (stderr, _("\
|
||||
%s: option `-W %s' doesn't allow an argument\n"),
|
||||
argv[0], pfound->name);
|
||||
|
||||
nextchar += strlen (nextchar);
|
||||
return '?';
|
||||
}
|
||||
}
|
||||
else if (pfound->has_arg == 1)
|
||||
{
|
||||
if (optind < argc)
|
||||
optarg = argv[optind++];
|
||||
else
|
||||
{
|
||||
if (opterr)
|
||||
fprintf (stderr,
|
||||
_("%s: option `%s' requires an argument\n"),
|
||||
argv[0], argv[optind - 1]);
|
||||
nextchar += strlen (nextchar);
|
||||
return optstring[0] == ':' ? ':' : '?';
|
||||
}
|
||||
}
|
||||
nextchar += strlen (nextchar);
|
||||
if (longind != NULL)
|
||||
*longind = option_index;
|
||||
if (pfound->flag)
|
||||
{
|
||||
*(pfound->flag) = pfound->val;
|
||||
return 0;
|
||||
}
|
||||
return pfound->val;
|
||||
}
|
||||
nextchar = NULL;
|
||||
return 'W'; /* Let the application handle it. */
|
||||
}
|
||||
if (temp[1] == ':')
|
||||
{
|
||||
if (temp[2] == ':')
|
||||
@@ -724,8 +893,8 @@ _getopt_internal (argc, argv, optstring, longopts, longind, long_only)
|
||||
{
|
||||
/* 1003.2 specifies the format of this message. */
|
||||
fprintf (stderr,
|
||||
_("%s: option requires an argument -- %c\n"),
|
||||
argv[0], c);
|
||||
_("%s: option requires an argument -- %c\n"),
|
||||
argv[0], c);
|
||||
}
|
||||
optopt = c;
|
||||
if (optstring[0] == ':')
|
||||
@@ -756,7 +925,7 @@ getopt (argc, argv, optstring)
|
||||
0);
|
||||
}
|
||||
|
||||
#endif /* _LIBC or not __GNU_LIBRARY__. */
|
||||
#endif /* Not ELIDE_CODE. */
|
||||
|
||||
#ifdef TEST
|
||||
|
||||
@@ -776,7 +945,7 @@ main (argc, argv)
|
||||
int this_option_optind = optind ? optind : 1;
|
||||
|
||||
c = getopt (argc, argv, "abc:d:0123456789");
|
||||
if (c == EOF)
|
||||
if (c == -1)
|
||||
break;
|
||||
|
||||
switch (c)
|
||||
|
||||
28
lib/getopt.h
28
lib/getopt.h
@@ -1,19 +1,23 @@
|
||||
/* Declarations for getopt.
|
||||
Copyright (C) 1989, 90, 91, 92, 93, 94 Free Software Foundation, Inc.
|
||||
Copyright (C) 1989,90,91,92,93,94,96,97 Free Software Foundation, Inc.
|
||||
|
||||
This program is free software; you can redistribute it and/or modify it
|
||||
under the terms of the GNU General Public License as published by the
|
||||
Free Software Foundation; either version 2, or (at your option) any
|
||||
later version.
|
||||
This file is part of the GNU C Library. Its master source is NOT part of
|
||||
the C library, however. The master source lives in /gd/gnu/lib.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Library General Public License as
|
||||
published by the Free Software Foundation; either version 2 of the
|
||||
License, or (at your option) any later version.
|
||||
|
||||
The GNU C Library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Library General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software Foundation,
|
||||
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
|
||||
You should have received a copy of the GNU Library General Public
|
||||
License along with the GNU C Library; see the file COPYING.LIB. If not,
|
||||
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
|
||||
Boston, MA 02111-1307, USA. */
|
||||
|
||||
#ifndef _GETOPT_H
|
||||
#define _GETOPT_H 1
|
||||
@@ -36,7 +40,7 @@ extern char *optarg;
|
||||
|
||||
On entry to `getopt', zero means this is the first call; initialize.
|
||||
|
||||
When `getopt' returns EOF, this is the index of the first of the
|
||||
When `getopt' returns -1, this is the index of the first of the
|
||||
non-option elements that the caller should itself scan.
|
||||
|
||||
Otherwise, `optind' communicates from one call to the next
|
||||
|
||||
@@ -1,20 +1,23 @@
|
||||
/* getopt_long and getopt_long_only entry points for GNU getopt.
|
||||
Copyright (C) 1987, 88, 89, 90, 91, 92, 1993, 1994
|
||||
Free Software Foundation, Inc.
|
||||
Copyright (C) 1987,88,89,90,91,92,93,94,96,97 Free Software Foundation, Inc.
|
||||
|
||||
This program is free software; you can redistribute it and/or modify it
|
||||
under the terms of the GNU General Public License as published by the
|
||||
Free Software Foundation; either version 2, or (at your option) any
|
||||
later version.
|
||||
This file is part of the GNU C Library. Its master source is NOT part of
|
||||
the C library, however. The master source lives in /gd/gnu/lib.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Library General Public License as
|
||||
published by the Free Software Foundation; either version 2 of the
|
||||
License, or (at your option) any later version.
|
||||
|
||||
The GNU C Library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Library General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
|
||||
You should have received a copy of the GNU Library General Public
|
||||
License along with the GNU C Library; see the file COPYING.LIB. If not,
|
||||
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
|
||||
Boston, MA 02111-1307, USA. */
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include <config.h>
|
||||
@@ -40,15 +43,21 @@
|
||||
program understand `configure --with-gnu-libc' and omit the object files,
|
||||
it is simpler to just do this in the source for each such file. */
|
||||
|
||||
#if defined (_LIBC) || !defined (__GNU_LIBRARY__)
|
||||
#define GETOPT_INTERFACE_VERSION 2
|
||||
#if !defined (_LIBC) && defined (__GLIBC__) && __GLIBC__ >= 2
|
||||
#include <gnu-versions.h>
|
||||
#if _GNU_GETOPT_INTERFACE_VERSION == GETOPT_INTERFACE_VERSION
|
||||
#define ELIDE_CODE
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifndef ELIDE_CODE
|
||||
|
||||
|
||||
/* This needs to come after some library #include
|
||||
to get __GNU_LIBRARY__ defined. */
|
||||
#ifdef __GNU_LIBRARY__
|
||||
#include <stdlib.h>
|
||||
#else
|
||||
char *getenv ();
|
||||
#endif
|
||||
|
||||
#ifndef NULL
|
||||
@@ -83,7 +92,7 @@ getopt_long_only (argc, argv, options, long_options, opt_index)
|
||||
}
|
||||
|
||||
|
||||
#endif /* _LIBC or not __GNU_LIBRARY__. */
|
||||
#endif /* Not ELIDE_CODE. */
|
||||
|
||||
#ifdef TEST
|
||||
|
||||
@@ -114,7 +123,7 @@ main (argc, argv)
|
||||
|
||||
c = getopt_long (argc, argv, "abc:d:0123456789",
|
||||
long_options, &option_index);
|
||||
if (c == EOF)
|
||||
if (c == -1)
|
||||
break;
|
||||
|
||||
switch (c)
|
||||
|
||||
@@ -177,7 +177,7 @@ readname (name, size, stream)
|
||||
/* Skip blank space. */
|
||||
while ((c = getc (stream)) != EOF && isspace (c))
|
||||
/* Do nothing. */ ;
|
||||
|
||||
|
||||
while (c != EOF && !isspace (c))
|
||||
{
|
||||
(*name)[name_index++] = c;
|
||||
|
||||
@@ -17,13 +17,13 @@
|
||||
|
||||
/* Written by David MacKenzie <djm@gnu.ai.mit.edu> */
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#if HAVE_CONFIG_H
|
||||
# include <config.h>
|
||||
#endif
|
||||
|
||||
#include "backupfile.h"
|
||||
|
||||
#ifdef STDC_HEADERS
|
||||
#if STDC_HEADERS
|
||||
# include <stdlib.h>
|
||||
#endif
|
||||
|
||||
|
||||
@@ -120,7 +120,7 @@ group_member (gid)
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
free_group_info (gi);
|
||||
|
||||
return found;
|
||||
@@ -1,7 +1,7 @@
|
||||
#ifndef _group_member_h_
|
||||
# define _group_member_h_ 1
|
||||
#ifndef GROUP_MEMBER_H_
|
||||
# define GROUP_MEMBER_H_ 1
|
||||
|
||||
int
|
||||
group_member ();
|
||||
|
||||
#endif /* _group_member_h_ */
|
||||
#endif /* GROUP_MEMBER_H_ */
|
||||
|
||||
@@ -12,8 +12,8 @@
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
|
||||
along with this program; if not, write to the Free Software Foundation,
|
||||
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
|
||||
|
||||
/* A `struct linebuffer' holds a line of text. */
|
||||
|
||||
@@ -26,9 +26,9 @@ struct linebuffer
|
||||
|
||||
#undef PARAMS
|
||||
#if defined (__STDC__) && __STDC__
|
||||
# define PARAMS(x) x
|
||||
# define PARAMS(Args) Args
|
||||
#else
|
||||
# define PARAMS(x) ()
|
||||
# define PARAMS(Args) ()
|
||||
#endif
|
||||
|
||||
/* Initialize linebuffer LINEBUFFER for use. */
|
||||
|
||||
@@ -46,10 +46,8 @@ parse_long_options (argc, argv, command_name, package, version, usage)
|
||||
{
|
||||
int c;
|
||||
int saved_opterr;
|
||||
int saved_optind;
|
||||
|
||||
saved_opterr = opterr;
|
||||
saved_optind = optind;
|
||||
|
||||
/* Don't print an error message for unrecognized options. */
|
||||
opterr = 0;
|
||||
@@ -75,6 +73,7 @@ parse_long_options (argc, argv, command_name, package, version, usage)
|
||||
/* Restore previous value. */
|
||||
opterr = saved_opterr;
|
||||
|
||||
/* Restore optind in case it has advanced past a leading `--'. */
|
||||
optind = saved_optind;
|
||||
/* Reset this to zero so that getopt internals get initialized from
|
||||
the probably-new parameters when/if getopt is called later. */
|
||||
optind = 0;
|
||||
}
|
||||
|
||||
@@ -44,7 +44,7 @@ char *alloca ();
|
||||
|
||||
#if STAT_MACROS_BROKEN
|
||||
# undef S_ISDIR
|
||||
#endif /* STAT_MACROS_BROKEN. */
|
||||
#endif
|
||||
|
||||
#if !defined(S_ISDIR) && defined(S_IFDIR)
|
||||
# define S_ISDIR(m) (((m) & S_IFMT) == S_IFDIR)
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
#if __STDC__
|
||||
# undef __P
|
||||
# define __P(args) args
|
||||
#if __STDC__
|
||||
# define __P(Args) Args
|
||||
#else
|
||||
# define __P(args) ()
|
||||
# define __P(Args) ()
|
||||
#endif
|
||||
|
||||
int
|
||||
|
||||
44
lib/md5.c
44
lib/md5.c
@@ -1,24 +1,24 @@
|
||||
/* md5.c - Functions to compute MD5 message digest of files or memory blocks
|
||||
Copyright (C) 1996 Free Software Foundation, Inc.
|
||||
This file is part of the GNU C Library.
|
||||
Contributed by Ulrich Drepper <drepper@cygnus.com>, 1996.
|
||||
according to the definition of MD5 in RFC 1321 from April 1992.
|
||||
Copyright (C) 1995, 1996 Free Software Foundation, Inc.
|
||||
NOTE: The canonical source of this file is maintained with the GNU C
|
||||
Library. Bugs can be reported to bug-glibc@prep.ai.mit.edu.
|
||||
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Library General Public License as
|
||||
published by the Free Software Foundation; either version 2 of the
|
||||
License, or (at your option) any later version.
|
||||
This program is free software; you can redistribute it and/or modify it
|
||||
under the terms of the GNU General Public License as published by the
|
||||
Free Software Foundation; either version 2, or (at your option) any
|
||||
later version.
|
||||
|
||||
The GNU C Library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Library General Public License for more details.
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Library General Public
|
||||
License along with the GNU C Library; see the file COPYING.LIB. If
|
||||
not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
|
||||
Boston, MA 02111-1307, USA. */
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software Foundation,
|
||||
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
|
||||
|
||||
/* Written by Ulrich Drepper <drepper@gnu.ai.mit.edu>. */
|
||||
/* Written by Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1995. */
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
# include <config.h>
|
||||
@@ -72,8 +72,11 @@ md5_init_ctx (ctx)
|
||||
ctx->buflen = 0;
|
||||
}
|
||||
|
||||
/* Put result from CTX in first 16 bytes following RESBUF. The result must
|
||||
be in little endian byte order. */
|
||||
/* Put result from CTX in first 16 bytes following RESBUF. The result
|
||||
must be in little endian byte order.
|
||||
|
||||
IMPORTANT: On some systems it is required that RESBUF is correctly
|
||||
aligned for a 32 bits value. */
|
||||
void *
|
||||
md5_read_ctx (ctx, resbuf)
|
||||
const struct md5_ctx *ctx;
|
||||
@@ -88,7 +91,10 @@ md5_read_ctx (ctx, resbuf)
|
||||
}
|
||||
|
||||
/* Process the remaining bytes in the internal buffer and the usual
|
||||
prolog according to the standard and write the result to RESBUF. */
|
||||
prolog according to the standard and write the result to RESBUF.
|
||||
|
||||
IMPORTANT: On some systems it is required that RESBUF is correctly
|
||||
aligned for a 32 bits value. */
|
||||
void *
|
||||
md5_finish_ctx (ctx, resbuf)
|
||||
struct md5_ctx *ctx;
|
||||
|
||||
56
lib/md5.h
56
lib/md5.h
@@ -1,22 +1,22 @@
|
||||
/* md5.h - Declaration of functions and data types used for MD5 sum
|
||||
computing library functions.
|
||||
Copyright (C) 1995, 1996 Free Software Foundation, Inc.
|
||||
This file is part of the GNU C Library.
|
||||
Copyright (C) 1995, 1996 Free Software Foundation, Inc.
|
||||
NOTE: The canonical source of this file is maintained with the GNU C
|
||||
Library. Bugs can be reported to bug-glibc@prep.ai.mit.edu.
|
||||
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Library General Public License as
|
||||
published by the Free Software Foundation; either version 2 of the
|
||||
License, or (at your option) any later version.
|
||||
This program is free software; you can redistribute it and/or modify it
|
||||
under the terms of the GNU General Public License as published by the
|
||||
Free Software Foundation; either version 2, or (at your option) any
|
||||
later version.
|
||||
|
||||
The GNU C Library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Library General Public License for more details.
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Library General Public
|
||||
License along with the GNU C Library; see the file COPYING.LIB. If
|
||||
not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
|
||||
Boston, MA 02111-1307, USA. */
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software Foundation,
|
||||
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
|
||||
|
||||
#ifndef _MD5_H
|
||||
#define _MD5_H 1
|
||||
@@ -97,44 +97,50 @@ struct md5_ctx
|
||||
|
||||
/* Initialize structure containing state of computation.
|
||||
(RFC 1321, 3.3: Step 3) */
|
||||
void md5_init_ctx __P ((struct md5_ctx *ctx));
|
||||
extern void md5_init_ctx __P ((struct md5_ctx *ctx));
|
||||
|
||||
/* Starting with the result of former calls of this function (or the
|
||||
initialization function update the context for the next LEN bytes
|
||||
starting at BUFFER.
|
||||
It is necessary that LEN is a multiple of 64!!! */
|
||||
void md5_process_block __P ((const void *buffer, size_t len,
|
||||
struct md5_ctx *ctx));
|
||||
extern void md5_process_block __P ((const void *buffer, size_t len,
|
||||
struct md5_ctx *ctx));
|
||||
|
||||
/* Starting with the result of former calls of this function (or the
|
||||
initialization function update the context for the next LEN bytes
|
||||
starting at BUFFER.
|
||||
It is NOT required that LEN is a multiple of 64. */
|
||||
void md5_process_bytes __P ((const void *buffer, size_t len,
|
||||
struct md5_ctx *ctx));
|
||||
extern void md5_process_bytes __P ((const void *buffer, size_t len,
|
||||
struct md5_ctx *ctx));
|
||||
|
||||
/* Process the remaining bytes in the buffer and put result from CTX
|
||||
in first 16 bytes following RESBUF. The result is always in little
|
||||
endian byte order, so that a byte-wise output yields to the wanted
|
||||
ASCII representation of the message digest. */
|
||||
void *md5_finish_ctx __P ((struct md5_ctx *ctx, void *resbuf));
|
||||
ASCII representation of the message digest.
|
||||
|
||||
IMPORTANT: On some systems it is required that RESBUF is correctly
|
||||
aligned for a 32 bits value. */
|
||||
extern void *md5_finish_ctx __P ((struct md5_ctx *ctx, void *resbuf));
|
||||
|
||||
|
||||
/* Put result from CTX in first 16 bytes following RESBUF. The result is
|
||||
always in little endian byte order, so that a byte-wise output yields
|
||||
to the wanted ASCII representation of the message digest. */
|
||||
void *md5_read_ctx __P ((const struct md5_ctx *ctx, void *resbuf));
|
||||
to the wanted ASCII representation of the message digest.
|
||||
|
||||
IMPORTANT: On some systems it is required that RESBUF is correctly
|
||||
aligned for a 32 bits value. */
|
||||
extern void *md5_read_ctx __P ((const struct md5_ctx *ctx, void *resbuf));
|
||||
|
||||
|
||||
/* Compute MD5 message digest for bytes read from STREAM. The
|
||||
resulting message digest number will be written into the 16 bytes
|
||||
beginning at RESBLOCK. */
|
||||
int md5_stream __P ((FILE *stream, void *resblock));
|
||||
extern int md5_stream __P ((FILE *stream, void *resblock));
|
||||
|
||||
/* Compute MD5 message digest for LEN bytes beginning at BUFFER. The
|
||||
result is always in little endian byte order, so that a byte-wise
|
||||
output yields to the wanted ASCII representation of the message
|
||||
digest. */
|
||||
void *md5_buffer __P ((const char *buffer, size_t len, void *resblock));
|
||||
extern void *md5_buffer __P ((const char *buffer, size_t len, void *resblock));
|
||||
|
||||
#endif
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
#undef PARAMS
|
||||
#if defined (__STDC__) && __STDC__
|
||||
# define PARAMS(args) args
|
||||
# define PARAMS(Args) Args
|
||||
#else
|
||||
# define PARAMS(args) ()
|
||||
# define PARAMS(Args) ()
|
||||
#endif
|
||||
|
||||
int
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* Copyright (C) 1991, 1993 Free Software Foundation, Inc.
|
||||
/* Copyright (C) 1991, 1993, 1995 Free Software Foundation, Inc.
|
||||
Contributed by Torbjorn Granlund (tege@sics.se).
|
||||
|
||||
NOTE: The canonical source of this file is maintained with the GNU C Library.
|
||||
@@ -364,3 +364,10 @@ memcmp (s1, s2, len)
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
#ifdef weak_alias
|
||||
#undef bcmp
|
||||
weak_alias (memcmp, bcmp)
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
if the source overlaps with the destination.
|
||||
Return DESTADDR. */
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#if HAVE_CONFIG_H
|
||||
# include <config.h>
|
||||
#endif
|
||||
|
||||
|
||||
12
lib/mkdir.c
12
lib/mkdir.c
@@ -1,4 +1,4 @@
|
||||
/* mkdir.c -- BSD compatible make directory function for System V
|
||||
/* BSD compatible make directory function for System V
|
||||
Copyright (C) 1988, 1990 Free Software Foundation, Inc.
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
@@ -15,8 +15,8 @@
|
||||
along with this program; if not, write to the Free Software Foundation,
|
||||
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include <config.h>
|
||||
#if HAVE_CONFIG_H
|
||||
# include <config.h>
|
||||
#endif
|
||||
|
||||
#include <sys/types.h>
|
||||
@@ -26,12 +26,12 @@
|
||||
extern int errno;
|
||||
#endif
|
||||
|
||||
#ifdef STAT_MACROS_BROKEN
|
||||
#undef S_ISDIR
|
||||
#if STAT_MACROS_BROKEN
|
||||
# undef S_ISDIR
|
||||
#endif
|
||||
|
||||
#if !defined(S_ISDIR) && defined(S_IFDIR)
|
||||
#define S_ISDIR(m) (((m) & S_IFMT) == S_IFDIR)
|
||||
# define S_ISDIR(m) (((m) & S_IFMT) == S_IFDIR)
|
||||
#endif
|
||||
|
||||
/* mkdir adapted from GNU tar. */
|
||||
|
||||
26
lib/mktime.c
26
lib/mktime.c
@@ -1,22 +1,22 @@
|
||||
/* Copyright (C) 1993, 1994, 1995 Free Software Foundation, Inc.
|
||||
Contributed by Paul Eggert (eggert@twinsun.com).
|
||||
|
||||
This file is part of the GNU C Library.
|
||||
NOTE: The canonical source of this file is maintained with the GNU C
|
||||
Library. Bugs can be reported to bug-glibc@prep.ai.mit.edu.
|
||||
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Library General Public License as
|
||||
published by the Free Software Foundation; either version 2 of the
|
||||
License, or (at your option) any later version.
|
||||
This program is free software; you can redistribute it and/or modify it
|
||||
under the terms of the GNU General Public License as published by the
|
||||
Free Software Foundation; either version 2, or (at your option) any
|
||||
later version.
|
||||
|
||||
The GNU C Library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Library General Public License for more details.
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Library General Public
|
||||
License along with the GNU C Library; see the file COPYING.LIB. If
|
||||
not, write to the Free Software Foundation, Inc., 59 Temple Place -
|
||||
Suite 330, Boston, MA 02111-1307, USA. */
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software Foundation,
|
||||
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
|
||||
|
||||
/* Define this to have a standalone program to test this implementation of
|
||||
mktime. */
|
||||
|
||||
@@ -44,7 +44,7 @@ char *malloc ();
|
||||
|
||||
#if STAT_MACROS_BROKEN
|
||||
# undef S_ISDIR
|
||||
#endif /* STAT_MACROS_BROKEN. */
|
||||
#endif
|
||||
|
||||
#if !defined(S_ISDIR) && defined(S_IFDIR)
|
||||
# define S_ISDIR(m) (((m) & S_IFMT) == S_IFDIR)
|
||||
|
||||
@@ -46,11 +46,11 @@ struct mode_change
|
||||
|
||||
#ifndef __P
|
||||
# if defined (__GNUC__) || (defined (__STDC__) && __STDC__)
|
||||
# define __P(args) args
|
||||
# define __P(Args) Args
|
||||
# else
|
||||
# define __P(args) ()
|
||||
# endif /* GCC. */
|
||||
#endif /* Not __P. */
|
||||
# define __P(Args) ()
|
||||
# endif
|
||||
#endif
|
||||
|
||||
struct mode_change *mode_compile __P ((const char *, unsigned));
|
||||
unsigned short mode_adjust __P ((unsigned, const struct mode_change *));
|
||||
|
||||
@@ -264,7 +264,7 @@ read_filesystem_list (need_fs_type, all_fs)
|
||||
struct tabmntent *mntlist, *p;
|
||||
struct mntent *mnt;
|
||||
struct mount_entry *me;
|
||||
|
||||
|
||||
/* the third and fourth arguments could be used to filter mounts,
|
||||
but Crays doesn't seem to have any mounts that we want to
|
||||
remove. Specifically, automount create normal NFS mounts.
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
/* obstack.c - subroutines used implicitly by object stack macros
|
||||
Copyright (C) 1988, 89, 90, 91, 92, 93, 94 Free Software Foundation, Inc.
|
||||
Copyright (C) 1988,89,90,91,92,93,94,96 Free Software Foundation, Inc.
|
||||
|
||||
This program is free software; you can redistribute it and/or modify it
|
||||
under the terms of the GNU General Public License as published by the
|
||||
Free Software Foundation; either version 2, or (at your option) any
|
||||
later version.
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation; either version 2, or (at your option)
|
||||
any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
@@ -12,23 +12,35 @@ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software Foundation,
|
||||
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
|
||||
|
||||
#include "obstack.h"
|
||||
|
||||
/* This is just to get __GNU_LIBRARY__ defined. */
|
||||
#include <stdio.h>
|
||||
/* NOTE BEFORE MODIFYING THIS FILE: This version number must be
|
||||
incremented whenever callers compiled using an old obstack.h can no
|
||||
longer properly call the functions in this obstack.c. */
|
||||
#define OBSTACK_INTERFACE_VERSION 1
|
||||
|
||||
/* Comment out all this code if we are using the GNU C Library, and are not
|
||||
actually compiling the library itself. This code is part of the GNU C
|
||||
Library, but also included in many other GNU distributions. Compiling
|
||||
actually compiling the library itself, and the installed library
|
||||
supports the same library interface we do. This code is part of the GNU
|
||||
C Library, but also included in many other GNU distributions. Compiling
|
||||
and linking in this code is a waste when using the GNU C library
|
||||
(especially if it is a shared library). Rather than having every GNU
|
||||
program understand `configure --with-gnu-libc' and omit the object files,
|
||||
it is simpler to just do this in the source for each such file. */
|
||||
program understand `configure --with-gnu-libc' and omit the object
|
||||
files, it is simpler to just do this in the source for each such file. */
|
||||
|
||||
#if defined (_LIBC) || !defined (__GNU_LIBRARY__)
|
||||
#include <stdio.h> /* Random thing to get __GNU_LIBRARY__. */
|
||||
#if !defined (_LIBC) && defined (__GNU_LIBRARY__) && __GNU_LIBRARY__ > 1
|
||||
#include <gnu-versions.h>
|
||||
#if _GNU_OBSTACK_INTERFACE_VERSION == OBSTACK_INTERFACE_VERSION
|
||||
#define ELIDE_CODE
|
||||
#endif
|
||||
#endif
|
||||
|
||||
|
||||
#ifndef ELIDE_CODE
|
||||
|
||||
|
||||
#if defined (__STDC__) && __STDC__
|
||||
@@ -69,14 +81,14 @@ struct obstack *_obstack;
|
||||
#define CALL_CHUNKFUN(h, size) \
|
||||
(((h) -> use_extra_arg) \
|
||||
? (*(h)->chunkfun) ((h)->extra_arg, (size)) \
|
||||
: (*(h)->chunkfun) ((size)))
|
||||
: (*(struct _obstack_chunk *(*) ()) (h)->chunkfun) ((size)))
|
||||
|
||||
#define CALL_FREEFUN(h, old_chunk) \
|
||||
do { \
|
||||
if ((h) -> use_extra_arg) \
|
||||
(*(h)->freefun) ((h)->extra_arg, (old_chunk)); \
|
||||
else \
|
||||
(*(h)->freefun) ((old_chunk)); \
|
||||
(*(void (*) ()) (h)->freefun) ((old_chunk)); \
|
||||
} while (0)
|
||||
|
||||
|
||||
@@ -482,4 +494,4 @@ POINTER (obstack_copy0) (obstack, pointer, length)
|
||||
|
||||
#endif /* 0 */
|
||||
|
||||
#endif /* _LIBC or not __GNU_LIBRARY__. */
|
||||
#endif /* !ELIDE_CODE */
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
/* obstack.h - object stack macros
|
||||
Copyright (C) 1988, 89, 90, 91, 92, 93, 94 Free Software Foundation, Inc.
|
||||
Copyright (C) 1988,89,90,91,92,93,94,96 Free Software Foundation, Inc.
|
||||
|
||||
This program is free software; you can redistribute it and/or modify it
|
||||
under the terms of the GNU General Public License as published by the
|
||||
Free Software Foundation; either version 2, or (at your option) any
|
||||
later version.
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation; either version 2, or (at your option)
|
||||
any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
@@ -12,8 +12,8 @@ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software Foundation,
|
||||
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
|
||||
|
||||
/* Summary:
|
||||
|
||||
@@ -102,11 +102,16 @@ Summary:
|
||||
|
||||
#ifndef __OBSTACK_H__
|
||||
#define __OBSTACK_H__
|
||||
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
# include <config.h>
|
||||
#endif
|
||||
|
||||
#if !defined (HAVE_BCOPY) && defined (HAVE_MEMCPY) && !defined (bcopy)
|
||||
# define bcopy(from, to, len) memcpy ((to), (from), (len))
|
||||
#endif
|
||||
|
||||
|
||||
/* We use subtraction of (char *)0 instead of casting to int
|
||||
because on word-addressable machines a simple cast to int
|
||||
may ignore the byte-within-word field of the pointer. */
|
||||
@@ -136,21 +141,18 @@ Summary:
|
||||
#include <stddef.h>
|
||||
#endif
|
||||
|
||||
#include <sys/types.h>
|
||||
|
||||
#ifndef HAVE_PTRDIFF_T
|
||||
# define ptrdiff_t off_t
|
||||
#endif
|
||||
|
||||
#if defined (__STDC__) && __STDC__
|
||||
#define PTR_INT_TYPE ptrdiff_t
|
||||
#else
|
||||
#define PTR_INT_TYPE long
|
||||
#endif
|
||||
|
||||
#if HAVE_STRING_H || STDC_HEADERS
|
||||
# include <string.h>
|
||||
# ifndef bcopy
|
||||
# define bcopy(s, d, n) memcpy ((d), (s), (n))
|
||||
# endif
|
||||
#else /* HAVE_STRING_H || STDC_HEADERS */
|
||||
# include <strings.h>
|
||||
#endif /* not (HAVE_STRING_H || STDC_HEADERS) */
|
||||
|
||||
struct _obstack_chunk /* Lives at front of each chunk. */
|
||||
{
|
||||
char *limit; /* 1 past end of this chunk */
|
||||
@@ -167,9 +169,18 @@ struct obstack /* control current object in current chunk */
|
||||
char *chunk_limit; /* address of char after current chunk */
|
||||
PTR_INT_TYPE temp; /* Temporary for some macros. */
|
||||
int alignment_mask; /* Mask of alignment for each object. */
|
||||
#if defined (__STDC__) && __STDC__
|
||||
/* These prototypes vary based on `use_extra_arg', and we use
|
||||
casts to the prototypeless function type in all assignments,
|
||||
but having prototypes here quiets -Wstrict-prototypes. */
|
||||
struct _obstack_chunk *(*chunkfun) (void *, long);
|
||||
void (*freefun) (void *, struct _obstack_chunk *);
|
||||
void *extra_arg; /* first arg for chunk alloc/dealloc funcs */
|
||||
#else
|
||||
struct _obstack_chunk *(*chunkfun) (); /* User's fcn to allocate a chunk. */
|
||||
void (*freefun) (); /* User's function to free a chunk. */
|
||||
char *extra_arg; /* first arg for chunk alloc/dealloc funcs */
|
||||
#endif
|
||||
unsigned use_extra_arg:1; /* chunk alloc/dealloc funcs take extra arg */
|
||||
unsigned maybe_empty_object:1;/* There is a possibility that the current
|
||||
chunk contains a zero-length object. This
|
||||
@@ -184,9 +195,10 @@ struct obstack /* control current object in current chunk */
|
||||
extern void _obstack_newchunk (struct obstack *, int);
|
||||
extern void _obstack_free (struct obstack *, void *);
|
||||
extern int _obstack_begin (struct obstack *, int, int,
|
||||
void *(*) (), void (*) ());
|
||||
void *(*) (long), void (*) (void *));
|
||||
extern int _obstack_begin_1 (struct obstack *, int, int,
|
||||
void *(*) (), void (*) (), void *);
|
||||
void *(*) (void *, long),
|
||||
void (*) (void *, void *), void *);
|
||||
#else
|
||||
extern void _obstack_newchunk ();
|
||||
extern void _obstack_free ();
|
||||
@@ -255,6 +267,34 @@ int obstack_chunk_size (struct obstack *obstack);
|
||||
|
||||
#define obstack_alignment_mask(h) ((h)->alignment_mask)
|
||||
|
||||
/* To prevent prototype warnings provide complete argument list in
|
||||
standard C version. */
|
||||
#if defined (__STDC__) && __STDC__
|
||||
|
||||
#define obstack_init(h) \
|
||||
_obstack_begin ((h), 0, 0, \
|
||||
(void *(*) (long)) obstack_chunk_alloc, (void (*) (void *)) obstack_chunk_free)
|
||||
|
||||
#define obstack_begin(h, size) \
|
||||
_obstack_begin ((h), (size), 0, \
|
||||
(void *(*) (long)) obstack_chunk_alloc, (void (*) (void *)) obstack_chunk_free)
|
||||
|
||||
#define obstack_specify_allocation(h, size, alignment, chunkfun, freefun) \
|
||||
_obstack_begin ((h), (size), (alignment), \
|
||||
(void *(*) (long)) (chunkfun), (void (*) (void *)) (freefun))
|
||||
|
||||
#define obstack_specify_allocation_with_arg(h, size, alignment, chunkfun, freefun, arg) \
|
||||
_obstack_begin_1 ((h), (size), (alignment), \
|
||||
(void *(*) (long)) (chunkfun), (void (*) (void *)) (freefun), (arg))
|
||||
|
||||
#define obstack_chunkfun(h, newchunkfun) \
|
||||
((h) -> chunkfun = (struct _obstack_chunk *(*)(long)) (newchunkfun))
|
||||
|
||||
#define obstack_freefun(h, newfreefun) \
|
||||
((h) -> freefun = (void (*)(void *)) (newfreefun))
|
||||
|
||||
#else
|
||||
|
||||
#define obstack_init(h) \
|
||||
_obstack_begin ((h), 0, 0, \
|
||||
(void *(*) ()) obstack_chunk_alloc, (void (*) ()) obstack_chunk_free)
|
||||
@@ -277,11 +317,13 @@ int obstack_chunk_size (struct obstack *obstack);
|
||||
#define obstack_freefun(h, newfreefun) \
|
||||
((h) -> freefun = (void (*)()) (newfreefun))
|
||||
|
||||
#endif
|
||||
|
||||
#define obstack_1grow_fast(h,achar) (*((h)->next_free)++ = achar)
|
||||
|
||||
#define obstack_blank_fast(h,n) ((h)->next_free += (n))
|
||||
|
||||
#if defined (__GNUC__) && defined (__STDC__)
|
||||
#if defined (__GNUC__) && defined (__STDC__) && __STDC__
|
||||
/* NextStep 2.0 cc is really gcc 1.93 but it defines __GNUC__ = 2 and
|
||||
does not implement __extension__. But that compiler doesn't define
|
||||
__GNUC_MINOR__. */
|
||||
|
||||
@@ -67,9 +67,56 @@ static struct tm t;
|
||||
|
||||
time_t mktime ();
|
||||
|
||||
#define yyparse posixtime_yyparse
|
||||
/* Remap normal yacc parser interface names (yyparse, yylex, yyerror, etc),
|
||||
as well as gratuitiously global symbol names, so we can have multiple
|
||||
yacc generated parsers in the same program. Note that these are only
|
||||
the variables produced by yacc. If other parser generators (bison,
|
||||
byacc, etc) produce additional global names that conflict at link time,
|
||||
then those parser generators need to be fixed instead of adding those
|
||||
names to this list. */
|
||||
|
||||
#define yymaxdepth pt_maxdepth
|
||||
#define yyparse pt_parse
|
||||
#define yylex pt_lex
|
||||
#define yyerror pt_error
|
||||
#define yylval pt_lval
|
||||
#define yychar pt_char
|
||||
#define yydebug pt_debug
|
||||
#define yypact pt_pact
|
||||
#define yyr1 pt_r1
|
||||
#define yyr2 pt_r2
|
||||
#define yydef pt_def
|
||||
#define yychk pt_chk
|
||||
#define yypgo pt_pgo
|
||||
#define yyact pt_act
|
||||
#define yyexca pt_exca
|
||||
#define yyerrflag pt_errflag
|
||||
#define yynerrs pt_nerrs
|
||||
#define yyps pt_ps
|
||||
#define yypv pt_pv
|
||||
#define yys pt_s
|
||||
#define yy_yys pt_yys
|
||||
#define yystate pt_state
|
||||
#define yytmp pt_tmp
|
||||
#define yyv pt_v
|
||||
#define yy_yyv pt_yyv
|
||||
#define yyval pt_val
|
||||
#define yylloc pt_lloc
|
||||
#define yyreds pt_reds /* With YYDEBUG defined */
|
||||
#define yytoks pt_toks /* With YYDEBUG defined */
|
||||
#define yylhs pt_yylhs
|
||||
#define yylen pt_yylen
|
||||
#define yydefred pt_yydefred
|
||||
#define yydgoto pt_yydgoto
|
||||
#define yysindex pt_yysindex
|
||||
#define yyrindex pt_yyrindex
|
||||
#define yygindex pt_yygindex
|
||||
#define yytable pt_yytable
|
||||
#define yycheck pt_yycheck
|
||||
|
||||
static int yylex ();
|
||||
static int yyerror ();
|
||||
|
||||
%}
|
||||
|
||||
%token DIGIT
|
||||
|
||||
23
lib/rename.c
23
lib/rename.c
@@ -1,4 +1,4 @@
|
||||
/* rename.c -- BSD compatible directory function for System V
|
||||
/* BSD compatible rename and directory rename function for System V.
|
||||
Copyright (C) 1988, 1990 Free Software Foundation, Inc.
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
@@ -15,8 +15,8 @@
|
||||
along with this program; if not, write to the Free Software Foundation,
|
||||
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include <config.h>
|
||||
#if HAVE_CONFIG_H
|
||||
# include <config.h>
|
||||
#endif
|
||||
|
||||
#include <sys/types.h>
|
||||
@@ -26,12 +26,12 @@
|
||||
extern int errno;
|
||||
#endif
|
||||
|
||||
#ifdef STAT_MACROS_BROKEN
|
||||
#undef S_ISDIR
|
||||
#endif /* STAT_MACROS_BROKEN. */
|
||||
#if STAT_MACROS_BROKEN
|
||||
# undef S_ISDIR
|
||||
#endif
|
||||
|
||||
#if !defined(S_ISDIR) && defined(S_IFDIR)
|
||||
#define S_ISDIR(m) (((m) & S_IFMT) == S_IFDIR)
|
||||
# define S_ISDIR(m) (((m) & S_IFMT) == S_IFDIR)
|
||||
#endif
|
||||
|
||||
/* Rename file FROM to file TO.
|
||||
@@ -67,6 +67,12 @@ rename (from, to)
|
||||
return -1;
|
||||
}
|
||||
|
||||
#ifdef MVDIR
|
||||
|
||||
/* If MVDIR is defined, it should be the full filename of a setuid root
|
||||
program able to link and unlink directories. If MVDIR is not defined,
|
||||
then the capability of renaming directories may be missing. */
|
||||
|
||||
if (S_ISDIR (from_stats.st_mode))
|
||||
{
|
||||
/* Need a setuid root process to link and unlink directories. */
|
||||
@@ -90,6 +96,9 @@ rename (from, to)
|
||||
}
|
||||
}
|
||||
else
|
||||
|
||||
#endif /* MVDIR */
|
||||
|
||||
{
|
||||
if (link (from, to))
|
||||
return -1;
|
||||
|
||||
12
lib/rmdir.c
12
lib/rmdir.c
@@ -1,4 +1,4 @@
|
||||
/* rmdir.c -- BSD compatible remove directory function for System V
|
||||
/* BSD compatible remove directory function for System V
|
||||
Copyright (C) 1988, 1990 Free Software Foundation, Inc.
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
@@ -15,8 +15,8 @@
|
||||
along with this program; if not, write to the Free Software Foundation,
|
||||
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include <config.h>
|
||||
#if HAVE_CONFIG_H
|
||||
# include <config.h>
|
||||
#endif
|
||||
|
||||
#include <sys/types.h>
|
||||
@@ -27,12 +27,12 @@
|
||||
extern int errno;
|
||||
#endif
|
||||
|
||||
#ifdef STAT_MACROS_BROKEN
|
||||
#undef S_ISDIR
|
||||
#if STAT_MACROS_BROKEN
|
||||
# undef S_ISDIR
|
||||
#endif
|
||||
|
||||
#if !defined(S_ISDIR) && defined(S_IFDIR)
|
||||
#define S_ISDIR(m) (((m) & S_IFMT) == S_IFDIR)
|
||||
# define S_ISDIR(m) (((m) & S_IFMT) == S_IFDIR)
|
||||
#endif
|
||||
|
||||
/* rmdir adapted from GNU tar. */
|
||||
|
||||
@@ -15,8 +15,8 @@
|
||||
along with this program; if not, write to the Free Software Foundation,
|
||||
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include <config.h>
|
||||
#if HAVE_CONFIG_H
|
||||
# include <config.h>
|
||||
#endif
|
||||
|
||||
/* Copy SRC to DEST, returning the address of the terminating '\0' in DEST. */
|
||||
|
||||
386
lib/strftime.c
386
lib/strftime.c
@@ -1,20 +1,21 @@
|
||||
/* Copyright (C) 1991, 92, 93, 94, 95, 96 Free Software Foundation, Inc.
|
||||
This file is part of the GNU C Library.
|
||||
/* Copyright (C) 1991, 92, 93, 94, 95, 96, 97 Free Software Foundation, Inc.
|
||||
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Library General Public License as
|
||||
published by the Free Software Foundation; either version 2 of the
|
||||
License, or (at your option) any later version.
|
||||
NOTE: The canonical source of this file is maintained with the GNU C
|
||||
Library. Bugs can be reported to bug-glibc@prep.ai.mit.edu.
|
||||
|
||||
The GNU C Library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Library General Public License for more details.
|
||||
This program is free software; you can redistribute it and/or modify it
|
||||
under the terms of the GNU General Public License as published by the
|
||||
Free Software Foundation; either version 2, or (at your option) any
|
||||
later version.
|
||||
|
||||
You should have received a copy of the GNU Library General Public
|
||||
License along with the GNU C Library; see the file COPYING.LIB. If
|
||||
not, write to the Free Software Foundation, Inc., 675 Mass Ave,
|
||||
Cambridge, MA 02139, USA. */
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software Foundation,
|
||||
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
# include <config.h>
|
||||
@@ -24,14 +25,18 @@ Cambridge, MA 02139, USA. */
|
||||
# define HAVE_LIMITS_H 1
|
||||
# define HAVE_MBLEN 1
|
||||
# define HAVE_MBRLEN 1
|
||||
# define HAVE_STRUCT_ERA_ENTRY 1
|
||||
# define HAVE_TM_GMTOFF 1
|
||||
# define HAVE_TM_ZONE 1
|
||||
# define HAVE_TZNAME 1
|
||||
# define HAVE_TZSET 1
|
||||
# define MULTIBYTE_IS_FORMAT_SAFE 1
|
||||
# define STDC_HEADERS 1
|
||||
# include <ansidecl.h>
|
||||
# include "../locale/localeinfo.h"
|
||||
#endif
|
||||
|
||||
#include <ctype.h>
|
||||
#include <sys/types.h> /* Some systems define `time_t' here. */
|
||||
|
||||
#ifdef TIME_WITH_SYS_TIME
|
||||
@@ -44,6 +49,9 @@ Cambridge, MA 02139, USA. */
|
||||
# include <time.h>
|
||||
# endif
|
||||
#endif
|
||||
#if HAVE_TZNAME
|
||||
extern char *tzname[];
|
||||
#endif
|
||||
|
||||
/* Do multibyte processing if multibytes are supported, unless
|
||||
multibyte sequences are safe in formats. Multibyte sequences are
|
||||
@@ -74,27 +82,31 @@ Cambridge, MA 02139, USA. */
|
||||
# include <stdlib.h>
|
||||
# include <string.h>
|
||||
#else
|
||||
# define memcpy(d, s, n) bcopy (s, d, n)
|
||||
# define memcpy(d, s, n) bcopy ((s), (d), (n))
|
||||
#endif
|
||||
|
||||
#ifndef __P
|
||||
#if defined (__GNUC__) || (defined (__STDC__) && __STDC__)
|
||||
#define __P(args) args
|
||||
#else
|
||||
#define __P(args) ()
|
||||
#endif /* GCC. */
|
||||
# if defined (__GNUC__) || (defined (__STDC__) && __STDC__)
|
||||
# define __P(args) args
|
||||
# else
|
||||
# define __P(args) ()
|
||||
# endif /* GCC. */
|
||||
#endif /* Not __P. */
|
||||
|
||||
#ifndef PTR
|
||||
#ifdef __STDC__
|
||||
#define PTR void *
|
||||
#else
|
||||
#define PTR char *
|
||||
#endif
|
||||
# ifdef __STDC__
|
||||
# define PTR void *
|
||||
# else
|
||||
# define PTR char *
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#ifndef CHAR_BIT
|
||||
#define CHAR_BIT 8
|
||||
# define CHAR_BIT 8
|
||||
#endif
|
||||
|
||||
#ifndef NULL
|
||||
# define NULL 0
|
||||
#endif
|
||||
|
||||
#define TYPE_SIGNED(t) ((t) -1 < 0)
|
||||
@@ -112,7 +124,7 @@ Cambridge, MA 02139, USA. */
|
||||
#ifndef __isleap
|
||||
/* Nonzero if YEAR is a leap year (every 4 years,
|
||||
except every 100th isn't, and every 400th is). */
|
||||
#define __isleap(year) \
|
||||
# define __isleap(year) \
|
||||
((year) % 4 == 0 && ((year) % 100 != 0 || (year) % 400 == 0))
|
||||
#endif
|
||||
|
||||
@@ -120,11 +132,14 @@ Cambridge, MA 02139, USA. */
|
||||
#ifdef _LIBC
|
||||
# define gmtime_r __gmtime_r
|
||||
# define localtime_r __localtime_r
|
||||
extern int __tz_compute __P ((time_t timer, const struct tm *tm));
|
||||
# define tzname __tzname
|
||||
# define tzset __tzset
|
||||
#else
|
||||
# if ! HAVE_LOCALTIME_R
|
||||
# if ! HAVE_TM_GMTOFF
|
||||
/* Approximate gmtime_r as best we can in its absence. */
|
||||
#define gmtime_r my_gmtime_r
|
||||
# define gmtime_r my_gmtime_r
|
||||
static struct tm *gmtime_r __P ((const time_t *, struct tm *));
|
||||
static struct tm *
|
||||
gmtime_r (t, tp)
|
||||
@@ -140,7 +155,7 @@ gmtime_r (t, tp)
|
||||
# endif /* ! HAVE_TM_GMTOFF */
|
||||
|
||||
/* Approximate localtime_r as best we can in its absence. */
|
||||
#define localtime_r my_localtime_r
|
||||
# define localtime_r my_localtime_r
|
||||
static struct tm *localtime_r __P ((const time_t *, struct tm *));
|
||||
static struct tm *
|
||||
localtime_r (t, tp)
|
||||
@@ -157,20 +172,95 @@ localtime_r (t, tp)
|
||||
#endif /* ! defined (_LIBC) */
|
||||
|
||||
|
||||
#define add(n, f) \
|
||||
#if !defined (memset) && !defined (HAVE_MEMSET) && !defined (_LIBC)
|
||||
/* Some systems lack the `memset' function and we don't want to
|
||||
introduce additional dependencies. */
|
||||
static const char spaces[16] = " ";
|
||||
|
||||
# define memset_space(P, Len) \
|
||||
do { \
|
||||
int _len = (Len); \
|
||||
\
|
||||
do \
|
||||
{ \
|
||||
int _this = _len > 16 ? 16 : _len; \
|
||||
memcpy ((P), spaces, _this); \
|
||||
(P) += _this; \
|
||||
_len -= _this; \
|
||||
} \
|
||||
while (_len > 0); \
|
||||
} while (0)
|
||||
#else
|
||||
# define memset_space(P, Len) memset ((P), ' ', (Len))
|
||||
#endif
|
||||
|
||||
#define add(n, f) \
|
||||
do \
|
||||
{ \
|
||||
i += (n); \
|
||||
if (i >= maxsize) \
|
||||
int _n = (n); \
|
||||
int _delta = width - _n; \
|
||||
int _incr = _n + (_delta > 0 ? _delta : 0); \
|
||||
if (i + _incr >= maxsize) \
|
||||
return 0; \
|
||||
else \
|
||||
if (p) \
|
||||
{ \
|
||||
f; \
|
||||
p += (n); \
|
||||
} \
|
||||
if (p) \
|
||||
{ \
|
||||
if (_delta > 0) \
|
||||
memset_space (p, _delta); \
|
||||
f; \
|
||||
p += _n; \
|
||||
} \
|
||||
i += _incr; \
|
||||
} while (0)
|
||||
#define cpy(n, s) add ((n), memcpy((PTR) p, (PTR) (s), (n)))
|
||||
|
||||
#define cpy(n, s) \
|
||||
add ((n), \
|
||||
if (to_lowcase) \
|
||||
memcpy_lowcase (p, (s), _n); \
|
||||
else if (to_uppcase) \
|
||||
memcpy_uppcase (p, (s), _n); \
|
||||
else \
|
||||
memcpy ((PTR) p, (PTR) (s), _n))
|
||||
|
||||
|
||||
|
||||
#ifdef _LIBC
|
||||
# define TOUPPER(Ch) toupper (Ch)
|
||||
# define TOLOWER(Ch) tolower (Ch)
|
||||
#else
|
||||
# define TOUPPER(Ch) (islower (Ch) ? toupper (Ch) : (Ch))
|
||||
# define TOLOWER(Ch) (isupper (Ch) ? tolower (Ch) : (Ch))
|
||||
#endif
|
||||
/* We don't use `isdigit' here since the locale dependent
|
||||
interpretation is not what we want here. We only need to accept
|
||||
the arabic digits in the ASCII range. One day there is perhaps a
|
||||
more reliable way to accept other sets of digits. */
|
||||
#define ISDIGIT(Ch) ((unsigned int) (Ch) - '0' <= 9)
|
||||
|
||||
static char *memcpy_lowcase __P ((char *dest, const char *src, size_t len));
|
||||
|
||||
static char *
|
||||
memcpy_lowcase (dest, src, len)
|
||||
char *dest;
|
||||
const char *src;
|
||||
size_t len;
|
||||
{
|
||||
while (len-- > 0)
|
||||
dest[len] = TOLOWER (src[len]);
|
||||
return dest;
|
||||
}
|
||||
|
||||
static char *memcpy_uppcase __P ((char *dest, const char *src, size_t len));
|
||||
|
||||
static char *
|
||||
memcpy_uppcase (dest, src, len)
|
||||
char *dest;
|
||||
const char *src;
|
||||
size_t len;
|
||||
{
|
||||
while (len-- > 0)
|
||||
dest[len] = TOUPPER (src[len]);
|
||||
return dest;
|
||||
}
|
||||
|
||||
#if ! HAVE_TM_GMTOFF
|
||||
/* Yield the difference between *A and *B,
|
||||
@@ -181,14 +271,17 @@ tm_diff (a, b)
|
||||
const struct tm *a;
|
||||
const struct tm *b;
|
||||
{
|
||||
int ay = a->tm_year + TM_YEAR_BASE - 1;
|
||||
int by = b->tm_year + TM_YEAR_BASE - 1;
|
||||
/* Divide years by 100, rounding towards minus infinity. */
|
||||
int ac = ay / 100 - (ay % 100 < 0);
|
||||
int bc = by / 100 - (by % 100 < 0);
|
||||
int intervening_leap_days =
|
||||
((ay >> 2) - (by >> 2)) - (ac - bc) + ((ac >> 2) - (bc >> 2));
|
||||
int years = ay - by;
|
||||
/* Compute intervening leap days correctly even if year is negative.
|
||||
Take care to avoid int overflow in leap day calculations,
|
||||
but it's OK to assume that A and B are close to each other. */
|
||||
int a4 = (a->tm_year >> 2) + (TM_YEAR_BASE >> 2) - ! (a->tm_year & 3);
|
||||
int b4 = (b->tm_year >> 2) + (TM_YEAR_BASE >> 2) - ! (b->tm_year & 3);
|
||||
int a100 = a4 / 25 - (a4 % 25 < 0);
|
||||
int b100 = b4 / 25 - (b4 % 25 < 0);
|
||||
int a400 = a100 >> 2;
|
||||
int b400 = b100 >> 2;
|
||||
int intervening_leap_days = (a4 - b4) - (a100 - b100) + (a400 - b400);
|
||||
int years = a->tm_year - b->tm_year;
|
||||
int days = (365 * years + intervening_leap_days
|
||||
+ (a->tm_yday - b->tm_yday));
|
||||
return (60 * (60 * (24 * days + (a->tm_hour - b->tm_hour))
|
||||
@@ -236,6 +329,31 @@ static char const month_name[][10] =
|
||||
};
|
||||
#endif
|
||||
|
||||
|
||||
#if !defined _LIBC && HAVE_TZNAME && HAVE_TZSET
|
||||
/* Solaris 2.5 tzset sometimes modifies the storage returned by localtime.
|
||||
Work around this bug by copying *tp before it might be munged. */
|
||||
size_t _strftime_copytm __P ((char *, size_t, const char *,
|
||||
const struct tm *));
|
||||
size_t
|
||||
strftime (s, maxsize, format, tp)
|
||||
char *s;
|
||||
size_t maxsize;
|
||||
const char *format;
|
||||
const struct tm *tp;
|
||||
{
|
||||
struct tm tmcopy;
|
||||
tmcopy = *tp;
|
||||
return _strftime_copytm (s, maxsize, format, &tmcopy);
|
||||
}
|
||||
# ifdef strftime
|
||||
# undef strftime
|
||||
# endif
|
||||
# define strftime _strftime_copytm
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
/* Write information from TP into S according to the format
|
||||
string FORMAT, writing no more that MAXSIZE characters
|
||||
(including the terminating '\0') and returning number of
|
||||
@@ -247,7 +365,7 @@ strftime (s, maxsize, format, tp)
|
||||
char *s;
|
||||
size_t maxsize;
|
||||
const char *format;
|
||||
register const struct tm *tp;
|
||||
const struct tm *tp;
|
||||
{
|
||||
int hour12 = tp->tm_hour;
|
||||
#ifdef _NL_CURRENT
|
||||
@@ -257,12 +375,9 @@ strftime (s, maxsize, format, tp)
|
||||
const char *const f_month = _NL_CURRENT (LC_TIME, MON_1 + tp->tm_mon);
|
||||
const char *const ampm = _NL_CURRENT (LC_TIME,
|
||||
hour12 > 11 ? PM_STR : AM_STR);
|
||||
size_t aw_len = strlen(a_wkday);
|
||||
size_t am_len = strlen(a_month);
|
||||
size_t aw_len = strlen (a_wkday);
|
||||
size_t am_len = strlen (a_month);
|
||||
size_t ap_len = strlen (ampm);
|
||||
|
||||
const char *alt_digits = _NL_CURRENT (LC_TIME, ALT_DIGITS);
|
||||
const char *end_alt_digits = _NL_CURRENT (LC_TIME, ALT_DIGITS + 1);
|
||||
#else
|
||||
const char *const f_wkday = weekday_name[tp->tm_wday];
|
||||
const char *const f_month = month_name[tp->tm_mon];
|
||||
@@ -277,15 +392,30 @@ strftime (s, maxsize, format, tp)
|
||||
size_t month_len = strlen (f_month);
|
||||
const char *zone;
|
||||
size_t zonelen;
|
||||
register size_t i = 0;
|
||||
register char *p = s;
|
||||
register const char *f;
|
||||
size_t i = 0;
|
||||
char *p = s;
|
||||
const char *f;
|
||||
|
||||
zone = 0;
|
||||
#if HAVE_TM_ZONE
|
||||
zone = NULL;
|
||||
#if !defined _LIBC && HAVE_TM_ZONE
|
||||
/* XXX We have some problems here. First, the string pointed to by
|
||||
tm_zone is dynamically allocated while loading the zone data. But
|
||||
when another zone is loaded since the information in TP were
|
||||
computed this would be a stale pointer.
|
||||
The second problem is the POSIX test suite which assumes setting
|
||||
the environment variable TZ to a new value before calling strftime()
|
||||
will influence the result (the %Z format) even if the information in
|
||||
TP is computed with a totally different time zone. --drepper@gnu */
|
||||
zone = (const char *) tp->tm_zone;
|
||||
#endif
|
||||
#if HAVE_TZNAME
|
||||
/* POSIX.1 8.1.1 requires that whenever strftime() is called, the
|
||||
time zone names contained in the external variable `tzname' shall
|
||||
be set as if the tzset() function had been called. */
|
||||
# if HAVE_TZSET
|
||||
tzset ();
|
||||
# endif
|
||||
|
||||
if (!(zone && *zone) && tp->tm_isdst >= 0)
|
||||
zone = tzname[tp->tm_isdst];
|
||||
#endif
|
||||
@@ -311,6 +441,9 @@ strftime (s, maxsize, format, tp)
|
||||
char buf[1 + (sizeof (int) < sizeof (time_t)
|
||||
? INT_STRLEN_BOUND (time_t)
|
||||
: INT_STRLEN_BOUND (int))];
|
||||
int width = -1;
|
||||
int to_lowcase = 0;
|
||||
int to_uppcase = 0;
|
||||
|
||||
#if DO_MULTIBYTE
|
||||
|
||||
@@ -385,20 +518,43 @@ strftime (s, maxsize, format, tp)
|
||||
|
||||
#endif /* ! DO_MULTIBYTE */
|
||||
|
||||
/* Check for flags that can modify a number format. */
|
||||
++f;
|
||||
switch (*f)
|
||||
/* Check for flags that can modify a format. */
|
||||
pad = 0;
|
||||
while (1)
|
||||
{
|
||||
case '_':
|
||||
case '-':
|
||||
pad = *f++;
|
||||
break;
|
||||
switch (*++f)
|
||||
{
|
||||
/* This influences the number formats. */
|
||||
case '_':
|
||||
case '-':
|
||||
case '0':
|
||||
pad = *f;
|
||||
continue;
|
||||
|
||||
default:
|
||||
pad = 0;
|
||||
/* This changes textual output. */
|
||||
case '^':
|
||||
to_uppcase = 1;
|
||||
continue;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
/* As a GNU extension we allow to specify the field width. */
|
||||
if (ISDIGIT (*f))
|
||||
{
|
||||
width = 0;
|
||||
do
|
||||
{
|
||||
width *= 10;
|
||||
width += *f - '0';
|
||||
++f;
|
||||
}
|
||||
while (ISDIGIT (*f));
|
||||
}
|
||||
|
||||
/* Check for modifiers. */
|
||||
switch (*f)
|
||||
{
|
||||
@@ -420,9 +576,6 @@ strftime (s, maxsize, format, tp)
|
||||
#define DO_NUMBER_SPACEPAD(d, v) \
|
||||
digits = d; number_value = v; goto do_number_spacepad
|
||||
|
||||
case '\0': /* GNU extension: % at end of format. */
|
||||
--f;
|
||||
/* Fall through. */
|
||||
case '%':
|
||||
if (modifier != 0)
|
||||
goto bad_format;
|
||||
@@ -462,23 +615,40 @@ strftime (s, maxsize, format, tp)
|
||||
&& *(subfmt = _NL_CURRENT (LC_TIME, ERA_D_T_FMT)) != '\0'))
|
||||
subfmt = _NL_CURRENT (LC_TIME, D_T_FMT);
|
||||
#else
|
||||
subfmt = "%a %b %e %H:%M:%S %Z %Y";
|
||||
subfmt = "%a %b %e %H:%M:%S %Y";
|
||||
#endif
|
||||
|
||||
subformat:
|
||||
{
|
||||
size_t len = strftime (p, maxsize - i, subfmt, tp);
|
||||
char *old_start = p;
|
||||
size_t len = strftime (NULL, maxsize - i, subfmt, tp);
|
||||
if (len == 0 && *subfmt)
|
||||
return 0;
|
||||
add (len, ;);
|
||||
add (len, strftime (p, maxsize - i, subfmt, tp));
|
||||
|
||||
if (to_uppcase)
|
||||
while (old_start < p)
|
||||
{
|
||||
*old_start = TOUPPER (*old_start);
|
||||
++old_start;
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
||||
case 'C': /* POSIX.2 extension. */
|
||||
if (modifier == 'O')
|
||||
goto bad_format;
|
||||
#ifdef _NL_CURRENT
|
||||
/* XXX %EC is not implemented yet. */
|
||||
#if HAVE_STRUCT_ERA_ENTRY
|
||||
if (modifier == 'E')
|
||||
{
|
||||
struct era_entry *era = _nl_get_era_entry (tp);
|
||||
if (era)
|
||||
{
|
||||
size_t len = strlen (era->name_fmt);
|
||||
cpy (len, era->name_fmt);
|
||||
break;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
{
|
||||
int year = tp->tm_year + TM_YEAR_BASE;
|
||||
@@ -517,26 +687,21 @@ strftime (s, maxsize, format, tp)
|
||||
jump to one of these two labels. */
|
||||
|
||||
do_number_spacepad:
|
||||
/* Force `_' flag. */
|
||||
pad = '_';
|
||||
/* Force `_' flag unless overwritten by `0' flag. */
|
||||
if (pad != '0')
|
||||
pad = '_';
|
||||
|
||||
do_number:
|
||||
/* Format the number according to the MODIFIER flag. */
|
||||
|
||||
#ifdef _NL_CURRENT
|
||||
if (modifier == 'O')
|
||||
if (modifier == 'O' && 0 <= number_value)
|
||||
{
|
||||
/* ALT_DIGITS is the first entry in an array with
|
||||
alternative digit symbols. We have to find string
|
||||
number NUMBER_VALUE, but must not look beyond
|
||||
END_ALT_DIGITS. */
|
||||
int run = number_value;
|
||||
const char *cp = alt_digits;
|
||||
/* Get the locale specific alternate representation of
|
||||
the number NUMBER_VALUE. If none exist NULL is returned. */
|
||||
const char *cp = _nl_get_alt_digit (number_value);
|
||||
|
||||
while (run > 0 && cp < end_alt_digits)
|
||||
cp = strchr (cp, '\0') + 1;
|
||||
|
||||
if (cp < end_alt_digits)
|
||||
if (cp != NULL)
|
||||
{
|
||||
size_t digitlen = strlen (cp);
|
||||
if (digitlen != 0)
|
||||
@@ -634,6 +799,10 @@ strftime (s, maxsize, format, tp)
|
||||
add (1, *p = '\n');
|
||||
break;
|
||||
|
||||
case 'P':
|
||||
to_lowcase = 1;
|
||||
/* FALLTHROUGH */
|
||||
|
||||
case 'p':
|
||||
cpy (ap_len, ampm);
|
||||
break;
|
||||
@@ -644,15 +813,14 @@ strftime (s, maxsize, format, tp)
|
||||
|
||||
case 'r': /* POSIX.2 extension. */
|
||||
#ifdef _NL_CURRENT
|
||||
subfmt = _NL_CURRENT (LC_TIME, T_FMT_AMPM);
|
||||
#else
|
||||
subfmt = "%I:%M:%S %p";
|
||||
if (*(subfmt = _NL_CURRENT (LC_TIME, T_FMT_AMPM)) == '\0')
|
||||
#endif
|
||||
subfmt = "%I:%M:%S %p";
|
||||
goto subformat;
|
||||
|
||||
case 'S':
|
||||
if (modifier == 'E')
|
||||
return 0;
|
||||
goto bad_format;
|
||||
|
||||
DO_NUMBER (2, tp->tm_sec);
|
||||
|
||||
@@ -776,10 +944,16 @@ strftime (s, maxsize, format, tp)
|
||||
DO_NUMBER (1, tp->tm_wday);
|
||||
|
||||
case 'Y':
|
||||
#ifdef _NL_CURRENT
|
||||
if (modifier == 'E'
|
||||
&& *(subfmt = _NL_CURRENT (LC_TIME, ERA_YEAR)) != '\0')
|
||||
goto subformat;
|
||||
#if HAVE_STRUCT_ERA_ENTRY
|
||||
if (modifier == 'E')
|
||||
{
|
||||
struct era_entry *era = _nl_get_era_entry (tp);
|
||||
if (era)
|
||||
{
|
||||
subfmt = strchr (era->name_fmt, '\0') + 1;
|
||||
goto subformat;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
if (modifier == 'O')
|
||||
goto bad_format;
|
||||
@@ -787,13 +961,22 @@ strftime (s, maxsize, format, tp)
|
||||
DO_NUMBER (1, tp->tm_year + TM_YEAR_BASE);
|
||||
|
||||
case 'y':
|
||||
#ifdef _NL_CURRENT
|
||||
/* XXX %Ey is not implemented yet. */
|
||||
#if HAVE_STRUCT_ERA_ENTRY
|
||||
if (modifier == 'E')
|
||||
{
|
||||
struct era_entry *era = _nl_get_era_entry (tp);
|
||||
if (era)
|
||||
{
|
||||
int delta = tp->tm_year - era->start_date[0];
|
||||
DO_NUMBER (1, (era->offset
|
||||
+ (era->direction == '-' ? -delta : delta)));
|
||||
}
|
||||
}
|
||||
#endif
|
||||
DO_NUMBER (2, (tp->tm_year % 100 + 100) % 100);
|
||||
|
||||
case 'Z':
|
||||
cpy(zonelen, zone);
|
||||
cpy (zonelen, zone);
|
||||
break;
|
||||
|
||||
case 'z': /* GNU extension. */
|
||||
@@ -847,6 +1030,9 @@ strftime (s, maxsize, format, tp)
|
||||
DO_NUMBER (4, (diff / 60) * 100 + diff % 60);
|
||||
}
|
||||
|
||||
case '\0': /* GNU extension: % at end of format. */
|
||||
--f;
|
||||
/* Fall through. */
|
||||
default:
|
||||
/* Unknown format; output the format, including the '%',
|
||||
since this is most likely the right thing to do if a
|
||||
@@ -854,7 +1040,7 @@ strftime (s, maxsize, format, tp)
|
||||
bad_format:
|
||||
{
|
||||
int flen;
|
||||
for (flen = 2; f[1 - flen] != '%'; flen++)
|
||||
for (flen = 1; f[1 - flen] != '%'; flen++)
|
||||
continue;
|
||||
cpy (flen, &f[1 - flen]);
|
||||
}
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
along with this program; if not, write to the Free Software Foundation,
|
||||
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#if HAVE_CONFIG_H
|
||||
# include <config.h>
|
||||
#endif
|
||||
|
||||
|
||||
106
lib/strtol.c
106
lib/strtol.c
@@ -1,24 +1,23 @@
|
||||
/* Copyright (C) 1991, 92, 94, 95, 96 Free Software Foundation, Inc.
|
||||
/* strtol - Convert string representation of a number into an integer value.
|
||||
Copyright (C) 1991, 92, 94, 95, 96 Free Software Foundation, Inc.
|
||||
NOTE: The canonical source of this file is maintained with the GNU C
|
||||
Library. Bugs can be reported to bug-glibc@prep.ai.mit.edu.
|
||||
|
||||
NOTE: The canonical source of this file is maintained with the GNU C Library.
|
||||
Bugs can be reported to bug-glibc@prep.ai.mit.edu.
|
||||
This program is free software; you can redistribute it and/or modify it
|
||||
under the terms of the GNU General Public License as published by the
|
||||
Free Software Foundation; either version 2, or (at your option) any
|
||||
later version.
|
||||
|
||||
This program is free software; you can redistribute it and/or modify it
|
||||
under the terms of the GNU General Public License as published by the
|
||||
Free Software Foundation; either version 2, or (at your option) any
|
||||
later version.
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software Foundation,
|
||||
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
|
||||
USA. */
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#if HAVE_CONFIG_H
|
||||
# include <config.h>
|
||||
#endif
|
||||
|
||||
@@ -33,6 +32,9 @@ USA. */
|
||||
#ifndef errno
|
||||
extern int errno;
|
||||
#endif
|
||||
#ifndef __set_errno
|
||||
# define __set_errno(Val) errno = (Val)
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_LIMITS_H
|
||||
# include <limits.h>
|
||||
@@ -41,6 +43,7 @@ extern int errno;
|
||||
#ifdef STDC_HEADERS
|
||||
# include <stddef.h>
|
||||
# include <stdlib.h>
|
||||
# include <string.h>
|
||||
#else
|
||||
# ifndef NULL
|
||||
# define NULL 0
|
||||
@@ -108,40 +111,38 @@ extern int errno;
|
||||
#else
|
||||
# define LONG long
|
||||
|
||||
# ifndef ULONG_MAX
|
||||
# define ULONG_MAX ((unsigned long) ~(unsigned long) 0)
|
||||
# endif
|
||||
# ifndef LONG_MAX
|
||||
# define LONG_MAX ((long int) (ULONG_MAX >> 1))
|
||||
# endif
|
||||
#ifndef ULONG_MAX
|
||||
# define ULONG_MAX ((unsigned long) ~(unsigned long) 0)
|
||||
#endif
|
||||
#ifndef LONG_MAX
|
||||
# define LONG_MAX ((long int) (ULONG_MAX >> 1))
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifdef USE_WIDE_CHAR
|
||||
# include <wchar.h>
|
||||
# include <wctype.h>
|
||||
# define L_(ch) L##ch
|
||||
# define L_(Ch) L##Ch
|
||||
# define UCHAR_TYPE wint_t
|
||||
# define STRING_TYPE wchar_t
|
||||
# define ISSPACE(ch) iswspace (ch)
|
||||
# define ISALPHA(ch) iswalpha (ch)
|
||||
# define TOUPPER(ch) towupper (ch)
|
||||
# define ISSPACE(Ch) iswspace (Ch)
|
||||
# define ISALPHA(Ch) iswalpha (Ch)
|
||||
# define TOUPPER(Ch) towupper (Ch)
|
||||
#else
|
||||
# define L_(ch) ch
|
||||
# define L_(Ch) Ch
|
||||
# define UCHAR_TYPE unsigned char
|
||||
# define STRING_TYPE char
|
||||
# define ISSPACE(ch) isspace (ch)
|
||||
# define ISALPHA(ch) isalpha (ch)
|
||||
# define TOUPPER(ch) toupper (ch)
|
||||
# define ISSPACE(Ch) isspace (Ch)
|
||||
# define ISALPHA(Ch) isalpha (Ch)
|
||||
# define TOUPPER(Ch) toupper (Ch)
|
||||
#endif
|
||||
|
||||
#ifdef __STDC__
|
||||
# define INTERNAL(x) INTERNAL1(x)
|
||||
# define INTERNAL1(x) __##x##_internal
|
||||
# define WEAKNAME(x) WEAKNAME1(x)
|
||||
# define WEAKNAME1(x) __##x
|
||||
# define INTERNAL(X) INTERNAL1(X)
|
||||
# define INTERNAL1(X) __##X##_internal
|
||||
# define WEAKNAME(X) WEAKNAME1(X)
|
||||
#else
|
||||
# define INTERNAL(x) __/**/x/**/_internal
|
||||
# define WEAKNAME(x) __/**/x
|
||||
# define INTERNAL(X) __/**/X/**/_internal
|
||||
#endif
|
||||
|
||||
#ifdef USE_NUMBER_GROUPING
|
||||
@@ -251,8 +252,9 @@ INTERNAL (strtol) (nptr, endptr, base, group)
|
||||
/* Find the end of the digit string and check its grouping. */
|
||||
end = s;
|
||||
for (c = *end; c != L_('\0'); c = *++end)
|
||||
if (c != thousands && (c < L_('0') || c > L_('9'))
|
||||
&& (!ISALPHA (c) || TOUPPER (c) - L_('A') + 10 >= base))
|
||||
if ((wchar_t) c != thousands
|
||||
&& ((wchar_t) c < L_('0') || (wchar_t) c > L_('9'))
|
||||
&& (!ISALPHA (c) || (int) (TOUPPER (c) - L_('A') + 10) >= base))
|
||||
break;
|
||||
if (*s == thousands)
|
||||
end = s;
|
||||
@@ -278,7 +280,7 @@ INTERNAL (strtol) (nptr, endptr, base, group)
|
||||
c = TOUPPER (c) - L_('A') + 10;
|
||||
else
|
||||
break;
|
||||
if (c >= base)
|
||||
if ((int) c >= base)
|
||||
break;
|
||||
/* Check for overflow. */
|
||||
if (i > cutoff || (i == cutoff && c > cutlim))
|
||||
@@ -311,7 +313,7 @@ INTERNAL (strtol) (nptr, endptr, base, group)
|
||||
|
||||
if (overflow)
|
||||
{
|
||||
errno = ERANGE;
|
||||
__set_errno (ERANGE);
|
||||
#if UNSIGNED
|
||||
return ULONG_MAX;
|
||||
#else
|
||||
@@ -324,7 +326,7 @@ INTERNAL (strtol) (nptr, endptr, base, group)
|
||||
|
||||
noconv:
|
||||
/* We must handle a special case here: the base is 0 or 16 and the
|
||||
first two characters and '0' and 'x', but the rest are no
|
||||
first two characters are '0' and 'x', but the rest are no
|
||||
hexadecimal digits. This is no error case. We return 0 and
|
||||
ENDPTR points to the `x`. */
|
||||
if (endptr != NULL)
|
||||
@@ -340,19 +342,23 @@ noconv:
|
||||
|
||||
/* External user entry point. */
|
||||
|
||||
#undef PARAMS
|
||||
#if defined (__STDC__) && __STDC__
|
||||
# define PARAMS(args) args
|
||||
#else
|
||||
# define PARAMS(args) ()
|
||||
#endif
|
||||
#if _LIBC - 0 == 0
|
||||
# undef PARAMS
|
||||
# if defined (__STDC__) && __STDC__
|
||||
# define PARAMS(Args) Args
|
||||
# else
|
||||
# define PARAMS(Args) ()
|
||||
# endif
|
||||
|
||||
/* Prototype. */
|
||||
INT strtol PARAMS ((const STRING_TYPE *nptr, STRING_TYPE **endptr,
|
||||
int base));
|
||||
INT strtol PARAMS ((const STRING_TYPE *nptr, STRING_TYPE **endptr, int base));
|
||||
#endif
|
||||
|
||||
|
||||
INT
|
||||
#ifdef weak_function
|
||||
weak_function
|
||||
#endif
|
||||
strtol (nptr, endptr, base)
|
||||
const STRING_TYPE *nptr;
|
||||
STRING_TYPE **endptr;
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/* xgetcwd.c -- return current directory with unlimited length
|
||||
Copyright (C) 1992 Free Software Foundation, Inc.
|
||||
Copyright (C) 1992, 1996 Free Software Foundation, Inc.
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
@@ -17,7 +17,7 @@
|
||||
|
||||
/* Written by David MacKenzie <djm@gnu.ai.mit.edu>. */
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#if HAVE_CONFIG_H
|
||||
# include <config.h>
|
||||
#endif
|
||||
|
||||
@@ -26,14 +26,15 @@
|
||||
#ifndef errno
|
||||
extern int errno;
|
||||
#endif
|
||||
|
||||
#include <sys/types.h>
|
||||
#include "pathmax.h"
|
||||
|
||||
#ifndef HAVE_GETCWD
|
||||
char *getwd ();
|
||||
# define getcwd(buf, max) getwd (buf)
|
||||
#else
|
||||
#if HAVE_GETCWD
|
||||
char *getcwd ();
|
||||
#else
|
||||
char *getwd ();
|
||||
# define getcwd(Buf, Max) getwd (Buf)
|
||||
#endif
|
||||
|
||||
/* Amount to increase buffer size by in each try. */
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/* xgethostname.c -- return current hostname with unlimited length
|
||||
Copyright (C) 1992 Free Software Foundation, Inc.
|
||||
Copyright (C) 1992, 1996 Free Software Foundation, Inc.
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
@@ -15,7 +15,7 @@
|
||||
along with this program; if not, write to the Free Software Foundation,
|
||||
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
|
||||
|
||||
/* Written by Jim Meyering, meyering@comco.com */
|
||||
/* written by Jim Meyering */
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
# include <config.h>
|
||||
@@ -23,12 +23,23 @@
|
||||
|
||||
#include <sys/types.h>
|
||||
|
||||
#include <errno.h>
|
||||
#ifndef errno
|
||||
extern int errno;
|
||||
#endif
|
||||
|
||||
#include "error.h"
|
||||
|
||||
#ifndef EXIT_FAILURE
|
||||
# define EXIT_FAILURE 1
|
||||
#endif
|
||||
|
||||
int gethostname ();
|
||||
char *xmalloc ();
|
||||
char *xrealloc ();
|
||||
|
||||
#ifndef INITIAL_HOSTNAME_LENGTH
|
||||
# define INITIAL_HOSTNAME_LENGTH 33
|
||||
# define INITIAL_HOSTNAME_LENGTH 34
|
||||
#endif
|
||||
|
||||
char *
|
||||
@@ -42,10 +53,20 @@ xgethostname ()
|
||||
hostname = xmalloc (size);
|
||||
while (1)
|
||||
{
|
||||
hostname[size - 1] = '\0';
|
||||
/* Use size - 2 here rather than size - 1 to work around the bug
|
||||
in SunOS5.5's gethostname whereby it NUL-terminates HOSTNAME
|
||||
even when the name is longer than the supplied buffer. */
|
||||
int k = size - 2;
|
||||
|
||||
errno = 0;
|
||||
hostname[k] = '\0';
|
||||
err = gethostname (hostname, size);
|
||||
if (err == 0 && hostname[size - 1] == '\0')
|
||||
if (err == 0 && hostname[k] == '\0')
|
||||
break;
|
||||
#ifdef ENAMETOOLONG
|
||||
else if (err != 0 && errno != ENAMETOOLONG && errno != 0)
|
||||
error (EXIT_FAILURE, errno, "gethostname");
|
||||
#endif
|
||||
size *= 2;
|
||||
hostname = xrealloc (hostname, size);
|
||||
}
|
||||
|
||||
@@ -32,7 +32,6 @@ char *xstrdup (char *string);
|
||||
char *xmalloc ();
|
||||
#endif
|
||||
|
||||
|
||||
/* Return a newly allocated copy of STRING. */
|
||||
|
||||
char *
|
||||
|
||||
@@ -18,11 +18,11 @@
|
||||
/* Written by Jim Meyering. */
|
||||
|
||||
#if HAVE_CONFIG_H
|
||||
#include <config.h>
|
||||
# include <config.h>
|
||||
#endif
|
||||
|
||||
#if STDC_HEADERS
|
||||
#include <stdlib.h>
|
||||
# include <stdlib.h>
|
||||
#endif
|
||||
|
||||
#if HAVE_STRING_H
|
||||
@@ -91,15 +91,14 @@ __xstrtol (s, ptr, base, val, valid_suffixes)
|
||||
return LONGINT_OVERFLOW;
|
||||
if (*p == s)
|
||||
return LONGINT_INVALID;
|
||||
|
||||
/* Let valid_suffixes == NULL mean `allow any suffix'. */
|
||||
/* FIXME: update all callers except the one in tail.c changing
|
||||
last parameter NULL to `""'. */
|
||||
if (!valid_suffixes)
|
||||
{
|
||||
if (**p == '\0')
|
||||
{
|
||||
*val = tmp;
|
||||
return LONGINT_OK;
|
||||
}
|
||||
else
|
||||
return LONGINT_INVALID_SUFFIX_CHAR;
|
||||
*val = tmp;
|
||||
return LONGINT_OK;
|
||||
}
|
||||
|
||||
if (**p != '\0')
|
||||
@@ -146,8 +145,8 @@ __xstrtol (s, ptr, base, val, valid_suffixes)
|
||||
|
||||
#ifdef TESTING_XSTRTO
|
||||
|
||||
#include <stdio.h>
|
||||
#include "error.h"
|
||||
# include <stdio.h>
|
||||
# include "error.h"
|
||||
|
||||
char *program_name;
|
||||
|
||||
@@ -175,4 +174,5 @@ main (int argc, char** argv)
|
||||
}
|
||||
exit (0);
|
||||
}
|
||||
|
||||
#endif /* TESTING_XSTRTO */
|
||||
|
||||
@@ -1,66 +1,69 @@
|
||||
#ifndef _xstrtol_h_
|
||||
#define _xstrtol_h_ 1
|
||||
#ifndef XSTRTOL_H_
|
||||
# define XSTRTOL_H_ 1
|
||||
|
||||
#if STRING_TO_UNSIGNED
|
||||
# define __xstrtol xstrtoul
|
||||
# define __strtol strtoul
|
||||
# define __unsigned unsigned
|
||||
# define __ZLONG_MAX ULONG_MAX
|
||||
#else
|
||||
# define __xstrtol xstrtol
|
||||
# define __strtol strtol
|
||||
# define __unsigned /* empty */
|
||||
# define __ZLONG_MAX LONG_MAX
|
||||
#endif
|
||||
# if STRING_TO_UNSIGNED
|
||||
# define __xstrtol xstrtoul
|
||||
# define __strtol strtoul
|
||||
# define __unsigned unsigned
|
||||
# define __ZLONG_MAX ULONG_MAX
|
||||
# else
|
||||
# define __xstrtol xstrtol
|
||||
# define __strtol strtol
|
||||
# define __unsigned /* empty */
|
||||
# define __ZLONG_MAX LONG_MAX
|
||||
# endif
|
||||
|
||||
#undef PARAMS
|
||||
#if defined (__STDC__) && __STDC__
|
||||
# define PARAMS(x) x
|
||||
#else
|
||||
# define PARAMS(x) ()
|
||||
#endif
|
||||
# undef PARAMS
|
||||
# if defined (__STDC__) && __STDC__
|
||||
# define PARAMS(Args) Args
|
||||
# else
|
||||
# define PARAMS(Args) ()
|
||||
# endif
|
||||
|
||||
#ifndef _STRTOL_ERROR
|
||||
enum strtol_error
|
||||
{
|
||||
LONGINT_OK, LONGINT_INVALID, LONGINT_INVALID_SUFFIX_CHAR, LONGINT_OVERFLOW
|
||||
};
|
||||
typedef enum strtol_error strtol_error;
|
||||
#endif
|
||||
|
||||
strtol_error
|
||||
__xstrtol PARAMS ((const char *s, char **ptr, int base,
|
||||
__unsigned long int *val, const char *valid_suffixes));
|
||||
|
||||
#define _STRTOL_ERROR(exit_code, str, argument_type_string, err) \
|
||||
#undef _STRTOL_ERROR
|
||||
# define _STRTOL_ERROR(Exit_code, Str, Argument_type_string, Err) \
|
||||
do \
|
||||
{ \
|
||||
switch ((err)) \
|
||||
switch ((Err)) \
|
||||
{ \
|
||||
case LONGINT_OK: \
|
||||
abort (); \
|
||||
\
|
||||
case LONGINT_INVALID: \
|
||||
error ((exit_code), 0, "invalid %s `%s'", \
|
||||
(argument_type_string), (str)); \
|
||||
error ((Exit_code), 0, "invalid %s `%s'", \
|
||||
(Argument_type_string), (Str)); \
|
||||
break; \
|
||||
\
|
||||
case LONGINT_INVALID_SUFFIX_CHAR: \
|
||||
error ((exit_code), 0, "invalid character following %s `%s'", \
|
||||
(argument_type_string), (str)); \
|
||||
error ((Exit_code), 0, "invalid character following %s `%s'", \
|
||||
(Argument_type_string), (Str)); \
|
||||
break; \
|
||||
\
|
||||
case LONGINT_OVERFLOW: \
|
||||
/* FIXME: make this message dependent on STRING_TO_UNSIGNED */\
|
||||
error ((exit_code), 0, "%s `%s' larger than maximum long int",\
|
||||
(argument_type_string), (str)); \
|
||||
error ((Exit_code), 0, "%s `%s' larger than maximum long int",\
|
||||
(Argument_type_string), (Str)); \
|
||||
break; \
|
||||
} \
|
||||
} \
|
||||
while (0)
|
||||
|
||||
#define STRTOL_FATAL_ERROR(str, argument_type_string, err) \
|
||||
_STRTOL_ERROR (2, str, argument_type_string, err)
|
||||
# define STRTOL_FATAL_ERROR(Str, Argument_type_string, Err) \
|
||||
_STRTOL_ERROR (2, Str, Argument_type_string, Err)
|
||||
|
||||
#define STRTOL_FAIL_WARN(str, argument_type_string, err) \
|
||||
_STRTOL_ERROR (0, str, argument_type_string, err)
|
||||
# define STRTOL_FAIL_WARN(Str, Argument_type_string, Err) \
|
||||
_STRTOL_ERROR (0, Str, Argument_type_string, Err)
|
||||
|
||||
#endif /* _xstrtol_h_ */
|
||||
#endif /* not XSTRTOL_H_ */
|
||||
|
||||
@@ -1,7 +1,13 @@
|
||||
#ifndef _xstrtoul_h_
|
||||
# define _xstrtoul_h_ 1
|
||||
#ifndef XSTRTOUL_H_
|
||||
# define XSTRTOUL_H_ 1
|
||||
|
||||
# define STRING_TO_UNSIGNED 1
|
||||
|
||||
/* Undefine this symbol so we can include xstrtol.h a second time.
|
||||
Otherwise, a program that wanted both xstrtol.h and xstrtoul.h
|
||||
would never get the declaration corresponding to the header file
|
||||
included after the first one. */
|
||||
# undef XSTRTOL_H_
|
||||
# include "xstrtol.h"
|
||||
|
||||
#endif /* _xstrtoul_h_ */
|
||||
#endif /* not XSTRTOUL_H_ */
|
||||
|
||||
1
m4/.cvsignore
Normal file
1
m4/.cvsignore
Normal file
@@ -0,0 +1 @@
|
||||
Makefile
|
||||
11
m4/Makefile.am
Normal file
11
m4/Makefile.am
Normal file
@@ -0,0 +1,11 @@
|
||||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
# Generate this list with
|
||||
# find . -type f -name '*.m4' -printf '%f\n'|sort |fmt |tr '\012' @ \
|
||||
# |sed 's/@$/%/;s/@/ \\@/g' |tr @% '\012\012'
|
||||
EXTRA_DIST = README \
|
||||
ccstdc.m4 dmalloc.m4 error.m4 getgroups.m4 getline.m4 getloadavg.m4 \
|
||||
gettext.m4 header.m4 init.m4 install.m4 jm-mktime.m4 jm-winsz1.m4 \
|
||||
jm-winsz2.m4 lcmessage.m4 lispdir.m4 maintainer.m4 memcmp.m4 mktime.m4 \
|
||||
obstack.m4 progtest.m4 protos.m4 ptrdiff.m4 regex.m4 sanity.m4 strftime.m4 \
|
||||
strtod.m4 termios.m4 uptime.m4 winsz.m4
|
||||
153
m4/Makefile.in
Normal file
153
m4/Makefile.in
Normal file
@@ -0,0 +1,153 @@
|
||||
# Makefile.in generated automatically by automake 1.1l from Makefile.am
|
||||
|
||||
# Copyright (C) 1994, 1995, 1996 Free Software Foundation, Inc.
|
||||
# This Makefile.in is free software; the Free Software Foundation
|
||||
# gives unlimited permission to copy, distribute and modify it.
|
||||
|
||||
# Generate this list with
|
||||
# find . -type f -name '*.m4' -printf '%f\n'|sort |fmt |tr '\012' @ \
|
||||
# |sed 's/@$/%/;s/@/ \\@/g' |tr @% '\012\012'
|
||||
|
||||
|
||||
SHELL = /bin/sh
|
||||
|
||||
srcdir = @srcdir@
|
||||
top_srcdir = @top_srcdir@
|
||||
VPATH = @srcdir@
|
||||
prefix = @prefix@
|
||||
exec_prefix = @exec_prefix@
|
||||
|
||||
bindir = @bindir@
|
||||
sbindir = @sbindir@
|
||||
libexecdir = @libexecdir@
|
||||
datadir = @datadir@
|
||||
sysconfdir = @sysconfdir@
|
||||
sharedstatedir = @sharedstatedir@
|
||||
localstatedir = @localstatedir@
|
||||
libdir = @libdir@
|
||||
infodir = @infodir@
|
||||
mandir = @mandir@
|
||||
includedir = @includedir@
|
||||
oldincludedir = /usr/include
|
||||
|
||||
pkgdatadir = $(datadir)/@PACKAGE@
|
||||
pkglibdir = $(libdir)/@PACKAGE@
|
||||
pkgincludedir = $(includedir)/@PACKAGE@
|
||||
|
||||
top_builddir = ..
|
||||
|
||||
INSTALL = @INSTALL@
|
||||
INSTALL_PROGRAM = @INSTALL_PROGRAM@
|
||||
INSTALL_DATA = @INSTALL_DATA@
|
||||
INSTALL_SCRIPT = @INSTALL_SCRIPT@
|
||||
transform = @program_transform_name@
|
||||
YACC = @YACC@
|
||||
GENCAT = @GENCAT@
|
||||
PERL = @PERL@
|
||||
MV = @MV@
|
||||
GMSGFMT = @GMSGFMT@
|
||||
CC = @CC@
|
||||
RANLIB = @RANLIB@
|
||||
LN = @LN@
|
||||
RM = @RM@
|
||||
|
||||
EXTRA_DIST = README \
|
||||
ccstdc.m4 dmalloc.m4 error.m4 getgroups.m4 getline.m4 getloadavg.m4 \
|
||||
gettext.m4 header.m4 init.m4 install.m4 jm-mktime.m4 jm-winsz1.m4 \
|
||||
jm-winsz2.m4 lcmessage.m4 lispdir.m4 maintainer.m4 memcmp.m4 mktime.m4 \
|
||||
obstack.m4 progtest.m4 protos.m4 ptrdiff.m4 regex.m4 sanity.m4 strftime.m4 \
|
||||
strtod.m4 termios.m4 uptime.m4 winsz.m4
|
||||
mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
|
||||
CONFIG_HEADER = ../config.h
|
||||
CONFIG_CLEAN_FILES =
|
||||
DIST_COMMON = README Makefile.am Makefile.in README
|
||||
|
||||
|
||||
PACKAGE = @PACKAGE@
|
||||
VERSION = @VERSION@
|
||||
|
||||
DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) \
|
||||
$(TEXINFOS) $(MANS) $(EXTRA_DIST)
|
||||
|
||||
TAR = tar
|
||||
default: all
|
||||
|
||||
.SUFFIXES:
|
||||
$(srcdir)/Makefile.in: @MAINT@ Makefile.am $(top_srcdir)/configure.in $(ACLOCAL)
|
||||
cd $(top_srcdir) && automake --gnu m4/Makefile
|
||||
|
||||
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status $(BUILT_SOURCES)
|
||||
cd $(top_builddir) \
|
||||
&& CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status
|
||||
|
||||
tags: TAGS
|
||||
TAGS:
|
||||
|
||||
|
||||
distdir = $(top_builddir)/$(PACKAGE)-$(VERSION)/$(subdir)
|
||||
|
||||
subdir = m4
|
||||
distdir: $(DISTFILES)
|
||||
@for file in $(DISTFILES); do \
|
||||
d=$(srcdir); \
|
||||
test -f $(distdir)/$$file \
|
||||
|| ln $$d/$$file $(distdir)/$$file 2> /dev/null \
|
||||
|| cp -p $$d/$$file $(distdir)/$$file; \
|
||||
done
|
||||
info:
|
||||
dvi:
|
||||
check: all
|
||||
$(MAKE)
|
||||
installcheck:
|
||||
install-exec:
|
||||
$(NORMAL_INSTALL)
|
||||
|
||||
install-data:
|
||||
$(NORMAL_INSTALL)
|
||||
|
||||
install: install-exec install-data all
|
||||
@:
|
||||
|
||||
uninstall:
|
||||
|
||||
all: Makefile
|
||||
|
||||
install-strip:
|
||||
$(MAKE) INSTALL_PROGRAM='$(INSTALL_PROGRAM) -s' install
|
||||
installdirs:
|
||||
|
||||
|
||||
mostlyclean-generic:
|
||||
test -z "$(MOSTLYCLEANFILES)" || rm -f $(MOSTLYCLEANFILES)
|
||||
|
||||
clean-generic:
|
||||
test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
|
||||
|
||||
distclean-generic:
|
||||
rm -f Makefile $(DISTCLEANFILES)
|
||||
rm -f config.cache config.log stamp-h
|
||||
test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
|
||||
|
||||
maintainer-clean-generic:
|
||||
test -z "$(MAINTAINERCLEANFILES)" || rm -f $(MAINTAINERCLEANFILES)
|
||||
test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES)
|
||||
mostlyclean: mostlyclean-generic
|
||||
|
||||
clean: clean-generic mostlyclean
|
||||
|
||||
distclean: distclean-generic clean
|
||||
rm -f config.status
|
||||
|
||||
maintainer-clean: maintainer-clean-generic distclean
|
||||
@echo "This command is intended for maintainers to use;"
|
||||
@echo "it deletes files that may require special tools to rebuild."
|
||||
|
||||
.PHONY: default tags distdir info dvi installcheck install-exec \
|
||||
install-data install uninstall all installdirs mostlyclean-generic \
|
||||
distclean-generic clean-generic maintainer-clean-generic clean \
|
||||
mostlyclean distclean maintainer-clean
|
||||
|
||||
|
||||
# Tell versions [3.59,3.63) of GNU make to not export all variables.
|
||||
# Otherwise a system limit (for SysV at least) may be exceeded.
|
||||
.NOEXPORT:
|
||||
9
m4/README
Normal file
9
m4/README
Normal file
@@ -0,0 +1,9 @@
|
||||
These files are used by a program called aclocal (part of the GNU automake
|
||||
package). aclocal uses these files to create aclocal.m4 which is in turn
|
||||
used by autoconf to create the configure script at the the top level in
|
||||
this distribution.
|
||||
|
||||
Some of these files are copies of the ones in the automake-1.1l
|
||||
distribution. Others are specific to this package.
|
||||
Eventually, I expect that aclocal will evolve so that this directory
|
||||
can contain only the .m4 files specific to this package.
|
||||
61
m4/ccstdc.m4
Normal file
61
m4/ccstdc.m4
Normal file
@@ -0,0 +1,61 @@
|
||||
## ----------------------------------------- ##
|
||||
## ANSIfy the C compiler whenever possible. ##
|
||||
## From Franc,ois Pinard ##
|
||||
## ----------------------------------------- ##
|
||||
|
||||
# serial 1
|
||||
|
||||
# @defmac AC_PROG_CC_STDC
|
||||
# @maindex PROG_CC_STDC
|
||||
# @ovindex CC
|
||||
# If the C compiler in not in ANSI C mode by default, try to add an option
|
||||
# to output variable @code{CC} to make it so. This macro tries various
|
||||
# options that select ANSI C on some system or another. It considers the
|
||||
# compiler to be in ANSI C mode if it defines @code{__STDC__} to 1 and
|
||||
# handles function prototypes correctly.
|
||||
#
|
||||
# If you use this macro, you should check after calling it whether the C
|
||||
# compiler has been set to accept ANSI C; if not, the shell variable
|
||||
# @code{am_cv_prog_cc_stdc} is set to @samp{no}. If you wrote your source
|
||||
# code in ANSI C, you can make an un-ANSIfied copy of it by using the
|
||||
# program @code{ansi2knr}, which comes with Ghostscript.
|
||||
# @end defmac
|
||||
|
||||
AC_DEFUN(AM_PROG_CC_STDC,
|
||||
[AC_REQUIRE([AC_PROG_CC])
|
||||
AC_MSG_CHECKING(for ${CC-cc} option to accept ANSI C)
|
||||
AC_CACHE_VAL(am_cv_prog_cc_stdc,
|
||||
[am_cv_prog_cc_stdc=no
|
||||
ac_save_CC="$CC"
|
||||
# Don't try gcc -ansi; that turns off useful extensions and
|
||||
# breaks some systems' header files.
|
||||
# AIX -qlanglvl=ansi
|
||||
# Ultrix and OSF/1 -std1
|
||||
# HP-UX -Aa -D_HPUX_SOURCE
|
||||
# SVR4 -Xc -D__EXTENSIONS__
|
||||
for ac_arg in "" -qlanglvl=ansi -std1 "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
|
||||
do
|
||||
CC="$ac_save_CC $ac_arg"
|
||||
AC_TRY_COMPILE(
|
||||
[#if !defined(__STDC__) || __STDC__ != 1
|
||||
choke me
|
||||
#endif
|
||||
/* DYNIX/ptx V4.1.3 can't compile sys/stat.h with -Xc -D__EXTENSIONS__. */
|
||||
#ifdef _SEQUENT_
|
||||
# include <sys/types.h>
|
||||
# include <sys/stat.h>
|
||||
#endif
|
||||
], [
|
||||
int test (int i, double x);
|
||||
struct s1 {int (*f) (int a);};
|
||||
struct s2 {int (*f) (double a);};],
|
||||
[am_cv_prog_cc_stdc="$ac_arg"; break])
|
||||
done
|
||||
CC="$ac_save_CC"
|
||||
])
|
||||
AC_MSG_RESULT($am_cv_prog_cc_stdc)
|
||||
case "x$am_cv_prog_cc_stdc" in
|
||||
x|xno) ;;
|
||||
*) CC="$CC $am_cv_prog_cc_stdc" ;;
|
||||
esac
|
||||
])
|
||||
21
m4/dmalloc.m4
Normal file
21
m4/dmalloc.m4
Normal file
@@ -0,0 +1,21 @@
|
||||
## ----------------------------------- ##
|
||||
## Check if --with-dmalloc was given. ##
|
||||
## From Franc,ois Pinard ##
|
||||
## ----------------------------------- ##
|
||||
|
||||
# serial 1
|
||||
|
||||
AC_DEFUN(AM_WITH_DMALLOC,
|
||||
[AC_MSG_CHECKING(if malloc debugging is wanted)
|
||||
AC_ARG_WITH(dmalloc,
|
||||
[ --with-dmalloc use dmalloc, as in
|
||||
ftp://ftp.letters.com/src/dmalloc/dmalloc.tar.gz],
|
||||
[if test "$withval" = yes; then
|
||||
AC_MSG_RESULT(yes)
|
||||
AC_DEFINE(WITH_DMALLOC)
|
||||
LIBS="$LIBS -ldmalloc"
|
||||
LDFLAGS="$LDFLAGS -g"
|
||||
else
|
||||
AC_MSG_RESULT(no)
|
||||
fi], [AC_MSG_RESULT(no)])
|
||||
])
|
||||
13
m4/error.m4
Normal file
13
m4/error.m4
Normal file
@@ -0,0 +1,13 @@
|
||||
dnl From Jim Meyering. Use this if you use the GNU error.[ch].
|
||||
dnl FIXME: Migrate into libit
|
||||
|
||||
AC_DEFUN(AM_FUNC_ERROR_AT_LINE,
|
||||
[AC_CACHE_CHECK([for error_at_line], am_cv_lib_error_at_line,
|
||||
[AC_TRY_LINK([],[error_at_line(0, 0, "", 0, "");],
|
||||
am_cv_lib_error_at_line=yes,
|
||||
am_cv_lib_error_at_line=no)])
|
||||
if test $am_cv_lib_error_at_line = no; then
|
||||
LIBOBJS="$LIBOBJS error.o"
|
||||
fi
|
||||
AC_SUBST(LIBOBJS)dnl
|
||||
])
|
||||
49
m4/getgroups.m4
Normal file
49
m4/getgroups.m4
Normal file
@@ -0,0 +1,49 @@
|
||||
#serial 2
|
||||
|
||||
dnl From Jim Meyering.
|
||||
dnl If you use this macro in a package, you should
|
||||
dnl add the following two lines to acconfig.h:
|
||||
dnl /* Define to rpl_getgroups if the replacement function should be used. */
|
||||
dnl #undef getgroups
|
||||
dnl
|
||||
dnl Invoking code should check $GETGROUPS_LIB something like this:
|
||||
dnl jm_FUNC_GETGROUPS
|
||||
dnl test -n "$GETGROUPS_LIB" && LIBS="$GETGROUPS_LIB $LIBS"
|
||||
dnl
|
||||
|
||||
AC_DEFUN(jm_FUNC_GETGROUPS,
|
||||
[AC_REQUIRE([AC_TYPE_GETGROUPS])dnl
|
||||
AC_REQUIRE([AC_TYPE_SIZE_T])dnl
|
||||
AC_CHECK_FUNCS(getgroups)
|
||||
|
||||
# If we don't yet have getgroups, see if it's in -lbsd.
|
||||
# This is reported to be necessary on an ITOS 3000WS running SEIUX 3.1.
|
||||
if test $ac_cv_func_getgroups = no; then
|
||||
jm_cv_sys_getgroups_saved_lib="$LIBS"
|
||||
AC_CHECK_LIB(bsd, getgroups, [GETGROUPS_LIB=-lbsd])
|
||||
LIBS="$jm_cv_sys_getgroups_saved_lib"
|
||||
fi
|
||||
|
||||
# Run the program to test the functionality of the system-supplied
|
||||
# getgroups function only if there is such a function.
|
||||
if test $ac_cv_func_getgroups = yes; then
|
||||
AC_CACHE_CHECK([for working getgroups], jm_cv_func_working_getgroups,
|
||||
[AC_TRY_RUN([
|
||||
int
|
||||
main ()
|
||||
{
|
||||
/* On Ultrix 4.3, getgroups (0, 0) always fails. */
|
||||
exit (getgroups (0, 0) == -1 ? 1 : 0);
|
||||
}
|
||||
],
|
||||
jm_cv_func_working_getgroups=yes,
|
||||
jm_cv_func_working_getgroups=no,
|
||||
dnl When crosscompiling, assume getgroups is broken.
|
||||
jm_cv_func_working_getgroups=no)
|
||||
])
|
||||
if test $jm_cv_func_working_getgroups = no; then
|
||||
LIBOBJS="$LIBOBJS getgroups.o"
|
||||
AC_DEFINE_UNQUOTED(getgroups, rpl_getgroups)
|
||||
fi
|
||||
fi
|
||||
])
|
||||
45
m4/getline.m4
Normal file
45
m4/getline.m4
Normal file
@@ -0,0 +1,45 @@
|
||||
#serial 1
|
||||
|
||||
dnl See if there's a working, system-supplied version of the getline function.
|
||||
dnl We can't just to AC_REPLACE_FUNCS(getline) because some systems
|
||||
dnl have a function by that name in -linet that doesn't have anything
|
||||
dnl to do with the function we need.
|
||||
AC_DEFUN(AM_FUNC_GETLINE,
|
||||
[dnl
|
||||
am_getline_needs_run_time_check=no
|
||||
am_cv_func_working_getline=yes
|
||||
AC_CHECK_FUNC(getline,
|
||||
dnl Found it in some library. Verify that it works.
|
||||
am_getline_needs_run_time_check=yes,
|
||||
am_cv_func_working_getline=no)
|
||||
if test $am_getline_needs_run_time_check = yes; then
|
||||
AC_CACHE_CHECK([for working getline function], am_cv_func_working_getline,
|
||||
[echo fooN |tr -d '\012'|tr N '\012' > conftestdata
|
||||
AC_TRY_RUN([
|
||||
# include <stdio.h>
|
||||
# include <sys/types.h>
|
||||
# if HAVE_STRING_H
|
||||
# include <string.h>
|
||||
# endif
|
||||
int main ()
|
||||
{ /* Based on a test program from Karl Heuer. */
|
||||
char *line = NULL;
|
||||
size_t siz = 0;
|
||||
int len;
|
||||
FILE *in = fopen ("./conftestdata", "r");
|
||||
if (!in)
|
||||
return 1;
|
||||
len = getline (&line, &siz, in);
|
||||
exit ((len == 4 && line && strcmp (line, "foo\n") == 0) ? 0 : 1);
|
||||
}
|
||||
], am_cv_func_working_getline=yes dnl The library version works.
|
||||
, am_cv_func_working_getline=no dnl The library version does NOT work.
|
||||
, am_cv_func_working_getline=no dnl We're cross compiling.
|
||||
)])
|
||||
fi
|
||||
|
||||
if test $am_cv_func_working_getline = no; then
|
||||
LIBOBJS="$LIBOBJS getline.o"
|
||||
AC_SUBST(LIBOBJS)dnl
|
||||
fi
|
||||
])
|
||||
127
m4/getloadavg.m4
Normal file
127
m4/getloadavg.m4
Normal file
@@ -0,0 +1,127 @@
|
||||
#serial 3
|
||||
|
||||
AC_DEFUN(AM_FUNC_GETLOADAVG,
|
||||
[ac_have_func=no # yes means we've found a way to get the load average.
|
||||
|
||||
am_cv_saved_LIBS="$LIBS"
|
||||
|
||||
# On HPUX9, an unprivileged user can get load averages through this function.
|
||||
AC_CHECK_FUNCS(pstat_getdynamic)
|
||||
|
||||
# Solaris has libkstat which does not require root.
|
||||
AC_CHECK_LIB(kstat, kstat_open)
|
||||
if test $ac_cv_lib_kstat_kstat_open = yes ; then ac_have_func=yes ; fi
|
||||
|
||||
# Some systems with -lutil have (and need) -lkvm as well, some do not.
|
||||
# On Solaris, -lkvm requires nlist from -lelf, so check that first
|
||||
# to get the right answer into the cache.
|
||||
# For kstat on solaris, we need libelf to force the definition of SVR4 below.
|
||||
AC_CHECK_LIB(elf, elf_begin, LIBS="-lelf $LIBS")
|
||||
if test $ac_have_func = no; then
|
||||
AC_CHECK_LIB(kvm, kvm_open, LIBS="-lkvm $LIBS")
|
||||
# Check for the 4.4BSD definition of getloadavg.
|
||||
AC_CHECK_LIB(util, getloadavg,
|
||||
[LIBS="-lutil $LIBS" ac_have_func=yes ac_cv_func_getloadavg_setgid=yes])
|
||||
fi
|
||||
|
||||
if test $ac_have_func = no; then
|
||||
# There is a commonly available library for RS/6000 AIX.
|
||||
# Since it is not a standard part of AIX, it might be installed locally.
|
||||
ac_save_LIBS="$LIBS"
|
||||
LIBS="-L/usr/local/lib $LIBS"
|
||||
AC_CHECK_LIB(getloadavg, getloadavg,
|
||||
LIBS="-lgetloadavg $LIBS", LIBS="$ac_save_LIBS")
|
||||
fi
|
||||
|
||||
# Make sure it is really in the library, if we think we found it.
|
||||
AC_REPLACE_FUNCS(getloadavg)
|
||||
|
||||
if test $ac_cv_func_getloadavg = yes; then
|
||||
AC_DEFINE(HAVE_GETLOADAVG)
|
||||
ac_have_func=yes
|
||||
else
|
||||
AC_DEFINE(C_GETLOADAVG)
|
||||
# Figure out what our getloadavg.c needs.
|
||||
ac_have_func=no
|
||||
AC_CHECK_HEADER(sys/dg_sys_info.h,
|
||||
[ac_have_func=yes; AC_DEFINE(DGUX)
|
||||
AC_CHECK_LIB(dgc, dg_sys_info)])
|
||||
|
||||
# We cannot check for <dwarf.h>, because Solaris 2 does not use dwarf (it
|
||||
# uses stabs), but it is still SVR4. We cannot check for <elf.h> because
|
||||
# Irix 4.0.5F has the header but not the library.
|
||||
if test $ac_have_func = no && test $ac_cv_lib_elf_elf_begin = yes; then
|
||||
ac_have_func=yes; AC_DEFINE(SVR4)
|
||||
fi
|
||||
|
||||
if test $ac_have_func = no; then
|
||||
AC_CHECK_HEADER(inq_stats/cpustats.h,
|
||||
[ac_have_func=yes; AC_DEFINE(UMAX)
|
||||
AC_DEFINE(UMAX4_3)])
|
||||
fi
|
||||
|
||||
if test $ac_have_func = no; then
|
||||
AC_CHECK_HEADER(sys/cpustats.h,
|
||||
[ac_have_func=yes; AC_DEFINE(UMAX)])
|
||||
fi
|
||||
|
||||
if test $ac_have_func = no; then
|
||||
AC_CHECK_HEADERS(mach/mach.h)
|
||||
fi
|
||||
|
||||
AC_CHECK_HEADER(nlist.h,
|
||||
[AC_DEFINE(NLIST_STRUCT)
|
||||
AC_CACHE_CHECK([for n_un in struct nlist], ac_cv_struct_nlist_n_un,
|
||||
[AC_TRY_COMPILE([#include <nlist.h>],
|
||||
[struct nlist n; n.n_un.n_name = 0;],
|
||||
ac_cv_struct_nlist_n_un=yes, ac_cv_struct_nlist_n_un=no)])
|
||||
if test $ac_cv_struct_nlist_n_un = yes; then
|
||||
AC_DEFINE(NLIST_NAME_UNION)
|
||||
fi
|
||||
])dnl
|
||||
fi # Do not have getloadavg in system libraries.
|
||||
|
||||
# Some definitions of getloadavg require that the program be installed setgid.
|
||||
dnl FIXME Don't hardwire the path of getloadavg.c in the top-level directory.
|
||||
AC_CACHE_CHECK(whether getloadavg requires setgid,
|
||||
ac_cv_func_getloadavg_setgid,
|
||||
[AC_EGREP_CPP([Yowza Am I SETGID yet],
|
||||
[#include "$srcdir/lib/getloadavg.c"
|
||||
#ifdef LDAV_PRIVILEGED
|
||||
Yowza Am I SETGID yet
|
||||
#endif],
|
||||
ac_cv_func_getloadavg_setgid=yes, ac_cv_func_getloadavg_setgid=no)])
|
||||
if test $ac_cv_func_getloadavg_setgid = yes; then
|
||||
NEED_SETGID=true; AC_DEFINE(GETLOADAVG_PRIVILEGED)
|
||||
else
|
||||
NEED_SETGID=false
|
||||
fi
|
||||
AC_SUBST(NEED_SETGID)dnl
|
||||
|
||||
if test $ac_cv_func_getloadavg_setgid = yes; then
|
||||
AC_CACHE_CHECK(group of /dev/kmem, ac_cv_group_kmem,
|
||||
changequote(<<, >>)dnl
|
||||
<<
|
||||
# On Solaris, /dev/kmem is a symlink. Get info on the real file.
|
||||
ac_ls_output=`ls -lgL /dev/kmem 2>/dev/null`
|
||||
# If we got an error (system does not support symlinks), try without -L.
|
||||
test -z "$ac_ls_output" && ac_ls_output=`ls -lg /dev/kmem`
|
||||
ac_cv_group_kmem=`echo $ac_ls_output \
|
||||
| sed -ne 's/[ ][ ]*/ /g;
|
||||
s/^.[sSrwx-]* *[0-9]* *\([^0-9]*\) *.*/\1/;
|
||||
/ /s/.* //;p;'`
|
||||
>>
|
||||
changequote([, ])dnl
|
||||
)
|
||||
KMEM_GROUP=$ac_cv_group_kmem
|
||||
fi
|
||||
AC_SUBST(KMEM_GROUP)dnl
|
||||
|
||||
if test x = "x$am_cv_saved_LIBS"; then
|
||||
GETLOADAVG_LIBS="$LIBS"
|
||||
else
|
||||
GETLOADAVG_LIBS=`echo "$LIBS"|sed "s!$am_cv_saved_LIBS!!"`
|
||||
fi
|
||||
AC_SUBST(GETLOADAVG_LIBS)dnl
|
||||
LIBS="$am_cv_saved_LIBS"
|
||||
])
|
||||
286
m4/gettext.m4
Normal file
286
m4/gettext.m4
Normal file
@@ -0,0 +1,286 @@
|
||||
# Macro to add for using GNU gettext.
|
||||
# Ulrich Drepper <drepper@cygnus.com>, 1995.
|
||||
|
||||
# serial 1
|
||||
|
||||
AC_DEFUN(AM_WITH_NLS,
|
||||
[AC_MSG_CHECKING([whether NLS is requested])
|
||||
dnl Default is enabled NLS
|
||||
AC_ARG_ENABLE(nls,
|
||||
[ --disable-nls do not use Native Language Support],
|
||||
USE_NLS=$enableval, USE_NLS=yes)
|
||||
AC_MSG_RESULT($USE_NLS)
|
||||
AC_SUBST(USE_NLS)
|
||||
|
||||
USE_INCLUDED_LIBINTL=no
|
||||
|
||||
dnl If we use NLS figure out what method
|
||||
if test "$USE_NLS" = "yes"; then
|
||||
AC_DEFINE(ENABLE_NLS)
|
||||
AC_MSG_CHECKING([whether included gettext is requested])
|
||||
AC_ARG_WITH(included-gettext,
|
||||
[ --with-included-gettext use the GNU gettext library included here],
|
||||
nls_cv_force_use_gnu_gettext=$withval,
|
||||
nls_cv_force_use_gnu_gettext=no)
|
||||
AC_MSG_RESULT($nls_cv_force_use_gnu_gettext)
|
||||
|
||||
nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext"
|
||||
if test "$nls_cv_force_use_gnu_gettext" != "yes"; then
|
||||
dnl User does not insist on using GNU NLS library. Figure out what
|
||||
dnl to use. If gettext or catgets are available (in this order) we
|
||||
dnl use this. Else we have to fall back to GNU NLS library.
|
||||
dnl catgets is only used if permitted by option --with-catgets.
|
||||
nls_cv_header_intl=
|
||||
nls_cv_header_libgt=
|
||||
CATOBJEXT=NONE
|
||||
|
||||
AC_CHECK_HEADER(libintl.h,
|
||||
[AC_CACHE_CHECK([for gettext in libc], gt_cv_func_gettext_libc,
|
||||
[AC_TRY_LINK([#include <libintl.h>], [return (int) gettext ("")],
|
||||
gt_cv_func_gettext_libc=yes, gt_cv_func_gettext_libc=no)])
|
||||
|
||||
if test "$gt_cv_func_gettext_libc" != "yes"; then
|
||||
AC_CHECK_LIB(intl, bindtextdomain,
|
||||
[AC_CACHE_CHECK([for gettext in libintl],
|
||||
gt_cv_func_gettext_libintl,
|
||||
[AC_TRY_LINK([], [return (int) gettext ("")],
|
||||
gt_cv_func_gettext_libintl=yes,
|
||||
gt_cv_func_gettext_libintl=no)])])
|
||||
fi
|
||||
|
||||
if test "$gt_cv_func_gettext_libc" = "yes" \
|
||||
|| test "$gt_cv_func_gettext_libintl" = "yes"; then
|
||||
AC_DEFINE(HAVE_GETTEXT)
|
||||
AM_PATH_PROG_WITH_TEST(MSGFMT, msgfmt,
|
||||
[test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"], no)dnl
|
||||
if test "$MSGFMT" != "no"; then
|
||||
AC_CHECK_FUNCS(dcgettext)
|
||||
AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT)
|
||||
AM_PATH_PROG_WITH_TEST(XGETTEXT, xgettext,
|
||||
[test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"], :)
|
||||
AC_TRY_LINK(, [extern int _nl_msg_cat_cntr;
|
||||
return _nl_msg_cat_cntr],
|
||||
[CATOBJEXT=.gmo
|
||||
DATADIRNAME=share],
|
||||
[CATOBJEXT=.mo
|
||||
DATADIRNAME=lib])
|
||||
INSTOBJEXT=.mo
|
||||
fi
|
||||
fi
|
||||
])
|
||||
|
||||
if test "$CATOBJEXT" = "NONE"; then
|
||||
AC_MSG_CHECKING([whether catgets can be used])
|
||||
AC_ARG_WITH(catgets,
|
||||
[ --with-catgets use catgets functions if available],
|
||||
nls_cv_use_catgets=$withval, nls_cv_use_catgets=no)
|
||||
AC_MSG_RESULT($nls_cv_use_catgets)
|
||||
|
||||
if test "$nls_cv_use_catgets" = "yes"; then
|
||||
dnl No gettext in C library. Try catgets next.
|
||||
AC_CHECK_LIB(i, main)
|
||||
AC_CHECK_FUNC(catgets,
|
||||
[AC_DEFINE(HAVE_CATGETS)
|
||||
INTLOBJS="\$(CATOBJS)"
|
||||
AC_PATH_PROG(GENCAT, gencat, no)dnl
|
||||
if test "$GENCAT" != "no"; then
|
||||
AC_PATH_PROG(GMSGFMT, gmsgfmt, no)
|
||||
if test "$GMSGFMT" = "no"; then
|
||||
AM_PATH_PROG_WITH_TEST(GMSGFMT, msgfmt,
|
||||
[test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"], no)
|
||||
fi
|
||||
AM_PATH_PROG_WITH_TEST(XGETTEXT, xgettext,
|
||||
[test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"], :)
|
||||
USE_INCLUDED_LIBINTL=yes
|
||||
CATOBJEXT=.cat
|
||||
INSTOBJEXT=.cat
|
||||
DATADIRNAME=lib
|
||||
INTLDEPS="../intl/libintl.a"
|
||||
INTLLIBS=$INTLDEPS
|
||||
LIBS=`echo $LIBS | sed -e 's/-lintl//'`
|
||||
nls_cv_header_intl=intl/libintl.h
|
||||
nls_cv_header_libgt=intl/libgettext.h
|
||||
fi])
|
||||
fi
|
||||
fi
|
||||
|
||||
if test "$CATOBJEXT" = "NONE"; then
|
||||
dnl Neither gettext nor catgets in included in the C library.
|
||||
dnl Fall back on GNU gettext library.
|
||||
nls_cv_use_gnu_gettext=yes
|
||||
fi
|
||||
fi
|
||||
|
||||
if test "$nls_cv_use_gnu_gettext" = "yes"; then
|
||||
dnl Mark actions used to generate GNU NLS library.
|
||||
INTLOBJS="\$(GETTOBJS)"
|
||||
AM_PATH_PROG_WITH_TEST(MSGFMT, msgfmt,
|
||||
[test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"], msgfmt)
|
||||
AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT)
|
||||
AM_PATH_PROG_WITH_TEST(XGETTEXT, xgettext,
|
||||
[test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"], :)
|
||||
AC_SUBST(MSGFMT)
|
||||
USE_INCLUDED_LIBINTL=yes
|
||||
CATOBJEXT=.gmo
|
||||
INSTOBJEXT=.mo
|
||||
DATADIRNAME=share
|
||||
INTLDEPS="../intl/libintl.a"
|
||||
INTLLIBS=$INTLDEPS
|
||||
LIBS=`echo $LIBS | sed -e 's/-lintl//'`
|
||||
nls_cv_header_intl=intl/libintl.h
|
||||
nls_cv_header_libgt=intl/libgettext.h
|
||||
fi
|
||||
|
||||
dnl Test whether we really found GNU xgettext.
|
||||
if test "$XGETTEXT" != ":"; then
|
||||
dnl If it is no GNU xgettext we define it as : so that the
|
||||
dnl Makefiles still can work.
|
||||
if $XGETTEXT --omit-header /dev/null 2> /dev/null; then
|
||||
: ;
|
||||
else
|
||||
AC_MSG_RESULT(
|
||||
[found xgettext programs is not GNU xgettext; ignore it])
|
||||
XGETTEXT=":"
|
||||
fi
|
||||
fi
|
||||
|
||||
# We need to process the po/ directory.
|
||||
POSUB=po
|
||||
else
|
||||
DATADIRNAME=share
|
||||
nls_cv_header_intl=intl/libintl.h
|
||||
nls_cv_header_libgt=intl/libgettext.h
|
||||
fi
|
||||
|
||||
# If this is used in GNU gettext we have to set USE_NLS to `yes'
|
||||
# because some of the sources are only built for this goal.
|
||||
if test "$PACKAGE" = gettext; then
|
||||
USE_NLS=yes
|
||||
USE_INCLUDED_LIBINTL=yes
|
||||
fi
|
||||
|
||||
dnl These rules are solely for the distribution goal. While doing this
|
||||
dnl we only have to keep exactly one list of the available catalogs
|
||||
dnl in configure.in.
|
||||
for lang in $ALL_LINGUAS; do
|
||||
GMOFILES="$GMOFILES $lang.gmo"
|
||||
POFILES="$POFILES $lang.po"
|
||||
done
|
||||
|
||||
dnl Make all variables we use known to autoconf.
|
||||
AC_SUBST(USE_INCLUDED_LIBINTL)
|
||||
AC_SUBST(CATALOGS)
|
||||
AC_SUBST(CATOBJEXT)
|
||||
AC_SUBST(DATADIRNAME)
|
||||
AC_SUBST(GMOFILES)
|
||||
AC_SUBST(INSTOBJEXT)
|
||||
AC_SUBST(INTLDEPS)
|
||||
AC_SUBST(INTLLIBS)
|
||||
AC_SUBST(INTLOBJS)
|
||||
AC_SUBST(POFILES)
|
||||
AC_SUBST(POSUB)
|
||||
])
|
||||
|
||||
AC_DEFUN(AM_GNU_GETTEXT,
|
||||
[AC_REQUIRE([AC_PROG_MAKE_SET])dnl
|
||||
AC_REQUIRE([AC_PROG_CC])dnl
|
||||
AC_REQUIRE([AC_PROG_RANLIB])dnl
|
||||
AC_REQUIRE([AC_HEADER_STDC])dnl
|
||||
AC_REQUIRE([AC_C_CONST])dnl
|
||||
AC_REQUIRE([AC_C_INLINE])dnl
|
||||
AC_REQUIRE([AC_TYPE_OFF_T])dnl
|
||||
AC_REQUIRE([AC_TYPE_SIZE_T])dnl
|
||||
AC_REQUIRE([AC_FUNC_ALLOCA])dnl
|
||||
AC_REQUIRE([AC_FUNC_MMAP])dnl
|
||||
|
||||
AC_CHECK_HEADERS([argz.h limits.h locale.h nl_types.h malloc.h string.h \
|
||||
unistd.h values.h])
|
||||
AC_CHECK_FUNCS([getcwd munmap putenv setenv setlocale strchr strcasecmp \
|
||||
__argz_count __argz_stringify __argz_next])
|
||||
|
||||
if test "${ac_cv_func_stpcpy+set}" != "set"; then
|
||||
AC_CHECK_FUNCS(stpcpy)
|
||||
fi
|
||||
if test "${ac_cv_func_stpcpy}" = "yes"; then
|
||||
AC_DEFINE(HAVE_STPCPY)
|
||||
fi
|
||||
|
||||
AM_LC_MESSAGES
|
||||
AM_WITH_NLS
|
||||
|
||||
if test "x$CATOBJEXT" != "x"; then
|
||||
if test "x$ALL_LINGUAS" = "x"; then
|
||||
LINGUAS=
|
||||
else
|
||||
AC_MSG_CHECKING(for catalogs to be installed)
|
||||
NEW_LINGUAS=
|
||||
for lang in ${LINGUAS=$ALL_LINGUAS}; do
|
||||
case "$ALL_LINGUAS" in
|
||||
*$lang*) NEW_LINGUAS="$NEW_LINGUAS $lang" ;;
|
||||
esac
|
||||
done
|
||||
LINGUAS=$NEW_LINGUAS
|
||||
AC_MSG_RESULT($LINGUAS)
|
||||
fi
|
||||
|
||||
dnl Construct list of names of catalog files to be constructed.
|
||||
if test -n "$LINGUAS"; then
|
||||
for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done
|
||||
fi
|
||||
fi
|
||||
|
||||
dnl Determine which catalog format we have (if any is needed)
|
||||
dnl For now we know about two different formats:
|
||||
dnl Linux libc-5 and the normal X/Open format
|
||||
test -d intl || mkdir intl
|
||||
if test "$CATOBJEXT" = ".cat"; then
|
||||
AC_CHECK_HEADER(linux/version.h, msgformat=linux, msgformat=xopen)
|
||||
|
||||
dnl Transform the SED scripts while copying because some dumb SEDs
|
||||
dnl cannot handle comments.
|
||||
sed -e '/^#/d' $srcdir/intl/$msgformat-msg.sed > intl/po2msg.sed
|
||||
fi
|
||||
dnl po2tbl.sed is always needed.
|
||||
sed -e '/^#.*[^\\]$/d' -e '/^#$/d' \
|
||||
$srcdir/intl/po2tbl.sed.in > intl/po2tbl.sed
|
||||
|
||||
dnl In the intl/Makefile.in we have a special dependency which makes
|
||||
dnl only sense for gettext. We comment this out for non-gettext
|
||||
dnl packages.
|
||||
if test "$PACKAGE" = "gettext"; then
|
||||
GT_NO="#NO#"
|
||||
GT_YES=
|
||||
else
|
||||
GT_NO=
|
||||
GT_YES="#YES#"
|
||||
fi
|
||||
AC_SUBST(GT_NO)
|
||||
AC_SUBST(GT_YES)
|
||||
|
||||
dnl If the AC_CONFIG_AUX_DIR macro for autoconf is used we possibly
|
||||
dnl find the mkinstalldirs script in another subdir but ($top_srcdir).
|
||||
dnl Try to locate is.
|
||||
MKINSTALLDIRS=
|
||||
if test $ac_aux_dir; then
|
||||
MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs"
|
||||
fi
|
||||
if test -z $MKINSTALLDIRS; then
|
||||
MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs"
|
||||
fi
|
||||
AC_SUBST(MKINSTALLDIRS)
|
||||
|
||||
dnl Generate list of files to be processed by xgettext which will
|
||||
dnl be included in po/Makefile.
|
||||
test -d po || mkdir po
|
||||
if test "x$srcdir" != "x."; then
|
||||
if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then
|
||||
posrcprefix="$srcdir/"
|
||||
else
|
||||
posrcprefix="../$srcdir/"
|
||||
fi
|
||||
else
|
||||
posrcprefix="../"
|
||||
fi
|
||||
sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \
|
||||
< $srcdir/po/POTFILES.in > po/POTFILES
|
||||
])
|
||||
12
m4/header.m4
Normal file
12
m4/header.m4
Normal file
@@ -0,0 +1,12 @@
|
||||
# Like AC_CONFIG_HEADER, but automatically create stamp file.
|
||||
|
||||
AC_DEFUN(AM_CONFIG_HEADER,
|
||||
[AC_PREREQ([2.12])
|
||||
AC_CONFIG_HEADER([$1])
|
||||
dnl When config.status generates a header, we must update the stamp-h file.
|
||||
dnl This file resides in the same directory as the config header
|
||||
dnl that is generated. We must strip everything past the first ":",
|
||||
dnl and everything past the last "/".
|
||||
AC_OUTPUT_COMMANDS(changequote(<<,>>)dnl
|
||||
test -z "<<$>>CONFIG_HEADERS" || echo timestamp > patsubst(<<$1>>, <<^\([^:]*/\)?.*>>, <<\1>>)stamp-h<<>>dnl
|
||||
changequote([,]))])
|
||||
20
m4/init.m4
Normal file
20
m4/init.m4
Normal file
@@ -0,0 +1,20 @@
|
||||
# Do all the work for Automake. This macro actually does too much --
|
||||
# some checks are only needed if your package does certain things.
|
||||
# But this isn't really a big deal.
|
||||
|
||||
# serial 1
|
||||
|
||||
dnl Usage:
|
||||
dnl AM_INIT_AUTOMAKE(package,version)
|
||||
|
||||
AC_DEFUN(AM_INIT_AUTOMAKE,
|
||||
[AC_REQUIRE([AM_PROG_INSTALL])
|
||||
PACKAGE=[$1]
|
||||
AC_SUBST(PACKAGE)
|
||||
AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE")
|
||||
VERSION=[$2]
|
||||
AC_SUBST(VERSION)
|
||||
AC_DEFINE_UNQUOTED(VERSION, "$VERSION")
|
||||
AM_SANITY_CHECK
|
||||
AC_ARG_PROGRAM
|
||||
AC_PROG_MAKE_SET])
|
||||
13
m4/install.m4
Normal file
13
m4/install.m4
Normal file
@@ -0,0 +1,13 @@
|
||||
## --------------------------------------------------------- ##
|
||||
## Use AC_PROG_INSTALL, supplementing it with INSTALL_SCRIPT ##
|
||||
## substitution. ##
|
||||
## From Franc,ois Pinard ##
|
||||
## --------------------------------------------------------- ##
|
||||
|
||||
# serial 1
|
||||
|
||||
AC_DEFUN(AM_PROG_INSTALL,
|
||||
[AC_REQUIRE([AC_PROG_INSTALL])
|
||||
test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
|
||||
AC_SUBST(INSTALL_SCRIPT)dnl
|
||||
])
|
||||
14
m4/jm-mktime.m4
Normal file
14
m4/jm-mktime.m4
Normal file
@@ -0,0 +1,14 @@
|
||||
#serial 1
|
||||
|
||||
dnl From Jim Meyering.
|
||||
dnl If you use this macro in a package, you should
|
||||
dnl add the following two lines to acconfig.h:
|
||||
dnl /* Define to rpl_mktime if the replacement function should be used. */
|
||||
dnl #undef mktime
|
||||
dnl
|
||||
AC_DEFUN(jm_FUNC_MKTIME,
|
||||
[AC_REQUIRE([AM_FUNC_MKTIME])dnl
|
||||
if test $am_cv_func_working_mktime = no; then
|
||||
AC_DEFINE_UNQUOTED(mktime, rpl_mktime)
|
||||
fi
|
||||
])
|
||||
19
m4/jm-winsz1.m4
Normal file
19
m4/jm-winsz1.m4
Normal file
@@ -0,0 +1,19 @@
|
||||
dnl From Jim Meyering.
|
||||
#serial 1
|
||||
AC_DEFUN(jm_HEADER_TIOCGWINSZ_IN_TERMIOS_H,
|
||||
[AC_REQUIRE([AM_SYS_POSIX_TERMIOS])
|
||||
AC_CACHE_CHECK([whether use of TIOCGWINSZ requires termios.h],
|
||||
jm_cv_sys_tiocgwinsz_needs_termios_h,
|
||||
[jm_cv_sys_tiocgwinsz_needs_termios_h=no
|
||||
|
||||
if test $am_cv_sys_posix_termios = yes; then
|
||||
AC_EGREP_CPP([yes],
|
||||
[#include <sys/types.h>
|
||||
# include <termios.h>
|
||||
# ifdef TIOCGWINSZ
|
||||
yes
|
||||
# endif
|
||||
], jm_cv_sys_tiocgwinsz_needs_termios_h=yes)
|
||||
fi
|
||||
])
|
||||
])
|
||||
22
m4/jm-winsz2.m4
Normal file
22
m4/jm-winsz2.m4
Normal file
@@ -0,0 +1,22 @@
|
||||
#serial 2
|
||||
|
||||
AC_DEFUN(jm_HEADER_TIOCGWINSZ_NEEDS_SYS_IOCTL,
|
||||
[AC_REQUIRE([jm_HEADER_TIOCGWINSZ_IN_TERMIOS_H])
|
||||
AC_CACHE_CHECK([whether use of TIOCGWINSZ requires sys/ioctl.h],
|
||||
jm_cv_sys_tiocgwinsz_needs_sys_ioctl_h,
|
||||
[jm_cv_sys_tiocgwinsz_needs_sys_ioctl_h=no
|
||||
|
||||
if test $jm_cv_sys_tiocgwinsz_needs_termios_h = no; then
|
||||
AC_EGREP_CPP([yes],
|
||||
[#include <sys/types.h>
|
||||
# include <sys/ioctl.h>
|
||||
# ifdef TIOCGWINSZ
|
||||
yes
|
||||
# endif
|
||||
], jm_cv_sys_tiocgwinsz_needs_sys_ioctl_h=yes)
|
||||
fi
|
||||
])
|
||||
if test $jm_cv_sys_tiocgwinsz_needs_sys_ioctl_h = yes; then
|
||||
AC_DEFINE(GWINSZ_IN_SYS_IOCTL)
|
||||
fi
|
||||
])
|
||||
14
m4/lcmessage.m4
Normal file
14
m4/lcmessage.m4
Normal file
@@ -0,0 +1,14 @@
|
||||
# Check whether LC_MESSAGES is available in <locale.h>.
|
||||
# Ulrich Drepper <drepper@cygnus.com>, 1995.
|
||||
|
||||
# serial 1
|
||||
|
||||
AC_DEFUN(AM_LC_MESSAGES,
|
||||
[if test $ac_cv_header_locale_h = yes; then
|
||||
AC_CACHE_CHECK([for LC_MESSAGES], am_cv_val_LC_MESSAGES,
|
||||
[AC_TRY_LINK([#include <locale.h>], [return LC_MESSAGES],
|
||||
am_cv_val_LC_MESSAGES=yes, am_cv_val_LC_MESSAGES=no)])
|
||||
if test $am_cv_val_LC_MESSAGES = yes; then
|
||||
AC_DEFINE(HAVE_LC_MESSAGES)
|
||||
fi
|
||||
fi])
|
||||
38
m4/lispdir.m4
Normal file
38
m4/lispdir.m4
Normal file
@@ -0,0 +1,38 @@
|
||||
## ------------------------
|
||||
## Emacs LISP file handling
|
||||
## From Ulrich Drepper
|
||||
## ------------------------
|
||||
|
||||
# serial 1
|
||||
|
||||
AC_DEFUN(AM_PATH_LISPDIR,
|
||||
[# If set to t, that means we are running in a shell under Emacs.
|
||||
# If you have an Emacs named "t", then use the full path.
|
||||
test "$EMACS" = t && EMACS=
|
||||
AC_PATH_PROG(EMACS, emacs xemacs, no)
|
||||
if test $EMACS != "no"; then
|
||||
AC_MSG_CHECKING([where .elc files should go])
|
||||
dnl Set default value
|
||||
lispdir="\$(datadir)/emacs/site-lisp"
|
||||
if test "x$prefix" = "xNONE"; then
|
||||
if test -d $ac_default_prefix/share/emacs/site-lisp; then
|
||||
lispdir="\$(prefix)/share/emacs/site-lisp"
|
||||
else
|
||||
if test -d $ac_default_prefix/lib/emacs/site-lisp; then
|
||||
lispdir="\$(prefix)/lib/emacs/site-lisp"
|
||||
fi
|
||||
fi
|
||||
else
|
||||
if test -d $prefix/share/emacs/site-lisp; then
|
||||
lispdir="\$(prefix)/share/emacs/site-lisp"
|
||||
else
|
||||
if test -d $prefix/lib/emacs/site-lisp; then
|
||||
lispdir="\$(prefix)/lib/emacs/site-lisp"
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
AC_MSG_RESULT($lispdir)
|
||||
ELCFILES="\$(ELCFILES)"
|
||||
fi
|
||||
AC_SUBST(lispdir)
|
||||
AC_SUBST(ELCFILES)])
|
||||
22
m4/maintainer.m4
Normal file
22
m4/maintainer.m4
Normal file
@@ -0,0 +1,22 @@
|
||||
# Add --enable-maintainer-mode option to configure.
|
||||
# From Jim Meyering
|
||||
|
||||
# serial 1
|
||||
|
||||
AC_DEFUN(AM_MAINTAINER_MODE,
|
||||
[AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
|
||||
dnl maintainer-mode is disabled by default
|
||||
AC_ARG_ENABLE(maintainer-mode,
|
||||
[ --enable-maintainer-mode enable make rules and dependencies not useful
|
||||
(and sometimes confusing) to the casual installer],
|
||||
USE_MAINTAINER_MODE=$enableval,
|
||||
USE_MAINTAINER_MODE=no)
|
||||
AC_MSG_RESULT($USE_MAINTAINER_MODE)
|
||||
if test $USE_MAINTAINER_MODE = yes; then
|
||||
MAINT=
|
||||
else
|
||||
MAINT='#M#'
|
||||
fi
|
||||
AC_SUBST(MAINT)dnl
|
||||
]
|
||||
)
|
||||
13
m4/memcmp.m4
Normal file
13
m4/memcmp.m4
Normal file
@@ -0,0 +1,13 @@
|
||||
#serial 1
|
||||
|
||||
dnl If you use this macro in a package, you should
|
||||
dnl add the following two lines to acconfig.h:
|
||||
dnl /* Define to rpl_memcmp if the replacement function should be used. */
|
||||
dnl #undef memcmp
|
||||
dnl
|
||||
AC_DEFUN(jm_FUNC_MEMCMP,
|
||||
[AC_REQUIRE([AC_FUNC_MEMCMP])dnl
|
||||
if test $ac_cv_func_memcmp_clean = no; then
|
||||
AC_DEFINE_UNQUOTED(memcmp, rpl_memcmp)
|
||||
fi
|
||||
])
|
||||
75
m4/mktime.m4
Normal file
75
m4/mktime.m4
Normal file
@@ -0,0 +1,75 @@
|
||||
#serial 2
|
||||
|
||||
dnl From Jim Meyering.
|
||||
dnl FIXME: this should migrate into libit.
|
||||
|
||||
AC_DEFUN(AM_FUNC_MKTIME,
|
||||
[AC_REQUIRE([AC_HEADER_TIME])dnl
|
||||
AC_CHECK_HEADERS(sys/time.h)
|
||||
AC_CACHE_CHECK([for working mktime], am_cv_func_working_mktime,
|
||||
[AC_TRY_RUN(
|
||||
changequote(<<, >>)dnl
|
||||
<</* Test program from Paul Eggert (eggert@twinsun.com)
|
||||
and Tony Leneis (tony@plaza.ds.adp.com). */
|
||||
#if TIME_WITH_SYS_TIME
|
||||
# include <sys/time.h>
|
||||
# include <time.h>
|
||||
#else
|
||||
# if HAVE_SYS_TIME_H
|
||||
# include <sys/time.h>
|
||||
# else
|
||||
# include <time.h>
|
||||
# endif
|
||||
#endif
|
||||
|
||||
static time_t time_t_max;
|
||||
|
||||
/* Values we'll use to set the TZ environment variable. */
|
||||
static const char *const tz_strings[] = {
|
||||
NULL, "GMT0", "JST-9", "EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00"
|
||||
};
|
||||
#define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
|
||||
|
||||
static void
|
||||
mktime_test (now)
|
||||
time_t now;
|
||||
{
|
||||
if (mktime (localtime (&now)) != now)
|
||||
exit (1);
|
||||
now = time_t_max - now;
|
||||
if (mktime (localtime (&now)) != now)
|
||||
exit (1);
|
||||
}
|
||||
|
||||
int
|
||||
main ()
|
||||
{
|
||||
time_t t, delta;
|
||||
int i;
|
||||
|
||||
for (time_t_max = 1; 0 < time_t_max; time_t_max *= 2)
|
||||
continue;
|
||||
time_t_max--;
|
||||
delta = time_t_max / 997; /* a suitable prime number */
|
||||
for (i = 0; i < N_STRINGS; i++)
|
||||
{
|
||||
if (tz_strings[i])
|
||||
putenv (tz_strings[i]);
|
||||
|
||||
for (t = 0; t <= time_t_max - delta; t += delta)
|
||||
mktime_test (t);
|
||||
mktime_test ((time_t) 60 * 60);
|
||||
mktime_test ((time_t) 60 * 60 * 24);
|
||||
}
|
||||
exit (0);
|
||||
}
|
||||
>>,
|
||||
changequote([, ])dnl
|
||||
am_cv_func_working_mktime=yes, am_cv_func_working_mktime=no,
|
||||
dnl When crosscompiling, assume mktime is missing or broken.
|
||||
am_cv_func_working_mktime=no)
|
||||
])
|
||||
if test $am_cv_func_working_mktime = no; then
|
||||
LIBOBJS="$LIBOBJS mktime.o"
|
||||
fi
|
||||
])
|
||||
15
m4/obstack.m4
Normal file
15
m4/obstack.m4
Normal file
@@ -0,0 +1,15 @@
|
||||
dnl From Jim Meyering.
|
||||
dnl FIXME: migrate into libit.
|
||||
|
||||
AC_DEFUN(AM_FUNC_OBSTACK,
|
||||
[AC_CACHE_CHECK([for obstacks], am_cv_func_obstack,
|
||||
[AC_TRY_LINK([#include "obstack.h"],
|
||||
[struct obstack *mem;obstack_free(mem,(char *) 0)],
|
||||
am_cv_func_obstack=yes,
|
||||
am_cv_func_obstack=no)])
|
||||
if test $am_cv_func_obstack = yes; then
|
||||
AC_DEFINE(HAVE_OBSTACK)
|
||||
else
|
||||
LIBOBJS="$LIBOBJS obstack.o"
|
||||
fi
|
||||
])
|
||||
42
m4/progtest.m4
Normal file
42
m4/progtest.m4
Normal file
@@ -0,0 +1,42 @@
|
||||
# Search path for a program which passes the given test.
|
||||
# Ulrich Drepper <drepper@cygnus.com>, 1996.
|
||||
|
||||
# serial 1
|
||||
|
||||
dnl AM_PATH_PROG_WITH_TEST(VARIABLE, PROG-TO-CHECK-FOR,
|
||||
dnl TEST-PERFORMED-ON-FOUND_PROGRAM [, VALUE-IF-NOT-FOUND [, PATH]])
|
||||
AC_DEFUN(AM_PATH_PROG_WITH_TEST,
|
||||
[# Extract the first word of "$2", so it can be a program name with args.
|
||||
set dummy $2; ac_word=[$]2
|
||||
AC_MSG_CHECKING([for $ac_word])
|
||||
AC_CACHE_VAL(ac_cv_path_$1,
|
||||
[case "[$]$1" in
|
||||
/*)
|
||||
ac_cv_path_$1="[$]$1" # Let the user override the test with a path.
|
||||
;;
|
||||
*)
|
||||
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
|
||||
for ac_dir in ifelse([$5], , $PATH, [$5]); do
|
||||
test -z "$ac_dir" && ac_dir=.
|
||||
if test -f $ac_dir/$ac_word; then
|
||||
if [$3]; then
|
||||
ac_cv_path_$1="$ac_dir/$ac_word"
|
||||
break
|
||||
fi
|
||||
fi
|
||||
done
|
||||
IFS="$ac_save_ifs"
|
||||
dnl If no 4th arg is given, leave the cache variable unset,
|
||||
dnl so AC_PATH_PROGS will keep looking.
|
||||
ifelse([$4], , , [ test -z "[$]ac_cv_path_$1" && ac_cv_path_$1="$4"
|
||||
])dnl
|
||||
;;
|
||||
esac])dnl
|
||||
$1="$ac_cv_path_$1"
|
||||
if test -n "[$]$1"; then
|
||||
AC_MSG_RESULT([$]$1)
|
||||
else
|
||||
AC_MSG_RESULT(no)
|
||||
fi
|
||||
AC_SUBST($1)dnl
|
||||
])
|
||||
25
m4/protos.m4
Normal file
25
m4/protos.m4
Normal file
@@ -0,0 +1,25 @@
|
||||
## ------------------------------- ##
|
||||
## Check for function prototypes. ##
|
||||
## From Franc,ois Pinard ##
|
||||
## ------------------------------- ##
|
||||
|
||||
# serial 1
|
||||
|
||||
AC_DEFUN(AM_C_PROTOTYPES,
|
||||
[AC_REQUIRE([AM_PROG_CC_STDC])
|
||||
AC_BEFORE([$0], [AC_C_INLINE])
|
||||
AC_MSG_CHECKING([for function prototypes])
|
||||
if test "$am_cv_prog_cc_stdc" != no; then
|
||||
AC_MSG_RESULT(yes)
|
||||
AC_DEFINE(PROTOTYPES)
|
||||
U= ANSI2KNR=
|
||||
else
|
||||
AC_MSG_RESULT(no)
|
||||
U=_ ANSI2KNR=./ansi2knr
|
||||
# Ensure some checks needed by ansi2knr itself.
|
||||
AC_HEADER_STDC
|
||||
AC_CHECK_HEADERS(string.h)
|
||||
fi
|
||||
AC_SUBST(U)dnl
|
||||
AC_SUBST(ANSI2KNR)dnl
|
||||
])
|
||||
12
m4/ptrdiff.m4
Normal file
12
m4/ptrdiff.m4
Normal file
@@ -0,0 +1,12 @@
|
||||
# From Ulrich Drepper.
|
||||
|
||||
# serial 1
|
||||
|
||||
AC_DEFUN(AM_TYPE_PTRDIFF_T,
|
||||
[AC_CACHE_CHECK([for ptrdiff_t], am_cv_type_ptrdiff_t,
|
||||
[AC_TRY_COMPILE([#include <stddef.h>], [ptrdiff_t p],
|
||||
am_cv_type_ptrdiff_t=yes, am_cv_type_ptrdiff_t=no)])
|
||||
if test $am_cv_type_ptrdiff_t = yes; then
|
||||
AC_DEFINE(HAVE_PTRDIFF_T)
|
||||
fi
|
||||
])
|
||||
37
m4/regex.m4
Normal file
37
m4/regex.m4
Normal file
@@ -0,0 +1,37 @@
|
||||
## --------------------------------- ##
|
||||
## Check if --with-regex was given. ##
|
||||
## --------------------------------- ##
|
||||
|
||||
# serial 1
|
||||
|
||||
# The idea is to distribute rx.[hc] and regex.[hc] together, for a while.
|
||||
# The WITH_REGEX symbol (which should also be documented in acconfig.h)
|
||||
# is used to decide which of regex.h or rx.h should be included in the
|
||||
# application. If `./configure --with-regex' is given (the default), the
|
||||
# package will use gawk's regex. If `./configure --without-regex', a
|
||||
# check is made to see if rx is already installed, as with newer Linux'es.
|
||||
# If not found, the package will use the rx from the distribution.
|
||||
# If found, the package will use the system's rx which, on Linux at least,
|
||||
# will result in a smaller executable file.
|
||||
|
||||
AC_DEFUN(AM_WITH_REGEX,
|
||||
[AC_MSG_CHECKING(which of GNU rx or gawk's regex is wanted)
|
||||
AC_ARG_WITH(regex,
|
||||
[ --without-regex use GNU rx in lieu of gawk's regex for matching],
|
||||
[test "$withval" = yes && am_with_regex=1],
|
||||
[am_with_regex=1])
|
||||
if test -n "$am_with_regex"; then
|
||||
AC_MSG_RESULT(regex)
|
||||
AC_DEFINE(WITH_REGEX)
|
||||
AC_CACHE_CHECK([for GNU regex in libc], am_cv_gnu_regex,
|
||||
AC_TRY_LINK([], [extern int re_max_failures; re_max_failures = 1],
|
||||
am_cv_gnu_regex=yes, am_cv_gnu_regex=no))
|
||||
if test $am_cv_gnu_regex = no; then
|
||||
LIBOBJS="$LIBOBJS regex.o"
|
||||
fi
|
||||
else
|
||||
AC_MSG_RESULT(rx)
|
||||
AC_CHECK_FUNC(re_rx_search, , [LIBOBJS="$LIBOBJS rx.o"])
|
||||
fi
|
||||
AC_SUBST(LIBOBJS)dnl
|
||||
])
|
||||
19
m4/sanity.m4
Normal file
19
m4/sanity.m4
Normal file
@@ -0,0 +1,19 @@
|
||||
#
|
||||
# Check to make sure that the build environment is sane.
|
||||
#
|
||||
|
||||
AC_DEFUN(AM_SANITY_CHECK,
|
||||
[AC_MSG_CHECKING([whether build environment is sane])
|
||||
echo timestamp > conftestfile
|
||||
# Do this in a subshell so we don't clobber the current shell's
|
||||
# arguments. FIXME: maybe try `-L' hack like GETLOADAVG test?
|
||||
if (set X `ls -t $srcdir/configure conftestfile`; test "[$]2" = conftestfile)
|
||||
then
|
||||
# Ok.
|
||||
:
|
||||
else
|
||||
AC_MSG_ERROR([newly created file is older than distributed files!
|
||||
Check your system clock])
|
||||
fi
|
||||
rm -f conftest*
|
||||
AC_MSG_RESULT(yes)])
|
||||
125
m4/strftime.m4
Normal file
125
m4/strftime.m4
Normal file
@@ -0,0 +1,125 @@
|
||||
#serial 3
|
||||
|
||||
dnl From Jim Meyering.
|
||||
dnl If you use this macro in a package, you should
|
||||
dnl add the following two lines to acconfig.h:
|
||||
dnl /* Define to gnu_strftime if the replacement function should be used. */
|
||||
dnl #undef strftime
|
||||
dnl
|
||||
AC_DEFUN(jm_FUNC_GNU_STRFTIME,
|
||||
[AC_REQUIRE([AC_HEADER_TIME])dnl
|
||||
AC_REQUIRE([AC_C_CONST])dnl
|
||||
AC_REQUIRE([AC_HEADER_STDC])dnl
|
||||
AC_CHECK_HEADERS(sys/time.h)
|
||||
AC_CACHE_CHECK([for working GNU strftime], jm_cv_func_working_gnu_strftime,
|
||||
[AC_TRY_RUN(
|
||||
changequote(<<, >>)dnl
|
||||
<< /* Ulrich Drepper provided parts of the test program. */
|
||||
#if STDC_HEADERS
|
||||
# include <stdlib.h>
|
||||
#endif
|
||||
|
||||
#if TIME_WITH_SYS_TIME
|
||||
# include <sys/time.h>
|
||||
# include <time.h>
|
||||
#else
|
||||
# if HAVE_SYS_TIME_H
|
||||
# include <sys/time.h>
|
||||
# else
|
||||
# include <time.h>
|
||||
# endif
|
||||
#endif
|
||||
|
||||
static int
|
||||
compare (const char *fmt, const struct tm *tm, const char *expected)
|
||||
{
|
||||
char buf[99];
|
||||
strftime (buf, 99, fmt, tm);
|
||||
if (strcmp (buf, expected))
|
||||
{
|
||||
#ifdef SHOW_FAILURES
|
||||
printf ("fmt: \"%s\", expected \"%s\", got \"%s\"\n",
|
||||
fmt, expected, buf);
|
||||
#endif
|
||||
return 1;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
int
|
||||
main ()
|
||||
{
|
||||
int n_fail = 0;
|
||||
struct tm *tm;
|
||||
time_t t = 738367; /* Fri Jan 9 13:06:07 1970 */
|
||||
tm = gmtime (&t);
|
||||
|
||||
/* This is necessary to make strftime give consistent zone strings and
|
||||
e.g., seconds since the epoch (%s). */
|
||||
putenv ("TZ=GMT0");
|
||||
|
||||
#undef CMP
|
||||
#define CMP(Fmt, Expected) n_fail += compare ((Fmt), tm, (Expected))
|
||||
|
||||
CMP ("%-m", "1"); /* GNU */
|
||||
CMP ("%A", "Friday");
|
||||
CMP ("%^A", "FRIDAY"); /* The ^ is a GNU extension. */
|
||||
CMP ("%B", "January");
|
||||
CMP ("%^B", "JANUARY");
|
||||
CMP ("%C", "19"); /* POSIX.2 */
|
||||
CMP ("%D", "01/09/70"); /* POSIX.2 */
|
||||
CMP ("%G", "1970"); /* GNU */
|
||||
CMP ("%H", "13");
|
||||
CMP ("%I", "01");
|
||||
CMP ("%M", "06");
|
||||
CMP ("%M", "06");
|
||||
CMP ("%R", "13:06"); /* POSIX.2 */
|
||||
CMP ("%S", "07");
|
||||
CMP ("%T", "13:06:07"); /* POSIX.2 */
|
||||
CMP ("%U", "01");
|
||||
CMP ("%V", "02");
|
||||
CMP ("%W", "01");
|
||||
CMP ("%X", "13:06:07");
|
||||
CMP ("%Y", "1970");
|
||||
CMP ("%Z", "GMT");
|
||||
CMP ("%_m", " 1"); /* GNU */
|
||||
CMP ("%a", "Fri");
|
||||
CMP ("%^a", "FRI");
|
||||
CMP ("%b", "Jan");
|
||||
CMP ("%^b", "JAN");
|
||||
CMP ("%c", "Fri Jan 9 13:06:07 1970");
|
||||
CMP ("%^c", "FRI JAN 9 13:06:07 1970");
|
||||
CMP ("%d", "09");
|
||||
CMP ("%e", " 9"); /* POSIX.2 */
|
||||
CMP ("%g", "70"); /* GNU */
|
||||
CMP ("%h", "Jan"); /* POSIX.2 */
|
||||
CMP ("%^h", "JAN");
|
||||
CMP ("%j", "009");
|
||||
CMP ("%k", "13"); /* GNU */
|
||||
CMP ("%l", " 1"); /* GNU */
|
||||
CMP ("%m", "01");
|
||||
CMP ("%n", "\n"); /* POSIX.2 */
|
||||
CMP ("%p", "PM");
|
||||
CMP ("%r", "01:06:07 PM"); /* POSIX.2 */
|
||||
CMP ("%s", "738367"); /* GNU */
|
||||
CMP ("%t", "\t"); /* POSIX.2 */
|
||||
CMP ("%u", "5"); /* POSIX.2 */
|
||||
CMP ("%w", "5");
|
||||
CMP ("%x", "01/09/70");
|
||||
CMP ("%y", "70");
|
||||
CMP ("%z", "+0000"); /* GNU */
|
||||
|
||||
exit (n_fail ? 1 : 0);
|
||||
}
|
||||
>>,
|
||||
changequote([, ])dnl
|
||||
jm_cv_func_working_gnu_strftime=yes,
|
||||
jm_cv_func_working_gnu_strftime=no,
|
||||
dnl When crosscompiling, assume strftime is missing or broken.
|
||||
jm_cv_func_working_gnu_strftime=no)
|
||||
])
|
||||
if test $jm_cv_func_working_gnu_strftime = no; then
|
||||
LIBOBJS="$LIBOBJS strftime.o"
|
||||
AC_DEFINE_UNQUOTED(strftime, gnu_strftime)
|
||||
fi
|
||||
])
|
||||
69
m4/strtod.m4
Normal file
69
m4/strtod.m4
Normal file
@@ -0,0 +1,69 @@
|
||||
## Copyright (C) 1996 Free Software Foundation, Inc.
|
||||
|
||||
## This program is free software; you can redistribute it and/or modify
|
||||
## it under the terms of the GNU General Public License as published by
|
||||
## the Free Software Foundation; either version 2, or (at your option)
|
||||
## any later version.
|
||||
|
||||
## This program is distributed in the hope that it will be useful,
|
||||
## but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
## GNU General Public License for more details.
|
||||
|
||||
## You should have received a copy of the GNU General Public License
|
||||
## along with this program; if not, write to the Free Software
|
||||
## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
|
||||
## 02111-1307, USA.
|
||||
|
||||
## From Jim Meyering.
|
||||
|
||||
## serial 1
|
||||
|
||||
## @defmac AC_FUNC_STRTOD
|
||||
## @maindex FUNC_STRTOD
|
||||
## @ovindex LIBOBJS
|
||||
## If the @code{strtod} function is not available, or does not work
|
||||
## correctly (like the one on SunOS 5.4), add @samp{strtod.o} to output
|
||||
## variable @code{LIBOBJS}.
|
||||
## @end defmac
|
||||
|
||||
AC_DEFUN(AM_FUNC_STRTOD,
|
||||
[AC_CACHE_CHECK(for working strtod, am_cv_func_strtod,
|
||||
[AC_TRY_RUN([
|
||||
double strtod ();
|
||||
int
|
||||
main()
|
||||
{
|
||||
{
|
||||
/* Some versions of Linux strtod mis-parse strings with leading '+'. */
|
||||
char *string = " +69";
|
||||
char *term;
|
||||
double value;
|
||||
value = strtod (string, &term);
|
||||
if (value != 69 || term != (string + 4))
|
||||
exit (1);
|
||||
}
|
||||
|
||||
{
|
||||
/* Under Solaris 2.4, strtod returns the wrong value for the
|
||||
terminating character under some conditions. */
|
||||
char *string = "NaN";
|
||||
char *term;
|
||||
strtod (string, &term);
|
||||
if (term != string && *(term - 1) == 0)
|
||||
exit (1);
|
||||
}
|
||||
exit (0);
|
||||
}
|
||||
], am_cv_func_strtod=yes, am_cv_func_strtod=no, am_cv_func_strtod=no)])
|
||||
test $am_cv_func_strtod = no && LIBOBJS="$LIBOBJS strtod.o"
|
||||
AC_SUBST(LIBOBJS)dnl
|
||||
am_cv_func_strtod_needs_libm=no
|
||||
if test $am_cv_func_strtod = no; then
|
||||
AC_CHECK_FUNCS(pow)
|
||||
if test $ac_cv_func_pow = no; then
|
||||
AC_CHECK_LIB(m, pow, [am_cv_func_strtod_needs_libm=yes],
|
||||
[AC_MSG_WARN(can't find library containing definition of pow)])
|
||||
fi
|
||||
fi
|
||||
])
|
||||
14
m4/termios.m4
Normal file
14
m4/termios.m4
Normal file
@@ -0,0 +1,14 @@
|
||||
dnl From Jim Meyering.
|
||||
|
||||
# serial 1
|
||||
|
||||
AC_DEFUN(AM_SYS_POSIX_TERMIOS,
|
||||
[AC_CACHE_CHECK([POSIX termios], am_cv_sys_posix_termios,
|
||||
[AC_TRY_LINK([#include <sys/types.h>
|
||||
#include <unistd.h>
|
||||
#include <termios.h>],
|
||||
[/* SunOS 4.0.3 has termios.h but not the library calls. */
|
||||
tcgetattr(0, 0);],
|
||||
am_cv_sys_posix_termios=yes,
|
||||
am_cv_sys_posix_termios=no)])
|
||||
])
|
||||
15
m4/uptime.m4
Normal file
15
m4/uptime.m4
Normal file
@@ -0,0 +1,15 @@
|
||||
#serial 1
|
||||
|
||||
AC_DEFUN(jm_SYS_PROC_UPTIME,
|
||||
[ dnl Require AC_PROG_CC to see if we're cross compiling.
|
||||
AC_REQUIRE([AC_PROG_CC])
|
||||
AC_CACHE_CHECK([for /proc/uptime], jm_cv_have_proc_uptime,
|
||||
[jm_cv_have_proc_uptime=no
|
||||
test -f /proc/uptime \
|
||||
&& test $ac_cv_prog_cc_cross = no \
|
||||
&& cat < /proc/uptime >/dev/null 2>/dev/null \
|
||||
&& jm_cv_have_proc_uptime=yes])
|
||||
if test $jm_cv_have_proc_uptime = yes; then
|
||||
AC_DEFINE(HAVE_PROC_UPTIME)
|
||||
fi
|
||||
])
|
||||
35
m4/winsz.m4
Normal file
35
m4/winsz.m4
Normal file
@@ -0,0 +1,35 @@
|
||||
dnl From Jim Meyering.
|
||||
|
||||
# serial 1
|
||||
|
||||
AC_DEFUN(AM_HEADER_TIOCGWINSZ_NEEDS_SYS_IOCTL,
|
||||
[AC_REQUIRE([AM_SYS_POSIX_TERMIOS])
|
||||
AC_CACHE_CHECK([whether use of TIOCGWINSZ requires sys/ioctl.h],
|
||||
am_cv_sys_tiocgwinsz_needs_sys_ioctl_h,
|
||||
[am_cv_sys_tiocgwinsz_needs_sys_ioctl_h=no
|
||||
|
||||
gwinsz_in_termios_h=no
|
||||
if test $am_cv_sys_posix_termios = yes; then
|
||||
AC_EGREP_CPP([yes],
|
||||
[#include <sys/types.h>
|
||||
# include <termios.h>
|
||||
# ifdef TIOCGWINSZ
|
||||
yes
|
||||
# endif
|
||||
], gwinsz_in_termios_h=yes)
|
||||
fi
|
||||
|
||||
if test $gwinsz_in_termios_h = no; then
|
||||
AC_EGREP_CPP([yes],
|
||||
[#include <sys/types.h>
|
||||
# include <sys/ioctl.h>
|
||||
# ifdef TIOCGWINSZ
|
||||
yes
|
||||
# endif
|
||||
], am_cv_sys_tiocgwinsz_needs_sys_ioctl_h=yes)
|
||||
fi
|
||||
])
|
||||
if test $am_cv_sys_tiocgwinsz_needs_sys_ioctl_h = yes; then
|
||||
AC_DEFINE(GWINSZ_IN_SYS_IOCTL)
|
||||
fi
|
||||
])
|
||||
@@ -1,3 +1,393 @@
|
||||
Sun Jan 26 20:17:50 1997 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* Version 3.16.
|
||||
|
||||
* acconfig.h (strftime): Add #undef. From Marcus Daniels.
|
||||
|
||||
Sat Jan 25 00:34:39 1997 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/du.c (count_entry): Fix blatant bug (typo?) that made
|
||||
--megabytes report numbers in units of kilobytes.
|
||||
Reported by Galen Hazelwood.
|
||||
|
||||
* src/cp.h: Remove now-unnecessary prototype for is_ancestor.
|
||||
|
||||
* lib/Makefile.am (noinst_HEADERS): Add getdate.h.
|
||||
|
||||
* src/cp-aux.c (is_ancestor): Remove function.
|
||||
* src/cp.c (is_ancestor): Add function.
|
||||
|
||||
* src/cp.h: Remove spurious extern dcl of htab.
|
||||
|
||||
* m4/getgroups.m4: Move the code from configure.in into
|
||||
this macro that resorts to looking for getgroups in -lbsd.
|
||||
Set new shell variable, GETGROUPS_LIB (that callers should check),
|
||||
if it is found there.
|
||||
* configure.in: Check $GETGROUPS_LIB just after jm_FUNC_GETGROUPS.
|
||||
(AC_CHECK_FUNCS): Remove getgroups.
|
||||
Remove code that resorts to looking for getgroups in -lbsd.
|
||||
|
||||
* configure.in (jm_FUNC_GNU_STRFTIME): Use it -- because ls
|
||||
needs a version of strftime that supports the %e format and
|
||||
pretty many systems lack that: NextStep 3.3, Mips Ultrix ?.?.
|
||||
This is a little bit overkill (for now) in that if the strftime
|
||||
in your C library doesn't have all features of GNU strftime (even
|
||||
though it may support %e) ls will be linked with the version of
|
||||
strftime provided with this package. But for an upcoming release,
|
||||
GNU ls will provide an option to allow the user to specify the
|
||||
date format string -- and for that I want to make GNU strftime
|
||||
the default in any case. Think of this as an incentive to use
|
||||
the GNU C library.
|
||||
|
||||
Fri Jan 24 23:36:00 1997 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* lib/long-options.c (parse_long_options): Reset optind to zero
|
||||
before just returning so that getopt internals get initialized from
|
||||
the probably-new parameters when/if getopt is called later.
|
||||
From Ulrich Drepper.
|
||||
|
||||
Mon Jan 20 06:52:09 1997 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* configure.in (fu_cv_sys_truncating_statfs): Add preprocessor
|
||||
guard to make sure that this test for Sun brokenness doesn't
|
||||
get a false positive on any other type of system. Eirik Fuller
|
||||
reported that Linux 2.1.20 <sys/vfs.h> has a f_spare member in
|
||||
the statfs struct. And that triggered a false positive.
|
||||
|
||||
Thu Jan 9 06:23:18 1997 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* m4/gettext.m4: Remove AC_ISC_POSIX. From Karl Heuer.
|
||||
|
||||
Wed Jan 8 16:38:24 1997 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* Version 3.15.
|
||||
|
||||
* src/ls.c (print_long_format): Cast alloca return value to char*.
|
||||
|
||||
* lib/getopt.c (_getopt_internal): Use `_', rather than the
|
||||
(sometimes-)expansion `gettext'.
|
||||
|
||||
Tue Jan 7 22:49:55 1997 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* lib/getopt.c: New (more POSIX compliant) version from GNU libc.
|
||||
[_]: Define to gettext also if ENABLE_NLS is defined.
|
||||
This is temporary.
|
||||
|
||||
Sun Jan 5 09:33:07 1997 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/ls.c (print_long_format): Avoid making unnecessary copy of
|
||||
date/time string. Patch from Paul Eggert.
|
||||
(print_long_format): NUL-terminate line of output.
|
||||
(print_long_format): Detect and handle strftime failure
|
||||
due to pathologically long strings in locale tables.
|
||||
Patch from Paul Eggert.
|
||||
(print_long_format): Change references to BIGBUF in use of
|
||||
FPUTS macro to references to BUF.
|
||||
Use 11 (not 20) bytes for mode string buffer.
|
||||
|
||||
Sat Jan 4 21:14:36 1997 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/ls.c (print_long_format): Clean up vestiges of legacy
|
||||
ctime-oriented code. With internationalization and strftime,
|
||||
you can't presume that %a expands to a 3-byte string.
|
||||
Reported by Ross Ridge.
|
||||
(print_long_format): Use POSIX-mandated %e (blank-padded numeric
|
||||
day of month), not %d (the same number, but *zero*-filled).
|
||||
|
||||
Fri Jan 3 21:08:29 1997 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* acconfig.h (getgroups): Add #undef.
|
||||
From Marcus Daniels.
|
||||
|
||||
Thu Jan 2 21:16:16 1997 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* lib/Makefile.am (EXTRA_DIST): Add getgroups.c.
|
||||
|
||||
Wed Jan 1 17:30:26 1997 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* lib/getgroups.c: New file.
|
||||
|
||||
* configure.in (AC_ARG_PROGRAM): Remove explicit use.
|
||||
It's implicit in AM_INIT_AUTOMAKE. From Wayne Stewart.
|
||||
(list_mounted_fs): Fix typo (by declaring NUMSYS) in test for
|
||||
getfsstat on osf1. From hitchens@epa001.enet.dec.com.
|
||||
|
||||
Sun Dec 29 21:55:13 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* configure.in (jm_FUNC_GETGROUPS): Use it.
|
||||
|
||||
Sat Dec 28 14:32:05 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/ls.c: Two problems fixed by these changes from Joakim Rosqvist.
|
||||
Quoting Joakim:
|
||||
1) The "total" number and the size of the first file as
|
||||
output from 'ls --color -s' did not get colorized according
|
||||
to the "no"-argument in LS_COLORS. Fixed by adding a function
|
||||
prep_non_filename_text which prints the C_LEFT C_NORM C_RIGHT
|
||||
strings (or C_END). It is called from main before any text is
|
||||
output, and from print_name_with_quoting after having output a
|
||||
colorized filename.
|
||||
2) If the "no"-argument of LS_COLORS is set, the terminal will be
|
||||
set to print in that color after ls exits. The man-pages suggests
|
||||
setting "no" and "fi" to the terminals default colors to avoid
|
||||
the problem, but that would mean I can't use anything but the
|
||||
default color for regular files and non-filename text. Fixed by
|
||||
outputting C_LEFT immediately followed by C_RIGHT right before
|
||||
exit, which restores the default color.
|
||||
|
||||
Fri Dec 27 17:29:02 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* Makefile.am (aclocal.m4): No longer depend on acinclude.m4.
|
||||
|
||||
* configure.in: AC_REQUIRE version 2.12 of autoconf.
|
||||
|
||||
Sun Dec 22 23:29:10 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* acinclude.m4: Move macros to individual files in new directory, m4/.
|
||||
See ChangeLog entries in sh-utils for the details.
|
||||
|
||||
Wed Dec 18 23:09:19 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/dircolors.hin (ORPHAN): By default, color orphans red on
|
||||
a black background.
|
||||
|
||||
* src/dircolors.c (usage): Remove --print-data-base.
|
||||
Now only --print-database remains. Although it wasn't documented,
|
||||
--print-data-base was still accepted. But it made `--p', `--print',
|
||||
`--print-data', etc. ambiguous.
|
||||
|
||||
* src/ls.c (gobble_file): Stat symlinks also when printing with
|
||||
color and set linkok to reflect existence of referent.
|
||||
Patches from Joakim Rosqvist, James Antill, and Jesse Thilo.
|
||||
|
||||
Tue Dec 17 21:03:40 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/system.h (ISDIGIT): Replace with smaller, faster edition
|
||||
that yields nonzero only on ASCII digits.
|
||||
(ISDIGIT_LOCALE): New macro, with same meaning that ISDIGIT
|
||||
used to have. From Paul Eggert.
|
||||
* lib/backupfile.c (ISDIGIT): Likewise.
|
||||
* lib/getdate.y (ISDIGIT): Likewise.
|
||||
|
||||
* src/cp.c (ROOT_CHOWN_AFFECTS_SYMLINKS): New macro.
|
||||
(DO_CHOWN): Take an additional parameter.
|
||||
(LINK_CHOWN): Remove macro.
|
||||
(copy): When preserving owner and group of a symlink, use
|
||||
chown only if ROOT_CHOWN_AFFECTS_SYMLINKS and EUID == 0.
|
||||
Otherwise, the chown would affect the file referenced through
|
||||
the symlink.
|
||||
|
||||
Sat Dec 14 14:51:50 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* acinclude.m4 (jm_SYS_PROC_UPTIME): Fix typo in cache variable
|
||||
name for cross compiling.
|
||||
Remove definitions of gettext-related macros. The gettext
|
||||
installation procedure installs corresponding .m4 files so that
|
||||
aclocal will use them.
|
||||
|
||||
Wed Dec 11 19:34:22 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* Version 3.14.
|
||||
|
||||
Tue Dec 10 00:14:24 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* configure.in: Bump version to 3.13k.
|
||||
|
||||
* src/install.c [_POSIX_VERSION]: Don't declare wait. That
|
||||
declaration conflicted with one in a system header file on
|
||||
i386-pc-isc3.0, now that I've removed the AC_ISC_POSIX macro
|
||||
and _POSIX_VERSION is no longer defined.
|
||||
Reported by Karl Heuer.
|
||||
|
||||
* configure.in (AC_ISC_POSIX): Remove kludgy macro.
|
||||
Use this test instead:
|
||||
(LIBS): Add -lcposix if it contains strerror.
|
||||
Patch from Karl Heuer.
|
||||
|
||||
* lib/Makefile.am (EXTRA_DIST): Add mktime.c.
|
||||
Reported by Thomas Bushnell.
|
||||
* (EXTRA_DIST): Add strftime.c to appease automake.
|
||||
Although it's not used yet, it'll be used by ls's (to-be-done)
|
||||
--format=FORMAT option.
|
||||
|
||||
Mon Dec 9 18:26:54 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* lib/obstack.h: Include config.h.
|
||||
[!HAVE_BCOPY && HAVE_MEMCPY && !defined (bcopy)]: Define bcopy
|
||||
in terms of memcpy. Reported by Marcus Daniels.
|
||||
|
||||
* configure.in (LIBOBJS): After AC_FUNC_FNMATCH, add fnmatch.o
|
||||
and define fnmatch to rpl_fnmatch if necessary.
|
||||
|
||||
* acconfig.h (fnmatch): Add undef.
|
||||
|
||||
* src/df.c (find_mount_point): Convert from K&R style header to ANSI.
|
||||
Patch from Kaveh Ghazi.
|
||||
|
||||
Sun Dec 8 07:22:38 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
=========== Update for automake-1.1k.
|
||||
* Makefile.am (AUTOMAKE_OPTIONS): Require 1.1k.
|
||||
* configure.in (AM_CONFIG_HEADER): Use it.
|
||||
(AC_OUTPUT): Remove stamp-h timestamping statement.
|
||||
Now, AM_CONFIG_HEADER does it automatically.
|
||||
* lib/Makefile.am (noinst_LIBRARIES): Rename to libfu.a as per
|
||||
new automake requirement.
|
||||
Rename fu_* variables to libfu_a_*.
|
||||
|
||||
Mon Dec 2 20:30:20 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* configure.in (jm_FUNC_MKTIME): Use this instead of AM_FUNC_MKTIME.
|
||||
|
||||
* src/system.h [!S_IXUGO] (S_IXUGO): Define it.
|
||||
|
||||
* src/ls.c (print_color_indicator): Check the file's suffix only
|
||||
if it's a regular file.
|
||||
Reported by Santiago Vila Doncel.
|
||||
(print_type_indicator): Use S_IXUGO instead of writing out
|
||||
(S_IEXEC | S_IXGRP | S_IXOTH).
|
||||
(length_of_file_name_and_frills): Likewise.
|
||||
|
||||
Sun Dec 1 13:07:39 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* lib/getdate.y (date): Interpret the date, L/M/N, as YYYY/MM/DD
|
||||
if L >= 1000, otherwise as MM/DD/YY. With this change,
|
||||
date --date=DATE accepts dates like those in an RCS log listing.
|
||||
|
||||
Sat Nov 30 22:11:42 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* acinclude.m4: (jm_FUNC_MKTIME): New macro. This is like
|
||||
AM_FUNC_MKTIME, but with one addition: when it replaces the
|
||||
function, it also redefines mktime to gnu_mktime.
|
||||
|
||||
Fri Nov 29 21:19:13 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/install.c (copy_file): Allow installation from non-directory
|
||||
(rather than only regular) files. Suggestion from Charles Karney.
|
||||
|
||||
* src/df.c (main): Accept -F as a synonym for -t for compatibility
|
||||
with Solaris. From Peter Eriksson.
|
||||
|
||||
* src/ls.c (main): Close stdout and check result, in case any
|
||||
deferred writes fail.
|
||||
Use EXIT_SUCCESS and EXIT_FAILURE in exit and usage calls.
|
||||
|
||||
Thu Nov 28 13:10:22 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/df.c (find_mount_point): Use strip_trailing_slashes and dirname
|
||||
instead of open-coding them. When given FILE containing no slashes,
|
||||
chdir to the directory containing it (the current directory) rather
|
||||
than to `..'.
|
||||
|
||||
Tue Nov 5 14:51:56 1996 Miles Bader <miles@gnu.ai.mit.edu>
|
||||
|
||||
* src/df.c (find_mount_point): Use save_cwd/restore_cwd.
|
||||
"save-cwd.h": New include.
|
||||
|
||||
Wed Oct 30 00:21:16 1996 Miles Bader <miles@gnu.ai.mit.edu>
|
||||
|
||||
* lib/fsusage.c (get_fs_usage): If DISK is 0 and we needed to use
|
||||
it, return -1 with 0 in ERRNO.
|
||||
* src/df.c (show_dev): Deal with null values for DISK and FSTYPE,
|
||||
including interpreting special 0 errno return from get_fs_usage.
|
||||
(show_point): Don't fail if we can't find a mount entry for POINT,
|
||||
just call show_dev with 0 values and let it fail if necessary.
|
||||
(main): Require a non-zero MOUNT_LIST only if showing all filesystems.
|
||||
(find_mount_point): New function.
|
||||
(xgetcwd): New declaration.
|
||||
|
||||
Thu Nov 28 00:31:11 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* configure.in (AM_GNU_GETTEXT): Renamed from ud_GNU_GETTEXT
|
||||
for gettext-0.10.25.
|
||||
|
||||
Tue Nov 26 23:24:13 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* acinclude.m4: Update with macros from gettext-0.10.25.
|
||||
|
||||
Sun Nov 24 22:43:24 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* acconfig.h (mktime): Add undef for my enhanced (beyond automake's
|
||||
1.1g version of) AM_FUNC_MKTIME.
|
||||
|
||||
* acinclude.m4 (AM_FUNC_GETLINE): Use am_, not su_ prefix for
|
||||
local/cache variables.
|
||||
|
||||
Sat Nov 23 16:11:59 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* lib/Makefile.am (EXTRA_DIST): Add getline.c now that getline
|
||||
isn't mentioned in AC_REPLACE_FUNCS.
|
||||
|
||||
* lib/Makefile.am (EXTRA_DIST):
|
||||
|
||||
* chgrp.c (usage): Alphabetize option descriptions the way
|
||||
sort -f would.
|
||||
* chown.c (usage): Likewise.
|
||||
* cp-aux.c (usage): Likewise.
|
||||
* df.c (usage): Likewise.
|
||||
* install.c (usage): Likewise.
|
||||
* ln.c (usage): Likewise.
|
||||
* ls.c (usage): Likewise.
|
||||
* mkdir.c (usage): Likewise.
|
||||
* mv.c (usage): Likewise.
|
||||
* rm.c (usage): Likewise.
|
||||
From Karl Berry.
|
||||
|
||||
Fri Nov 22 22:14:10 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* configure.in (AC_REPLACE_FUNCS): Don't try to replace getline this
|
||||
way. AM_FUNC_GETLINE does it now.
|
||||
(AM_FUNC_GETLINE): Use it here.
|
||||
|
||||
* src/cp.c (copy): With -i and not -f, prompt for any type of
|
||||
(non-directory) source file before overwriting an existing target.
|
||||
Reported by Mark A. Thomas and Emile LeBlanc.
|
||||
|
||||
Tue Nov 19 23:10:32 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* configure.in (AM_SANITY_CHECK_CC): Remove it. Autoconf-2.11
|
||||
has this built-in.
|
||||
(AC_FUNC_FNMATCH): Use this macro (new with autoconf-2.11) instead
|
||||
of open-coding it.
|
||||
|
||||
Sun Nov 17 20:53:00 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/touch.c: Remove unused declaration of mktime. From Tony Leneis.
|
||||
|
||||
Mon Nov 4 23:18:03 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* configure.in (test for group_member): Handle it separately
|
||||
so I can keep the hyphen (not the underscore) in the filename.
|
||||
|
||||
* lib/rename.c: New version from François Pinard.
|
||||
|
||||
Sat Nov 2 07:05:36 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/ls.c (gobble_file): Set linkok for non-orphaned symlinks.
|
||||
From Bauke Jan Douma.
|
||||
(gobble_file): Initialize linkok.
|
||||
With these two changes, ls --color should display orphaned symlinks
|
||||
as blinking text on terminals that support it.
|
||||
|
||||
* configure.in (ALL_LINGUAS): Add Spanish (es).
|
||||
|
||||
* doc/Makefile.am (MAKEINFO): Set to makeinfo --no-split.
|
||||
Otherwise, the generated info files have names longer than
|
||||
the 14-byte max of some old systems.
|
||||
Reported by Karl Heuer.
|
||||
|
||||
Tue Oct 29 06:49:16 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/ls.c (decode_switches): Make -A set really_all_files to zero
|
||||
as well as setting all_files to 1. With this change, ls -f -A prints
|
||||
everything but . and .., unsorted. Before, the -A was effectively
|
||||
ignored. From Karl Berry.
|
||||
|
||||
Tue Oct 22 07:00:00 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/Makefile.am (dircolors.h): Depend on dcgen only in maintainer
|
||||
mode.
|
||||
|
||||
Mon Oct 21 16:52:28 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* lib/Makefile.am (EXTRA_DIST): Remove group-member.c.
|
||||
|
||||
@@ -1,7 +1,34 @@
|
||||
Changes in release 3.16:
|
||||
[3.15a]
|
||||
* du --megabytes (-m) works
|
||||
* ls -l works even on systems with non-POSIX strftime in their C library
|
||||
|
||||
Changes in release 3.15:
|
||||
* touch --date=DATE bug (due to broken getdate.y) has been fixed
|
||||
* ls -l no longer misformats the date when run in a locale for which the
|
||||
locale's abbreviated week-day name (strftime's %a format) is shorter or
|
||||
longer than the `normal' three bytes (with LANG=de it's a two-byte string).
|
||||
* Using --program-prefix no longer applies the prefix twice
|
||||
* ls --color properly restores color attributes upon completion when the
|
||||
normal (`no') color attribute is not the default color.
|
||||
* with ls -s --color, the `total' and size of the first file are printed
|
||||
* ls --color stats symlinks and distinguishes between regular symlinks
|
||||
and orphan ones.
|
||||
* cp --preserve preserves owner and group of symlinks on Linux when run
|
||||
with EUID == 0
|
||||
* dircolors no longer accepts --print-data-base (alternate spelling of
|
||||
--print-database)
|
||||
|
||||
Changes in release 3.14:
|
||||
[3.13h]
|
||||
* ls --color highlights based on suffix rules only for regular files
|
||||
* touch --date=DATE accepts dates like those in an RCS log listing, e.g.,
|
||||
`1992/11/01 05:44:34'.
|
||||
* install SRC DST no longer rejects non-regular, non-directory SRC
|
||||
* df accepts -F as a synonym for -t for compatibility with Solaris
|
||||
* cp -i /dev/null existing-file now prompts before overwriting the target
|
||||
* ls --color highlights orphaned symlinks text on terminals that support it
|
||||
* ls -l honors current locale with respect to abbreviated month names (and,
|
||||
with --full-time day names) on systems with a locale-sensitive strftime
|
||||
with --full-time day names) on systems with a locale-supporting strftime
|
||||
function, e.g., ones based on recent versions of the GNU C library
|
||||
* ls -l recognizes Cray's migrated dmf files.
|
||||
* chgrp no longer aborts when given a group number larger than INT_MAX
|
||||
|
||||
@@ -1,3 +1,599 @@
|
||||
Sun Jan 26 12:51:05 1997 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* Version 1.16.
|
||||
|
||||
* src/who-users.c (usage): Fix typo (--writeable -> --writable)
|
||||
in help output. From Galen Hazelwood.
|
||||
|
||||
Sat Jan 25 21:01:13 1997 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/factor.c (print_factors): Reflect changes to xstrtoul interface.
|
||||
|
||||
* tests/date/mk-script.pl: Generated script now reflects
|
||||
specification (in Test.pm) of default and per-test environment
|
||||
settings.
|
||||
|
||||
Fri Jan 24 23:36:00 1997 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* lib/long-options.c (parse_long_options): Reset optind to zero
|
||||
before just returning so that getopt internals get initialized from
|
||||
the probably-new parameters when/if getopt is called later.
|
||||
This solves the problem (reintroduced with 1.15) where `stty -tabs'
|
||||
would not work as advertised but instead act like `stty -a'.
|
||||
Reported by Arne Juul.
|
||||
Suggested fix from Ulrich Drepper.
|
||||
|
||||
Wed Jan 22 20:12:31 1997 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* lib/getopt.c: Update from GNU C library.
|
||||
* lib/getopt1.c: Update from GNU C library.
|
||||
* lib/getopt.h: Update from GNU C library.
|
||||
|
||||
* tests/Makefile.am (EXTRA_DIST): Add README Makefile.am.in.
|
||||
(SUBDIRS): Set to `date'.
|
||||
|
||||
* configure.in: Check for perl.
|
||||
(AC_OUTPUT): Add tests/date/Makefile.
|
||||
* tests/date: New directory.
|
||||
|
||||
* m4/getgroups.m4: Move the code from configure.in into
|
||||
this macro that resorts to looking for getgroups in -lbsd.
|
||||
Set new shell variable, GETGROUPS_LIB (that callers should check),
|
||||
if it is found there.
|
||||
* configure.in: Check $GETGROUPS_LIB just after jm_FUNC_GETGROUPS.
|
||||
(AC_CHECK_FUNCS): Remove getgroups.
|
||||
Remove code that resorts to looking for getgroups in -lbsd.
|
||||
|
||||
* m4/mktime.m4 (AM_FUNC_MKTIME): Run tests for each of a few values
|
||||
for the TZ environment variable. Andre Novaes Cunha provided the
|
||||
hairy TZ setting that exercized the Solaris tzset bug.
|
||||
|
||||
1997-01-22 Paul Eggert <eggert@twinsun.com>
|
||||
|
||||
* lib/strftime.c (_strftime_copytm):
|
||||
New function, to work around Solaris 2.5 tzset bug.
|
||||
|
||||
* m4/mktime.m4: (AM_FUNC_MKTIME): Fix bug in mktime test -- don't
|
||||
test now, test a couple of thousand times.
|
||||
|
||||
* m4/strftime.m4 (main): Use TZ=GMT0, not TZ=GMT, since only GMT0 is
|
||||
specified by Posix.1.
|
||||
|
||||
Sat Jan 18 09:32:26 1997 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* lib/getdate.y (get_date): Change prototype to reflect const'ness
|
||||
of parameters.
|
||||
Indent cpp-directives to reflect nesting.
|
||||
Indent with GNU indent.
|
||||
|
||||
* lib/getdate.h: New file.
|
||||
* src/date.c: Include getdate.h.
|
||||
(<time.h>, <sys/time.h>): Don't include -- now getdate.h does it.
|
||||
(get_date): Don't declare. getdate.h does it.
|
||||
|
||||
* lib/Makefile.am (noinst_HEADERS): Add getdate.h.
|
||||
|
||||
1997-01-06 Paul Eggert <eggert@twinsun.com>
|
||||
|
||||
* getdate.y: Rewrite to use mktime.
|
||||
|
||||
<sys/timeb.h>: Don't include.
|
||||
(mktime): Declare.
|
||||
|
||||
(struct timeb, timezone, DOOMSDAY, SECSPERDAY, DSTMODE, yyDSTmode,
|
||||
ToSeconds, Convert, DSTcorrect, RelativeDate, RelativeMonth): Remove.
|
||||
(ToHour): New function (part of the old ToSeconds fn).
|
||||
(ToYear): New function (part of the old Convert fn).
|
||||
|
||||
(TABLE.value, yyDayOrdinal, yyDayNumber, yyTimezone, yyDay, yyHour,
|
||||
yyMinutes, yyMonth, yySeconds, yyYear, yyRelMonth, yyRelSeconds,
|
||||
Number): Now int instead of time_t.
|
||||
(HOUR): Don't cast to time_t.
|
||||
|
||||
(tDAY_UNIT, tHOUR_UNIT, tYEAR_UNIT): New %tokens.
|
||||
(UnitsTable): Use new units that are closer to the keywords.
|
||||
|
||||
(yyRelDay, yyRelHour, yyRelMinutes, yyRelYear): New variables.
|
||||
(rel, relunit, get_date): Add support for them.
|
||||
|
||||
(time): Fix timezone calculations for negative half-hour offsets
|
||||
when integer division truncates towards minus infinity.
|
||||
|
||||
(zone): Incorporiate DST calculation directly.
|
||||
|
||||
(get_date): 2nd arg is now time_t *, not struct timeb *.
|
||||
Use mktime to do most of the work, instead of computing it ourselves.
|
||||
Guard against falsely reporting errors near the time_t boundaries
|
||||
when parsing times in other time zones.
|
||||
|
||||
Thu Jan 16 20:58:40 1997 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Check for pstat_getdynamic.
|
||||
* configure.in (AC_CHECK_FUNCS): Don't check for pstat_getdynamic here.
|
||||
|
||||
Tue Jan 14 22:45:36 1997 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* configure.in (AC_CHECK_FUNCS): Add pstat_getdynamic.
|
||||
Alphabetize functions.
|
||||
|
||||
* lib/getloadavg.c [hpux && HAVE_PSTAT_GETDYNAMIC]: Use HPUX's
|
||||
pstat_getdynamic function so we don't need any special privileges
|
||||
to determine load averages. Patch from Kaveh Ghazi, based on a
|
||||
sample implementation from Richard J. Rauenzahn.
|
||||
Indent cpp-directives to reflect nesting.
|
||||
|
||||
Wed Jan 8 16:38:24 1997 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* Version 1.15.
|
||||
|
||||
* lib/getopt.c (_getopt_internal): Use `_', rather than the
|
||||
(sometimes-)expansion `gettext'.
|
||||
|
||||
Tue Jan 7 22:10:51 1997 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/nice.c (main): Work around failures induced by new version of
|
||||
getopt.c by not modifying optind before the first getopt_long call
|
||||
in main. With suggestions from Ulrich Drepper.
|
||||
|
||||
* lib/getopt.c: New (more POSIX compliant) version from GNU libc.
|
||||
[_]: Define to gettext also if ENABLE_NLS is defined.
|
||||
This is temporary.
|
||||
|
||||
Fri Jan 3 21:08:29 1997 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* acconfig.h (getgroups): Add #undef.
|
||||
From Marcus Daniels.
|
||||
|
||||
Fri Dec 27 17:25:18 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/who-users.c [!WTMP_FILE]: Provide default path.
|
||||
(UTMP_FILE) [UTMPX_FILE]: Use UTMPX_FILE in favor of UTMP_FILE.
|
||||
Patch from Kaveh R. Ghazi.
|
||||
Indent cpp directives.
|
||||
|
||||
* m4/getgroups.m4: Rewrite the test so that systems lacking
|
||||
getgroups don't try to use the supplied replacement function --
|
||||
that depends on the existence of such a function.
|
||||
|
||||
* Makefile.am (aclocal.m4): No longer depend on acinclude.m4.
|
||||
|
||||
* configure.in (jm_FUNC_GETGROUPS): Use it.
|
||||
Reported by Marcus Daniels.
|
||||
AC_REQUIRE version 2.12 of autoconf.
|
||||
|
||||
Sun Dec 22 23:31:32 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* configure.in: Increment version to 1.14a.
|
||||
|
||||
* m4/Makefile.am (EXTRA_DIST): Add README.
|
||||
|
||||
Fri Dec 20 19:28:37 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/who-users.c (usage): Say that UTMP_FILE is the default FILE
|
||||
rather than hard-coding /etc/utmp. Replace hard-coded /etc/wtmp
|
||||
with WTMP_FILE. Suggestion from Eivind.
|
||||
|
||||
* src/seq.c (usage): Tweak --help text.
|
||||
|
||||
* configure.in (AC_OUTPUT): Add m4/Makefile.
|
||||
|
||||
* lib/Makefile.am (EXTRA_DIST): Add getgroups.c.
|
||||
|
||||
* Makefile.am (SUBDIRS): Add m4.
|
||||
(aclocal-files): Add rules that rely on (GNU) make's include
|
||||
directive that computes dependencies for aclocal.m4.
|
||||
(aclocal.m4): Override automake-generated rule.
|
||||
|
||||
* m4/Makefile.am: New file.
|
||||
|
||||
* lib/strftime.c: Update from GNU libc.
|
||||
|
||||
* m4/getline.m4: New file, extracted from acinclude.m4.
|
||||
* m4/getloadavg.m4: Likewise.
|
||||
* m4/jm-mktime.m4: Likewise.
|
||||
* m4/jm-winsz1.m4: Likewise.
|
||||
* m4/jm-winsz2.m4: Likewise.
|
||||
* m4/memcmp.m4: Likewise.
|
||||
* m4/strftime.m4: Likewise.
|
||||
* m4/uptime.m4: Likewise.
|
||||
|
||||
* m4/ccstdc.m4: Copied from automake-1.1l.
|
||||
* m4/dmalloc.m4: Likewise.
|
||||
* m4/error.m4: Likewise.
|
||||
* m4/gettext.m4: Likewise.
|
||||
* m4/header.m4: Likewise.
|
||||
* m4/init.m4: Likewise.
|
||||
* m4/install.m4: Likewise.
|
||||
* m4/lcmessage.m4: Likewise.
|
||||
* m4/lispdir.m4: Likewise.
|
||||
* m4/maintainer.m4: Likewise.
|
||||
* m4/mktime.m4: Likewise.
|
||||
* m4/obstack.m4: Likewise.
|
||||
* m4/progtest.m4: Likewise.
|
||||
* m4/protos.m4: Likewise.
|
||||
* m4/ptrdiff.m4: Likewise.
|
||||
* m4/regex.m4: Likewise.
|
||||
* m4/sanity.m4: Likewise.
|
||||
* m4/strtod.m4: Likewise.
|
||||
* m4/termios.m4: Likewise.
|
||||
* m4/winsz.m4: Likewise.
|
||||
|
||||
* m4/getgroups.m4: New file.
|
||||
(jm_FUNC_GETGROUPS): New macro
|
||||
* lib/getgroups.c: New file.
|
||||
|
||||
* m4: New directory.
|
||||
|
||||
Wed Dec 18 07:47:29 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* configure.in (AC_CHECK_HEADERS): Add paths.h.
|
||||
* src/su.c [HAVE_PATHS_H]: Include <paths.h>.
|
||||
[_PATH_DEFPATH]: Use this to define DEFAULT_LOGIN_PATH.
|
||||
[_PATH_DEFPATH_ROOT]: Use this to define DEFAULT_ROOT_LOGIN_PATH.
|
||||
From Rik Faith.
|
||||
|
||||
* acinclude.m4 (jm_FUNC_GNU_STRFTIME): Change m4 quote strings
|
||||
outside the quoted test program. Quote the test program with <<, >>.
|
||||
Reported by Andreas Schwab.
|
||||
(AM_FUNC_GETLOADAVG): Likewise.
|
||||
(jm_FUNC_GNU_STRFTIME): Add tests for new, upcasing ^ modifier
|
||||
|
||||
Tue Dec 17 18:54:32 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/Makefile.am (install-exec-local): Properly redirect stdout
|
||||
and stderr to /dev/null. From Eric Backus.
|
||||
|
||||
* lib/strftime.c: Update from GNU libc.
|
||||
|
||||
* acinclude.m4 (jm_SYS_PROC_UPTIME): Require AC_PROG_CC, rather than
|
||||
now-obsolete AC_C_CROSS.
|
||||
(jm_FUNC_MKTIME): When redefining, use rpl_ prefix, not gnu_ one
|
||||
since there's nothing GNU-specific about the replacement. Contrast
|
||||
with gnu_ prefix added to strftime.
|
||||
(jm_FUNC_MEMCMP): New macro.
|
||||
* configure.in: Use jm_FUNC_MEMCMP instead of AM_FUNC_MEMCMP.
|
||||
* acconfig.h: Add memcmp.
|
||||
|
||||
Sun Dec 15 18:37:08 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* configure.in (check for 3-argument setpriority function): Complete
|
||||
partial change made on Dec 12. From Arne Juul.
|
||||
|
||||
Sat Dec 14 14:51:50 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* acinclude.m4 (jm_SYS_PROC_UPTIME): Fix typo in cache variable
|
||||
name for cross compiling.
|
||||
Remove definitions of gettext-related macros. The gettext
|
||||
installation procedure installs corresponding .m4 files so that
|
||||
aclocal will use them.
|
||||
|
||||
Thu Dec 12 06:07:30 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* Version 1.14.
|
||||
|
||||
* src/system.h (ISDIGIT): Replace with smaller, faster edition
|
||||
that yields nonzero only on ASCII digits.
|
||||
(ISDIGIT_LOCALE): New macro, with same meaning that ISDIGIT
|
||||
used to have. From Paul Eggert.
|
||||
|
||||
* configure.in: Bump version to 1.14.
|
||||
|
||||
* lib/getdate.y (IN_CTYPE_DOMAIN): Rename from ISASCII.
|
||||
(ISDIGIT): New definition from Paul Eggert.
|
||||
This one evaluates its argument exactly once.
|
||||
(yylex): Move increment out of ISALPHA argument. Use a
|
||||
comma-expression instead.
|
||||
|
||||
* src/false.sh (usage): Update bug-reporting address.
|
||||
* src/groups.sh (usage): Likewise.
|
||||
* src/nohup.sh (usage): Likewise.
|
||||
* src/true.sh (usage): Likewise.
|
||||
Reported by Karl Heuer.
|
||||
|
||||
* configure.in (check for 3-argument setpriority function): Add nohup
|
||||
to list of scripts, not the list of programs.
|
||||
From Karl Heuer.
|
||||
|
||||
* POTFILES.in: Add chroot.c. Reported by Michel Robitaille.
|
||||
|
||||
Wed Dec 11 19:33:36 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* Version 1.13.
|
||||
|
||||
Tue Dec 10 06:36:57 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* acinclude.m4 (jm_SYS_PROC_UPTIME): New macro. Derived from the
|
||||
code in configure.in, except now it punts when cross compiling.
|
||||
Suggestion from Karl Heuer.
|
||||
* configure.in (jm_SYS_PROC_UPTIME): Use it instead of open-coded
|
||||
version.
|
||||
|
||||
* lib/Makefile.am (EXTRA_DIST): Add mktime.c.
|
||||
Reported by Thomas Bushnell.
|
||||
|
||||
* configure.in: Bump version to 1.12t.
|
||||
|
||||
* Regenerate all Makefile.in using a patched version of automake-1.1l.
|
||||
|
||||
* acconfig.h (strftime): Add #undef.
|
||||
From Karl Heuer.
|
||||
|
||||
* acinclude.m4 (AM_GNU_GETTEXT): Don't require AC_ISC_POSIX.
|
||||
From Karl Heuer.
|
||||
|
||||
Mon Dec 9 06:58:11 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* configure.in: Bump version to 1.12s.
|
||||
|
||||
* lib/getdate.y (Convert): Don't reject all dates in 2038.
|
||||
Some fit in 31 bits.
|
||||
|
||||
* configure.in (jm_FUNC_GNU_STRFTIME): Use it.
|
||||
|
||||
* acinclude.m4 (AC_REPLACE_GNU_GETOPT): Remove unused macro.
|
||||
(jm_FUNC_GNU_STRFTIME): New macro.
|
||||
|
||||
* lib/Makefile.am (libsu_a_SOURCES): Remove strftime.c.
|
||||
(EXTRA_DIST): Add strftime.c.
|
||||
|
||||
* configure.in (jm_HEADER_TIOCGWINSZ_IN_TERMIOS_H): Fix typo:
|
||||
Change $am_cv_sys_tiocgwinsz_needs_sys_ioctl_h to
|
||||
$jm_cv_sys_tiocgwinsz_needs_sys_ioctl_h.
|
||||
Patch from Kaveh R. Ghazi.
|
||||
|
||||
* src/stty.c: Include config.h before testing for
|
||||
TERMIOS_NEEDS_XOPEN_SOURCE.
|
||||
Patch from Karl Heuer.
|
||||
|
||||
* configure.in (AC_ISC_POSIX): Remove kludgy macro.
|
||||
Use this test instead:
|
||||
(LIBS): Add -lcposix if it contains strerror.
|
||||
Patch from Karl Heuer.
|
||||
|
||||
* acinclude.m4 (AM_FUNC_GETLOADAVG): Put shell assignments to
|
||||
ac_save_LIBS and LIBS on separate lines to avoid order-of-evaluation
|
||||
problems -- some versions of sh (e.g. SunOS4.1.3's) evaluate such
|
||||
space-separated assignments from right to left. Patch from Karl Heuer.
|
||||
(AM_FUNC_GETLOADAVG): Fix typo: su_save_LIBS => am_cv_saved_LIBS.
|
||||
Patch from Karl Heuer.
|
||||
|
||||
* lib/strftime.c [HAVE_TZNAME]: Declare tzname.
|
||||
Patch from Karl Heuer.
|
||||
|
||||
* src/Makefile.am (.sh): Also substitute @bindir@.
|
||||
Reported by Karl Heuer.
|
||||
|
||||
Sun Dec 8 07:22:38 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
=========== Update for automake-1.1k.
|
||||
* Makefile.am (AUTOMAKE_OPTIONS): Require 1.1k.
|
||||
* configure.in (AM_CONFIG_HEADER): Use it.
|
||||
(AC_OUTPUT): Remove stamp-h timestamping statement.
|
||||
Now, AM_CONFIG_HEADER does it automatically.
|
||||
* lib/Makefile.am (noinst_LIBRARIES): Rename to libsu.a as per
|
||||
new automake requirement.
|
||||
Rename su_* variables to libsu_a_*.
|
||||
|
||||
Sun Dec 8 00:08:44 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/stty.c (get_win_size): Rename formal parameter from fileno to FD.
|
||||
|
||||
Sat Dec 7 12:52:00 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/chroot.c (main): Call setlocale, bindtextdomain, and textdomain.
|
||||
From Michel Robitaille.
|
||||
|
||||
* configure.in (ALL_LINGUAS): Add Portuguese (pt).
|
||||
|
||||
* lib/getloadavg.c [__SVR4]: Define SVR4.
|
||||
Remove duplicate `|| defined(SVR4)' disjunct guarding the
|
||||
#define KERNEL_FILE "/unix" definiton.
|
||||
|
||||
* configure.in (jm_HEADER_TIOCGWINSZ_NEEDS_SYS_IOCTL): Use this variant
|
||||
of the AM_ prefixed macro.
|
||||
(check for TIOCGWINSZ in sys/pty): In essence, require
|
||||
jm_HEADER_TIOCGWINSZ_IN_TERMIOS_H so that
|
||||
$jm_cv_sys_tiocgwinsz_needs_termios_h (renamed from
|
||||
$gwinsz_in_termios_h) is defined.
|
||||
|
||||
* lib/strftime.c (strftime): Remove " %Z" part of format for %c.
|
||||
Correction from Paul Eggert.
|
||||
|
||||
Fri Dec 6 20:52:07 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* acinclude.m4 (jm_FUNC_MKTIME): Rather than including the text of
|
||||
AM_FUNC_MKTIME, simply AC_REQUIRE it.
|
||||
|
||||
Mon Dec 2 20:59:38 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* configure.in (su_cv_func_ut_host_in_utmp): Move test that can
|
||||
define WINSIZE_IN_PTEM to precede test that checks whether
|
||||
`TIOCGWINSZ in sys/pty.h'. The latter test uses the symbol.
|
||||
(jm_FUNC_MKTIME): Use this instead of AM_FUNC_MKTIME.
|
||||
|
||||
Sun Dec 1 13:07:39 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* lib/getdate.y (date): Interpret the date, L/M/N, as YYYY/MM/DD
|
||||
if L >= 1000, otherwise as MM/DD/YY. With this change,
|
||||
date --date=DATE accepts dates like those in an RCS log listing.
|
||||
|
||||
Sat Nov 30 22:08:00 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* lib/strftime.c: Update from GNU libc.
|
||||
|
||||
Fri Nov 29 22:16:40 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/uname.c (main) [HAVE_SYSINFO && SI_ARCHITECTURE]: Support
|
||||
--processor (-p). Print processor type.
|
||||
(usage): Document it.
|
||||
|
||||
Thu Nov 28 00:28:37 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* configure.in (AM_GNU_GETTEXT): Renamed from ud_GNU_GETTEXT
|
||||
for gettext-0.10.25.
|
||||
(AM_FUNC_GETLINE): Move the test to just before the check for getdelim.
|
||||
|
||||
Sun Nov 24 11:02:29 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/system.h [!defined STDIN_FILENO]: Define it.
|
||||
[!defined STDOUT_FILENO]: Define it.
|
||||
[!defined STDERR_FILENO]: Define it.
|
||||
|
||||
* src/stty.c (get_win_size): Take a FILENO parameter rather than
|
||||
trying to get a size from both stdin and stdout.
|
||||
Update callers.
|
||||
Use STDIN_FILENO and STDOUT_FILENO instead of literal 0, 1.
|
||||
|
||||
========== From Karl Heuer =========
|
||||
* src/stty.c [TERMIOS_NEEDS_XOPEN_SOURCE]: Define _XOPEN_SOURCE.
|
||||
i386-pc-isc3.0, needs that in order to cause all of the useful
|
||||
termios symbols to be defined, instead of just those that are
|
||||
required by POSIX. This enables all of: iuclc ixany olcuc ocrnl
|
||||
onlcr onocr onlret ofill ofdel nl0 cr0 tab0 bs0 vt0 ff0 xcase.
|
||||
|
||||
[GWINSZ_IN_SYS_PTY]: Include sys/ioctl.h, sys/tty.h, and sys/pty.h.
|
||||
|
||||
[!VSUSP && !VSWTCH]: Map VSWTCH and CSWTCH to VSUSP and CSUSP resp.
|
||||
termio.h defines VSWTCH, but termios.h defines VSUSP instead (since
|
||||
POSIX requires that symbol). Define VSWTCH as a synonym if needed,
|
||||
so that either one can be used on input.
|
||||
(display_changed): If the slot for swtch is the same as the one for
|
||||
susp, display only the setting for susp.
|
||||
(display_all): Likewise.
|
||||
|
||||
(display_changed): Some systems still have (VEOF,VEOL) == (VMIN,VTIME).
|
||||
On such systems, it's confusing to print both pairs. So, skip eof and
|
||||
eol when icanon is unset, and skip min and time when icanon is set.
|
||||
(display_all): Likewise.
|
||||
|
||||
(set_window_size): Check only stdin (the device being queried) for
|
||||
window size info. You don't want "stty </dev/foo" to report the size
|
||||
of your current window when /dev/foo has no size info.
|
||||
(display_window_size): Likewise.
|
||||
|
||||
(screen_columns): Check only stdout for window size info. You want
|
||||
"stty </dev/foo" to wrap columns at the right margin of your current
|
||||
window, not the /dev/foo width.
|
||||
|
||||
* acconfig.h (GWINSZ_IN_SYS_PTY): Add #undef.
|
||||
(TERMIOS_NEEDS_XOPEN_SOURCE): Add #undef.
|
||||
|
||||
* configure.in (whether termios.h needs _XOPEN_SOURCE): New test.
|
||||
(whether TIOCGWINSZ is defined in sys/pty.h): New test.
|
||||
|
||||
Sat Nov 23 16:15:37 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* lib/Makefile.am (EXTRA_DIST): Add getline.c now that getline
|
||||
isn't mentioned in AC_REPLACE_FUNCS.
|
||||
|
||||
* env.c (usage): Alphabetize option descriptions the way sort -f would.
|
||||
* test.c (usage): Likewise.
|
||||
* who-users.c (usage): Likewise.
|
||||
From Karl Berry.
|
||||
|
||||
Fri Nov 22 20:33:26 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* configure.in (AC_REPLACE_FUNCS): Don't try to replace getline this
|
||||
way. AM_FUNC_GETLINE does it now.
|
||||
|
||||
* configure.in New test to check for TIOCGWINSZ in sys/pty.h.
|
||||
* config.h.in (GWINSZ_IN_SYS_PTY): Add #undef.
|
||||
From Karl Heuer.
|
||||
|
||||
* src/printf.c (main): Warn if excess arguments are ignored.
|
||||
E.g., printf foo bar now warns that it is ignoring the single
|
||||
non-format argument, bar.
|
||||
|
||||
Wed Nov 20 20:37:54 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* lib/xgethostname.c (xgethostname): Work around bug in SunOS5.5's
|
||||
gethostname. Reported by Fletcher Mattox.
|
||||
|
||||
Tue Nov 19 23:01:01 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* configure.in (AM_SANITY_CHECK_CC): Remove it. Autoconf-2.11
|
||||
has this built-in.
|
||||
(OPTIONAL_BIN_ZCRIPTS): Rename from OPTIONAL_SCRIPTS -- because
|
||||
automake-1.1g couldn't deal with the _SCRIPTS suffix.
|
||||
* src/Makefile.am (bin_SCRIPTS): Rename @OPTIONAL_SCRIPTS@.
|
||||
|
||||
Sun Nov 17 20:49:37 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/id.c (main): Ignore -a, for compatibility with SVR4.
|
||||
Suggestion from Noah Friedman.
|
||||
|
||||
Mon Nov 4 20:24:31 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* configure.in (test for group_member): Handle it separately
|
||||
so I can keep the hyphen (not the underscore) in the filename.
|
||||
|
||||
Thu Oct 31 19:32:32 1996 Miles Bader <miles@gnu.ai.mit.edu>
|
||||
|
||||
* lib/xgethostname.c [ENAMETOOLONG] (xgethostname): If gethostname
|
||||
returns an error other than buffer overflow, exit with an error
|
||||
message instead of allocating infinite amounts of space.
|
||||
[!EXIT_FAILURE] (EXIT_FAILURE): New macro.
|
||||
<errno.h>: New include.
|
||||
[!errno] (errno): New declaration.
|
||||
|
||||
* acinclude.m4 (AM_FUNC_GETLINE): Use cache.
|
||||
|
||||
* configure.in: Check for -linet library before checking for the
|
||||
gethostbyname function. Suggested by Karl Heuer.
|
||||
Use AM_FUNC_GETLINE.
|
||||
|
||||
* acinclude.m4 (AM_FUNC_GETLINE): Add run-time test for getline.
|
||||
Based on a test from Karl Heuer.
|
||||
|
||||
Sun Nov 3 14:57:09 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* acinclude.m4 (GETLOADAVG_LIBS): Unanchor the sed regexp that removes
|
||||
am_cv_saved_LIBS from LIBS. From Karl Heuer.
|
||||
|
||||
* src/stty.c (recover_mode): Fail also if there are too many fields.
|
||||
From Karl Heuer.
|
||||
|
||||
* lib/canon-host.c: Include sys/types.h for the definitions
|
||||
(otherwise missing on some systems) of caddr_t (used by
|
||||
sys/socket.h) and ushort (used by netinet/in.h). From Karl Heuer.
|
||||
|
||||
Sat Nov 2 00:16:16 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* doc/Makefile.am (MAKEINFO): Set to makeinfo --no-split.
|
||||
Otherwise, the generated info files have names longer than
|
||||
the 14-byte max of some old systems.
|
||||
Reported by Karl Heuer.
|
||||
|
||||
* src/date.c (main): Give better diagnostic.
|
||||
Suggestion from Karl Berry.
|
||||
|
||||
Thu Oct 31 18:28:05 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* lib/posixtm.y: Remap yacc globals to have pt_ prefix.
|
||||
* lib/getdate.y: Remap yacc globals to have gd_ prefix.
|
||||
Suggestion to do as in gdb/c-exp.y from Tom Tromey.
|
||||
|
||||
Mon Oct 28 17:40:54 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/Makefile.am (install-exec-local): Redirect stderr of chown to
|
||||
/dev/null and suggest running `make install-root' upon failure to
|
||||
install su. Suggestions from François Pinard.
|
||||
|
||||
* configure.in: Don't output confusing diagnostic: `checking for
|
||||
shadow password routines'. Suggestion from François Pinard.
|
||||
|
||||
Thu Oct 24 13:50:46 1996 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
|
||||
|
||||
* src/tee.c (main): Ignore SIGPIPE.
|
||||
|
||||
Wed Oct 23 23:42:43 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/stty.c: Guard inclusion of stdarg.h and definition of VA_START
|
||||
with #if PROTOTYPES rather than with #ifdef __STDC__. The latter
|
||||
loses with Dynix/PTX.
|
||||
(wrapf) [PROTOTYPES]: Similarly, guard ANSI-style ... definition.
|
||||
Suggestion from Marcus Daniels.
|
||||
|
||||
Mon Oct 21 16:49:08 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* lib/getloadavg.c [__linux__]: Don't bother with a.out/nlist/kernel
|
||||
|
||||
@@ -1,5 +1,34 @@
|
||||
Changes in release 1.16
|
||||
1.15a
|
||||
* stty -tabs works properly
|
||||
* add tests for date
|
||||
|
||||
Changes in release 1.15
|
||||
* nice works with very recently-changed GNU libc getopt
|
||||
* fix several bugs in m4 macros used to create `configure' script
|
||||
* id works on systems with disfunctional getgroups function
|
||||
* uptime configure test detects /proc/uptime on Linux
|
||||
|
||||
Changes in release 1.14
|
||||
* fix bug in getdate.y that broke date's --date=DATE option on systems
|
||||
like SunOS4.
|
||||
* expr treats unadorned ? and + as literals. To make expr treat them as
|
||||
operators you have to use \? and \+.
|
||||
|
||||
Changes in release 1.13
|
||||
[1.12p]
|
||||
* two patches for ISC
|
||||
* Regenerate all Makefile.in using a patched version of automake-1.1l.
|
||||
[1.12s]
|
||||
* lots of little bug fixes -- see ChangeLog
|
||||
[1.12r]
|
||||
* uname --processor (-p) works on systems that have sysinfo and define
|
||||
SI_ARCHITECTURE.
|
||||
* stty works better on systems like i386-pc-isc3.0
|
||||
* date --date=DATE accepts dates like those in an RCS log listing, e.g.,
|
||||
`1992/11/01 05:44:34'.
|
||||
* printf now warns if excess arguments are ignored.
|
||||
* tee no longer fails immediately upon receipt of SIGPIPE
|
||||
[1.12q]
|
||||
* running `make check' runs tests of nice
|
||||
* lots of configuration-related improvements
|
||||
* nice allows `+' in options like -+8 and -+13.
|
||||
|
||||
@@ -1,3 +1,367 @@
|
||||
Sun Jan 26 12:49:50 1997 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* Version 1.22.
|
||||
|
||||
* src/tail.c (parse_options): Add quotes to make messages identical.
|
||||
|
||||
Sat Jan 25 00:12:29 1997 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/tail.c (parse_obsolescent_option): Comment.
|
||||
(parse_options): Remove unnecessary goto and label.
|
||||
|
||||
* tests/sort-test/mk-script.pl: Interpret `input arg is a hash
|
||||
reference' as meaning that the tested program will read no input.
|
||||
Most of the tests for the date program use this feature.
|
||||
Also for date, the generated script now reflects specification
|
||||
(in Test.pm) of default and per-test environment settings.
|
||||
|
||||
* src/csplit.c: Reflect changes to xstrtol and xstrtoul interfaces.
|
||||
* src/fold.c: Likewise.
|
||||
* src/head.c: Likewise.
|
||||
* src/join.c: Likewise.
|
||||
* src/nl.c: Likewise.
|
||||
* src/od.c: Likewise.
|
||||
* src/pr.c: Likewise.
|
||||
* src/uniq.c: Likewise.
|
||||
|
||||
* lib/xstrtoul.h (XSTRTOL_H): Undefine it.
|
||||
|
||||
* lib/xstrtol.h [!_STRTOL_ERROR]: Define the type `enum strtol_error'
|
||||
only if it hasn't already been defined.
|
||||
(_STRTOL_ERROR): Undefine.
|
||||
|
||||
* lib/xstrtol.c (__xstrtol): Change interpretation of
|
||||
VALID_SUFFIXES == NULL vs VALID_SUFFIXES == "". Use the former
|
||||
when any suffix is valid, the later when no suffix is allowed.
|
||||
|
||||
Fri Jan 24 23:36:00 1997 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* lib/long-options.c (parse_long_options): Reset optind to zero
|
||||
before just returning so that getopt internals get initialized from
|
||||
the probably-new parameters when/if getopt is called later.
|
||||
From Ulrich Drepper.
|
||||
|
||||
Thu Jan 23 19:17:03 1997 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/tail.c (parse_obsolescent_option): Recognize and fail for
|
||||
more malformed obsolescent options. Makes for better diagnostics.
|
||||
|
||||
Wed Jan 22 21:34:50 1997 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* tests/Makefile.am (SUBDIRS): Add tail.
|
||||
* tests/tail: New directory.
|
||||
* configure.in (AC_OUTPUT): Add tests/tail/Makefile.
|
||||
|
||||
* src/tail.c (parse_options): New function.
|
||||
(parse_obsolescent_option): New function.
|
||||
(main): Use the new functions instead of open-coding them.
|
||||
This better fixes the bug in handling obsolescent `+Nc' options.
|
||||
General cleanup.
|
||||
|
||||
Tue Jan 21 22:49:00 1997 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/tail.c (main): Properly handle what the POSIX spec calls
|
||||
the `obsolescent' usage (e.g., tail +2c). It didn't work.
|
||||
Reported by Karl Heuer.
|
||||
|
||||
Sun Jan 12 22:13:27 1997 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* tests/tr-test/Test.pm: Rename tests so that the associated files
|
||||
have names that are distinct even on filesystems on which file
|
||||
names are case insensitive.
|
||||
Reported by Fred Fish.
|
||||
* tests/cut-test/Test.pm: Likewise.
|
||||
|
||||
* tests/tr-test/Makefile.am: Regenerated to reflect renamed tests.
|
||||
* tests/cut-test/Makefile.am: Likewise.
|
||||
|
||||
Wed Jan 8 16:38:24 1997 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* Version 1.21.
|
||||
|
||||
* lib/getopt.c (_getopt_internal): Use `_', rather than the
|
||||
(sometimes-)expansion `gettext'.
|
||||
|
||||
Tue Jan 7 22:50:13 1997 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* lib/getopt.c: New (more POSIX compliant) version from GNU libc.
|
||||
[_]: Define to gettext also if ENABLE_NLS is defined.
|
||||
This is temporary.
|
||||
|
||||
Thu Jan 2 21:17:50 1997 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/pr.c (init_fps): Initialize lines_stored field in three places.
|
||||
This avoids uninitialized memory reads in close_file.
|
||||
|
||||
Wed Jan 1 17:32:18 1997 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* configure.in (AC_ARG_PROGRAM): Remove explicit use.
|
||||
It's implicit in AM_INIT_AUTOMAKE. From Wayne Stewart.
|
||||
|
||||
Sun Dec 29 23:42:57 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/pr.c (init_header): Plug a small memory leak by using stack
|
||||
rather than heap for a 15-byte temporary buffer.
|
||||
|
||||
Sat Dec 28 00:03:23 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/pr.c (TAB_WIDTH): Parenthesize uses of parameters and renamed
|
||||
from tab_width.
|
||||
(POS_AFTER_TAB): Renamed from pos_after_tab. Define in terms of
|
||||
TAB_WIDTH rather than duplicating the expression.
|
||||
|
||||
Fri Dec 27 17:29:02 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* tests/join-test/mk-script.pl: Fix a couple of thinkos and typos.
|
||||
Now it works with pr's tests, too.
|
||||
|
||||
* tests/pr-test/Makefile.am (explicit): Regenerate list of files,
|
||||
this time with duplicates removed.
|
||||
|
||||
* src/pr.c (usage): Break long string literal into two separate
|
||||
printf statements to accomodate default maximum of 2048 characters
|
||||
for Irix-4.0.5. Reported by Kaveh Ghazi.
|
||||
|
||||
* Makefile.am (aclocal.m4): No longer depend on acinclude.m4.
|
||||
|
||||
* tests/Makefile.am (SUBDIRS): Add pr-test.
|
||||
|
||||
* configure.in: AC_REQUIRE version 2.12 of autoconf.
|
||||
AC_OUTPUT: Add tests/pr-test/Makefile.
|
||||
|
||||
Sun Dec 22 08:11:27 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* acinclude.m4: Move macros to individual files in new directory, m4/.
|
||||
See ChangeLog entries in sh-utils for the details.
|
||||
|
||||
* configure.in: Increment version to 1.20a.
|
||||
|
||||
* tests/md5sum-test/Makefile.am: Use same framework as other tests.
|
||||
* tests/md5sum-test/Test.pm: New file.
|
||||
|
||||
Sat Dec 21 20:32:58 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* tests/Makefile.am (EXTRA_DIST): Add README and Makefile.am.in.
|
||||
|
||||
* tests/Makefile.am.in: New file.
|
||||
|
||||
* tests/sort-test/Makefile.am: Clone the Makefile.am from join-test.
|
||||
Replace only the definition of $x and the auto-generated lists of
|
||||
test files.
|
||||
* tests/cut-test/Makefile.am: Likewise.
|
||||
* tests/tr-test/Makefile.am: Likewise.
|
||||
|
||||
* tests/join-test/Makefile.am: Add @MAINT@-protected rule for
|
||||
verifying that Makefile.am is consistent with Test.pm.
|
||||
|
||||
Fri Dec 20 00:08:36 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* tests/join-test/Makefile.am (MAINTAINERCLEANFILES): Use $(in1)
|
||||
and $(in2), not $(in).
|
||||
|
||||
* tests/join-test/mk-script.pl: New option: --list.
|
||||
Generate lists of files used/generated.
|
||||
|
||||
Thu Dec 19 23:28:41 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* tests/join-test/mk-script.pl: Rewrite to be more general -- so
|
||||
it can be used for join, cut, sort, tr, and soon, pr test suites.
|
||||
* tests/tr-test/mk-script.pl: Symlink through CVS repo to join's
|
||||
mk-script.pl.
|
||||
* tests/sort-test/mk-script.pl: Likewise.
|
||||
* tests/cut-test/mk-script.pl: Likewise.
|
||||
|
||||
* tests/tr-test/Test.pm: Adapted for new mk-script.pl.
|
||||
* tests/join-test/Test.pm: Likewise.
|
||||
|
||||
Tue Dec 17 16:48:51 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* tests/join-test/Makefile.am (.pl): Make generated file read-only so
|
||||
I don't accidentally modify it instead of the one with the .pl suffix.
|
||||
|
||||
* acinclude.m4 (jm_SYS_PROC_UPTIME): Require AC_PROG_CC, rather than
|
||||
now-obsolete AC_C_CROSS.
|
||||
(jm_FUNC_MKTIME): When redefining, use rpl_ prefix, not gnu_ one
|
||||
since there's nothing GNU-specific about the replacement. Contrast
|
||||
with gnu_ prefix added to strftime.
|
||||
(jm_FUNC_MEMCMP): New macro.
|
||||
* configure.in: Use jm_FUNC_MEMCMP instead of AM_FUNC_MEMCMP.
|
||||
* acconfig.h: Add memcmp.
|
||||
* README: Remove warning about memcmp. The new macro handles it.
|
||||
|
||||
Mon Dec 16 23:03:27 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* tests/Makefile.am (pkgdata_DATA): Remove unnecessary assignment.
|
||||
From Eric Backus.
|
||||
(AUTOMAKE_OPTIONS): Likewise.
|
||||
|
||||
Sat Dec 14 14:51:50 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* acinclude.m4 (jm_SYS_PROC_UPTIME): Fix typo in cache variable
|
||||
name for cross compiling.
|
||||
Remove definitions of gettext-related macros. The gettext
|
||||
installation procedure installs corresponding .m4 files so that
|
||||
aclocal will use them.
|
||||
|
||||
1996-12-12 Paul Eggert <eggert@twinsun.com>
|
||||
|
||||
* system.h (ISDIGIT): Replace with smaller, faster edition
|
||||
that yields nonzero only on ASCII digits.
|
||||
(ISDIGIT_LOCALE): New macro, with same meaning that ISDIGIT
|
||||
used to have.
|
||||
|
||||
* tr.c (is_char_class_member): Use ISDIGIT_LOCALE instead of
|
||||
ISDIGIT to test for characters in CC_DIGIT class.
|
||||
|
||||
* sort.c (digits): Remove; subsumed by new ISDIGIT.
|
||||
(inittables): Remove initialization of `digits'.
|
||||
(fraccompare, numcompare, main): Use ISDIGIT (x) instead of digits[x].
|
||||
(fraccompare, numcompare): Avoid casts to unsigned char that are no
|
||||
longer needed.
|
||||
|
||||
* csplit.c (get_format_width, get_format_prec): Avoid
|
||||
unnecessary comparison of digit to '\0'.
|
||||
|
||||
Thu Dec 12 23:42:51 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/sort.c (usage): Clarify description of -u option.
|
||||
From Karl Berry.
|
||||
|
||||
Wed Dec 11 19:32:18 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* Version 1.20.
|
||||
|
||||
Tue Dec 10 00:15:50 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
The file name, `build-script.pl' is longer than 14 characters.
|
||||
Rename it.
|
||||
* tests/cut-test/mk-script.pl: Rename from build-script.pl.
|
||||
* tests/cut-test/Makefile.am: Reflect renaming.
|
||||
* tests/tr-test/mk-script.pl: Rename from build-script.pl.
|
||||
* tests/tr-test/Makefile.am: Reflect renaming.
|
||||
* tests/sort-test/mk-script.pl: Rename from build-script.pl.
|
||||
* tests/sort-test/Makefile.am: Reflect renaming.
|
||||
* tests/join-test/mk-script.pl: Rename from build-script.pl.
|
||||
* tests/join-test/Makefile.am: Reflect renaming.
|
||||
Reported by Karl Heuer.
|
||||
|
||||
* configure.in (VERSION): Bump to 1.19r.
|
||||
(AC_ISC_POSIX): Remove kludgy macro.
|
||||
Use this test instead:
|
||||
(LIBS): Add -lcposix if it contains strerror.
|
||||
Patch from Karl Heuer.
|
||||
|
||||
Sun Dec 8 07:22:38 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
=========== Update for automake-1.1k.
|
||||
* Makefile.am (AUTOMAKE_OPTIONS): Require 1.1k.
|
||||
* configure.in (AM_CONFIG_HEADER): Use it.
|
||||
(AC_OUTPUT): Remove stamp-h timestamping statement.
|
||||
Now, AM_CONFIG_HEADER does it automatically.
|
||||
* lib/Makefile.am (noinst_LIBRARIES): Rename to libtu.a as per
|
||||
new automake requirement.
|
||||
Rename tu_* variables to libtu_a_*.
|
||||
|
||||
Wed Dec 4 21:03:18 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/pr.c: Apply big patch from Roland Huebner.
|
||||
|
||||
* src/tr.c (main) [!POSIXLY_CORRECT]: Allow the identity mappings:
|
||||
[:upper:] to [:upper:] and [:lower:] to [:lower:].
|
||||
(main) [POSIXLY_CORRECT]: Give a more specific diagnostic for
|
||||
the invalid identity mappings [:upper:] to [:upper:] and [:lower:]
|
||||
to [:lower:].
|
||||
(class_ok): Update table to reflect that tr now allows these
|
||||
identity mappings. Suggestion from Risto Kankkunen.
|
||||
|
||||
Thu Nov 28 00:31:18 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* configure.in (AM_GNU_GETTEXT): Renamed from ud_GNU_GETTEXT
|
||||
for gettext-0.10.25.
|
||||
|
||||
Tue Nov 26 23:05:14 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/sort.c (fraccompare): Add explicit `int' in `register' dcls,
|
||||
to avoid new warning from gcc.
|
||||
|
||||
Sun Nov 24 21:02:15 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* tests/sort-test/Makefile.am (t): Add names of those 5 tests.
|
||||
|
||||
* tests/sort-test/Test.pm: Add 5 tests to exercize just-fixed code.
|
||||
|
||||
* src/sort.c (set_ordering): Revert 1994-05-04 change to this function
|
||||
so that blanks are not unconditionally ignored when computing start
|
||||
and end positions for numeric keys with explicit character offsets.
|
||||
Reported by Markus Demleitner.
|
||||
|
||||
Sat Nov 23 16:07:08 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* cat.c (usage): Alphabetize option descriptions the way sort -f would.
|
||||
* fmt.c (usage): Likewise.
|
||||
* join.c (usage): Likewise.
|
||||
* md5sum.c (usage): Likewise.
|
||||
* od.c (usage): Likewise.
|
||||
* pr.c (usage): Likewise.
|
||||
* sort.c (usage): Likewise.
|
||||
* split.c (usage): Likewise.
|
||||
* wc.c (usage): Likewise.
|
||||
From Karl Berry.
|
||||
|
||||
Fri Nov 22 20:20:37 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/csplit.c (process_regexp): Update CURRENT_LINE only if
|
||||
the new value would be larger. This avoids the infinite loop
|
||||
otherwise provoked by situations like this:
|
||||
printf "\na\n" | csplit - '/a/-1' '{*}'
|
||||
From Jens Schmidt.
|
||||
|
||||
Tue Nov 19 23:16:57 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* configure.in (AM_SANITY_CHECK_CC): Remove it. Autoconf-2.11
|
||||
has this built-in.
|
||||
|
||||
Sat Nov 2 08:50:01 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* doc/Makefile.am (MAKEINFO): Set to makeinfo --no-split.
|
||||
Otherwise, the generated info files have names longer than
|
||||
the 14-byte max of some old systems.
|
||||
Reported by Karl Heuer.
|
||||
|
||||
Fri Nov 1 21:33:16 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* lib/strtol.c: Update from GNU libc.
|
||||
|
||||
* tests/sort-test/Test.pm: Add a test to exercize this fix.
|
||||
|
||||
* src/sort.c [!ENABLE_ASSERTIONS]: Guard NDEBUG definition.
|
||||
(checkfp): Fix off-by-one error that resulted in writing one byte
|
||||
beyond the end of a malloc'd buffer. It caused `sort -c' to segfault
|
||||
on Linux systems having a relatively recent libc. Before, running
|
||||
the command, perl -e "print 'x' x 30, \"\n\";"|sort -c
|
||||
would provoke the memory overrun (though not necessarily the failure).
|
||||
Add an assertion.
|
||||
Reported by Risto Kankkunen.
|
||||
|
||||
Thu Oct 31 17:48:24 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/sort.c (key_init): New function.
|
||||
(main): Use key_init in the two places where it was open-coded.
|
||||
This fixes a UMR of the general_numeric field.
|
||||
|
||||
* src/join.c (decode_field_spec): Always give FIELD_INDEX a value.
|
||||
This avoids a spurious UMR report from purify.
|
||||
(prjoin): Add an assertion.
|
||||
(add_field): Update assertion.
|
||||
|
||||
* src/tr.c (es_free): New function.
|
||||
(parse_str): Use it to plug a small memory leak.
|
||||
|
||||
Wed Oct 23 22:02:24 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* lib/md5.c: Update from GNU libc.
|
||||
* lib/md5.h: Update from GNU libc.
|
||||
|
||||
Mon Oct 21 16:48:12 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/tr.c (validate): Remove TAB from diagnostic, for consistency.
|
||||
@@ -128,7 +492,12 @@ Thu Sep 26 21:02:54 1996 Jim Meyering <meyering@na-net.ornl.gov>
|
||||
|
||||
* src/md5sum.c (usage): Remove references in --help output to
|
||||
the now-deprecated --string option. Support for it will be
|
||||
removed soon.
|
||||
removed soon. Using this option can provoke a memory access
|
||||
violation on some systems because of (unavoidable in an efficient
|
||||
implementation) alignment assumptions made by functions in md5.c.
|
||||
md5sum.c could leave the option in and accomodate the alignment
|
||||
restriction, but this option was intended solely for testing, and
|
||||
the tests are now all file-oriented, so it's not necessary.
|
||||
|
||||
* tests/md5sum-test/md5-rfc: Rewrite to avoid use of --string option.
|
||||
|
||||
|
||||
@@ -1,5 +1,43 @@
|
||||
Changes in release 1.22
|
||||
[1.21a]
|
||||
* Fix a bug in tail when invoked with an argument like `+NUMBERc'
|
||||
* Add test suite for tail
|
||||
|
||||
Changes in release 1.21
|
||||
* Using --program-prefix no longer applies the prefix twice
|
||||
|
||||
Changes in release 1.20
|
||||
Changes in test release 1.19o
|
||||
* fix pr: -l now uses total number of lines per page also with -f
|
||||
* fix pr: use left-hand-side truncation of header string to avoid line
|
||||
overflow
|
||||
* fix pr: it now accepts `form feeds set in input files', also with -m
|
||||
and multiple form feeds at different pages in each file
|
||||
* pr now accepts: -h "", print a blank line header
|
||||
* pr: when skipping pages (+FIRST_PAGE option) line counting (-n option)
|
||||
starts with 1st line of input file (not of 1st page printed) by default
|
||||
* pr accepts new option: -N, start printing with an optional line number
|
||||
* pr -t retains `form feeds set in input files' (`don't destroy page layout')
|
||||
* pr accepts new option: -T, equivalent to -t, but eliminate also form feeds
|
||||
(`clear file')
|
||||
* pr accepts the extension: +FIRST_PAGE[:LAST_PAGE]
|
||||
* pr -w and -s option disentangled (`use a separator' no longer destroys
|
||||
column alignment)
|
||||
* pr accepts new option: -j, merge lines of full length
|
||||
* pr accepts the extension: -s[STRING], use separator string instead of
|
||||
character only
|
||||
* pr -b is no longer an independent option, balancing is always used
|
||||
with -COLUMN (a requirement of unrestricted use of form feeds)
|
||||
* pr accepts new option: --test, to run the pr tests with a constant
|
||||
header string
|
||||
* join passes all of its tests on Alpha OSF 4.0.
|
||||
* sort no longer improperly ignores blanks in determining starting and ending
|
||||
positions for keys with explicit character offsets
|
||||
* fix bug in csplit with regexp and negative offset that led to infinite loop
|
||||
Changes in test release 1.19q
|
||||
* fix bug in sort -c that sometimes resulted in a segfault
|
||||
Changes in test release 1.19p
|
||||
* md5sum's --string option is being deprecated and is no longer documented.
|
||||
It is still accepted, but will be removed altogether in 1.22.
|
||||
* tr '[:lower:]' '[:upper:]' no longer fails when LC_CTYPE is set to
|
||||
iso_8859_1 on Solaris -- or any other character set with differing
|
||||
numbers of uppercase and lowercase characters
|
||||
|
||||
@@ -59,7 +59,7 @@ If specified, also remove a trailing SUFFIX.\n\
|
||||
--help display this help and exit\n\
|
||||
--version output version information and exit\n\
|
||||
"));
|
||||
puts (_("\nReport bugs to bug-gnu-utils@gnu.ai.mit.edu"));
|
||||
puts (_("\nReport bugs to sh-utils-bugs@gnu.ai.mit.edu"));
|
||||
}
|
||||
exit (status);
|
||||
}
|
||||
|
||||
@@ -89,22 +89,22 @@ Usage: %s [OPTION] [FILE]...\n\
|
||||
printf (_("\
|
||||
Concatenate FILE(s), or standard input, to standard output.\n\
|
||||
\n\
|
||||
-A, --show-all equivalent to -vET\n\
|
||||
-b, --number-nonblank number nonblank output lines\n\
|
||||
-e equivalent to -vE\n\
|
||||
-E, --show-ends display $ at end of each line\n\
|
||||
-n, --number number all output lines\n\
|
||||
-s, --squeeze-blank never more than one single blank line\n\
|
||||
-t equivalent to -vT\n\
|
||||
-T, --show-tabs display TAB characters as ^I\n\
|
||||
-u (ignored)\n\
|
||||
-v, --show-nonprinting use ^ and M- notation, except for LFD and TAB\n\
|
||||
-A, --show-all equivalent to -vET\n\
|
||||
-E, --show-ends display $ at end of each line\n\
|
||||
-T, --show-tabs display TAB characters as ^I\n\
|
||||
--help display this help and exit\n\
|
||||
--version output version information and exit\n\
|
||||
\n\
|
||||
With no FILE, or when FILE is -, read standard input.\n\
|
||||
"));
|
||||
puts (_("\nReport bugs to bug-gnu-utils@gnu.ai.mit.edu"));
|
||||
puts (_("\nReport bugs to textutils-bugs@gnu.ai.mit.edu"));
|
||||
}
|
||||
exit (status == 0 ? EXIT_SUCCESS : EXIT_FAILURE);
|
||||
}
|
||||
|
||||
@@ -282,12 +282,12 @@ Change the group membership of each FILE to GROUP.\n\
|
||||
-h, --no-dereference affect symbolic links instead of any referenced file\n\
|
||||
(available only on systems with lchown system call)\n\
|
||||
-f, --silent, --quiet suppress most error messages\n\
|
||||
-v, --verbose output a diagnostic for every file processed\n\
|
||||
-R, --recursive change files and directories recursively\n\
|
||||
-v, --verbose output a diagnostic for every file processed\n\
|
||||
--help display this help and exit\n\
|
||||
--version output version information and exit\n\
|
||||
"));
|
||||
puts (_("\nReport bugs to bug-gnu-utils@gnu.ai.mit.edu"));
|
||||
puts (_("\nReport bugs to fileutils-bugs@gnu.ai.mit.edu"));
|
||||
}
|
||||
exit (status);
|
||||
}
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user