Compare commits

...

565 Commits

Author SHA1 Message Date
Chris Allegretta
2257893ac2 GNU nano 1.1.12 release
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1308 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-10-25 03:14:11 +00:00
Chris Allegretta
2a15c584f1 Add DLR's --disable-nls to version info
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1307 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-10-25 01:51:13 +00:00
Chris Allegretta
d45c5992d3 Ken's ngettext fix
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1306 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-10-25 01:41:31 +00:00
Jordi Mallach
573b61f2af German translation update.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1305 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-10-17 15:31:31 +00:00
David Lawrence Ramsey
1536d4bb0b put header files in a slightly more consistent order
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1304 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-10-17 03:50:36 +00:00
David Lawrence Ramsey
2ab03f6896 miscellaneous bug fixes
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1303 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-10-17 02:19:31 +00:00
Chris Allegretta
e42df73644 - Disable VSTOP keystroke. Stops people accidentally locking up, nano (suggested by David Benbennick)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1302 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-10-15 00:27:55 +00:00
Jordi Mallach
492f8e62f0 Updated French translation (Jean-Philippe Guérard).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1301 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-10-14 09:20:53 +00:00
Chris Allegretta
1dd0bc98a2 Remove malloc.h completely and add color synatx highlighting toggle
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1300 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-10-13 18:43:45 +00:00
Jordi Mallach
1801c176d9 Updated Spanish translation (Ricardo Javier Cárdenes Medina).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1299 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-10-13 17:40:12 +00:00
Jordi Mallach
f4420f8842 Indonesian and Malay updates.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1298 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-10-08 12:11:18 +00:00
Jordi Mallach
dc54e12d94 German translation updates (Michael Piefel).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1297 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-10-07 09:30:01 +00:00
Jordi Mallach
4da47eab9e Updated Catalan translation.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1296 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-10-07 00:16:22 +00:00
Jordi Mallach
dab0299d88 Swedish, Galician and Polish updates.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1295 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-10-06 23:35:19 +00:00
Jordi Mallach
1fc9da6597 Nitpick about being root to install. Maybe people stop compiling as root, even.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1294 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-10-06 23:32:21 +00:00
Jordi Mallach
0b761fa277 Require gettext >= 0.11.
Fix typo, thanks David.


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1293 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-10-06 23:29:56 +00:00
Chris Allegretta
ec6388e255 Post update to gettext 0.11.5
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1292 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-10-06 22:06:36 +00:00
Chris Allegretta
71fb1f5bd1 Back to CVS
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1291 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-10-02 00:21:31 +00:00
Chris Allegretta
6866f6fb7d GNU nano 1.1.11 release
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1289 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-10-02 00:20:19 +00:00
Chris Allegretta
136a38af2f nanorc.sample: - Add some examples for HTML and TeX files (David Benbennick)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1288 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-10-02 00:05:40 +00:00
Chris Allegretta
3a24c12a92 Give DB credit for the new color code
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1287 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-09-28 01:07:10 +00:00
Jordi Mallach
e3ebfead53 For great justice!
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1286 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-09-27 14:51:57 +00:00
David Lawrence Ramsey
1f28b8f400 DB's rewrite of the screen update and color routines
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1285 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-09-27 14:21:59 +00:00
David Lawrence Ramsey
7c4222ca90 make the spacing fix use isspace(); it works the same way and takes up
less space in the binary


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1284 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-09-26 22:49:56 +00:00
Chris Allegretta
4300092919 Newer version of DLR's patch based on DB's tab thing
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1283 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-09-21 15:41:33 +00:00
Chris Allegretta
81dea02ca7 Add DLR's fixes to the wrapping behavior
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1282 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-09-21 02:19:45 +00:00
Chris Allegretta
079b5495c8 winio.c:edit_refresh() - Turn on leaveok() so the cursor doesn't bounce around the screen while we're updating it (most noticeable when using color syntax over a very slow connection)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1281 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-09-19 23:54:53 +00:00
Chris Allegretta
0ae5c722bd Make that ChangeLog for do_wrap a little less overly verbose
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1280 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-09-19 23:20:26 +00:00
Chris Allegretta
67ca2aa874 nano.c:do_wrap() - Restore the wrapping behavior to the previous wrapping point behavior (pre 1.1.10) (David Benbennick)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1279 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-09-19 23:19:34 +00:00
Chris Allegretta
de852623ee - rcfile.c:parse_colors() - Stop infinite loop when syntax doesn't begin with " char
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1278 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-09-18 00:28:57 +00:00
Chris Allegretta
3f9c3bf10b - Add a better string matching sequence that includes escaped quotes (thanks to Carl E. Lindberg, who doesn't even know he helped ;-)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1277 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-09-18 00:00:12 +00:00
Chris Allegretta
515ba32513 - nano.h: - Add support for HP-UX's curses, which doesn't seem to support KEY_HOME and KEY_END
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1276 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-09-14 21:16:40 +00:00
David Lawrence Ramsey
e21adfa181 David Benbennick's minor fixes, plus one of mine
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1275 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-09-13 18:14:04 +00:00
David Lawrence Ramsey
605165e292 DLR: Document minor typo fix for the FAQ.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1274 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-09-11 01:48:14 +00:00
David Lawrence Ramsey
947c037212 DLR: Minor typo fix for the FAQ.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1273 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-09-10 22:24:14 +00:00
Jordi Mallach
56ae5a096c Malay update.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1272 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-09-08 18:26:40 +00:00
Jordi Mallach
bf89768c70 French & Danish updates.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1271 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-09-08 15:39:22 +00:00
David Lawrence Ramsey
ad40fdba59 DLR: prototype overhaul, etc.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1270 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-09-06 20:35:28 +00:00
Chris Allegretta
f7c6811e36 - Changed do_insertfile to (a) report multibuffer status at the prompt and allowing it to be toggled, taking into account the need to keep the translatable strings, and (b) added a variable inspath to keep track of what the string was before toggling. I'm sure there's bugs, have at it
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1269 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-09-03 22:58:40 +00:00
David Lawrence Ramsey
768e8f0810 DLR: Spell Jeff DeFouw's name right in the Changelog
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1268 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-08-22 04:03:45 +00:00
Chris Allegretta
79cdfdc204 - nanorc.sample: - Fix the c-file regex for all caps words to be extended regex format ({} instead of \{\}) (found by DLR)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1267 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-08-22 02:58:55 +00:00
Chris Allegretta
82559b3ab0 - configure.ac: - Changed --enable-color warning to be slightly less severe
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1266 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-08-22 01:12:41 +00:00
Jordi Mallach
1f1022faaa Upgrade to Gettext 0.11.5.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1265 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-08-21 18:19:53 +00:00
David Lawrence Ramsey
0341b58c05 DLR: minor bits
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1264 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-08-21 16:10:37 +00:00
Jordi Mallach
64f49c7a99 German and Malay updates.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1263 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-08-18 22:08:25 +00:00
Jordi Mallach
3c2a7de9b6 Galician translation updates.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1261 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-07-31 23:48:57 +00:00
Jordi Mallach
7b01a0ff1c Added Claudio and Javier.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1260 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-07-31 23:05:51 +00:00
Jordi Mallach
5f8905ee69 Spanish translation updates (Ricardo Javier Cárdenes Medina).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1259 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-07-31 23:03:16 +00:00
Jordi Mallach
7a06bcc8c3 French translation update (Jean-Philippe Guérard).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1258 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-07-31 00:05:49 +00:00
Jordi Mallach
085f087743 Polish & Swedish translation updates.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1257 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-07-30 21:33:19 +00:00
Chris Allegretta
d865da108f DLR's latest and greatest
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1256 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-07-29 23:46:38 +00:00
Jordi Mallach
d793cc186f Catalan translation update.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1255 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-07-29 13:39:32 +00:00
Jordi Mallach
9a3c260315 Catalan translation updates.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1254 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-07-29 13:39:03 +00:00
Jordi Mallach
e5d06c08c6 Oops, really note changes.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1253 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-07-29 00:18:07 +00:00
Jordi Mallach
25daa05bf6 Swedish translation updates (Christian Rose).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1252 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-07-29 00:16:38 +00:00
Jordi Mallach
dd19573388 New Brazilian Portuguese translation (Claudio Neves).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1249 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-07-27 02:52:32 +00:00
Jordi Mallach
cb7c8d8172 Added pt_BR to ALL_LINGUAS.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1248 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-07-27 02:49:46 +00:00
Chris Allegretta
52069c6bb2 Back to CVS
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1247 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-07-25 22:27:50 +00:00
Chris Allegretta
720a9e0f8a GNU nano 1.1.10 release
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1245 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-07-25 22:26:33 +00:00
Jordi Mallach
3ec22383e9 Updated Indonesian translation (Tedi Heriyanto).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1244 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-07-25 16:07:50 +00:00
Chris Allegretta
70bb886849 Update the NEWS fo 1.1.10 in advance for laughs
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1243 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-07-24 01:34:13 +00:00
Chris Allegretta
7d5f3077ea Take out the DB color ChangeLog entry as I didn't put it in
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1242 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-07-24 01:19:40 +00:00
Chris Allegretta
dffa207320 Everything from DB's patch that makes any sense to me
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1241 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-07-24 01:02:26 +00:00
Chris Allegretta
c46337b9c7 Credit DLR for the tabs/spaces fixes in nano.h
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1240 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-07-23 00:34:48 +00:00
Chris Allegretta
1c5c338f95 Fix to parsing getopt args for -I/--ignorercfiles (DLR)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1239 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-07-23 00:33:07 +00:00
Chris Allegretta
87104114bd Get rid of annoying init error in read_file
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1238 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-07-21 15:46:48 +00:00
Chris Allegretta
c4e3d9ed01 Another DLR fixin: credits and DOS/Mac compatibility. Also get rid of those colons in ChangeLog after function names
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1237 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-07-21 15:44:13 +00:00
Chris Allegretta
cf287c87cd More DLR updates
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1236 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-07-20 13:57:41 +00:00
Chris Allegretta
6df90f5787 DLR and DB fixes mega-merge
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1235 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-07-19 01:08:59 +00:00
Jordi Mallach
cf2f6563ca Added Sharuzzaman (Bahasa Melayu).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1234 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-07-12 00:14:50 +00:00
Jordi Mallach
20eb232922 Upgrade automake requirements and add glib.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1233 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-07-09 22:21:13 +00:00
Jordi Mallach
2641d00c52 German translation updates (Michael Piefel).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1232 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-07-09 15:35:30 +00:00
Jordi Mallach
8bf8f890c3 Updated Danish translation (Keld Simonsen).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1231 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-07-07 19:08:00 +00:00
Jordi Mallach
7d401345c2 Merged acconfig.h into configure.ac.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1229 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-07-05 23:46:31 +00:00
Jordi Mallach
d9797bddc2 New Bahasa Melayu translation (Sharuzzaman Ahmat Raslan).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1226 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-07-03 09:49:20 +00:00
David Lawrence Ramsey
5db0cdc4c9 Carl Drinkwater's backup patch, plus miscellaneous fixes by David
Benbennick and me


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1225 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-06-28 22:45:14 +00:00
Jordi Mallach
fbc7920654 Use AM_GNU_GETTEXT([external]) to fix make distcheck now that intl/ is gone.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1224 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-06-28 12:31:16 +00:00
David Lawrence Ramsey
c5967551f6 Carl Drinkwater's titlebar spacing fixes, David Benbennick's help browser
fixes, and my regexp searching bug fix


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1223 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-06-21 03:20:06 +00:00
Jordi Mallach
834913c8b1 Added remove-potcdate.sed.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1222 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-06-13 16:09:51 +00:00
David Lawrence Ramsey
f21cd10a3f DLR: latest patch
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1221 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-06-13 00:40:19 +00:00
Jordi Mallach
790d362f41 Updated credits.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1220 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-06-03 12:44:05 +00:00
Jordi Mallach
bd338658be Upgraded to gettext 0.11.2.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1219 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-06-03 12:32:28 +00:00
Jordi Mallach
75d057238a Reformat for better reading.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1218 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-05-18 21:22:47 +00:00
Jordi Mallach
3ac937a023 Reformat: put open bugs at the top.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1217 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-05-18 21:15:24 +00:00
Chris Allegretta
5c6379d64f nanorc.sample - Put in much less crappy example regex rules for c-file
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1216 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-05-18 03:13:03 +00:00
Chris Allegretta
6fe98d7d76 - global.c:shortcut_init() - Rework IFHELP macro (David Benbennick)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1215 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-05-16 23:30:14 +00:00
Jordi Mallach
539e27f166 French and German updates.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1214 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-05-13 18:30:17 +00:00
Jordi Mallach
1f22687cd8 Italian, Galician, Catalan and Spanish updates.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1213 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-05-13 15:05:38 +00:00
Chris Allegretta
8b75a78f6f GNU nano 1.1.9 release
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1211 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-05-13 00:09:30 +00:00
Jordi Mallach
193d77527b Swedish updates.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1210 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-05-12 22:57:27 +00:00
Jordi Mallach
a5e889b7cf Added autom4ate.cache, whatever that is.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1209 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-05-12 21:24:11 +00:00
Chris Allegretta
5e76fe9997 Add same regfree call to color.c:update_color()
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1208 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-05-12 20:54:16 +00:00
Chris Allegretta
3674c1da71 - winio.c:edit_add() - Add in the necessary regfree() calls to stop nano from leaking memory like a sieve when using color syntax highlighting :-)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1207 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-05-12 20:43:49 +00:00
Chris Allegretta
6232d6659f DB's latest patch, minus one totsize--. Also fixed a < in help_init that should be <=
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1206 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-05-12 19:52:15 +00:00
Jordi Mallach
403f8dc0a3 Added nano.spec.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1205 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-05-11 16:02:31 +00:00
Chris Allegretta
4dc03d5733 DLR's latest patch
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1204 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-05-11 03:04:44 +00:00
Chris Allegretta
7c27be42d0 added an update_color, updated edit_add, i18ned a string and changed some getopt handlers in main to mallocstrcpy
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1203 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-05-05 23:03:54 +00:00
Jordi Mallach
ca76fa9b39 Swedish translation updates (Christian Rose).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1202 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-05-05 15:04:26 +00:00
Chris Allegretta
9dccc48a64 Update and space the nanorc.sample a bit better
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1201 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-05-04 04:27:06 +00:00
Chris Allegretta
21c433dca6 Global flag -Y, --syntax to specify the type on the command line, if there's no good filename regex to use. Global variable syntaxstr. Made some errors in the rc file less fatal
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1200 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-05-04 04:24:29 +00:00
Chris Allegretta
09900ff808 Global flag -Y, --syntax to specify the type on the command line, if there's no good filename regex to use. Global variable syntaxstr. Made some errors in the rc file less fatal
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1199 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-05-04 04:23:30 +00:00
Chris Allegretta
9189c1f258 Oops, get rid of the stupid debugging code
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1198 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-05-04 03:58:44 +00:00
Chris Allegretta
b6c5dc29ef - Added syntax command to .nanorc file, to allow multiple syntaxes. New function color.c:update_color(), calls in various files.c places, syntaxtype struct, global variables syntaxes, syntaxfile_regexp and synfilematches
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1197 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-05-04 03:47:33 +00:00
Jordi Mallach
42c6405572 s/Debian GNU/Linux/Debian GNU/g
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1196 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-04-30 02:33:14 +00:00
Jordi Mallach
934b76b0ed Indonesian translation updates (Tedi Heriyanto).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1195 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-04-25 22:24:48 +00:00
Chris Allegretta
dab017e786 - More cleanups with DISABLE flags, better free_shortcutage and free_toggle, and get rid of unnecessary variable decls with NANO_SMALL in shortcut_init() by David Benbennick
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1194 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-04-23 10:56:06 +00:00
Chris Allegretta
b275175bef Re-add O_CREAT since I botched the merge, some indentation fixes also, by DB
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1193 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-04-23 10:22:33 +00:00
Chris Allegretta
0547eb36c4 - General: - Change from read() and write() to file streams by Jay Carlson. Allows OS to implement read and write ahead rather than making us do it. Hopefully merged properly
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1192 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-04-22 23:52:34 +00:00
Chris Allegretta
2542274250 Prepend fixes for O_CREAT & append compatibililty by David Benbennick
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1191 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-04-21 23:15:36 +00:00
Jordi Mallach
0417a7b7f2 Russian and Ukrainian updates.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1189 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-04-19 21:59:35 +00:00
Chris Allegretta
0e9b7aa16d - General: - Preliminary prepend code. This may be a bad idea, but I've been wanting it for awhile now and we'll see how bad it messes everything up. Changes to files.c:do_writeout(), write_file()
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1188 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-04-16 03:15:47 +00:00
Jordi Mallach
7f80e6639f Italian translation updates (Marco Colombo).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1185 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-04-13 16:31:03 +00:00
Jordi Mallach
d301e10372 Dutch translation updates (Guus Sliepen).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1184 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-04-13 14:46:26 +00:00
Jordi Mallach
b18bc69b88 Swedish updates.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1174 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-04-10 16:26:17 +00:00
Chris Allegretta
f2387fbdf7 - Change to openfilestruct for multibuffer mode by DLR. New functions nano.c:make_new_opennode(), free_openfilestruct(), delete_opennode(), unlink_opennode(), splice_opennode(), new struct openfilestruct in nano.h
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1173 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-04-10 02:31:20 +00:00
Chris Allegretta
70feb4f8e5 Back that out, as it braks Linux :(
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1172 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-04-08 17:48:15 +00:00
Chris Allegretta
108ff58956 - FreeBSD compat. Remove KEY_DC from the delete shortcut in global.c:shortcut_init(), add case for 330 under nano.c:main()
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1171 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-04-08 17:44:10 +00:00
Chris Allegretta
7162e3d686 DB's latest patch
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1170 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-04-06 05:02:14 +00:00
Chris Allegretta
66f373f3e7 - nano.h: - NANO_ALT_COMMAND and NANO_ALT_PERIOD were reversed (lol) (David Benbennick)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1169 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-04-05 23:33:09 +00:00
Jordi Mallach
8349c92e09 gettext 0.11 writes to messages.mo by default.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1168 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-04-05 11:26:01 +00:00
Jordi Mallach
0ab011f54a ca, de, es, fr, gl updates.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1167 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-04-05 11:25:00 +00:00
Chris Allegretta
8902ebad43 - nano.spec.in: - Don't put Chris' name as the Packager in the distribution by default (Im an idiot)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1166 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-30 18:02:54 +00:00
Chris Allegretta
32b4c960ac Back to CVS ver
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1165 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-30 16:58:55 +00:00
Chris Allegretta
4ceb30cfe7 GNU nano 1.1.8 release
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1163 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-30 16:56:53 +00:00
Chris Allegretta
ec8c1bc79d Fix the formatting of the spec a leetle
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1162 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-30 16:52:42 +00:00
Chris Allegretta
06d62372dc - Added new nano.spec file from Brett <brett@bad-sports.com>, added because maintaining the spec file is getting to be a large
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1161 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-30 16:51:38 +00:00
Chris Allegretta
78f0fc61ff rcfile fixes
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1160 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-29 19:41:57 +00:00
Chris Allegretta
77777d4c0d Add David Benbennick's changes to open_pipe() and move it to nano.c, and add his nperror function
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1159 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-29 16:31:29 +00:00
Chris Allegretta
9b4055c4da Bah, don't fix what isn't broken
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1158 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-29 16:00:59 +00:00
Chris Allegretta
6ca01b1cd8 - nano.c: - Move the termios things in main() up to signal_init(), where they should probably be anyway
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1157 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-29 15:38:17 +00:00
Chris Allegretta
8e207bf03f - nano.c: - Move the termios things in main() up to signal_init(), where they should probably be anyway
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1156 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-29 15:31:54 +00:00
Chris Allegretta
f3a07b2d7e - winio.c:do_cursorpos() - Make col numbering start from 1 (suggested by Andrew Ho)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1155 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-29 15:15:38 +00:00
Chris Allegretta
e373909037 - files.c:do_insertfile() - Handle cancel from ExtCmd properly (David Benbennick)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1154 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-29 15:06:05 +00:00
Jordi Mallach
465a0ffa15 Danish updates.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1153 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-29 00:46:05 +00:00
Chris Allegretta
2598c66d81 DLR's patch
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1152 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-28 01:59:34 +00:00
Jordi Mallach
7afc6d9468 Italian updates (Marco Colombo).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1151 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-27 16:34:46 +00:00
Chris Allegretta
d1c2c1ca76 - search.c:do_gotoline() - Set placewewant if we actually move to a different line
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1150 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-26 17:58:42 +00:00
Chris Allegretta
f6cba64376 David's fixes for read_file and the assert stuff for renumber
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1147 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-26 13:05:54 +00:00
Chris Allegretta
bb88ece93c Rocco's mods to open_pipe
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1145 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-25 13:40:39 +00:00
Chris Allegretta
f21f3fcc1e - nano.c:do_int_speller() - Fix zombie processes and spelling buffer issues (Rocco Corsi)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1143 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-25 03:26:27 +00:00
Jordi Mallach
9c20ab0d5e Indonesian translation updates.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1142 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-25 01:13:59 +00:00
Chris Allegretta
373bc2fa48 General - Added separate regex variable (color_regex and colormatches) so that color syntax and regex search/replace can coexist
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1141 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-24 23:20:32 +00:00
Chris Allegretta
3533a348fc General - Added separate regex variable (color_regex and colormatches) so that color syntax and regex search/replace can coexist
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1140 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-24 23:19:32 +00:00
Chris Allegretta
b23d14460e Redo open_pipe with just pipes and no FIFOs
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1138 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-21 23:39:56 +00:00
Chris Allegretta
cf1d812ccb - nano.c:do_justify() - More fixes for indented justify (David Benbennick)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1137 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-21 19:53:36 +00:00
Chris Allegretta
52c5a6ea48 External command code and fix for BUG #70
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1136 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-21 05:07:28 +00:00
Jordi Mallach
7fa082dc90 French translation updates (Jean-Philippe Guérard).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1133 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-17 00:35:41 +00:00
Chris Allegretta
dce44abec7 winio.c:do_credits() - Add Thomas Dickey
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1131 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-16 01:03:41 +00:00
Jordi Mallach
b83e61aea0 Polish translation updates (Wojciech Kotwica).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1130 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-15 15:15:13 +00:00
Jordi Mallach
286ee1faff Fix date.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1129 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-14 11:01:21 +00:00
Jordi Mallach
057c3c4aba Russian and Ukrainian translation updates (Sergey A. Ribalchenko).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1128 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-14 11:00:56 +00:00
Jordi Mallach
6e6a7ac493 Iberian translations update.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1127 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-12 17:23:07 +00:00
Jordi Mallach
5477e1028a Galician translatin updates (Jacobo Tarrio).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1126 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-12 16:15:50 +00:00
Jordi Mallach
558b5d8774 French translation updates (Jean-Philippe Guérard).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1125 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-11 13:23:33 +00:00
Chris Allegretta
45329a127a Rocco's fixes
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1124 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-10 01:22:21 +00:00
Chris Allegretta
d1ec7b0287 Allow flags with args to be translatable
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1123 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-09 20:05:26 +00:00
Chris Allegretta
b479c89594 - nano.c:help_init() - Various fixes and string changes
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1122 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-09 20:03:10 +00:00
Chris Allegretta
1f8394d4bc Add newlines to gotodir help text
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1121 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-09 19:58:18 +00:00
Jordi Mallach
f7277b8176 Header fixes.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1120 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-09 19:42:08 +00:00
Chris Allegretta
3fc5d5722c - nano.c:usage() - Rewritten to encompass systems with and without GETOPT_LONG. New function print1opt does most of the dirty work, stops duplication of effort and eases translator's jobs. Also breaks all the current translations ;-)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1119 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-09 18:51:58 +00:00
Jordi Mallach
4e803aa59b Catalan, Indonesian and Spanish translation updates.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1118 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-09 18:05:53 +00:00
Chris Allegretta
97e6fe6331 - nano.c:usage() - Add -N to short format (no GETOPT_LONG) strings (noticed by Jordi)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1117 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-09 17:38:47 +00:00
Jordi Mallach
4951c66adc German & Swedish translation updates.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1116 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-07 14:12:53 +00:00
Chris Allegretta
5902f9672d - nano.c:help_init() - Capitalize Meta altkeys
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1115 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-07 12:40:39 +00:00
Chris Allegretta
e8e10347a9 - rcfile.c:parse_rcfile() - Don't use i for both for loop and atoi(), fixes lots of potential crashes, 1st reported by Jean-Philippe Gue'rard
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1114 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-07 00:47:22 +00:00
Chris Allegretta
1596d38698 - rcfile.c:parse_rcfile() - Don't use i for both for loop and atoi(), fixes lots of potential crashes, 1st reported by Jean-Philippe Gue'rard
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1113 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-07 00:46:17 +00:00
Jordi Mallach
79dcc475a7 Groar. Kill it this time.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1112 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-06 16:17:49 +00:00
Chris Allegretta
564535a6f7 - files.c:check_writable_directory() - Stat full_path, not path (Steven Kneizys)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1111 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-06 15:32:17 +00:00
Chris Allegretta
40ecbad296 NANO_SMALL issues
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1110 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-06 15:27:44 +00:00
Jordi Mallach
ee91f71a66 shitstamp
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1109 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-06 10:58:52 +00:00
Chris Allegretta
bef1297c6d Type misalignments and mem leaks in renumber_all, do_justify and do_spell (Rocco & Steven Kneizys)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1108 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-06 03:30:40 +00:00
Chris Allegretta
26d59eae5f Back to CVS
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1107 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-05 23:49:14 +00:00
Chris Allegretta
97489d211f GNU nano 1.1.7 release
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1105 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-05 23:47:44 +00:00
Chris Allegretta
46c1b9e344 nano.c:do_justify() - Don't continue to justify string if it's indented more (quoting wise) than the beginning of the justification
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1104 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-05 19:58:45 +00:00
Chris Allegretta
d4fa0d3904 justify_format(), do_justify() - Various fixes for starting blank spaces, spaces after punctuation, & segfault with quoting strings (David Benbennick)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1103 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-05 19:55:55 +00:00
Jordi Mallach
46e3118e9d We actually need ac 2.52.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1102 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-05 18:59:56 +00:00
Jordi Mallach
87435d9223 Removed m4 stuff from topdir Makefile.am, again.
Added a small macro that tells configure.ac where to look for macros.
Removed cruftly stamp-h.in from rep.


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1101 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-05 17:58:34 +00:00
Jordi Mallach
a3322fd65d Polish translation updates (Wojciech Kotwica).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1100 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-05 11:23:17 +00:00
Chris Allegretta
459c03d3fc Ugh\! Re-readding the M4 stuff because I don't want to have to run autogen every time I touch configure.ac
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1099 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-04 22:29:19 +00:00
Chris Allegretta
6324530ec8 Minor fix for quote code, forgot to adjust null by qdepth
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1098 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-04 18:12:28 +00:00
Jordi Mallach
7a053fc431 Added -N, -Q.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1097 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-04 17:35:44 +00:00
Chris Allegretta
fd0fe7ef15 Prototype fix for get_full_path (DLR)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1096 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-04 16:30:17 +00:00
Chris Allegretta
40639ddc0c Fixed broken mouse handling with new shortcut setup
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1095 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-04 12:25:34 +00:00
Chris Allegretta
309aa50fda Fix typo and add man page
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1094 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-04 12:15:44 +00:00
Chris Allegretta
d76ca2bc9f Add rcfile support for quotestr and fix strcasestr
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1093 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-03 22:52:52 +00:00
Chris Allegretta
e4f940dbaa - Preliminary quoting support for justify. New arg -Q, --quotestr, changes to do_justify(), global variable quotestr()
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1092 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-03 22:36:36 +00:00
Chris Allegretta
5f87021c08 Make do_cursorpos() use xpt() instead of just current_x which is inaccurate
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1091 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-01 02:25:35 +00:00
Chris Allegretta
6f746000c0 Back out M4 stuff in Makefile.am since it doesn't seem to be needed - wtf
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1090 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-03-01 00:34:49 +00:00
Chris Allegretta
99ed9dc9fe - utils.c:strcasestr(),revstrcasestr() - Renamed to stristr and revstristr since strcasestr has not been confirmed to be detected properly on various Linux systems
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1089 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-02-28 00:57:18 +00:00
Chris Allegretta
6235a7d6d5 Get rid of stupid uninitialized warnings and move nano_dos_msg and nano_mac_msg into NANO_SMALL check
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1087 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-02-27 04:38:32 +00:00
Chris Allegretta
2d698b7132 Makefile.am: - Re-added M4DIR & ACLOCAL_AMFLAGS, make seems to fail without it Jordi ;-)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1086 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-02-27 04:16:52 +00:00
Chris Allegretta
f5de33a6ef - Many malloc() cleanups and files.c tweaks by Steven Kneizys, new functions utils.c:free_shortcutage() (got to love that name\!) & free_toggles(), and big cleanup program thanks_for_all_the_fish() (originally thanks_for_the_memories()). Mods to shortcut_init() by Chris
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1085 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-02-27 04:14:16 +00:00
Jordi Mallach
bbcac936a0 I suck. Forgot to add m4 to SUBDIRS, and typoed m4/Makefile.am. All in the same commit!
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1084 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-02-26 23:18:49 +00:00
Jordi Mallach
f821db9b1f Argh. Now call autoheader after aclocal.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1083 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-02-26 22:49:02 +00:00
Jordi Mallach
3c5653d83e Move to autoconf 2.5.
configure.in moved to configure.ac, to make things completely obvious.
Removed m4/largefile.m4, which is provided by ac2.5, and add Makefile.am for that dir.
Updated README.CVS to reflect this.


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1082 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-02-23 18:23:43 +00:00
Chris Allegretta
48b06708ff Multiple unnamed buffers allowed, multiple filename extensions on die_save_file(), more DLR fixes
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1081 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-02-22 04:30:50 +00:00
Chris Allegretta
3a6d70dfb6 Get rid of unneeded skip var
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1080 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-02-22 03:29:43 +00:00
Jordi Mallach
2ce9205823 Fix header.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1079 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-02-20 16:23:22 +00:00
Jordi Mallach
62d2171745 Dutch translation updates (Guus Sliepen).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1078 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-02-20 16:21:27 +00:00
Chris Allegretta
ff8a68c258 rcfile.c:do_rcfile() - Parse rcfile in as well (Dwayne Rightler)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1077 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-02-16 20:34:57 +00:00
Chris Allegretta
bc72e366d2 Added Ken's patch, DLR's latest fixes and a little cleanup to bottombars()
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1076 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-02-16 20:03:44 +00:00
Chris Allegretta
7e65d2f5ad Get rid of unnecessary stuff in help_init() that was commented out
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1075 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-02-15 21:12:52 +00:00
Chris Allegretta
9caa193fe1 407 == ^z fix, get rid of unusaed variables
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1074 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-02-15 20:08:05 +00:00
Chris Allegretta
a8c225787b DLR's patch merged, Static toggles and shortcut gone, lots of stuff changed
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1073 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-02-15 19:17:02 +00:00
Jordi Mallach
025a42c67f Norwegian bokmål translation updates (Stig E Sandø).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1072 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-02-15 18:55:06 +00:00
Jordi Mallach
e46d43d299 Norwegian bokmål translation updates (Stig E Sandoe).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1070 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-02-15 17:13:11 +00:00
Jordi Mallach
507c361bcf Danish translation updates (Keld Simonsen).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1069 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-02-14 18:57:23 +00:00
Chris Allegretta
a824a9af9d Remove RELATIVECHARS from nano.h (DLR)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1068 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-02-14 01:29:07 +00:00
Chris Allegretta
f27c69703d - winio.c:do_cursorpos() - Rewritten to show col place as well as charcter place, without needing an entirely separate flag
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1067 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-02-12 01:57:24 +00:00
Jordi Mallach
7eccc7991c Hungarian translation updates (Gergely Nagy).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1065 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-02-09 23:15:44 +00:00
Chris Allegretta
40b85e7aca - Makefile.am: - Change localedir line to 1.0's version
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1064 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-02-09 21:56:09 +00:00
Jordi Mallach
b3b28c19b5 Russian and Ukrainian translation updates (Sergey A. Ribalchenko).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1062 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-02-07 13:51:00 +00:00
Jordi Mallach
8bfd3114be Hungarian translation updates (Gergely Nagy).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1061 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-02-06 20:53:04 +00:00
Jordi Mallach
94def068ef Partial Czech translation updates (Vaclav Haisman).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1060 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-02-06 12:14:25 +00:00
Chris Allegretta
3d8e759a4c Allow " symbol to be in regex without leading by checking for *ptr+1 is not the end of the regex
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1057 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-02-02 07:13:02 +00:00
Chris Allegretta
db3dc57a7e Update the Sourceforge lists to the GNU ones
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1056 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-02-01 13:40:34 +00:00
Jordi Mallach
a039b57d05 Oops, correct anonymous user name.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1055 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-31 09:53:57 +00:00
Jordi Mallach
02f3394917 Changed recommendation on automake to -p5, not -p4.
Moved to Savannah repositories.
Added a hint to download the stable branch.


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1054 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-30 16:29:31 +00:00
Chris Allegretta
8dbfb5c2ce Re-add the changes since the CVS tarball was made *argh*
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1052 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-28 15:56:15 +00:00
Jordi Mallach
8636f7b66a French, German and Norwegian nynorsk updates.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1051 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-26 19:23:37 +00:00
Chris Allegretta
3c597d0b91 - nanorc.sample - Mention unset in the sample nanorc
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1050 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-26 03:42:14 +00:00
Chris Allegretta
2440a5199c Mention unset in the sample nanorc
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1049 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-26 03:34:06 +00:00
Jordi Mallach
9c34a167d8 French and Swedish translation updates.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1048 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-26 00:46:47 +00:00
Chris Allegretta
14b3ca94b7 - General - New flag RELATIVECHARS to show column positino relative to the current line instead of the current file. New flag -C, --relative, changes to do_cursorpos()
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1046 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-25 21:59:02 +00:00
Jordi Mallach
83ffefbfdd Catalan and Spanish updates.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1045 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-25 21:00:18 +00:00
Chris Allegretta
121b9b99f9 Back to CVS
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1043 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-25 17:04:18 +00:00
Chris Allegretta
491029ed8d GNU nano 1.1.6 release
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1041 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-25 17:02:32 +00:00
Chris Allegretta
915b680e6b Oops, add glib21.m4 to the m4 dir
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1040 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-24 22:00:50 +00:00
Chris Allegretta
54c7b16cf1 Oops, make that NANO_AM_GNU_GETTEXT
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1039 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-24 14:18:05 +00:00
Jordi Mallach
b9b9f5cf94 Added depcomp.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1038 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-23 13:32:55 +00:00
Jordi Mallach
380076ba55 Catalan & Spanish updates.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1037 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-23 13:24:38 +00:00
Jordi Mallach
9045319eb8 CVS usage documentation.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1036 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-23 13:20:20 +00:00
Chris Allegretta
4756de366e No Im not releasing 1.1.6 yet
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1035 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-23 02:38:52 +00:00
Chris Allegretta
05f4065960 Add the codeset.m4 and iconv.m4 entries to Makefile.am
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1034 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-23 02:37:36 +00:00
Chris Allegretta
28ab38ddad Add all of automake 1.4s .m4 files
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1033 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-23 02:27:19 +00:00
Chris Allegretta
bb7bbed753 Downgraded from automake 1.5, as there are severe security implications
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1032 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-23 01:17:23 +00:00
Chris Allegretta
24e48d8314 Downgraded from automake 1.5, as there are severe security implications
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1031 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-23 01:06:20 +00:00
Chris Allegretta
34f8098045 - rcfile.c:General - Added stdarg.h to includes
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1030 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-22 20:09:20 +00:00
Chris Allegretta
1c2fddcb40 - search.c:do_search() - Check position of cursor and return value of findnextstr and tell user if search string only occurs once (Rocco & Chris)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1029 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-21 20:40:14 +00:00
Chris Allegretta
23b74b226e - nano.c:do_int_spell_fix() - Temporarily unset REVERSE_SEARCH if it's set (Rocco Corsi)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1028 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-21 20:32:22 +00:00
Chris Allegretta
b2cd10d57c - nano.c:do_char() - Run edit_refresh() if ENABLE_COLOR is defined so adding multi-liners will update (e.g. /* in C)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1027 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-20 00:54:42 +00:00
Chris Allegretta
9963b0e885 - .cvsignore - Added config.guess config.sub install-sh missing & mkinstalldirs
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1026 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-19 19:35:12 +00:00
Jordi Mallach
fef9d86fae autoheader should be called before.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1025 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-19 19:23:55 +00:00
Chris Allegretta
3351ce15a9 - Upgraded missing and installdirs scripts
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1024 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-19 19:23:21 +00:00
Jordi Mallach
a437e54b7a Oh, asty...
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1023 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-19 19:20:44 +00:00
Chris Allegretta
15b23f46c3 - Upgrade to gettext 0.10.40, probably broke everything again :)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1022 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-19 19:15:18 +00:00
Chris Allegretta
6c1e6612ad - General - Added multiple-line regex support. Format in .nanorc is start=regex end=regex. Cleaned up nanorc:parse_colors(), added parse_next_regex(), changes to edit_add in winio.c(), changes to colortype, cleaning up some old cruft
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1021 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-19 16:52:34 +00:00
Chris Allegretta
598106e55a re-indent winio.c
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1020 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-19 01:59:37 +00:00
Jordi Mallach
69bba322f5 Catalan and Spanish updates, sync with CVS.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1019 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-18 23:32:22 +00:00
Jordi Mallach
394797c15e Fix typo.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1018 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-18 23:16:33 +00:00
Jordi Mallach
3a23a55018 Danish translation update (Keld Simonsen).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1017 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-18 23:04:16 +00:00
Chris Allegretta
f478f8361e Latest color and regex fixes. Multi-line color doesn't work yet, just syncing in case of disaster
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1016 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-18 21:54:35 +00:00
Jordi Mallach
5285ca9d0a Show --enable-multibuffer independently of --enable-extra.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1015 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-17 12:40:33 +00:00
Jordi Mallach
78aad94851 Translation updates since 1.1.5.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1014 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-17 12:22:15 +00:00
Jordi Mallach
d6481e4fc1 Hm, fix entry.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1011 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-17 12:14:23 +00:00
Jordi Mallach
83d5cede73 Added new Norwegian translations, fixed THANKS.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1010 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-17 12:06:49 +00:00
Jordi Mallach
8a97efc2f8 Moved no.po to nn.po.
New Norwegian bokmål translation, by Stig E Sandoe <stig@ii.uib.no>.
Updated Norwegian nynorsk translation, by Kjetil Torgrim Homme <kjetilho@linpro.no>.


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1009 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-17 11:54:37 +00:00
Chris Allegretta
ea250e8b90 - color.c:do_colorinit() - Moved some comments and braces around so color can work w/slang (DLR)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1005 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-16 01:09:11 +00:00
Chris Allegretta
438f713b3f - nano.c:do_wrap() - Move right increment to part where new line is created, should change (fix?) some wrapping problems with autoindent
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1004 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-16 00:54:47 +00:00
Chris Allegretta
e29697d210 - search.c:findnextstr() - Fix off by one in check for wrap around (Rocco Corsi)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1002 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-14 03:31:10 +00:00
Rocco Corsi
562964dab3 Minor bracket alignment fix
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1001 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-13 03:18:03 +00:00
Jordi Mallach
6f8222a8cc Typo fix.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@999 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-12 22:15:41 +00:00
Jordi Mallach
7ced6bf54b Yet another French translation update.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@998 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-12 02:31:38 +00:00
Chris Allegretta
5bbce6a847 Oops, make that Bug #68 :-)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@994 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-10 12:48:16 +00:00
Chris Allegretta
7b0667fa7a - nano.c:do_suspend() - Call tcsetattr() to restore the old terminal settings, so tcsh can use ^C after suspend for example (fixes BUG #67)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@992 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-10 12:44:21 +00:00
Chris Allegretta
967a1e28f6 - General - Add Alt-G (NANO_ALT_GOTO_KEY) as alternate for goto dir in browser
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@991 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-10 00:50:38 +00:00
Jordi Mallach
c2c9b64705 New French updates.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@990 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-09 23:54:24 +00:00
Chris Allegretta
1bc0c7e047 - Better partial word checking code. New function search.c:is_whole_word(), changes to findnextstr(), and nano.c:do_int_spell_fix() (Rocco Corsi)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@989 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-08 15:00:24 +00:00
Jordi Mallach
bf1a1e84e2 French, Russian and Ukrainian translation updates.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@988 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-08 14:07:39 +00:00
Chris Allegretta
044d1b1a6e - General - Add Meta-A as alternate keyystroke for ^^ for people with non-US keyboards, and fix one missed NANO_ALT_R that should be NANO_ALT_REPLACE_KEY
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@987 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-08 00:33:32 +00:00
Chris Allegretta
f7dee92189 main() alt val - 32 check fix, and shortcut_init() fix in global.c for hard coded values
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@986 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-07 16:43:25 +00:00
Jordi Mallach
d39698ff1f German translation update (Michael Piefel).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@985 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-07 15:16:26 +00:00
Jordi Mallach
e36a15209a Swedish translation update.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@984 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-07 15:12:48 +00:00
Chris Allegretta
3d0739c384 - winio.c:edit_refresh() - Rename lines to nlines to fix AIX breakage (reported by Dennis Cranston, re-reported by arh14@cornell.edu)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@983 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-07 14:41:32 +00:00
Jordi Mallach
3da9139159 Catalan and Spanish translation updates.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@982 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-07 11:50:13 +00:00
Jordi Mallach
345a8467ae Fixed --keypad description.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@981 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-07 11:35:16 +00:00
Chris Allegretta
d17519321e Back to CVS ver
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@980 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-05 20:01:53 +00:00
Chris Allegretta
110927bbc5 GNU nano 1.1.5 release
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@978 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-05 19:49:06 +00:00
Chris Allegretta
a16e4e96c0 - winio.c:statusq() - Initialize "list"
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@977 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-05 18:59:54 +00:00
Chris Allegretta
bdea41e2c1 Update TODO with -l and -g done, add NEWS for 1.1.5 release
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@976 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-05 18:54:43 +00:00
Chris Allegretta
d49ec07cae Update nano.1.html to match -K option
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@975 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-05 04:08:01 +00:00
Chris Allegretta
1bf8f5e9d2 - winio.c:edit_add() - Little fixes to let color highlights not bleed onto the next line
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@974 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-05 03:30:10 +00:00
Chris Allegretta
66577acae1 Slightly better version of the fix
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@973 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-05 02:03:29 +00:00
Chris Allegretta
e5b9eacd89 winio.c:bottombars() - Get rid of that annoying reversed line when color is on! :)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@972 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-05 01:52:02 +00:00
Jordi Mallach
6d6edd6fe0 Newer config.guess and config.sub
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@971 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-04 18:16:50 +00:00
Jordi Mallach
ae08077dfc Mark some items as [DONE].
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@970 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-04 18:09:07 +00:00
Jordi Mallach
2391bf499b DLR moved to AUTHORS.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@969 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-04 18:04:08 +00:00
Jordi Mallach
cb0cbcc058 Added -K item.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@968 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-04 18:00:24 +00:00
Jordi Mallach
8ae5789447 Updated copyright notices to 2002.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@967 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-04 17:57:40 +00:00
Jordi Mallach
65f3e42de3 Polish translation update (Wojciech Kotwica).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@966 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-04 17:48:58 +00:00
Chris Allegretta
fae0dce708 Add DLR to AUTHORS
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@965 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-04 13:30:42 +00:00
Chris Allegretta
48bd37812b - The keypad handling has changed (again). We now use the keypad() function by default. New flag -K, --keypad allows the old behavior for those using the keypad arrow keys and rxvt-based terminals
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@964 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-03 21:26:34 +00:00
Jordi Mallach
13f3017d0f French translation update (Jean-Philippe Guérard).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@962 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-02 18:45:58 +00:00
Chris Allegretta
32da456ab0 DLR's latest patch: view+multibuffer, die() fixes, insert key fixes in main()
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@961 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-02 15:12:21 +00:00
Chris Allegretta
180a569fdb - nano.c:help_init() - Typo in file switch string (found by David Lawrence Ramsey). main() - Handle Alt prev/next file keys (,.), as well as normal ones (<>).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@960 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-02 14:30:33 +00:00
Chris Allegretta
13fd44bfe4 Get rid of \n in abort check of parse_next_word(), new var helplen in help_init()
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@959 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2002-01-02 13:59:11 +00:00
Jordi Mallach
327939843d German translation update (Michael Piefel).
Ukrainian translation update (Sergey A. Ribalchenko).


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@957 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-12-28 16:35:28 +00:00
Jordi Mallach
78e2c9d844 Italian translation update (Marco Colombo).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@956 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-12-27 22:06:38 +00:00
Chris Allegretta
64dd95dd75 files.c:read_file() - Make conversion message less confusing (suggested by Jordi)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@955 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-12-27 20:53:54 +00:00
Jordi Mallach
05d8ce9adf Galician translation update (Jacobo Tarrío).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@954 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-12-27 20:34:42 +00:00
Jordi Mallach
1a58fb46f5 French translation update (Michel Robitaille).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@952 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-12-27 16:00:23 +00:00
Jordi Mallach
cf9f783d26 Faq fixes.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@949 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-12-26 12:33:01 +00:00
Jordi Mallach
a4ffccb321 New incomplete Polish translation, contributed by Cezary Sliwa <sliwa@cft.edu.pl>.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@947 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-12-26 00:31:17 +00:00
Jordi Mallach
f4e572919d Typo fix.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@944 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-12-26 00:16:40 +00:00
Jordi Mallach
414acab0ce Updated Catalan translation.
More Spanish fixes.


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@943 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-12-26 00:15:16 +00:00
Jordi Mallach
5b85366a50 Typo fix.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@942 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-12-25 20:39:59 +00:00
Jordi Mallach
11f39e7044 Updated Spanish translation.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@941 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-12-25 19:17:32 +00:00
Jordi Mallach
39d02c4796 Russian translation update (Sergey A. Ribalchenko).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@940 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-12-25 18:31:53 +00:00
Jordi Mallach
9335f91085 Made two strings translatable.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@939 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-12-23 00:03:18 +00:00
Jordi Mallach
77b12326c8 Swedish translation update (Christian Rose)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@938 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-12-22 23:23:40 +00:00
Chris Allegretta
3c57e50db8 - winio.c:update_line() - set realdata check to >= 1 && <= 31, lack of > 0 check screwed high ascii chars
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@937 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-12-19 16:20:43 +00:00
Chris Allegretta
cf6807100b m4/gettext.m4: - Back down to 1.1.3 version
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@936 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-12-18 14:59:20 +00:00
Chris Allegretta
52db7a2c3d - winio.c:update_line() - back out check for (realdata[i] < 32) as it will screw high ascii characters
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@932 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-12-17 23:39:36 +00:00
Chris Allegretta
0bb70dcda5 VDSUSP fix from 1.0 tree
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@931 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-12-17 04:34:23 +00:00
Chris Allegretta
5fd6cacfa5 Back to CVS
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@925 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-12-12 13:55:19 +00:00
Chris Allegretta
7bf2509a70 GNU nano 1.1.4 release
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@923 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-12-12 02:44:40 +00:00
Chris Allegretta
9c23a44907 Remove some debug code and update to mutt's gettext.m4
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@922 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-12-12 01:45:01 +00:00
Chris Allegretta
7dd7768bb6 Fix the ifdefs in winio.c
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@921 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-12-08 19:52:28 +00:00
Jordi Mallach
df59ae64e9 French update, by Michel Robitaille <robitail@IRO.UMontreal.CA>
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@920 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-12-07 14:00:56 +00:00
Jordi Mallach
b439622d3a Fixed typos.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@918 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-12-05 17:51:02 +00:00
Chris Allegretta
8083827088 do_spell() - Dont prompt for replace if we don't change the word in question (Rocco Corsi).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@917 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-12-02 06:03:22 +00:00
Chris Allegretta
db4c08e8f9 stoopid unused variable
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@916 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-12-02 05:13:34 +00:00
Chris Allegretta
2fa11b836d Two fixes, create new colorstrings array for each regex, allows proper order of highlighting, second make color work with the marker
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@915 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-12-02 04:55:44 +00:00
Chris Allegretta
86c9676f7a Fix leftover variable
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@914 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-11-29 03:52:21 +00:00
Chris Allegretta
81cbfad086 Comment out more debugging code
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@913 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-11-29 03:49:09 +00:00
Chris Allegretta
2084acc37d At LONG last committed David's patch
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@912 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-11-29 03:43:08 +00:00
Chris Allegretta
3795e5fc76 Damn newline code
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@911 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-11-29 03:03:18 +00:00
Chris Allegretta
08893e08e3 Preliminary syntax highlighting support. New functions colortoint() and parse_color() in rcfile.c, new code in edit_add() in winio.c to actually do the highlighting. It's not even close to pretty yet :P
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@910 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-11-29 02:42:27 +00:00
Jordi Mallach
feebeb90ea Danish and Spanish updates.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@909 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-11-19 12:09:51 +00:00
Chris Allegretta
9b8b370132 Put 1.0 Hurd fixes in 1.1 tree (function keys, SIGTSTP sigaction
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@908 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-11-19 05:09:15 +00:00
Jordi Mallach
8c9c572309 Updated German, Swedish and Russian translations.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@904 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-31 13:02:12 +00:00
Jordi Mallach
33088740da Added aclocal.m4, config.in.h.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@900 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-29 13:32:06 +00:00
Jordi Mallach
1fa00797ef Removing autogenerated files.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@899 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-29 13:29:19 +00:00
Jordi Mallach
6859079638 Added nano.info.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@898 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-29 13:27:12 +00:00
Jordi Mallach
773623c066 Typo fixes in help strings.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@896 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-28 21:00:49 +00:00
Chris Allegretta
0567bfe14c files.c:add_open_file() - Get rid of unsetting MARK_ISSET because otherwise writing marked text will automatically unset the marker with multibuffer enabled
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@894 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-28 14:42:18 +00:00
Chris Allegretta
8c8d370470 global.c: - Define currshortcut and currslen when either DISABLE_MOUSE or DISABLE_HELP or DISABLE_BROWSER is not defined (Silvan Minghetti)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@893 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-28 05:00:39 +00:00
Chris Allegretta
22ec59a073 global.c: - Define currshortcut and currslen when either DISABLE_MOUSE or DISABLE_BROWSER is not defined (Silvan Minghetti)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@892 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-28 04:56:08 +00:00
Chris Allegretta
f3e80adbe4 Oops, typo in dec there, it's Alt-[-whatever
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@891 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-28 04:49:10 +00:00
Chris Allegretta
7bf7274d9f nano.c:main() - Add Esc-[IGL] keys for FreeBSD Console (PgUp,PgDn,Insert)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@890 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-28 04:29:55 +00:00
Chris Allegretta
7b409bd6b6 Back to CVS
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@889 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-26 16:15:58 +00:00
Chris Allegretta
dc57bbab7a Nano 1.1.3 release
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@887 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-26 16:14:45 +00:00
Chris Allegretta
6d0aa9f3b7 More do_prev_word() fixes
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@886 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-26 15:21:41 +00:00
Chris Allegretta
e59fc829d8 Okay, now fix do_prev_word so it doesn't crash when it hits a blank line, it's still not perfect =/
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@884 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-24 18:07:58 +00:00
Chris Allegretta
a1a6a7fda6 Oopos, wrote the test backwards :-)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@880 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-24 17:34:29 +00:00
Chris Allegretta
107864058b nano.h: Additional #define, SMALL_TOO to determine how long MAIN_LIST_LEN is. We need this because of the find matching bracket code
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@879 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-24 17:27:46 +00:00
Chris Allegretta
2cd72b6aa2 Back out off by one fix that's not actually off by one, it was a different bug :-)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@878 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-24 17:25:36 +00:00
Chris Allegretta
3a24f3f780 Changed header comments to say "version 2" instead of "version 1" as the COPYING file is actually version 2 of the GPL (bug noticed by Jordi Mallach)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@873 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-24 11:33:54 +00:00
Chris Allegretta
347c184b6f nano.c:main() - Moved #ifndef NANO_SMALL down past the case 0: line so control-space doesn't insert a \0 (ack!)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@872 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-24 01:37:13 +00:00
Chris Allegretta
48ebb81fb2 nano.c:main() - Fixed off by one when checking for MAIN_LIST_LEN. Ugh.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@871 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-24 01:34:15 +00:00
Chris Allegretta
abf22a8fb2 - nano.c: - Added the #ifdefs around do_prev_word the code in main()
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@870 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-24 00:58:19 +00:00
Chris Allegretta
e7ee63f271 - cut.c: cut_marked_segment() - Fix off-by one in mem allocation
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@868 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-23 12:58:42 +00:00
Chris Allegretta
fa0c6963ce Fixed null_at to ACTUALLY DO SOMETHING with its arg. Again, this was causing nasty errors if the call to nrealloc moved where the data was located
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@866 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-22 23:22:19 +00:00
Chris Allegretta
878ced39bf - nano.c:do_prev_word() - Fixed goofy logic setting x pos to value of last line when hitting the beginning of first line, prog should simply abort.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@865 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-22 20:05:34 +00:00
Chris Allegretta
b3655b4c5e DLR's cut and miscellaneous fixes, my cut fixes, and context-sensitive help, woohoo
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@864 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-22 03:15:31 +00:00
Jordi Mallach
fac011a5e1 I mean add, not replace... duh.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@863 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-20 12:30:46 +00:00
Jordi Mallach
9f4e583e52 Added stamp-h1
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@862 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-20 12:30:12 +00:00
Chris Allegretta
beead28619 - faq.html - Removed nano-editor.org FTP site address [deprecated] and added the GNU one
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@860 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-18 14:15:28 +00:00
Jordi Mallach
eb94b9edcd Updated Ukrainian translation (Sergey A. Ribalchenko).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@859 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-15 14:26:48 +00:00
Chris Allegretta
76e291beee Added conversion messages for DOS and Mac files, and Alt-space as do-previous-word
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@858 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-14 19:05:10 +00:00
Jordi Mallach
ab23fbd019 Updated Russian translation (Sergey A. Ribalchenko).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@856 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-08 14:05:36 +00:00
Jordi Mallach
26f4603a89 Style updates for Spanish, by Santiago Vila.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@855 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-07 15:53:27 +00:00
Jordi Mallach
2476ebd31b Updated Danish translation (Keld Simonsen).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@854 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-07 00:26:26 +00:00
Jordi Mallach
482d165ab5 Updated Swedish translation (Christian Rose).
Updated gl.po from TP.


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@853 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-06 02:36:25 +00:00
Jordi Mallach
02a24525c5 Small typo fix.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@852 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-05 10:58:07 +00:00
Jordi Mallach
cdcac1ccc2 And what if I actually fix it?
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@851 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-05 03:26:52 +00:00
Jordi Mallach
633dab0340 Darn, that %s vs %d bug again.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@850 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-05 03:26:00 +00:00
Jordi Mallach
14a0e55bc9 Getting rid of Makefile.in too, autogenerated file.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@849 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-04 01:54:03 +00:00
Jordi Mallach
8fd15e2672 Oops, m4 stuff is in m4/ in nano 1.1.x...
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@848 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-04 01:44:06 +00:00
Jordi Mallach
19aad376ef Added script to get working configure, etc.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@845 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-04 01:37:36 +00:00
Jordi Mallach
c17aa63200 Bye bye you too. To the Attic! (replaced by autogen.sh)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@844 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-04 01:34:13 +00:00
Chris Allegretta
9a39789cb6 Back to CVS version
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@843 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-04 01:25:43 +00:00
Chris Allegretta
03260b40fa GNU nano 1.1.2 release
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@841 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-04 01:24:07 +00:00
Jordi Mallach
58a3353307 Have a nice day in the Attic, nano.info. We just need nano.texi.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@840 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-04 01:02:26 +00:00
Jordi Mallach
4c6438be6f Fixed the remaining fuzzy string in fi.po. Phear my Finnish :) (thanks Antti-Juhani Kaijanaho).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@835 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-03 21:57:00 +00:00
Jordi Mallach
780f3205f1 Finnish update for 1.1.2pre3, by Pauli Virtanen.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@834 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-03 20:47:47 +00:00
Jordi Mallach
8a9863736b Italian updates for 1.1.2 (Marco Colombo).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@832 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-03 19:04:38 +00:00
Jordi Mallach
cdbabfd4fc * Added more command line options that are currently ignored by nano (DLR).
* nano.1: Updated the statement about nano.save & multibuffers.


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@830 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-03 15:53:25 +00:00
Jordi Mallach
7d589ca5fa Fixed typos found by DLR and ispell.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@829 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-03 15:44:16 +00:00
Chris Allegretta
ca1a82ecab - rcfile.c: - Fix incorrect argument in fill and tabsize error message (Nathan Heagy)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@828 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-03 15:18:41 +00:00
Jordi Mallach
f57b886bed Documentation updates for nano 1.1.2 (texi and manpage).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@827 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-03 12:45:22 +00:00
Jordi Mallach
22262441c7 Galician translation brought up to date for 1.1.2 by Jacobo Tarrío.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@826 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-03 10:59:23 +00:00
Jordi Mallach
b97bedafe8 Updated ca & es for 1.1.2 release (tab size changes).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@825 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-03 10:12:37 +00:00
Chris Allegretta
31b2b81e53 Add filebot magic line bug as bug #66
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@823 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-03 01:51:33 +00:00
Chris Allegretta
5e4b1085b4 Add single line bug as Bug #65
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@822 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-03 00:45:06 +00:00
Chris Allegretta
b516d8e3f3 - nano.c:main() - Added var constcheck as a CRC-like check of whether cursor pos has changed and if so update the pos with -c
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@820 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-03 00:01:36 +00:00
Chris Allegretta
66c33b8731 Add tabsize support to rc file (Nathan Heagy)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@819 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-02 23:57:31 +00:00
Chris Allegretta
dc2ca88718 - cut.c:do_cut_text() - Don't recenter the line when cutting one line (DLR)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@818 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-02 23:55:09 +00:00
Jordi Mallach
a2d849bcd4 * Added notes about the Free Translation Project.
* Updated the ChangeLog, so it has some meaning :)


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@817 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-02 19:13:03 +00:00
Jordi Mallach
14b0accd81 * We can't live WITHOUT bells and whistles 8) (Nathan Heagy)
* Removed ftp.sourceforge.net from download sites as it'll go shortly.
* Added the `testing' distribution page for nano in the Debian section.
* Added a direct link to Debian's package pools too.
* Added --disable-operatingdir to "how make nano smaller?".
* Zsh advocacy :)


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@816 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-02 18:21:55 +00:00
Chris Allegretta
b26cb39296 Don't show non-positive shortcut keys in help_init()
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@814 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-02 04:22:34 +00:00
Chris Allegretta
e10f389e9c Take out the unneeded case sensitive and reverse stuff from -tiny
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@813 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-02 03:54:40 +00:00
Chris Allegretta
ad3f478452 - Take control-space out of -tiny build, unneeded
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@812 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-02 03:54:13 +00:00
Chris Allegretta
59121a9aaf Change do_bracket ctrl shortcut to -9 (junk value) instead of 0 so control-space will work
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@811 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-02 03:14:43 +00:00
Chris Allegretta
92f5fdc230 Finally, do the ChangeLog
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@810 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-02 02:58:07 +00:00
Chris Allegretta
386e0518b5 winio.c:nanogetstr() - Don't be clever and wasteful, just repaint every iteration
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@809 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-02 02:57:26 +00:00
Chris Allegretta
1c27d3e875 nano.c:main() - Fix the KEY_IC being undefined when using slang
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@808 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-02 02:56:45 +00:00
Chris Allegretta
7fdbd05b41 Readded DISABLE_CURPOS cause we can't get away without it (Search Wrapped msgs) and Ken's findnextr fixes
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@807 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-02 00:55:38 +00:00
Chris Allegretta
d948edc4f3 DLR's latest smooth scroll fix, case where there's not a full half page up from the cursor to fileage screws up the cursor position
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@806 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-02 00:38:56 +00:00
Chris Allegretta
222a0863fa cut.c:cut_marked_segment() - Add magic line when cutting a selection including filebot (discovered by DLR, fixed by DLR & Chris)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@805 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-02 00:24:37 +00:00
Jordi Mallach
1e36fd8f69 Italian updates for 1.1.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@804 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-01 17:24:24 +00:00
Chris Allegretta
f727da88b0 Add smooth scroll and the DOS/Mac file support to the README
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@803 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-10-01 14:42:27 +00:00
Jordi Mallach
73889487f0 Added Karl, fixed Hungarian translator address (blindly believing Google).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@802 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-30 05:03:15 +00:00
Jordi Mallach
200b27e33e Fixes from Karl Eichwalder to de.po, so Emacs doesn't barf.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@801 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-30 05:01:31 +00:00
Jordi Mallach
10398ade49 Corrected small spacing typo in --dos help.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@800 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-29 18:54:46 +00:00
Chris Allegretta
1b3381bee8 Initialize totsize in files.c:new_file() and let do_gotopos keep current position when invoking the alternate speller (DLR)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@799 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-28 21:59:01 +00:00
Chris Allegretta
2bef18210a Fixes to bracket_msg in global.c by DLR
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@798 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-28 19:53:11 +00:00
Chris Allegretta
352801cf4c Fix brace error with nano-tiny in do_writeout()
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@797 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-28 19:42:41 +00:00
Jordi Mallach
c1917e7b66 Updated Catalan and Spanish translations to 1.1.2pre2.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@796 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-28 13:06:29 +00:00
Jordi Mallach
acf4b16b72 Header fixes for some old po files.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@795 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-28 12:58:07 +00:00
Jordi Mallach
475f96d0b3 Updated Catalan and Spanish translations.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@794 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-28 12:55:18 +00:00
Chris Allegretta
a951f21c59 - nano.c: do_mouse() - Change k based on currslen to allow the new widths in bottombars()
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@793 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-27 21:07:39 +00:00
Chris Allegretta
26a86e350c Initialize bracket_msg (David Lawrence Ramsey
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@792 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-27 20:52:53 +00:00
Chris Allegretta
9519eb0c88 - files.c: do_writeout() - Expanded strings to not use %s and ?: to determine write/append string to be nice to translators
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@791 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-27 20:46:25 +00:00
Chris Allegretta
759d3523fc Search prompt changes, bracketed modifiers and to search at the front
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@790 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-27 13:04:10 +00:00
Chris Allegretta
56214c6aef DLR's fixes: arg for operatingdir's getopt_long text, changes to cases 2b and 2c in do_wrap for Pico compatibility, and new arg save_cutbuffer to global_init() to stop the cutbuffer from being lost with multiple buffers
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@789 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-27 02:46:53 +00:00
Chris Allegretta
5050d35e87 Fixes to paging (smooth scroll) by David Lawrence Ramsey
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@788 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-27 00:44:58 +00:00
Chris Allegretta
ecc1933c14 Off by one error in findnextstr?
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@787 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-25 01:49:38 +00:00
Jordi Mallach
c1968a0795 Updated Spanish to 1.1.2pre1
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@786 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-24 00:46:31 +00:00
Chris Allegretta
99e30e1bee Oops, we shoudn't let DOS_FILE and MAX_FILE be set at the same time
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@784 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-23 02:45:27 +00:00
Chris Allegretta
ce78c1eb88 DLR's latest fixes for the tabcomp code and keys
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@783 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-23 01:18:03 +00:00
Chris Allegretta
beb5497530 rcfile.c: - NUM_RCOPTS fix (DLR)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@782 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-22 23:54:45 +00:00
Chris Allegretta
96bd4e4ed8 Readd skipping Meta-A,B,E in do_toggle, oops I'm with it now :-)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@781 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-22 22:27:37 +00:00
Chris Allegretta
8d990b5e8b - Bracket (brace, parens, etc) matching code by Ken Tyler. New functions do_find_bracket(), changes to findnextstr(), command is Meta-] (hope you dont mind since I already sold off Meta-O to the MacOS file code Ken...)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@780 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-22 22:14:25 +00:00
Chris Allegretta
6f6aba0350 Move the smooth_msg up a tiny
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@779 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-22 19:03:01 +00:00
Chris Allegretta
3e3ae94084 - New smooth scroll code by Ken Tyler. New flag -S, --smooth, changes to page_up() and page_down()
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@778 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-22 19:02:04 +00:00
Chris Allegretta
0319176f2d More Mac file fixes
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@777 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-22 06:38:38 +00:00
Chris Allegretta
960a8635bc Oops, another Mac fix
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@776 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-22 05:08:12 +00:00
Chris Allegretta
995177f2d9 Add Mac toggle Meta-O for Mac format
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@775 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-22 04:34:23 +00:00
Chris Allegretta
8fa1e28681 Added mac file support too
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@774 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-22 04:20:25 +00:00
Chris Allegretta
7004c289f8 -D cmdline flag for DOS formatted files
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@773 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-22 00:42:10 +00:00
Chris Allegretta
6414b40d3d Make the Alt-key seqs work with the mouse
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@772 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-21 03:21:11 +00:00
Chris Allegretta
91841895e0 Code to read/write dos formatted files. Massive amounts of new code in read_line and write_file. New flag DOS_FILE
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@771 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-21 02:37:01 +00:00
Jordi Mallach
5d25f06e3b Catalan commit with no translation changes, just to avoid more conflicts.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@770 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-19 10:12:11 +00:00
Jordi Mallach
128e95ffdc Updated Spanish for chroot patch.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@769 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-19 10:07:50 +00:00
Chris Allegretta
e09cd1d4d1 Credit DLR for his code =-)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@768 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-19 03:22:52 +00:00
Chris Allegretta
e1f1452eb5 General: - New flag -o, --operatingdir, similar to Pico's -o mode. New function check_operating_dir(), changes to load_file (arg), open_file_dup_search (arg), new function do_gotopos for -F.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@767 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-19 03:19:43 +00:00
Chris Allegretta
b6c89eed9f Completely get rid of DISABLE_CURPOS
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@766 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-19 03:09:22 +00:00
Chris Allegretta
0357c4d552 - nano.c: main() - Added vars oldcurrent and oldcurrent_x to check whether cursor pos has changed and if so update the pos with -c
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@765 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-19 02:59:25 +00:00
Chris Allegretta
68532c37ef Fix unneeded vars with NANO_SMALL
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@764 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-17 13:49:33 +00:00
Chris Allegretta
ff98983602 Fix acconfig.h, NANO_SMALL leaves out Auto Indent
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@763 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-17 13:48:00 +00:00
Jordi Mallach
6c49b3f32c Updated Swedish translation (Christian Rose)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@762 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-15 22:47:05 +00:00
Jordi Mallach
4d69d4313f Added Keld Simonsen (Danish).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@761 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-15 22:46:21 +00:00
Jordi Mallach
90bbdd3c40 New Danish translation, by Keld Simonsen <keld@dkuug.dk>.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@760 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-12 19:06:59 +00:00
Jordi Mallach
d1625cdfe6 Updated Galician translation; thanks, Jacobo Tarrío.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@757 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-10 11:36:45 +00:00
Jordi Mallach
c6c35eafc8 Added recent translators to THANKS
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@756 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-09 11:04:43 +00:00
Jordi Mallach
b1aaa27c10 Updated Spanish translation.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@754 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-09 10:55:51 +00:00
Jordi Mallach
2cde0a24d4 Added Dutch translation, by Guus Sliepen <guus@nl.linux.org>.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@753 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-09-05 13:23:53 +00:00
Chris Allegretta
7dd1869713 Make the new bottombars not suck quite so badly
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@751 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-08-26 23:16:44 +00:00
Chris Allegretta
96eef7332b winio.c:bottombars() - Spread out the menu items, feedback definitely needed on this
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@750 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-08-25 16:41:37 +00:00
Chris Allegretta
9b3c7e8be7 winio.c: - Add David Lawrence Ramsey to credits
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@749 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-08-25 16:00:53 +00:00
Chris Allegretta
c2acb81782 Unset the flag chris you dolt
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@745 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-08-17 00:08:44 +00:00
Chris Allegretta
c1049aced1 Add and fix bugs #63 and 64
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@744 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-08-17 00:03:46 +00:00
Jordi Mallach
372b1a0939 Corrected the Mouse Toggle help in the texinfo manual.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@743 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-08-08 19:35:23 +00:00
Chris Allegretta
47a2686e41 Back to CVS version
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@742 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-07-29 01:17:38 +00:00
Chris Allegretta
0e8c8d8cdc GNU nano 1.1.1 release
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@740 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-07-29 01:16:27 +00:00
Chris Allegretta
41ed01632f do_mark() - Temporarily disable cursorpos when enabled to be able to see the mark (un)set message (Ken Tyler)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@739 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-07-24 00:21:03 +00:00
Chris Allegretta
4839d23b11 Spelling fixes by DLR
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@738 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-07-19 22:03:51 +00:00
Chris Allegretta
279aaa9bdb Deleted the old files we didn't need for old gettext
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@737 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-07-19 12:26:56 +00:00
Chris Allegretta
ef8f98d0c8 Reverted to gettext 0.10.35 in intl/ added m4/ directory to allow system independent rebuild of configure stuff
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@736 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-07-19 12:24:17 +00:00
Chris Allegretta
e642197ff7 new_file() and close_open_file() fixes by DLR
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@735 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-07-18 01:03:36 +00:00
Chris Allegretta
5cce53b5a8 do_writeout() - Check for open_files == NULL before using it (Ryan Krebs)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@734 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-07-17 10:42:50 +00:00
Chris Allegretta
5f36c3760f Fixes for the nano.h #defines, shortcut_init() lists and search.c reverse search stuff when NANO_SMALL is used
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@733 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-07-16 00:48:53 +00:00
Chris Allegretta
f372bd9f8c nano.h: - Fix type in INSERTFILE_LIST_LEN. && search_init() - add #ifdef NANO_SMALL around toggles code.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@732 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-07-15 22:24:24 +00:00
Chris Allegretta
307d4c8f6b Many multibuffer fixes by DLR
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@731 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-07-15 20:25:33 +00:00
Chris Allegretta
47f77b4715 Back to CVS
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@730 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-07-15 16:13:18 +00:00
Chris Allegretta
9a74860957 Nano 1.1.0 release
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@728 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-07-15 16:07:23 +00:00
Chris Allegretta
355fbe5770 Moved --loadoninsert to --multibuffer and -F, --enable-extra defines --enable-multibuffer
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@727 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-07-14 19:32:47 +00:00
Chris Allegretta
a212acf100 Oops, no need to translate %s
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@726 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-07-13 02:00:49 +00:00
Chris Allegretta
9cf9e06003 Put the #ifdef back, dope
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@725 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-07-11 12:06:13 +00:00
Chris Allegretta
802c6ef076 Updated README for some of the schnazzy 1.1 features
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@724 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-07-11 02:49:43 +00:00
Chris Allegretta
819e3db74d Move previous and next buffer code to main loop instead of do_toggles()
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@723 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-07-11 02:37:19 +00:00
Chris Allegretta
2d7893d086 Added multi buffer (load on insert) code. This wont intoduce any bugs ;-)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@722 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-07-11 02:08:33 +00:00
Jordi Mallach
240998b25f New updates from the Swedish team.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@721 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-07-08 01:30:54 +00:00
Jordi Mallach
df7d8b2e57 Added Norwegian and Swedish to HEAD.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@720 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-07-05 23:16:05 +00:00
Chris Allegretta
b26ecb597e Oops, make that Alt-[-7.8
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@719 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-07-04 16:27:05 +00:00
Chris Allegretta
052f9d238e main() - Added Alt-[-[-7,8 support for home/end keys (Jeff Teunissen).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@718 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-07-04 16:06:21 +00:00
Chris Allegretta
049149f1da Make the THANKS file slightly less incomplete but far from perfect
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@711 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-07-02 01:57:44 +00:00
Chris Allegretta
a2c02e9c8d do_browser() - More Picoish keystrokes for the browser, ^P, ^N, etc, for up, down, etc, and add the consistent ^C to exit (Jim Knoble)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@710 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-07-02 01:31:44 +00:00
Chris Allegretta
df20e83412 Okay I guess the wnouterefresh()s aren't needed in the SIGCONT handler
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@706 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-07-01 04:28:45 +00:00
Chris Allegretta
33db9bf473 Silly typo in the faq
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@705 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-06-30 19:14:01 +00:00
Chris Allegretta
1a8b296adf write_file() - Increment lineswritten when the very last line isn't null. Fixes off by one count when writing selection to file.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@704 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-06-30 18:41:08 +00:00
Chris Allegretta
ac899e5f80 do_suspend() - Added _POSIX_VDISABLE macro to fully ignore suspend keystroke. Eliminates the possibility that nano can be suspended when it's not supposed to be
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@703 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-06-30 04:09:09 +00:00
Chris Allegretta
d173c15ce5 Add and close BUG #62
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@701 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-06-28 16:54:59 +00:00
Chris Allegretta
521e00d761 rewrote suspend handler, added sigfillset before setting up handler with sigaction, allows nano to suspend properly with mutt
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@699 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-06-28 16:52:52 +00:00
Jordi Mallach
7fde37f006 Added THANKS, listing nano's friends :)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@693 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-06-22 23:26:19 +00:00
Chris Allegretta
34319a1ff7 Okay, and now dont add extra blanks when at filebot
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@692 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-06-22 21:47:23 +00:00
Jordi Mallach
efd2236319 Updated Indonesian by Tedi Heriyanto
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@691 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-06-22 16:59:29 +00:00
Chris Allegretta
500b5e3539 do_cut_text(): Moved the case of current == mark_beginbuf into cut_marke segment, so do_writeout could call it when writing selection to file. Added some NANO_SMALL ifdefs
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@689 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-06-21 23:58:47 +00:00
Chris Allegretta
40f45c8689 Last fixes, add reset of cutbuffer when uncutting marked text and reset marked_cut when cutbuffer reset
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@688 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-06-21 15:07:40 +00:00
Jordi Mallach
68b3dfb431 Updated for Backwards search
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@687 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-06-14 17:41:27 +00:00
Chris Allegretta
658399aeb9 Moved extension functions to meta keys, new macro TOGGLE() for toggling flags
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@686 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-06-14 02:54:22 +00:00
Chris Allegretta
e4933a393a Reverse Search by Ken Tyler
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@685 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-06-13 02:35:44 +00:00
Chris Allegretta
a75bc41faf Better for for -k bug
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@683 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-06-12 23:22:26 +00:00
Chris Allegretta
1cde322359 Don't keep cutbufer on reset, fix -k cut on first line if blank
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@682 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-06-11 06:56:10 +00:00
Chris Allegretta
cf785632ed Add a message about --enable-color being severely broken so we can have a 1.1 release
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@681 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-06-11 02:49:50 +00:00
Chris Allegretta
3ba29535a3 do_cut_text() - If the next line is empty when using -k, create a dummy line and add it to the cutbuffer (fixes bug #61)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@680 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-06-10 20:41:20 +00:00
Chris Allegretta
0241d19e4c Ugh, sigh
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@678 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-06-05 23:45:54 +00:00
Chris Allegretta
ecc3d7f39e write_file() - New arg, nonamechange, means whether or not to update the current filename after writing the file out.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@677 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-06-05 23:24:55 +00:00
Chris Allegretta
d21195f882 Oops\! Don't automatically assume the current filename when writing a selection to file, very bad\!\!\!
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@676 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-06-05 22:57:43 +00:00
Jordi Mallach
34654ab41a UTF8 would be leet!
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@675 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-06-02 02:02:29 +00:00
Jordi Mallach
de3d800e67 Nifty script which we'll learn to love.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@674 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-06-02 02:02:08 +00:00
Chris Allegretta
c4e1a131d3 Oops, fix write_file calls in nano.c also
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@673 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-05-29 04:46:38 +00:00
Chris Allegretta
cc197ef0ea Added selection write to file and append codes, main changes to files.c stuff, new shortcut list for inserting files, new args to do_writeout and write_file
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@672 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-05-29 04:21:44 +00:00
Chris Allegretta
43fee64400 Sample file nanorc.sample added to dist (ad Makefile.am)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@671 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-05-26 04:18:54 +00:00
Jordi Mallach
b4d6ad0ef6 Added rcfile.c to the translated files, added gettext calls to some messages that didn't have it and updated Spanish. New po files for the rest.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@670 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-05-24 13:10:06 +00:00
Chris Allegretta
d46156258b do_browser() - Don't shift the size of the file is it's less than 1K. Fixed files less than 1K being displayed as 0B (Rocco)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@669 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-05-23 21:54:47 +00:00
Chris Allegretta
6fe61499e8 All the updates that I've been waiting all weekend to commit, no desc, tough
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@668 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-05-21 12:56:25 +00:00
Jordi Mallach
9a46f3cf56 Oops, translations of Prev. and Next Page were reversed
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@667 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-05-19 10:03:46 +00:00
Jordi Mallach
1e43a12b49 Added po/messages
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@666 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-05-19 00:40:06 +00:00
Chris Allegretta
dd0491380a Add -W to TODO
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@665 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-05-18 20:00:08 +00:00
Chris Allegretta
53ea9d162b Add BUG #60
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@664 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-05-18 19:58:33 +00:00
Chris Allegretta
3b41212d61 Changed charalloc's calloc() call to use sizeof (char) not sizeof(char *)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@663 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-05-18 04:53:45 +00:00
Chris Allegretta
8d848afb89 Changed ncalloc calls in rcfile.c to charalloc
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@662 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-05-18 04:44:16 +00:00
Chris Allegretta
88b091510b Changed all string allocations to charalloc(), new function designed to take nmalloc argument but call calloc based on (char *) size.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@661 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-05-17 11:35:43 +00:00
Chris Allegretta
9fe015cca3 cut_marked_segment() - Add bizarre copy of bot node, else *BSD goes ballistic.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@660 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-05-17 03:41:00 +00:00
Chris Allegretta
63ba2d63ff po/it.po - Updated Italian translation by Marco Colombo.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@659 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-05-16 12:16:28 +00:00
Jordi Mallach
92b3bd2de6 New Russian translation by Sergey A. Ribalchenko.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@658 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-05-16 09:10:31 +00:00
Chris Allegretta
611e98be29 typo
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@656 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-05-16 04:23:37 +00:00
Chris Allegretta
5c27385a16 I'm back to the older gettext, sync these files too
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@655 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-05-16 04:21:31 +00:00
Chris Allegretta
99afb85752 strcasestr() - Replaced by mutt's mutt_stristr function, because the thought of dynamically allocating memory and copying each line in a file to do a search or replace was causing me to lose sleep
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@654 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-05-16 04:20:57 +00:00
Jordi Mallach
64bacd20b5 gl.po status update (it's not new, it's been released already)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@652 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-05-14 13:55:30 +00:00
Jordi Mallach
3bf6bf45b7 Added Ukrainian translation by Sergey A. Ribalchenko.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@651 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-05-14 13:11:56 +00:00
Chris Allegretta
4cb991dda1 add_to_cutbuffer() - Remove useless statements (Rocco).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@644 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-05-10 22:55:16 +00:00
Chris Allegretta
b10283c4e8 Move down current shortcut assignment into loop in browser code to keep it updated
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@643 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-05-07 12:08:37 +00:00
Chris Allegretta
f3fde7c2fc Fix not being able to select last item in browser with mouse
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@642 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-05-06 03:02:21 +00:00
Chris Allegretta
5f07180e8a Okay, now let unjustify work with the mouse too :P
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@641 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-05-06 02:34:31 +00:00
Chris Allegretta
051fc6e05a Added file clicking ability in file browser
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@640 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-05-05 23:17:36 +00:00
Chris Allegretta
88520c93be Various spelling updates by David Lawrence Ramsey
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@639 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-05-05 17:45:54 +00:00
Chris Allegretta
a9434800df Add correct name to rcfile.c comments (thx Rocco)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@635 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-05-05 15:02:27 +00:00
Chris Allegretta
4e18b8f9ce I should actually add the file to the tree
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@634 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-05-05 15:01:42 +00:00
Jordi Mallach
725490495c Updated FAQ, updated Spanish and Catalan, added utils.c to translations and
little typo fixes here and there.


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@633 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-05-02 17:18:17 +00:00
Chris Allegretta
09898d99d4 Commit the rest of the stuff backing down gettext changed *shrug*
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@632 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-05-01 11:27:43 +00:00
Chris Allegretta
0bafa91096 Back to the 1.0 version of gettext, I can't figure this one out to save my life =(
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@631 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-04-30 14:04:44 +00:00
Chris Allegretta
b0bce4b429 Mention config.whatever files in ChangeLog
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@629 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-04-30 12:22:21 +00:00
Chris Allegretta
8ce2413feb Add color changes, undocumented and ugly, but hey maybe people want to see what chap I wrote so far
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@624 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-04-30 11:28:46 +00:00
Chris Allegretta
465f1e305d Update html man page too
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@623 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-04-30 11:23:33 +00:00
Jordi Mallach
3f8db49622 Hugo van der Merwe pointed out that -r was missing in the manpage.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@621 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-04-30 10:30:43 +00:00
Jordi Mallach
4be36bf1d4 Jacobo updated Galician to latest CVS.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@620 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-04-29 22:36:58 +00:00
Jordi Mallach
9634571dd6 Added Galician translation by Jacobo Tarrío <jtarrio@trasno.net>.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@619 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-04-29 10:38:07 +00:00
Chris Allegretta
6cb4e885f2 page_up() - Rewritten with a loop to make screen updates work when mark is set (fixes bug #59).
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@618 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-04-29 02:26:17 +00:00
Chris Allegretta
6efda54a6c Move config.h up in include lists and remove actual_x inline tag
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@616 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-04-28 18:03:52 +00:00
Chris Allegretta
316e4d9a67 ABCD(), main() - Add Alt-whatever-[a-d] support as well as Alt-whatever-[A-D].
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@615 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-04-28 16:31:19 +00:00
Chris Allegretta
18d70f1478 added --enable-color and updated nanorc description in ChangeLog
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@613 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-04-28 15:53:28 +00:00
Chris Allegretta
5050aa6ae7 Addand fix bug #59
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@612 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-04-22 07:10:21 +00:00
Rocco Corsi
4dfaf93bcd Alt Speller returns to same line & do_gotoline optimizations
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@609 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-04-20 01:59:55 +00:00
Chris Allegretta
7a50009b1f Fix proto.h ifdef for do_nanorc()
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@608 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-04-19 21:13:46 +00:00
Chris Allegretta
03bf98015d One more
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@607 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-04-19 03:20:07 +00:00
Chris Allegretta
bf521fabaa Newer config.guess and config.sub
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@606 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-04-19 02:49:57 +00:00
Chris Allegretta
2fe0ddeab4 *** empty log message ***
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@605 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-04-19 01:23:44 +00:00
Chris Allegretta
1f0ab55e6d Update configure
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@604 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-04-19 01:23:08 +00:00
Chris Allegretta
528310223b I guess we need these now?
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@603 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-04-18 22:10:52 +00:00
Chris Allegretta
cbee08f335 And the Makefile.in.in in po/ also
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@602 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-04-18 17:15:17 +00:00
Chris Allegretta
cc0da8ab53 Oops, add the new files too
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@601 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-04-18 14:03:21 +00:00
Chris Allegretta
819d46ac71 Upgrade libintl stuff to gettext 0.10.36
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@600 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-04-18 14:00:10 +00:00
Chris Allegretta
b881d3ea57 Add --enable-nanorc to version string in nano.c
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@599 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-04-18 04:34:43 +00:00
Chris Allegretta
8d8e01224b Added rcfile.c source code and basic .nanorc functionality
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@598 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-04-18 04:28:54 +00:00
Rocco Corsi
12f294c651 "Goto Directory" added and minor fixes in the browser
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@597 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-04-14 06:50:24 +00:00
Chris Allegretta
ea066c8413 Added --enable-nanorc to configure
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@596 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-04-13 02:32:06 +00:00
Chris Allegretta
84de552b28 Added --disable-mouse option
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@595 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-04-12 14:51:48 +00:00
Chris Allegretta
235ab192af Add yesno support to mouse
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@594 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-04-12 13:24:40 +00:00
Chris Allegretta
6b58acd377 More mouse integration, esp with the shortcut lists
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@593 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-04-12 03:01:53 +00:00
Chris Allegretta
ac840eb42b Added fork info to ChangeLog
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@592 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-04-07 18:21:47 +00:00
Chris Allegretta
6e2853705a 1.1 version and note added to README that this is the unstable branch
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@591 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-04-07 17:50:03 +00:00
Chris Allegretta
9afd119dd5 Back to CVS version
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@590 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2001-04-06 23:13:57 +00:00
120 changed files with 49376 additions and 22615 deletions

View File

@@ -1,10 +1,23 @@
Makefile
Makefile.in
aclocal.m4
autom4te.cache
confdefs.h
config.cache
config.h
config.h.in
config.log
config.status
configure
config.guess
config.sub
depcomp
install-sh
missing
mkinstalldirs
nano
nano.info
nano.spec
stamp-h
stamp-h.in
stamp-h1

412
ABOUT-NLS
View File

@@ -8,7 +8,7 @@ A few packages already provide translations for their messages.
If you found this `ABOUT-NLS' file inside a distribution, you may
assume that the distributed package does use GNU `gettext' internally,
itself available at your nearest GNU archive site. But you do *not*
itself available at your nearest GNU archive site. But you do _not_
need to install GNU `gettext' prior to configuring, installing or using
this package with messages translated.
@@ -22,8 +22,8 @@ related to internationalization, you should tell about the version of
`gettext' which is used. The information can be found in the
`intl/VERSION' file, in internationalized packages.
One advise in advance
=====================
Quick configuration advice
==========================
If you want to exploit the full power of internationalization, you
should configure it using
@@ -34,13 +34,14 @@ to force usage of internationalizing routines provided within this
package, despite the existence of internationalizing capabilities in the
operating system where this package is being installed. So far, only
the `gettext' implementation in the GNU C library version 2 provides as
many features (such as locale alias or message inheritance) as the
implementation here. It is also not possible to offer this additional
functionality on top of a `catgets' implementation. Future versions of
GNU `gettext' will very likely convey even more functionality. So it
might be a good idea to change to GNU `gettext' as soon as possible.
many features (such as locale alias, message inheritance, automatic
charset conversion or plural form handling) as the implementation here.
It is also not possible to offer this additional functionality on top
of a `catgets' implementation. Future versions of GNU `gettext' will
very likely convey even more functionality. So it might be a good idea
to change to GNU `gettext' as soon as possible.
So you need not provide this option if you are using GNU libc 2 or
So you need _not_ provide this option if you are using GNU libc 2 or
you have installed a recent copy of the GNU gettext package with the
included `libintl'.
@@ -53,23 +54,20 @@ Most such packages use GNU `gettext'. Other packages have their own
ways to internationalization, predating GNU `gettext'.
By default, this package will be installed to allow translation of
messages. It will automatically detect whether the system provides
usable `catgets' (if using this is selected by the installer) or
`gettext' functions. If neither is available, the GNU `gettext' own
messages. It will automatically detect whether the system already
provides the GNU `gettext' functions. If not, the GNU `gettext' own
library will be used. This library is wholly contained within this
package, usually in the `intl/' subdirectory, so prior installation of
the GNU `gettext' package is *not* required. Installers may use
the GNU `gettext' package is _not_ required. Installers may use
special options at configuration time for changing the default
behaviour. The commands:
./configure --with-included-gettext
./configure --with-catgets
./configure --disable-nls
will respectively bypass any pre-existing `catgets' or `gettext' to use
the internationalizing routines provided within this package, enable
the use of the `catgets' functions (if found on the locale system), or
else, *totally* disable translation of messages.
will respectively bypass any pre-existing `gettext' to use the
internationalizing routines provided within this package, or else,
_totally_ disable translation of messages.
When you already have GNU `gettext' installed on your system and run
configure without an option for your new package, `configure' will
@@ -83,18 +81,10 @@ package is more recent, you should use
to prevent auto-detection.
By default the configuration process will not test for the `catgets'
function and therefore they will not be used. The reasons are already
given above: the emulation on top of `catgets' cannot provide all the
extensions provided by the GNU `gettext' library. If you nevertheless
want to use the `catgets' functions use
./configure --with-catgets
to enable the test for `catgets' (this causes no harm if `catgets' is
not available on your system). If you really select this option we
would like to hear about the reasons because we cannot think of any
good one ourself.
The configuration process will not test for the `catgets' function
and therefore it will not be used. The reason is that even an
emulation of `gettext' on top of `catgets' could not provide all the
extensions of the GNU `gettext' library.
Internationalized packages have usually many `po/LL.po' files, where
LL gives an ISO 639 two-letter code identifying the language. Unless
@@ -110,22 +100,42 @@ Using This Package
As a user, if your language has been installed for this package, you
only have to set the `LANG' environment variable to the appropriate
ISO 639 `LL' two-letter code prior to using the programs in the
package. For example, let's suppose that you speak German. At the
shell prompt, merely execute `setenv LANG de' (in `csh'),
`export LANG; LANG=de' (in `sh') or `export LANG=de' (in `bash'). This
can be done from your `.login' or `.profile' file, once and for all.
`LL_CC' combination. Here `LL' is an ISO 639 two-letter language code,
and `CC' is an ISO 3166 two-letter country code. For example, let's
suppose that you speak German and live in Germany. At the shell
prompt, merely execute `setenv LANG de_DE' (in `csh'),
`export LANG; LANG=de_DE' (in `sh') or `export LANG=de_DE' (in `bash').
This can be done from your `.login' or `.profile' file, once and for
all.
An operating system might already offer message localization for
many of its programs, while other programs have been installed locally
with the full capabilities of GNU `gettext'. Just using `gettext'
extended syntax for `LANG' would break proper localization of already
available operating system programs. In this case, users should set
both `LANGUAGE' and `LANG' variables in their environment, as programs
using GNU `gettext' give preference to `LANGUAGE'. For example, some
Swedish users would rather read translations in German than English for
when Swedish is not available. This is easily accomplished by setting
`LANGUAGE' to `sv:de' while leaving `LANG' to `sv'.
You might think that the country code specification is redundant.
But in fact, some languages have dialects in different countries. For
example, `de_AT' is used for Austria, and `pt_BR' for Brazil. The
country code serves to distinguish the dialects.
The locale naming convention of `LL_CC', with `LL' denoting the
language and `CC' denoting the country, is the one use on systems based
on GNU libc. On other systems, some variations of this scheme are
used, such as `LL' or `LL_CC.ENCODING'. You can get the list of
locales supported by your system for your country by running the command
`locale -a | grep '^LL''.
Not all programs have translations for all languages. By default, an
English message is shown in place of a nonexistent translation. If you
understand other languages, you can set up a priority list of languages.
This is done through a different environment variable, called
`LANGUAGE'. GNU `gettext' gives preference to `LANGUAGE' over `LANG'
for the purpose of message handling, but you still need to have `LANG'
set to the primary language; this is required by other parts of the
system libraries. For example, some Swedish users who would rather
read translations in German than English for when Swedish is not
available, set `LANGUAGE' to `sv:de' while leaving `LANG' to `sv_SE'.
In the `LANGUAGE' environment variable, but not in the `LANG'
environment variable, `LL_CC' combinations can be abbreviated as `LL'
to denote the language's main dialect. For example, `de' is equivalent
to `de_DE' (German as spoken in Germany), and `pt' to `pt_PT'
(Portuguese as spoken in Portugal) in this context.
Translating Teams
=================
@@ -133,33 +143,21 @@ Translating Teams
For the Free Translation Project to be a success, we need interested
people who like their own language and write it well, and who are also
able to synergize with other translators speaking the same language.
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 December
1997:
Each translation team has its own mailing list. The up-to-date list of
teams can be found at the Free Translation Project's homepage,
`http://www.iro.umontreal.ca/contrib/po/HTML/', in the "National teams"
area.
Chinese `zh', Czech `cs', Danish `da', Dutch `nl', English `en',
Esperanto `eo', Finnish `fi', French `fr', German `de', Hungarian
`hu', Irish `ga', Italian `it', Indonesian `id', Japanese `ja',
Korean `ko', Latin `la', Norwegian `no', Persian `fa', Polish
`pl', Portuguese `pt', Russian `ru', Slovenian `sl', Spanish `es',
Swedish `sv', and Turkish `tr'.
For example, you may reach the Chinese translation team by writing to
`zh@li.org'.
If you'd like to volunteer to *work* at translating messages, you
If you'd like to volunteer to _work_ at translating messages, you
should become a member of the translating team for your own language.
The subscribing address is *not* the same as the list itself, it has
The subscribing address is _not_ the same as the list itself, it has
`-request' appended. For example, speakers of Swedish can send a
message to `sv-request@li.org', having this message body:
subscribe
Keep in mind that team members are expected to participate
*actively* in translations, or at solving translational difficulties,
_actively_ in translations, or at solving translational difficulties,
rather than merely lurking around. If your team does not exist yet and
you want to start one, or if you are unsure about what to do or how to
get started, please write to `translation@iro.umontreal.ca' to reach the
@@ -173,42 +171,232 @@ Available Packages
==================
Languages are not equally supported in all packages. The following
matrix shows the current state of internationalization, as of December
1997. The matrix shows, in regard of each package, for which languages
PO files have been submitted to translation coordination.
matrix shows the current state of internationalization, as of August
2002. The matrix shows, in regard of each package, for which languages
PO files have been submitted to translation coordination, with a
translation percentage of at least 50%.
Ready PO files cs da de en es fi fr it ja ko nl no pl pt ru sl sv
.----------------------------------------------------.
bash | [] [] [] | 3
bison | [] [] [] | 3
clisp | [] [] [] [] | 4
cpio | [] [] [] [] [] [] | 6
diffutils | [] [] [] [] [] | 5
enscript | [] [] [] [] [] [] | 6
fileutils | [] [] [] [] [] [] [] [] [] [] | 10
findutils | [] [] [] [] [] [] [] [] [] | 9
flex | [] [] [] [] | 4
gcal | [] [] [] [] [] | 5
gettext | [] [] [] [] [] [] [] [] [] [] [] | 12
grep | [] [] [] [] [] [] [] [] [] [] | 10
hello | [] [] [] [] [] [] [] [] [] [] [] | 11
id-utils | [] [] [] | 3
indent | [] [] [] [] [] | 5
libc | [] [] [] [] [] [] [] | 7
m4 | [] [] [] [] [] [] | 6
make | [] [] [] [] [] [] | 6
music | [] [] | 2
ptx | [] [] [] [] [] [] [] [] | 8
recode | [] [] [] [] [] [] [] [] [] | 9
sh-utils | [] [] [] [] [] [] [] [] | 8
sharutils | [] [] [] [] [] [] | 6
tar | [] [] [] [] [] [] [] [] [] [] [] | 11
texinfo | [] [] [] | 3
textutils | [] [] [] [] [] [] [] [] [] | 9
wdiff | [] [] [] [] [] [] [] [] | 8
`----------------------------------------------------'
17 languages cs da de en es fi fr it ja ko nl no pl pt ru sl sv
27 packages 6 4 25 1 18 1 26 2 1 12 20 9 19 7 4 7 17 179
Ready PO files be bg ca cs da de el en eo es et fi fr
+----------------------------------------+
a2ps | [] [] [] [] |
ap-utils | |
bash | [] [] [] [] |
bfd | [] [] |
binutils | [] [] |
bison | [] [] [] [] |
clisp | |
clisp | [] [] [] [] |
clisplow | |
cpio | [] [] [] [] |
darkstat | () |
diffutils | [] [] [] [] [] [] |
enscript | [] [] |
error | [] [] [] |
fetchmail | [] () [] [] [] () |
fileutils | [] [] [] [] [] |
findutils | [] [] [] [] [] [] |
flex | [] [] [] [] [] |
gas | [] [] |
gawk | [] [] [] |
gcal | [] [] |
gcc | [] [] |
gettext | [] [] [] [] [] |
gnupg | [] [] [] [] [] [] [] |
gprof | [] [] |
gpsdrive | () () () () () |
grep | [] [] [] [] [] [] [] [] |
gretl | [] |
gthumb | () () () |
hello | [] [] [] [] [] [] [] [] [] |
id-utils | [] [] [] |
indent | [] [] [] [] [] |
jpilot | () [] [] [] |
jwhois | [] [] |
kbd | [] [] [] |
ld | [] [] |
libc | [] [] [] [] [] [] [] [] |
libiconv | [] [] [] [] |
lifelines | () () |
lilypond | [] [] |
lingoteach | [] [] |
lingoteach_lessons| () () |
lynx | [] [] [] [] [] |
m4 | [] [] [] [] [] |
make | [] [] [] [] |
man-db | [] () () [] () () |
mysecretdiary | [] [] [] |
nano | [] () [] [] [] [] |
nano_1_0 | [] () [] [] [] [] |
opcodes | [] [] [] |
parted | [] [] [] [] [] |
ptx | [] [] [] [] [] [] [] |
python | |
recode | [] [] [] [] [] [] |
sed | [] [] [] [] [] [] [] [] [] [] |
sh-utils | [] [] [] [] |
sharutils | [] [] [] [] [] [] [] |
sketch | () [] () |
soundtracker | [] [] [] |
sp | [] |
tar | [] [] [] [] [] [] |
texinfo | [] [] [] [] [] |
textutils | [] [] [] [] [] |
util-linux | [] [] [] [] [] [] |
vorbis-tools | [] |
wastesedge | |
wdiff | [] [] [] [] [] [] |
wget | [] [] [] [] [] [] [] [] [] [] |
+----------------------------------------+
be bg ca cs da de el en eo es et fi fr
0 2 19 10 30 44 9 1 12 44 17 6 53
gl he hr hu id it ja ko lv nb nl nn
+-------------------------------------+
a2ps | () () [] |
ap-utils | |
bash | [] |
bfd | [] |
binutils | [] |
bison | [] [] [] [] |
clisp | |
clisp | [] |
clisplow | |
cpio | [] [] [] [] |
darkstat | |
diffutils | [] [] [] [] [] |
enscript | [] [] |
error | [] |
fetchmail | [] |
fileutils | [] [] [] |
findutils | [] [] [] [] [] [] [] [] |
flex | [] |
gas | |
gawk | [] |
gcal | |
gcc | [] |
gettext | [] [] |
gnupg | [] [] [] [] |
gprof | [] |
gpsdrive | [] () () |
grep | [] [] [] [] [] [] [] |
gretl | |
gthumb | () () |
hello | [] [] [] [] [] [] [] [] [] [] [] [] |
id-utils | [] [] |
indent | [] [] [] [] |
jpilot | () () |
jwhois | [] [] |
kbd | |
ld | |
libc | [] [] [] [] |
libiconv | [] [] [] |
lifelines | |
lilypond | [] |
lingoteach | [] |
lingoteach_lessons| |
lynx | [] [] [] [] |
m4 | [] [] [] [] |
make | [] [] [] [] [] [] |
man-db | () () |
mysecretdiary | [] |
nano | [] [] [] [] |
nano_1_0 | [] [] [] [] [] |
opcodes | [] [] |
parted | [] [] [] |
ptx | [] [] [] [] [] |
python | |
recode | [] [] [] |
sed | [] [] [] [] [] [] [] [] |
sh-utils | [] [] [] |
sharutils | [] [] [] |
sketch | () |
soundtracker | [] [] |
sp | |
tar | [] [] [] [] [] [] |
texinfo | [] [] [] |
textutils | [] [] [] [] |
util-linux | () [] |
vorbis-tools | [] |
wastesedge | |
wdiff | [] [] [] |
wget | [] [] [] [] [] [] |
+-------------------------------------+
gl he hr hu id it ja ko lv nb nl nn
23 9 12 19 16 13 26 9 1 7 19 3
no pl pt pt_BR ru sk sl sv tr uk zh_CN zh_TW
+----------------------------------------------+
a2ps | () () () [] [] [] [] [] | 10
ap-utils | () | 0
bash | [] | 6
bfd | [] [] | 5
binutils | [] [] | 5
bison | [] [] [] [] | 12
clisp | | 0
clisp | | 5
clisplow | | 0
cpio | [] [] [] [] | 12
darkstat | [] [] () () | 2
diffutils | [] [] [] [] [] [] | 17
enscript | [] [] [] [] | 8
error | [] [] [] | 7
fetchmail | () () [] | 6
fileutils | [] [] [] [] [] [] | 14
findutils | [] [] [] [] [] [] [] | 21
flex | [] [] [] | 9
gas | [] | 3
gawk | [] [] | 6
gcal | [] [] | 4
gcc | [] | 4
gettext | [] [] [] [] [] [] | 13
gnupg | [] [] [] | 14
gprof | [] [] | 5
gpsdrive | [] [] | 3
grep | [] [] [] [] [] | 20
gretl | | 1
gthumb | () () [] | 1
hello | [] [] [] [] [] [] [] | 28
id-utils | [] [] [] [] | 9
indent | [] [] [] [] [] | 14
jpilot | () () [] [] | 5
jwhois | [] () () [] [] | 7
kbd | [] [] | 5
ld | [] [] | 4
libc | [] [] [] [] [] [] | 18
libiconv | [] [] [] [] [] | 12
lifelines | [] | 1
lilypond | [] | 4
lingoteach | [] [] | 5
lingoteach_lessons| () | 0
lynx | [] [] [] [] | 13
m4 | [] [] [] [] | 13
make | [] [] [] [] [] | 15
man-db | | 3
mysecretdiary | [] [] [] | 7
nano | [] [] [] [] | 13
nano_1_0 | [] [] [] [] | 14
opcodes | [] [] [] | 8
parted | [] [] [] [] | 12
ptx | [] [] [] [] [] [] [] | 19
python | | 0
recode | [] [] [] [] [] [] | 15
sed | [] [] [] [] [] [] | 24
sh-utils | [] [] | 9
sharutils | [] [] [] [] | 14
sketch | [] () [] | 4
soundtracker | [] | 6
sp | | 1
tar | [] [] [] [] [] [] [] | 19
texinfo | [] [] | 10
textutils | [] [] [] [] [] | 14
util-linux | [] [] [] | 10
vorbis-tools | [] | 3
wastesedge | | 0
wdiff | [] [] [] [] [] | 14
wget | [] [] [] [] [] [] [] [] | 24
+----------------------------------------------+
37 teams no pl pt pt_BR ru sk sl sv tr uk zh_CN zh_TW
68 domains 4 15 2 28 28 12 10 49 43 4 1 9 609
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
@@ -221,7 +409,27 @@ 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
distribution.
If December 1997 seems to be old, you may fetch a more recent copy
of this `ABOUT-NLS' file on most GNU archive sites.
If August 2002 seems to be old, you may fetch a more recent copy of
this `ABOUT-NLS' file on most GNU archive sites. The most up-to-date
matrix with full percentage details can be found at
`http://www.iro.umontreal.ca/contrib/po/HTML/matrix.html'.
Using `gettext' in new packages
===============================
If you are writing a freely available program and want to
internationalize it you are welcome to use GNU `gettext' in your
package. Of course you have to respect the GNU Library General Public
License which covers the use of the GNU `gettext' library. This means
in particular that even non-free programs can use `libintl' as a shared
library, whereas only free software can use `libintl' as a static
library or use modified versions of `libintl'.
Once the sources are changed appropriately and the setup can handle
to use of `gettext' the only thing missing are the translations. The
Free Translation Project is also available for packages which are not
developed inside the GNU project. Therefore the information given above
applies also for every other Free Software Project. Contact
`translation@iro.umontreal.ca' to make the `.pot' files available to
the translation teams.
$Id$

View File

@@ -24,3 +24,12 @@ Rocco Corsi <rocco.corsi@sympatico.ca>
* Internal spelling code, many optimizations and bug fixes for
findnextstr and search-related functions, various display and
file handling fixes.
David Lawrence Ramsey <pooka_regent@sluggy.net>
* Multiple buffer support, operating dir (-o) option, bug fixes
for display routines, wrapping code, spelling fixes, const
mode and various other fixes.
David Benbennick <dbenbenn@math.cornell.edu>
* Wrap and justify bugfixes/enhancements, new color syntax
code, memleak fixes and other miscellaneous fixes.

96
BUGS
View File

@@ -1,3 +1,6 @@
** Open BUGS **
** Fixed BUGS **
- Marked cutting sometimes leaves a newline in the file unintelligently,
such as when all of a line is selected but the mark doesn't proceed to
the new line. (8) [FIXED/IRRELEVANT]
@@ -6,20 +9,20 @@
- edit_refresh() and update_line() do not handle selecting text when the
cursor is beyond COLS (10) [FIXED]
- no way to do a replace with the empty string (11) [FIXED, yay!]
- Spelling support is not elegant like pico's integration of the 'spell'
- Spelling support is not elegant like Pico's integration of the 'spell'
program. Nano only uses ispell (for now) (12) [FIXED]
- Moving to the end of a line when close to a multiple of COLS and at
least COLS * 2 does not make the screen jump early like it would for
if we were around COLS (bugs in edit_refresh, update_line) (13)
[FIXED, mostly]
- When at the very bottom of the edit window, do_wrap goes berzerk and
puts the curor somewhere bad, subsequent keystrokes crash the program
- When at the very bottom of the edit window, do_wrap goes berserk and
puts the cursor somewhere bad; subsequent keystrokes crash the program
(14) [FIXED, mostly]
- Doing a replacement of a substring of the replace string (e.g. replacing
"ed" with "fred" causes an infinite loop. (15) [FIXED]
"ed" with "fred" causes an infinite loop). (15) [FIXED]
- Cutting a file with marked text and both marker ends on the same line
causes a random segfault (16) [FIXED]
- Cutting more than one line resets the KEEP_CUTBUFFER flag in 0.9.3
- Cutting more than one line resets the KEEP_CUTBUFFER flag in 0.9.3.
Error is in bitwise assignment (nano.h). (17) [FIXED]
- The wrapping code does not work right for lines like the following:
* *
@@ -27,9 +30,10 @@
- Nano fails to follow symlinks, even though -l isn't being used (20).
[Bug in global flag init, FIXED]
- When using --help or --version, the SIGINT character gets lost. (21) [FIXED]
- edit_refresh() and update_line() (and related functions), have
trouble when a tab is the character that is the boundry at COLS (23) [FIXED]
- there is an off-by-one error in keeping track of totsize. It is caused
- edit_refresh() and update_line() (and related functions) have
trouble when a tab is the character that is the boundary at COLS (23)
[FIXED]
- There is an off-by-one error in keeping track of totsize. It is caused
by the fact that we count the newline at the end when we read in a file
but we do not, in fact, display this newline. This should go away
implicitly when the "Magic Line" returns, but it is noted here for
@@ -41,50 +45,52 @@
a dialog about not being able to write the file, and it will not let the
user exit (29, discovered by Joshua Jensen) [FIXED]
- Using nano -k, marked text is not cut properly. (31) [FIXED]
- Invoking -t or -k has the effect of invoking both option. (32) [FIXED]
- Invoking -t or -k has the effect of invoking both options. (32) [FIXED]
- totsize becomes incorrect after word-wrapping (25) [FIXED]
- Wrapping a line with autoindent mode sometimes causes a segfault (19)[FIXED]
- Wrapping a line with autoindent mode sometimes causes a segfault (19)
[FIXED]
- When inserting files, the display sometimes fails to display properly
until a pageup/down occurs (22)[FIXED]
- In search/replace code there is too much refreshing in bottomwin (26)
[FIXED]
until a pageup/down occurs (22) [FIXED]
- In search/replace code, there is too much refreshing in bottomwin (26)
[FIXED]
- In replace, there is no way to accept the default replace string. (27)
[FIXED]
[FIXED]
- Using nano -t, user can not exit until a filename is given via ^O. (30)
[FIXED]
[FIXED]
- totsize problems still abound in do_justify (33) [FIXED]
- Using -k cut text is not pasted properly. (34) [FIXED].
- Using -k pasted text is not updated properly if it goes beyond editbot. (35)
[FIXED]
- Doing a cut with -k can screw up the filestruct, fault is in cutting
- Using -k, cut text is not pasted properly. (34) [FIXED].
- Using -k, pasted text is not updated properly if it goes beyond editbot. (35)
[FIXED]
- Doing a cut with -k can screw up the filestruct; fault is in cutting
code. (36) [FIXED]
- Hitting enter on the magic line makes new lines, but they are not
written out to disk when saved..... (37). [FIXED]
- Page up and page down do not work the same way as Pico (# of lines). (38)
[FIXED]
- Page up and page down do not work the same way as in Pico (# of lines). (38)
[FIXED]
- When doing a search and the marker is set, the screen does not always
properly update the inverted text (39). [FIXED]
- Searches for a string that only exist on one line multiple times will
fail after finding the last occurance (discovered by Ken Tyler) (40). [FIXED]
- Alt-Z is current broken to toggle suspend. I guess I still don't know
- Searches for a string that only exists on one line multiple times will
fail after finding the last occurrence (discovered by Ken Tyler) (40).
[FIXED]
- Alt-Z is currently broken to toggle suspend. I guess I still don't know
signals very well =-) (41) [FIXED].
- Unable to cut the entire file using the marker (discovered by Kev Tyler)
- Unable to cut the entire file using the marker (discovered by Ken Tyler)
(42). [FIXED]
- The keypad does not work when nano runs in the Gnome terminal (43). [FIXED]
- When reading in a file, if the file is a directory the contents of the
- When reading in a file, if the file is a directory, the contents of the
file being edited are blown away (discovered by Chris Pimlot) (44). [FIXED]
- in certain terms, nano will leave a "ghost" of screen upon exit
when called from inside mutt (among other settings) (45). [FIXED]
- In replace, hitting the Goto line shortcut key does nothing after a
search string is entered (discovered by Rocco Corsi) (46) [FIXED].
- When typing in a string in serahc or replace and hitting CASE_SENSITVE
- When typing in a string in search or replace and hitting CASE_SENSITIVE
or the other search string, the current string edit is blown away in
favor of the last stored search (47) [FIXED]
- If nano fails to open a file when it starts up,doing almost anything
- If nano fails to open a file when it starts up, doing almost anything
causes a segfault (discovered by Ben Roberts) (48). [FIXED]
- In certain terminals, nano would not work properly with keypad().
Turned out to be the silly timeout(0) call which is completely
unneeded anyway. (49) [FIXED]
Turned out to be the silly timeout(0) call, which is completely
unneeded, anyway. (49) [FIXED]
- With less than a page of text, doing a page down will move the
current line to the top of the screen, which it shouldn't do. (50)
[FIXED]
@@ -97,15 +103,37 @@
- Cut to end cutting (-k) causes segfaults (try cutting "- Backup making
(filename~)?" line in TODO file) (discovered by
higuita@cadernoverde.com) (54) [FIXED].
- When using autoindent (-i), wrapped text does not get auto-indented
- When using autoindent (-i), wrapped text does not get autoindented
(55, discovered by Mark Senior) [FIXED].
- When using -R (regex) and -p (pico mode), subsequent searches after
- When using -R (regex) and -p (Pico mode), subsequent searches after
the first fail if no string is entered (56) [FIXED].
- Page down on a file of editwinrows fails (again). Reported by Ryan
Krebs (57) [FIXED].
- File browser aborts on Solaris in qsort() call. (Reported by
Matthias Andree) (58) [FIXED].
** Open BUGS **
- Can modify the current file in view mode with ^W^R (discovered by Rocco
Corsi) (58) [FIXED].
- When page up is used after two page down's, the screen doesn't update
properly (discovered by David Lawrence Ramsey) (59) [FIXED].
- On BSD systems, marked cutting sna paste often screws up the
last line in the cutbuffer (discovered by Barry Pederson) (60) [FIXED]
- Blank lines are not kept when cutting with -k (discovered by Rocco)
(61) [FIXED].
- Nano will not suspend properly inside of mutt (62) [FIXED].
- When switching from Pico mode to normal mode, the previous search is
not displayed until cancelling the search (63) [FIXED].
- If you change search options but don't change the search string in
normal mode, hitting enter causes the search/replace to abort (64)
(Jordi Mallach) [FIXED].
- Cutting one line of text causes the screen to recenter the line
(reported and fixed by David Lawrence Ramsey) (65) [FIXED].
- When cutting marked text including the bottom of the file, a new
"magic line" is not created" (reported by David Lawrence
Ramsey, fixed by David Lawrence Ramsey & Chris) (66) [FIXED].
- ^C does not work after a suspend in tcsh (discovered by
Trevor Cordes) (68) [FIXED].
- Home and End control keys (^A, ^E) do not always work in filename
prompt (bug found by Ian Turner) (69) [1.0 series only] [FIXED].
- Trying to insert a file of 0 bytes will hang nano (70) [FIXED].
$Id$

1651
ChangeLog

File diff suppressed because it is too large Load Diff

View File

@@ -1,27 +1,36 @@
## $Id$
AUTOMAKE_OPTIONS = gnu no-dependencies
DEFS= -DSYSCONFDIR=\"$(sysconfdir)\"
bin_PROGRAMS = nano
nano_SOURCES = cut.c \
nano_SOURCES = color.c \
cut.c \
files.c \
global.c \
move.c \
nano.c \
nano.h \
proto.h \
rcfile.c \
search.c \
utils.c \
winio.c
man_MANS = nano.1
nano_LDADD = @INTLLIBS@
nano_LDADD = @GLIB_LIBS@ @LIBINTL@
info_TEXINFOS = nano.texi
MAKEINFO = makeinfo --no-split
EXTRA_DIST = AUTHORS BUGS COPYING ChangeLog INSTALL NEWS README \
TODO install-sh missing mkinstalldirs nano.1 nano.1.html \
faq.html
EXTRA_DIST = ABOUT-NLS AUTHORS BUGS COPYING ChangeLog INSTALL NEWS \
README THANKS TODO config.rpath install-sh missing \
mkinstalldirs nano.1 nano.1.html faq.html nanorc.sample \
nano.spec
SUBDIRS = po intl
SUBDIRS = po m4
localedir = $(datadir)/locale
INCLUDES = -Iintl -DLOCALEDIR=\"$(localedir)\" -I@includedir@
ACLOCAL_AMFLAGS = -I m4

View File

@@ -1,635 +0,0 @@
# Makefile.in generated automatically by automake 1.4 from Makefile.am
# Copyright (C) 1994, 1995-8, 1999 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
# PARTICULAR PURPOSE.
SHELL = @SHELL@
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
DESTDIR =
pkgdatadir = $(datadir)/@PACKAGE@
pkglibdir = $(libdir)/@PACKAGE@
pkgincludedir = $(includedir)/@PACKAGE@
top_builddir = .
ACLOCAL = @ACLOCAL@
AUTOCONF = @AUTOCONF@
AUTOMAKE = @AUTOMAKE@
AUTOHEADER = @AUTOHEADER@
INSTALL = @INSTALL@
INSTALL_PROGRAM = @INSTALL_PROGRAM@ $(AM_INSTALL_PROGRAM_FLAGS)
INSTALL_DATA = @INSTALL_DATA@
INSTALL_SCRIPT = @INSTALL_SCRIPT@
transform = @program_transform_name@
NORMAL_INSTALL = :
PRE_INSTALL = :
POST_INSTALL = :
NORMAL_UNINSTALL = :
PRE_UNINSTALL = :
POST_UNINSTALL = :
CATALOGS = @CATALOGS@
CATOBJEXT = @CATOBJEXT@
CC = @CC@
CURSES_LIB = @CURSES_LIB@
DATADIRNAME = @DATADIRNAME@
GENCAT = @GENCAT@
GLIB_CFLAGS = @GLIB_CFLAGS@
GLIB_CONFIG = @GLIB_CONFIG@
GLIB_LIBS = @GLIB_LIBS@
GMOFILES = @GMOFILES@
GMSGFMT = @GMSGFMT@
GT_NO = @GT_NO@
GT_YES = @GT_YES@
INCLUDE_LOCALE_H = @INCLUDE_LOCALE_H@
INSTOBJEXT = @INSTOBJEXT@
INTLDEPS = @INTLDEPS@
INTLLIBS = @INTLLIBS@
INTLOBJS = @INTLOBJS@
MKINSTALLDIRS = @MKINSTALLDIRS@
MSGFMT = @MSGFMT@
PACKAGE = @PACKAGE@
POFILES = @POFILES@
POSUB = @POSUB@
RANLIB = @RANLIB@
USE_INCLUDED_LIBINTL = @USE_INCLUDED_LIBINTL@
USE_NLS = @USE_NLS@
VERSION = @VERSION@
l = @l@
bin_PROGRAMS = nano
nano_SOURCES = cut.c files.c global.c move.c nano.c nano.h proto.h search.c utils.c winio.c
man_MANS = nano.1
nano_LDADD = @INTLLIBS@
info_TEXINFOS = nano.texi
MAKEINFO = makeinfo --no-split
EXTRA_DIST = AUTHORS BUGS COPYING ChangeLog INSTALL NEWS README TODO install-sh missing mkinstalldirs nano.1 nano.1.html faq.html
SUBDIRS = po intl
localedir = $(datadir)/locale
INCLUDES = -Iintl -DLOCALEDIR=\"$(localedir)\" -I@includedir@
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
CONFIG_HEADER = config.h
CONFIG_CLEAN_FILES =
PROGRAMS = $(bin_PROGRAMS)
DEFS = @DEFS@ -I. -I$(srcdir) -I.
CPPFLAGS = @CPPFLAGS@
LDFLAGS = @LDFLAGS@
LIBS = @LIBS@
nano_OBJECTS = cut.o files.o global.o move.o nano.o search.o utils.o \
winio.o
nano_DEPENDENCIES =
nano_LDFLAGS =
CFLAGS = @CFLAGS@
COMPILE = $(CC) $(DEFS) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
CCLD = $(CC)
LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(LDFLAGS) -o $@
TEXI2DVI = texi2dvi
INFO_DEPS = nano.info
DVIS = nano.dvi
TEXINFOS = nano.texi
man1dir = $(mandir)/man1
MANS = $(man_MANS)
NROFF = nroff
DIST_COMMON = README ./stamp-h.in ABOUT-NLS AUTHORS COPYING ChangeLog \
INSTALL Makefile.am Makefile.in NEWS TODO acconfig.h aclocal.m4 \
config.h.in configure configure.in install-sh missing mkinstalldirs \
texinfo.tex
DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST)
TAR = tar
GZIP_ENV = --best
SOURCES = $(nano_SOURCES)
OBJECTS = $(nano_OBJECTS)
all: all-redirect
.SUFFIXES:
.SUFFIXES: .S .c .dvi .info .o .ps .s .texi .texinfo .txi
$(srcdir)/Makefile.in: Makefile.am $(top_srcdir)/configure.in $(ACLOCAL_M4)
cd $(top_srcdir) && $(AUTOMAKE) --gnu --include-deps Makefile
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
cd $(top_builddir) \
&& CONFIG_FILES=$@ CONFIG_HEADERS= $(SHELL) ./config.status
$(ACLOCAL_M4): configure.in
cd $(srcdir) && $(ACLOCAL)
config.status: $(srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
$(SHELL) ./config.status --recheck
$(srcdir)/configure: $(srcdir)/configure.in $(ACLOCAL_M4) $(CONFIGURE_DEPENDENCIES)
cd $(srcdir) && $(AUTOCONF)
config.h: stamp-h
@if test ! -f $@; then \
rm -f stamp-h; \
$(MAKE) stamp-h; \
else :; fi
stamp-h: $(srcdir)/config.h.in $(top_builddir)/config.status
cd $(top_builddir) \
&& CONFIG_FILES= CONFIG_HEADERS=config.h:config.h.in \
$(SHELL) ./config.status
@echo timestamp > stamp-h 2> /dev/null
$(srcdir)/config.h.in: $(srcdir)/stamp-h.in
@if test ! -f $@; then \
rm -f $(srcdir)/stamp-h.in; \
$(MAKE) $(srcdir)/stamp-h.in; \
else :; fi
$(srcdir)/stamp-h.in: $(top_srcdir)/configure.in $(ACLOCAL_M4) acconfig.h
cd $(top_srcdir) && $(AUTOHEADER)
@echo timestamp > $(srcdir)/stamp-h.in 2> /dev/null
mostlyclean-hdr:
clean-hdr:
distclean-hdr:
-rm -f config.h
maintainer-clean-hdr:
mostlyclean-binPROGRAMS:
clean-binPROGRAMS:
-test -z "$(bin_PROGRAMS)" || rm -f $(bin_PROGRAMS)
distclean-binPROGRAMS:
maintainer-clean-binPROGRAMS:
install-binPROGRAMS: $(bin_PROGRAMS)
@$(NORMAL_INSTALL)
$(mkinstalldirs) $(DESTDIR)$(bindir)
@list='$(bin_PROGRAMS)'; for p in $$list; do \
if test -f $$p; then \
echo " $(INSTALL_PROGRAM) $$p $(DESTDIR)$(bindir)/`echo $$p|sed 's/$(EXEEXT)$$//'|sed '$(transform)'|sed 's/$$/$(EXEEXT)/'`"; \
$(INSTALL_PROGRAM) $$p $(DESTDIR)$(bindir)/`echo $$p|sed 's/$(EXEEXT)$$//'|sed '$(transform)'|sed 's/$$/$(EXEEXT)/'`; \
else :; fi; \
done
uninstall-binPROGRAMS:
@$(NORMAL_UNINSTALL)
list='$(bin_PROGRAMS)'; for p in $$list; do \
rm -f $(DESTDIR)$(bindir)/`echo $$p|sed 's/$(EXEEXT)$$//'|sed '$(transform)'|sed 's/$$/$(EXEEXT)/'`; \
done
.c.o:
$(COMPILE) -c $<
.s.o:
$(COMPILE) -c $<
.S.o:
$(COMPILE) -c $<
mostlyclean-compile:
-rm -f *.o core *.core
clean-compile:
distclean-compile:
-rm -f *.tab.c
maintainer-clean-compile:
nano: $(nano_OBJECTS) $(nano_DEPENDENCIES)
@rm -f nano
$(LINK) $(nano_LDFLAGS) $(nano_OBJECTS) $(nano_LDADD) $(LIBS)
nano.info: nano.texi
nano.dvi: nano.texi
DVIPS = dvips
.texi.info:
@cd $(srcdir) && rm -f $@ $@-[0-9] $@-[0-9][0-9]
cd $(srcdir) \
&& $(MAKEINFO) `echo $< | sed 's,.*/,,'`
.texi.dvi:
TEXINPUTS=.:$$TEXINPUTS \
MAKEINFO='$(MAKEINFO) -I $(srcdir)' $(TEXI2DVI) $<
.texi:
@cd $(srcdir) && rm -f $@ $@-[0-9] $@-[0-9][0-9]
cd $(srcdir) \
&& $(MAKEINFO) `echo $< | sed 's,.*/,,'`
.texinfo.info:
@cd $(srcdir) && rm -f $@ $@-[0-9] $@-[0-9][0-9]
cd $(srcdir) \
&& $(MAKEINFO) `echo $< | sed 's,.*/,,'`
.texinfo:
@cd $(srcdir) && rm -f $@ $@-[0-9] $@-[0-9][0-9]
cd $(srcdir) \
&& $(MAKEINFO) `echo $< | sed 's,.*/,,'`
.texinfo.dvi:
TEXINPUTS=.:$$TEXINPUTS \
MAKEINFO='$(MAKEINFO) -I $(srcdir)' $(TEXI2DVI) $<
.txi.info:
@cd $(srcdir) && rm -f $@ $@-[0-9] $@-[0-9][0-9]
cd $(srcdir) \
&& $(MAKEINFO) `echo $< | sed 's,.*/,,'`
.txi.dvi:
TEXINPUTS=.:$$TEXINPUTS \
MAKEINFO='$(MAKEINFO) -I $(srcdir)' $(TEXI2DVI) $<
.txi:
@cd $(srcdir) && rm -f $@ $@-[0-9] $@-[0-9][0-9]
cd $(srcdir) \
&& $(MAKEINFO) `echo $< | sed 's,.*/,,'`
.dvi.ps:
$(DVIPS) $< -o $@
install-info-am: $(INFO_DEPS)
@$(NORMAL_INSTALL)
$(mkinstalldirs) $(DESTDIR)$(infodir)
@list='$(INFO_DEPS)'; \
for file in $$list; do \
d=$(srcdir); \
for ifile in `cd $$d && echo $$file $$file-[0-9] $$file-[0-9][0-9]`; do \
if test -f $$d/$$ifile; then \
echo " $(INSTALL_DATA) $$d/$$ifile $(DESTDIR)$(infodir)/$$ifile"; \
$(INSTALL_DATA) $$d/$$ifile $(DESTDIR)$(infodir)/$$ifile; \
else : ; fi; \
done; \
done
@$(POST_INSTALL)
@if $(SHELL) -c 'install-info --version | sed 1q | fgrep -s -v -i debian' >/dev/null 2>&1; then \
list='$(INFO_DEPS)'; \
for file in $$list; do \
echo " install-info --info-dir=$(DESTDIR)$(infodir) $(DESTDIR)$(infodir)/$$file";\
install-info --info-dir=$(DESTDIR)$(infodir) $(DESTDIR)$(infodir)/$$file || :;\
done; \
else : ; fi
uninstall-info:
$(PRE_UNINSTALL)
@if $(SHELL) -c 'install-info --version | sed 1q | fgrep -s -v -i debian' >/dev/null 2>&1; then \
ii=yes; \
else ii=; fi; \
list='$(INFO_DEPS)'; \
for file in $$list; do \
test -z "$ii" \
|| install-info --info-dir=$(DESTDIR)$(infodir) --remove $$file; \
done
@$(NORMAL_UNINSTALL)
list='$(INFO_DEPS)'; \
for file in $$list; do \
(cd $(DESTDIR)$(infodir) && rm -f $$file $$file-[0-9] $$file-[0-9][0-9]); \
done
dist-info: $(INFO_DEPS)
list='$(INFO_DEPS)'; \
for base in $$list; 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-aminfo:
-rm -f nano.aux nano.cp nano.cps nano.dvi nano.fn nano.fns nano.ky \
nano.kys nano.ps nano.log nano.pg nano.toc nano.tp nano.tps \
nano.vr nano.vrs nano.op nano.tr nano.cv nano.cn
clean-aminfo:
distclean-aminfo:
maintainer-clean-aminfo:
cd $(srcdir) && for i in $(INFO_DEPS); do \
rm -f $$i; \
if test "`echo $$i-[0-9]*`" != "$$i-[0-9]*"; then \
rm -f $$i-[0-9]*; \
fi; \
done
install-man1:
$(mkinstalldirs) $(DESTDIR)$(man1dir)
@list='$(man1_MANS)'; \
l2='$(man_MANS)'; for i in $$l2; do \
case "$$i" in \
*.1*) list="$$list $$i" ;; \
esac; \
done; \
for i in $$list; do \
if test -f $(srcdir)/$$i; then file=$(srcdir)/$$i; \
else file=$$i; fi; \
ext=`echo $$i | sed -e 's/^.*\\.//'`; \
inst=`echo $$i | sed -e 's/\\.[0-9a-z]*$$//'`; \
inst=`echo $$inst | sed '$(transform)'`.$$ext; \
echo " $(INSTALL_DATA) $$file $(DESTDIR)$(man1dir)/$$inst"; \
$(INSTALL_DATA) $$file $(DESTDIR)$(man1dir)/$$inst; \
done
uninstall-man1:
@list='$(man1_MANS)'; \
l2='$(man_MANS)'; for i in $$l2; do \
case "$$i" in \
*.1*) list="$$list $$i" ;; \
esac; \
done; \
for i in $$list; do \
ext=`echo $$i | sed -e 's/^.*\\.//'`; \
inst=`echo $$i | sed -e 's/\\.[0-9a-z]*$$//'`; \
inst=`echo $$inst | sed '$(transform)'`.$$ext; \
echo " rm -f $(DESTDIR)$(man1dir)/$$inst"; \
rm -f $(DESTDIR)$(man1dir)/$$inst; \
done
install-man: $(MANS)
@$(NORMAL_INSTALL)
$(MAKE) $(AM_MAKEFLAGS) install-man1
uninstall-man:
@$(NORMAL_UNINSTALL)
$(MAKE) $(AM_MAKEFLAGS) uninstall-man1
# This directory's subdirectories are mostly independent; you can cd
# into them and run `make' without going through this Makefile.
# To change the values of `make' variables: instead of editing Makefiles,
# (1) if the variable is set in `config.status', edit `config.status'
# (which will cause the Makefiles to be regenerated when you run `make');
# (2) otherwise, pass the desired values on the `make' command line.
@SET_MAKE@
all-recursive install-data-recursive install-exec-recursive \
installdirs-recursive install-recursive uninstall-recursive \
check-recursive installcheck-recursive info-recursive dvi-recursive:
@set fnord $(MAKEFLAGS); amf=$$2; \
dot_seen=no; \
target=`echo $@ | sed s/-recursive//`; \
list='$(SUBDIRS)'; for subdir in $$list; do \
echo "Making $$target in $$subdir"; \
if test "$$subdir" = "."; then \
dot_seen=yes; \
local_target="$$target-am"; \
else \
local_target="$$target"; \
fi; \
(cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
|| case "$$amf" in *=*) exit 1;; *k*) fail=yes;; *) exit 1;; esac; \
done; \
if test "$$dot_seen" = "no"; then \
$(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
fi; test -z "$$fail"
mostlyclean-recursive clean-recursive distclean-recursive \
maintainer-clean-recursive:
@set fnord $(MAKEFLAGS); amf=$$2; \
dot_seen=no; \
rev=''; list='$(SUBDIRS)'; for subdir in $$list; do \
rev="$$subdir $$rev"; \
test "$$subdir" = "." && dot_seen=yes; \
done; \
test "$$dot_seen" = "no" && rev=". $$rev"; \
target=`echo $@ | sed s/-recursive//`; \
for subdir in $$rev; do \
echo "Making $$target in $$subdir"; \
if test "$$subdir" = "."; then \
local_target="$$target-am"; \
else \
local_target="$$target"; \
fi; \
(cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
|| case "$$amf" in *=*) exit 1;; *k*) fail=yes;; *) exit 1;; esac; \
done && test -z "$$fail"
tags-recursive:
list='$(SUBDIRS)'; for subdir in $$list; do \
test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \
done
tags: TAGS
ID: $(HEADERS) $(SOURCES) $(LISP)
list='$(SOURCES) $(HEADERS)'; \
unique=`for i in $$list; do echo $$i; done | \
awk ' { files[$$0] = 1; } \
END { for (i in files) print i; }'`; \
here=`pwd` && cd $(srcdir) \
&& mkid -f$$here/ID $$unique $(LISP)
TAGS: tags-recursive $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) $(LISP)
tags=; \
here=`pwd`; \
list='$(SUBDIRS)'; for subdir in $$list; do \
if test "$$subdir" = .; then :; else \
test -f $$subdir/TAGS && tags="$$tags -i $$here/$$subdir/TAGS"; \
fi; \
done; \
list='$(SOURCES) $(HEADERS)'; \
unique=`for i in $$list; do echo $$i; done | \
awk ' { files[$$0] = 1; } \
END { for (i in files) print i; }'`; \
test -z "$(ETAGS_ARGS)config.h.in$$unique$(LISP)$$tags" \
|| (cd $(srcdir) && etags $(ETAGS_ARGS) $$tags config.h.in $$unique $(LISP) -o $$here/TAGS)
mostlyclean-tags:
clean-tags:
distclean-tags:
-rm -f TAGS ID
maintainer-clean-tags:
distdir = $(PACKAGE)-$(VERSION)
top_distdir = $(distdir)
# This target untars the dist file and tries a VPATH configuration. Then
# it guarantees that the distribution is self-contained by making another
# tarfile.
distcheck: dist
-rm -rf $(distdir)
GZIP=$(GZIP_ENV) $(TAR) zxf $(distdir).tar.gz
mkdir $(distdir)/=build
mkdir $(distdir)/=inst
dc_install_base=`cd $(distdir)/=inst && pwd`; \
cd $(distdir)/=build \
&& ../configure --with-included-gettext --srcdir=.. --prefix=$$dc_install_base \
&& $(MAKE) $(AM_MAKEFLAGS) \
&& $(MAKE) $(AM_MAKEFLAGS) dvi \
&& $(MAKE) $(AM_MAKEFLAGS) check \
&& $(MAKE) $(AM_MAKEFLAGS) install \
&& $(MAKE) $(AM_MAKEFLAGS) installcheck \
&& $(MAKE) $(AM_MAKEFLAGS) dist
-rm -rf $(distdir)
@banner="$(distdir).tar.gz is ready for distribution"; \
dashes=`echo "$$banner" | sed s/./=/g`; \
echo "$$dashes"; \
echo "$$banner"; \
echo "$$dashes"
dist: distdir
-chmod -R a+r $(distdir)
GZIP=$(GZIP_ENV) $(TAR) chozf $(distdir).tar.gz $(distdir)
-rm -rf $(distdir)
dist-all: distdir
-chmod -R a+r $(distdir)
GZIP=$(GZIP_ENV) $(TAR) chozf $(distdir).tar.gz $(distdir)
-rm -rf $(distdir)
distdir: $(DISTFILES)
-rm -rf $(distdir)
mkdir $(distdir)
-chmod 777 $(distdir)
@for file in $(DISTFILES); do \
d=$(srcdir); \
if test -d $$d/$$file; then \
cp -pr $$d/$$file $(distdir)/$$file; \
else \
test -f $(distdir)/$$file \
|| ln $$d/$$file $(distdir)/$$file 2> /dev/null \
|| cp -p $$d/$$file $(distdir)/$$file || :; \
fi; \
done
for subdir in $(SUBDIRS); do \
if test "$$subdir" = .; then :; else \
test -d $(distdir)/$$subdir \
|| mkdir $(distdir)/$$subdir \
|| exit 1; \
chmod 777 $(distdir)/$$subdir; \
(cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir=../$(distdir) distdir=../$(distdir)/$$subdir distdir) \
|| exit 1; \
fi; \
done
$(MAKE) $(AM_MAKEFLAGS) top_distdir="$(top_distdir)" distdir="$(distdir)" dist-info
info-am: $(INFO_DEPS)
info: info-recursive
dvi-am: $(DVIS)
dvi: dvi-recursive
check-am: all-am
check: check-recursive
installcheck-am:
installcheck: installcheck-recursive
all-recursive-am: config.h
$(MAKE) $(AM_MAKEFLAGS) all-recursive
install-exec-am: install-binPROGRAMS
install-exec: install-exec-recursive
install-data-am: install-info-am install-man
install-data: install-data-recursive
install-am: all-am
@$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
install: install-recursive
uninstall-am: uninstall-binPROGRAMS uninstall-info uninstall-man
uninstall: uninstall-recursive
all-am: Makefile $(INFO_DEPS) $(PROGRAMS) $(MANS) config.h
all-redirect: all-recursive-am
install-strip:
$(MAKE) $(AM_MAKEFLAGS) AM_INSTALL_PROGRAM_FLAGS=-s install
installdirs: installdirs-recursive
installdirs-am:
$(mkinstalldirs) $(DESTDIR)$(bindir) $(DESTDIR)$(infodir) \
$(DESTDIR)$(mandir)/man1
mostlyclean-generic:
clean-generic:
distclean-generic:
-rm -f Makefile $(CONFIG_CLEAN_FILES)
-rm -f config.cache config.log stamp-h stamp-h[0-9]*
maintainer-clean-generic:
mostlyclean-am: mostlyclean-hdr mostlyclean-binPROGRAMS \
mostlyclean-compile mostlyclean-aminfo mostlyclean-tags \
mostlyclean-generic
mostlyclean: mostlyclean-recursive
clean-am: clean-hdr clean-binPROGRAMS clean-compile clean-aminfo \
clean-tags clean-generic mostlyclean-am
clean: clean-recursive
distclean-am: distclean-hdr distclean-binPROGRAMS distclean-compile \
distclean-aminfo distclean-tags distclean-generic \
clean-am
distclean: distclean-recursive
-rm -f config.status
maintainer-clean-am: maintainer-clean-hdr maintainer-clean-binPROGRAMS \
maintainer-clean-compile maintainer-clean-aminfo \
maintainer-clean-tags maintainer-clean-generic \
distclean-am
@echo "This command is intended for maintainers to use;"
@echo "it deletes files that may require special tools to rebuild."
maintainer-clean: maintainer-clean-recursive
-rm -f config.status
.PHONY: mostlyclean-hdr distclean-hdr clean-hdr maintainer-clean-hdr \
mostlyclean-binPROGRAMS distclean-binPROGRAMS clean-binPROGRAMS \
maintainer-clean-binPROGRAMS uninstall-binPROGRAMS install-binPROGRAMS \
mostlyclean-compile distclean-compile clean-compile \
maintainer-clean-compile install-info-am uninstall-info \
mostlyclean-aminfo distclean-aminfo clean-aminfo \
maintainer-clean-aminfo install-man1 uninstall-man1 install-man \
uninstall-man install-data-recursive uninstall-data-recursive \
install-exec-recursive uninstall-exec-recursive installdirs-recursive \
uninstalldirs-recursive all-recursive check-recursive \
installcheck-recursive info-recursive dvi-recursive \
mostlyclean-recursive distclean-recursive clean-recursive \
maintainer-clean-recursive tags tags-recursive mostlyclean-tags \
distclean-tags clean-tags maintainer-clean-tags distdir info-am info \
dvi-am dvi check check-am installcheck-am installcheck all-recursive-am \
install-exec-am install-exec install-data-am install-data install-am \
install uninstall-am uninstall all-redirect all-am all installdirs-am \
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:

266
NEWS
View File

@@ -1,3 +1,191 @@
10/24/2002 - GNU nano 1.1.12 "Make Jordi happy" is released. This
release demonstrated that nano is starting to freeze for
version 1.2. New features include a Meta-Y toggle
for syntax highlighting, pluralized i18n, and a handler
for SIGTERM. Nano now ignores XOFF (^S) to stop
accidental lock-ups, and no longer references malloc.h.
Also included are fixes for zero-length regex
matches, segfaults with --disable-mouse, justification,
memory corruption with the browser, version and help
cmdline output, and translation updates. Aside from
the (currently up in the air) search history behavior,
the next version of nano should be 1.1.99pre1. Have
fun!
10/01/2002 - GNU nano 1.1.11 "Oddball" is released. This release
features a new version of gettext, a new and improved syntax
highlighting engine, and some updates for the nanorc.sample
file. The toggles for case sensitivity (Meta-C) and regular
expressions (Meta-R) have changed in the search and replace
prompts, multibuffer status is now displayed and can be
toggled from the insert file menu, and some wrapping behavior
that changed in 1.1.10 has reverted. The --enable-color
warning was also made less severe, as the color syntax code
has improved, and nano now uses extended regexes in the
.nanorc file.
Also included are fixes for various memory leaks,
the operating directory option, username tab completion,
the page_up and down arrow, go to previous word and next
word, nanorc parser and line wrapping code. Have fun!
07/25/2002 - At long last! GNU nano 1.1.10 "What didn't we break?" is
released. This version of GNU nano features version
0.11.2 of gettext, building with automake 1.6, some new
code for displaying control characters, browser
improvements, a new backup file option (-B, --backup),
a new option to ignore rc files (-I,--ignorercfiles),
compatibility with -pedantic, handling null characters
before EOF, a slightly sportier nanorc.sample and more.
Fixes are included included for justification, the
reading and writing file routines, resizing and fill
length, millions of memory leaks, the usage screen was
updated, and the the --quotestr and --regexp really work
now ;-) Enjoy :)
05/12/2002 - GNU nano 1.1.9 is released, happy Mother's Day! This release
includes many new features, including a prepend mode
(^O,M-P), a new "syntax" command in the .nanorc to allow
multiple syntax highlighting types, and a new -Y, --syntax
flag to set a specific one if there's no filename regex to
match it against (i.e. w/mutt). The ^space and M-space keys
will now show up in the help menu, which itself has been
tweaked a bit, and many more configure options should now
cooperate (like the odd pairing of --enable-tiny and
--enable-multibuffer). The marker should now work
when using multiple buffers, and the huge memory leak in
color syntax highlighting has been fixed. A lot of
new stuff for everyone's favorite text editor ;) Have fun!
03/30/2002 - GNU nano 1.1.8 is released. New features include an
"Insert Output of External Command", ^R^X, and a .spec
file is now included in the distribution. There are
cleanups in the usage code, fixes for regex parsing,
the file browser, the NO_CONVERT auto-detect, indented
justification, the internal spell checker, and a serious
bug where reading a file of 0 lines would hang nano.
Also, the "show position" code now shows the starting
column as 1 instead of 0. Have fun!
03/05/2002 - GNU nano 1.1.7 "lets change everything and see what breaks"
is released. New features include new flags
-N,--noconvert to stop any file format conversion and
-Q, --quotestr for the new quoted text justification,
a new tempnam() implementation to avoid silly warnings,
DOS and Mac file options in the Write File dialog,
multiple save files (file.1) for abnormal exits, ^C
now shows column as well as character position, and
multibuffer allows duplicate files, even unnamed ones.
Also, the static shortcut and toggle lengths are
history, nano now reads $SYSCONFDIR/nanorc if rc file
support is enabled, and nano is now built with (and
requires for rebuilding) autoconf 2.5.
This release also includes fixes for some memory
leaks, detecting DOS and mac file format, justification,
suspending keys, search & replace under various
conditions, variable width for shortcuts, and the usual
ton of translation updates.
01/25/2002 - GNU nano 1.1.6 is released. Lots of new features in this
release. New Meta-keys were added as alternates for
control sequences: Meta-A for the marker key (^^), and
Meta-G for the 'goto dir' key in the file browser (^_).
The color syntax highlighting now supports multiple
lines via start="regex" end="regex" syntax, and the
.nanorc regex format itself has changed. Also, the
gettext code was upgraded to version 0.10.40, and nano
will now display a message if only occurrence of a
given search exists.
For bugfixes, there are fixes for spelling,
stray newlines in the usage() function, suspend issues
with tcsh, auto-indent and wrapping clashes, ugly code
in rcfile.c, global variable compatibility with AIX.
There are also oodles of translation updates.
Have fun with it.
01/05/2002 - GNU nano 1.1.5 is out. The main new feature in this
release is the changed behavior of the keypad. Nano now
does the Right Thing and used keypad() by default. If
you wish to use the keypad arrow keys in certain
terminals, you may use the -K or --keypad flag to
use the old behavior. Users of other OSes should see
better handling of their non-keypad keys in this
release. Other changes include more Hurd fixes, fixes
parsing the .nanorc, display fixes for the color syntax
highlighting, gettext stabilization and many translation
updates. This is amost like a stable release, much like
in the 0.9.x series when every other release was the
mosts stable one :) Have fun!
12/11/2001 - GNU nano 1.1.4 is released. This release contains
rudimentary color syntax support (but it's still
broken), compatibility fixes for the Hurd and FreeBSD,
spell checker and wrapping fixes, and more. It seems
that the amount of interest in the code is inversely
proportional to the amount of time since last release,
so it's time to show the world all the changes since
1.1.3 ;) Have fun with it!
10/26/2001 - GNU nano 1.1.3 is released. As far as new features go,
the help system is now available for all functions in the
editor. Also, nano will also now print a message on
the status bar when it automatically converts a file from
Mac or DOS format, and trying to load a file that
has already been loaded in multibuffer mode will now also
cause an error message. There is now a "goto previous
word" which you can use by hitting Meta-Space Bar.
As for fixes, a SEVERE bug in the
null_at code which discarded the memory address of
reallocated memory has been fixed. This is probably
the biggest bug fix in well over the last year of
development. There are also some display fixes for when
the screen shouldn't center itself on cut or uncut text.
Also, the comments in the header files incorectly said
that nano was distributed under version 1 of the GPL when
the accompanying license was the GPLv2.
If you're using nano-1.1, it is highly
recommeneded you upgrade to this release. If using 1.0,
wait for version 1.0.6 which should be available early
next week. Enjoy!
10/03/2001 - GNU nano 1.1.2 is out there. Many new features in this
release, including support for auto-converting from
DOS and Mac formatted files, as well as toggles for
writing out files in these formats. Pico's -o flag has
been implemented, as has some new smooth scrolling code
(which can be used in place of the default jerky scrolling
behavior). Also, there is now a "find matching
bracket/brace/etc" feature (Meta-]). The .nanorc file
now accepts setting the tabsize, and the help text at the
bottom of the editor is now better spaced out in the
search/replace prompts. There are also the usual helping
of bugfixes, translation updates and, surely a bug or two.
You better get ready!
07/28/2001 - GNU nano 1.1.1 is released. Our second 1.1 unstable release
features many bugfixes from the initial release, in
particular fixs for the multibuffer code, and various
compiler macro fixes. The shortcut lists for
the search and replace prompts are a little more logical
(with cancel the last option again), and the included
gettext was re-downgraded to 0.10.35 due to problems
on the PPC platform. GNU nano now includes its own
aclocal macros in the m4/ directory to allow rebuilding
the configure script to work on platforms regardless of
their gettext version.
07/15/2001 - GNU nano 1.1.0 is released. This is the first release
in the 1.1.x unstable series of GNU nano. It
incorporates all changes up to the 1.0.3 release,
and also includes many many new features, including
appending to as well as overwriting files, writing
marked text to a separate file, dynamic wrap length,
lots more compatibility with Pico, and new optional
features like .nanorc file support and multiple file
buffers! All in all, plenty of new stuff that's sure
to introduce lots of bugs ;-) Have fun with it, but
be careful, unstable means unstable.
04/06/2001 - GNU nano 1.0.1 is out there. The only new feature is a
configure option for those who want to disable all
word wrapping from nano, --disable-wrapping. Bug fixes
@@ -23,11 +211,11 @@
default list of shortcuts, "^G Get Help" is now Listed and
"^_ Goto Line" is not). The Yes/No/All keys have
finally been internationalized also. All in all, quite
a few changes considering nano is supposed to be in a code
freeze. But there are the usual helping of bugfixes, a
a few changes, considering nano is supposed to be in a code
freeze. But there are the usual helping of bugfixes, a
nasty bug when cutting text in -k mode and some
compatibility with older ncurses libraries have also been
fixed. All in all, a lot to see.
compatibility issues with older ncurses libraries have also
been fixed. All in all, a lot to see.
01/31/2001 - Nano 0.9.99pre2 is released. Not surprisingly, all that is
new is bugfixes, bugfixes, bugfixes. There were a few
@@ -60,7 +248,7 @@
tab completion in certain instances. Have fun and Happy
New Year!
12/18/2000 - Nano 0.9.24 is released. This versions contains the last of
12/18/2000 - Nano 0.9.24 is released. This version contains the last of
the security fixes for writing files, as well as for a
nasty segfault when nano is unable to open a file for
reading, among other fixes. Nano also now cowardly
@@ -74,11 +262,11 @@
12/08/2000 - Nano 0.9.23 is the "race conditions bite" release. The
main reason for this release is the less-than-optimal
fix for the security issue in nano with following symbolic
links. Hopefully this will fix the probelm permanently.
links. Hopefully this will fix the problem permanently.
The --nofollow option also works again for those who
are real security nuts. There are also some display and
search fixes, and the --disable-spell function was renamed
to --disable-speller to be in line with nano and pico's
to --disable-speller to be in line with nano and Pico's
"speller" term.
12/02/2000 - Nano 0.9.22 is released, with many more changes and
@@ -114,10 +302,10 @@
(courtesy of Mr. Rocco Corsi) and tab completion when
reading in or writing out files! There's also the usual
billion or so bug fixes. Feedback on this release is
welcome because so much much has changed, especially with
the previous string display in search and replace. Email
-> nano@nano-editor.org <-. If you like something, don't
like something, or just want to order a pizza, let us know!
welcome because so much has changed, especially with the
previous string display in search and replace. Email ->
nano@nano-editor.org <-. If you like something, don't like
something, or just want to order a pizza, let us know!
10/02/2000 - Nano 0.9.19 is the "Chris is getting married in less than
a week and needs a distraction" release. There are only
@@ -143,16 +331,16 @@
flags (M-c, M-i, M-z, M-x, M-p, M-w, M-m, M-k and M-e for
-c, -i, -x, -p, -w, -k, and -R).
08/09/2000 - Nano 0.9.16, after some struggling, is release. This release
08/09/2000 - Nano 0.9.16, after some struggling, is released. This release
should fix a few of the holes that 0.9.15 dug. The
"cutting text on the first line" bug is fixed, as is the
"cutting text on the last line" bug. Nice symmetry there
huh? Also the --tabsize argument should now work as well
as by using -T.
08/03/2000 - Nano 0.9.15 is the "I cant think of a release description"
08/03/2000 - Nano 0.9.15 is the "I can't think of a release description"
release. There are the usual gala of display bugfixes,
a for the the nasty bug in -k mode that could create a
a fix for the the nasty bug in -k mode that could create a
loop in the file being edited, and some other code
cleanup. Also, the -T option should now work regardless
of the curses library used. Yay.
@@ -161,7 +349,7 @@
be skipped as a version number" release. One typo
caused unending problems (calling nano with either -t or
-k caused both flags to be used). The -k code is also now
closer in functionality to Pico's -k mode, please
closer in functionality to Pico's -k mode; please
note that this code is not finished yet. Working on this
code has made me realize that there is not enough
abstraction in the code, and I will be working on that
@@ -170,7 +358,7 @@
07/23/2000 - Nano 0.9.13 has a few new bits and bobs, most notably the
-k option from Pico (cut to end of line). The majority
of changes in this release are bugfixes however, including
of changes in this release are bugfixes, however, including
the usual display fixes and fixes for writing to symbolic
links and un-writeable files. Barring any other major
changes, this should be the feature set for nano 1.0,
@@ -179,12 +367,12 @@
07/07/2000 - Nano 0.9.12 (The "lucky day" release) is bursting with new
features, bug fixes, and yummy fruit flavor. For
changes, the alternate replace keystroke ^W^T is now
^W^R to be compatible with later version of Pico.
^W^R to be compatible with later versions of Pico.
^W^T is now goto line, again for Pico compatibility.
As for new features, the wonderful/hated magic line
code has returned with a vengeance! Also, regular
expression searches and replaces have been incorporated
via the -R flag. And of course there are the usual
via the -R flag. And, of course, there are the usual
helping of display and other bug fixes to top it all
off.
@@ -198,8 +386,8 @@
this function just changes the way tabs LOOK in the
editor, the tabs you input are still real tabs of normal
width (usually 8 characters); nano just makes them look
smaller or bigger whlie in the editor. New in the
translation department is an indonesian translation (id).
smaller or bigger while in the editor. New in the
translation department is an Indonesian translation (id).
06/06/2000 - Nano 0.9.10 is primarily a bugfix for the loss of SIGINT when
using "run and terminate" flags (for example, --help).
@@ -218,7 +406,7 @@
the resize crash people have been experiencing. It also
offers a new input method that should allow nano to do
things the right way (like ^S, ^Q, custom suspend keys)
and hopefully wont break with non-US keyboards. There
and hopefully won't break with non-US keyboards. There
are also the obligatory display fixes and speedups. Have
fun with it.
@@ -239,7 +427,7 @@
05/01/2000 - Nano 0.9.5 attempts to speed up the display of text
to be at least somewhat reasonable. Much
code profiling has been done to reduce the
rediculous number of redundant display updates. This
ridiculous number of redundant display updates. This
will probably expose a lot of bugs that can then be
fixed, so this release is probably not for the faint
of heart. For anyone curious, I would call nano 0.9.2
@@ -265,7 +453,7 @@
so it is being removed for the time being, and perhaps
indefinitely.
Other new stuff includes a --emable-tiny option to make
Other new stuff includes an --enable-tiny option to make
nano ultra small (disabling i18n, detailed help and the
marker and mouse code), and --with-slang to use the
slang libraries instead of ncurses.
@@ -273,13 +461,13 @@
04/15/2000 - Nano 0.9.2 just fixes the serious segfault problem if
nano is invoked any way other than using the absolute
path. The bug was in the new code for checking whether
nano is invoked as pico.
nano is invoked as 'pico'.
04/14/2000 - 0.9.1 has some more Pico compatibility built-in. The
option to switch to/from Search and Search/Replace
(^T) is now available, and nano now displays the
more Pico-like shortcut list when invoked as 'pico'
(i.e. if pico is a symlink to nano). There is an
(i.e. if 'pico' is a symlink to nano). There is an
important change to the handling of symbolic links
as well. Now, nano does the "correct" thing and
automatically writes to the object of the symlink,
@@ -292,7 +480,7 @@
04/07/2000 - Nano 0.9.0 has some updates, new language support and
a much better refresh setup (It's still not great, but...)
There should also be more stabillity editing long lines,
There should also be more stability editing long lines,
as there was a stupid mistake in the update_line
call. Silly me =)
@@ -301,13 +489,13 @@
Most things work, the rest doesn't doesn't work because
(a) I can't fix it or I would have already done so, and
(b) the amount of patches I'm receiving right now is quite
negligible. Forrunately this release marks the first
negligible. Fortunately, this release marks the first
release since I have acquired ownership of the nano pages
on SourceForge. Here's hoping SF will get us some more
visibilitiy, translators and patches.
visibility, translators and patches.
03/12/2000 - After a hiatus, I have finally moved (not unpacked though)
to my new home into albany. Thus I should now have more
to my new home into Albany. Thus I should now have more
time to work on nano. Nano 0.8.8, the "dear god what
broke this time?" release, incorporates patches for both
i18n and many bugfixes. It is VERY likely something broke
@@ -316,8 +504,8 @@
I would like to announce that I'm going to need
translations soonish, so if you are fluent in other
languages than english (or even better, if your native
language is not english) and you would like to submit a
languages than English (or even better, if your native
language is not English) and you would like to submit a
translation file to me, please feel free to do so. If you
do, I will list your name and email in the AUTHORS file as
the maintainer of the .po file, and from then on it is
@@ -325,9 +513,9 @@
03/01/2000 - Well, to continue my trend of going back on my previous
release's comments, nano 0.8.7 is released. The crashing
behavior was still occuring, and this most recent fix also
behavior was still occurring, and this most recent fix also
fixes some other wrapping problems, so here you go.
There may be another relase soon, there may not be, is
There may be another release soon, there may not be, is
that vague enough? =)
02/25/2000 - More minor bugfixes in 0.8.6, the bizarre behavior at the end
@@ -354,11 +542,11 @@
but I may be changing jobs very soon. I will release
version 0.8.2 as is (no i18n, no help menu (yet). I
expect things to settle down by the end of next week, and
then I can try to start on the i18n support and help menu,
then I can try to start on the i18n support and help menu;
look for these new features in version 0.8.5 to 0.9.0.
01/28/2000 - Nano 0.8.1 marks our first official step toward
internationaliation (i18n) and the help system (^G). I
internationalization (i18n) and the help system (^G). I
will be merging in Jordi's patches for initial i18n in the
next version, and will implement the help system with
i18n built into it shortly after that. Please don't
@@ -367,14 +555,14 @@
01/25/2000 - Nano 0.8.0 is officially the 'let's try and be at least a
little portable, mmmmkay?' release. There are many
portability checks and fixes, many thanks to Andy Kahn for
portability checks and fixes; many thanks to Andy Kahn for
his patches. I removed the broken do_spell behavior with
the 'spell' program, for now we only try to call 'ispell'
the 'spell' program; for now, we only try to call 'ispell'
until I write a better method to handle the output of the
normal 'spell' command.
01/24/2000 - Nano 0.7.9 features many new features. Among them are a
new autoindent feature (-i, --autoondent), tempfile
new autoindent feature (-i, --autoindent), tempfile
flag like Pico's -t flag (-t, --tempfile), and preliminary
spelling program support. The spelling function tries
to run 'spell' and then 'ispell' in that order, but you
@@ -387,7 +575,7 @@
all the changes in this release will cause a few bugs, so
0.7.8 will primarily be about fixing those bugs.
Things added this release include resizeability (kinda),
Things added this release include resizability (kinda),
new -x and -c flags (see nano -h for help), long command
line flag support, and the usual array of bugfixes.

50
README
View File

@@ -1,6 +1,6 @@
GNU nano - an enhanced clone of the Pico text editor.
Overview
The nano project was started because of a few "problems" with the
@@ -11,10 +11,10 @@ Overview
redistribution. Because of this, Pine and Pico are not included with
many GNU/Linux distributions. Also, other features (like goto line
number or search and replace) were unavailable until recently or
require a command-line flag. Yuck.
require a command line flag. Yuck.
nano aims to solve these problems by emulating the functionality of
Pico as closely as possible while adressing the problems above and
Pico as closely as possible while addressing the problems above and
perhaps providing other extra functionality.
The nano editor is now an official GNU package. For more information
@@ -29,7 +29,7 @@ How to compile and install nano
make
make install
It's that simple. Use --prefix with configutr to override the
It's that simple. Use --prefix with configure to override the
default installation directory of /usr/local.
Web Page
@@ -38,14 +38,17 @@ Web Page
Mailing List and Bug Reports
SourceForge hosts all the nano-related mailing-lists.
+ nano-announce@lists.sourceforge.net is a very low traffic list
Savannah hosts all the nano-related mailing-lists.
+ info-nano@gnu.org is a very low traffic list
used to announce new Nano versions or other important information
about the project.
+ nano-devel@lists.sourceforge.net is the list used by the people
+ help-nano@gnu.org is for those seeking to get help without
wanting to hear about the technical details of its
development.
+ nano-devel@gnu.org is the list used by the people
that make Nano and a general development discussion list, with
moderate traffic.
To subscribe, send email to nano-<name>-request@lists.sourceforge.net
To subscribe, send email to nano-<name>-request@gnu.org
with a subject of "subscribe", where <name> is the list you want to
subscribe to.
For general bug reports, send a description of the problem to
@@ -53,11 +56,32 @@ Mailing List and Bug Reports
Current Status
GNU nano has finally reached its first stable release (1.0).
The development tree will fork soon and it will be called 1.1.x,
in the Linux kernel naming style. Many thanks to all of our
bug reporters and contributors of code to get nano where it is
today.
This is the 1.1 or unstable branch of nano. New features
will be added and things will be changed around and basically
stability is not guaranteed. If this is not what you're
interested in, please use the latest 1.0.x release of nano.
New features in this branch include:
+ .nanorc file support (--enable-nanorc configure option,
see sample.nanorc file)
+ Negative -r value for "#cols from right", allows dynamic adjustment
of wrap margin based on window size.
+ Write marked text to separate file (^O after selecting with ^^).
+ Append to file (Meta-A at write file menu).
+ Multiple file buffers! (--enable-multibuffer configure option,
--multibuffer, -F cmdline flag, Meta-F toggle, then ^R to load).
+ Better compatibility with Pico. Mouse mode now supports clicking
shortcuts and files in browser, search toggles that are Pico
extensions moved to Meta keys so as to not interfere with Pico
control sequences.
+ Smooth scrolling through files, instead of the jerky half-page
down, half-page up method. This is available by using the
-S or --smooth switch, or the Meta-S toggle.
+ Better non-*nix file support. GNU nano now automatically
converts files from DOS format or Mac format to standard file
format. It can also write files in either format by using the
appropriate command line (-D, --dos or -M, --mac) or toggle
(Meta-D, Meta-O).
Chris Allegretta (chrisa@asty.org)

38
README.CVS Normal file
View File

@@ -0,0 +1,38 @@
INSTRUCTIONS TO COMPILE AND INSTALL NANO CVS VERSIONS
-----------------------------------------------------
GNU nano is available from CVS, but building this needs a bit
more care than the official stable and unstable tarballs.
To succesfully compile GNU nano from CVS, you'll need the
following packages:
- autoconf (version >= 2.52)
- automake (version >= 1.5-pl5, 1.6.x recommended)
- gettext (version >= 0.11)
- texinfo
- cvs
- glib (if your system doesn't have snprintf() and/or vsnprintf())
- make, gcc and the normal development libraries (ncurses, etc)
These should be available on your GNU mirror.
To download the CVS tree, execute the following command:
$ cvs -z3 -d:pserver:anoncvs@subversions.gnu.org:/cvsroot/nano login
and press enter at the password prompt.
Then, do
$ cvs -z3 -d:pserver:anoncvs@subversions.gnu.org:/cvsroot/nano checkout nano
and the nano tree will download.
If you want to checkout the stable CVS branch, append -r nano_1_0_branch:
$ cvs -z3 -d:pserver:anonymous@subversions.gnu.org:/cvsroot/nano checkout -r nano_1_0_branch nano
Once you have the sources in the "nano" directory, cd into it, and execute
the "autogen.sh" script in the top dir. This will setup a configure script
and Makefile.in, and you will be ready to compile with
$ ./configure [--add-options-here] && make
Once it's done compiling,
$ make install
(as root) should put the required files in their respective directories.
Please submit any bugs in the CVS branch to nano-devel@gnu.org.

49
THANKS Normal file
View File

@@ -0,0 +1,49 @@
The following people have helped GNU nano in some way or another.
If we missed you here, let us know!
Sharuzzaman Ahmat Raslan <sharuzzaman@excite.com>
Bahasa Melayu translator
Ricardo Cárdenes Medina <ricardo@conisys.com> Spanish translator
Marco Colombo <magicdice@inwind.it> Italian translator
Karl Eichwalder <keichwa@gmx.net> German translator
Jean-Philippe Guérard <jean-philippe.guerard@laposte.net>
French translator
Tedi Heriyanto <tedi_h@gmx.net> Indonesian translator
Václav Haisman <V.Haisman@sh.cvut.cz> Czech translator
Szabolcs Horvath <horvaths@janus.gimsz.sulinet.hu>
Hungarian translator
Eivind Kjørstad <ekj@vestdata.no> Norwegian nynorsk translator
Florian König <floki@bigfoot.com> German translator
Wojciech Kotwica <wkotwica@post.pl> Polish translator
Clement Laforet <clem_laf@wanadoo.fr> French translator
Gergely Nagy <algernon@debian.org> Hungarian translator
Claudio Neves <cneves@nextis.com> Brazilian Portuguese translator
Michael Piefel <piefel@informatik.hu-berlin.de> German translator
Sergey A. Ribalchenko <fisher@obu.ck.ua> Russian, Ukrainian translator
Michel Robitaille <robitail@IRO.UMontreal.CA> French translator
Christian Rose <menthos@menthos.com> Swedish translator
Stig E Sandoe <stig@ii.uib.no> Norwegian bokmål translator
Keld Simonsen <keld@dkuug.dk> Danish translator
Guus Sliepen <guus@nl.linux.org> Dutch translator
Cezary Sliwa <sliwa@cft.edu.pl> Polish translator
Pierre Tane <tanep@bigfoot.com> French translator
Jacobo Tarrío <jtarrio@trasno.net> Galician translator
Kjetil Torgrim Homme <kjetilho@linpro.no> Norwegian nynorsk translator
Miquel Vidal <miquel@sindominio.net> Catalan translator
Pauli Virtanen <pauli.virtanen@saunalahti.fi> Finnish translator
Ben Armstrong <synrg@sanctuary.nslug.ns.ca> Negative -r value idea, code
Thomas Dickey <dickey@herndon4.his.com> Curses help and advice
Sven Guckes <guckes@math.fu-berlin.de> Advice and Advocacy
Jim Knoble <jmknoble@pobox.com> Pico compat for browser
Ryan Krebs <fluffy@highwire.stanford.edu> Many bug fixes and testing
Roy Lanek <lanek@ranahminang.net> Advice and advocacy
Chuck Mead <csm@MoonGroup.com> Feedback and RPM stuff
Mike Melanson <melanson@pcisys.net> Bugs
Neil Parks <nparks@acsmail.com> Bug reports and fixes
Jeremy Robichaud <robicj@yahoo.com> Beta tester
Bill Soudan <wes0472@rit.edu> Regex code, etc
Ken Tyler <kent@werple.net.au> Search fixes and more
$Id$

36
TODO
View File

@@ -1,7 +1,28 @@
TODO file (? means the feature may be implemented, but not definitely)
-----------------------------------------------------------------------------
Current Version:
For version 1.2:
- Single line scroll up/down? [DONE]
- Color syntax highlighting? (certainly seems like there's a demand for it.)
- .nanorc [DONE]
- Backup making (filename~)? [DONE]
- Search (etc) string history [1.2]
- Implement Pico's -j and -g flags, as they are pretty easy to do. [DONE]
- Make mouse support work with clicking on the shortcuts (-m). Must
make global variable pointing to current shortcut list to determine what
keystroke to ungetch(). [DONE].
- Implement -o (chroot of sorts) [DONE]
- Allow -r to take a negative argument, meaning right margin instead of
left (allows resizing that way), formerly -W arg. [DONE]
For version 1.4:
- UTF-8 support.
- Support for Pico's paragraph searching ability.
- Undo/Redo key?
Old requests:
For version 1.0:
- Implement Spelling [DONE]
- Implement Help [DONE]
- Internationalization [In progress, translators welcome!]
@@ -18,17 +39,4 @@ Current Version:
- Unjustify command (^U after ^J) [DONE =-].
- Username completion (~user) [DONE =-].
For Next Version:
- Undo/Redo key?
- Single line scroll up/down?
- Color syntax highlighting? (certainly seems like there's a demand for it.)
- .nanorc ?????
- Backup making (filename~)?
- Search (etc) string history [1.1]
- Implent Pico's -j and -g flags, as they are pretty easy to do.
- Make mouse support work with clicking on the shortcuts (-m). Must
make global variable pointing to current shortcut list to determine what
keystroke to ungetch().
- Implement -o (chroot of sorts)
$Id$

View File

@@ -1,53 +0,0 @@
/* $Id$ */
/* Define this if you have the wresize function in your ncurses-type library */
#undef HAVE_WRESIZE
/* Define this if you have the resizeterm function in your ncurses-type library */
#undef HAVE_RESIZETERM
/* Define this if your curses lib has the _use_keypad flag */
#undef HAVE_USEKEYPAD
/* Define this if you have NLS */
#undef ENABLE_NLS
/* Define this is you have the catgets command */
#undef HAVE_CATGETS
/* Define this is you have GNU gettext */
#undef HAVE_GETTEXT
/* Define this for HAVE_LC_MESSAGES */
#undef HAVE_LC_MESSAGES
/* Define this if you have the stpcpy function (cool) */
#undef HAVE_STPCPY
/* Define this to make the nano executable as small as possible */
#undef NANO_SMALL
/* Define to use the slang wrappers for curses instead of native curses */
#undef USE_SLANG
/* Define this to enable the extra stuff */
#undef NANO_EXTRA
/* Define to disable the tab completion code Chris worked so hard on! */
#undef DISABLE_TABCOMP
/* Define this to disable the justify routine */
#undef DISABLE_JUSTIFY
/* Define this to disable the use(full|less) spelling functions */
#undef DISABLE_SPELLER
/* Define this to disable the ^G help menu */
#undef DISABLE_HELP
/* Define this to disable the built-in (crappy) file browser */
#undef DISABLE_BROWSER
/* Define this to disable any and all text wrapping */
#undef DISABLE_WRAPPING

708
aclocal.m4 vendored
View File

@@ -1,708 +0,0 @@
dnl aclocal.m4 generated automatically by aclocal 1.4
dnl Copyright (C) 1994, 1995-8, 1999 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
dnl with or without modifications, as long as this notice is preserved.
dnl This program is distributed in the hope that it will be useful,
dnl but WITHOUT ANY WARRANTY, to the extent permitted by law; without
dnl even the implied warranty of MERCHANTABILITY or FITNESS FOR A
dnl PARTICULAR PURPOSE.
# 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, [no-define])
AC_DEFUN(AM_INIT_AUTOMAKE,
[AC_REQUIRE([AC_PROG_INSTALL])
PACKAGE=[$1]
AC_SUBST(PACKAGE)
VERSION=[$2]
AC_SUBST(VERSION)
dnl test to see if srcdir already configured
if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
fi
ifelse([$3],,
AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package]))
AC_REQUIRE([AM_SANITY_CHECK])
AC_REQUIRE([AC_ARG_PROGRAM])
dnl FIXME This is truly gross.
missing_dir=`cd $ac_aux_dir && pwd`
AM_MISSING_PROG(ACLOCAL, aclocal, $missing_dir)
AM_MISSING_PROG(AUTOCONF, autoconf, $missing_dir)
AM_MISSING_PROG(AUTOMAKE, automake, $missing_dir)
AM_MISSING_PROG(AUTOHEADER, autoheader, $missing_dir)
AM_MISSING_PROG(MAKEINFO, makeinfo, $missing_dir)
AC_REQUIRE([AC_PROG_MAKE_SET])])
#
# Check to make sure that the build environment is sane.
#
AC_DEFUN(AM_SANITY_CHECK,
[AC_MSG_CHECKING([whether build environment is sane])
# Just in case
sleep 1
echo timestamp > conftestfile
# Do `set' in a subshell so we don't clobber the current shell's
# arguments. Must try -L first in case configure is actually a
# symlink; some systems play weird games with the mod time of symlinks
# (eg FreeBSD returns the mod time of the symlink's containing
# directory).
if (
set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
if test "[$]*" = "X"; then
# -L didn't work.
set X `ls -t $srcdir/configure conftestfile`
fi
if test "[$]*" != "X $srcdir/configure conftestfile" \
&& test "[$]*" != "X conftestfile $srcdir/configure"; then
# If neither matched, then we have a broken ls. This can happen
# if, for instance, CONFIG_SHELL is bash and it inherits a
# broken ls alias from the environment. This has actually
# happened. Such a system could not be considered "sane".
AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
alias in your environment])
fi
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)])
dnl AM_MISSING_PROG(NAME, PROGRAM, DIRECTORY)
dnl The program must properly implement --version.
AC_DEFUN(AM_MISSING_PROG,
[AC_MSG_CHECKING(for working $2)
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
if ($2 --version) < /dev/null > /dev/null 2>&1; then
$1=$2
AC_MSG_RESULT(found)
else
$1="$3/missing $2"
AC_MSG_RESULT(missing)
fi
AC_SUBST($1)])
# 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
ifelse(patsubst(<<$1>>, <<[^ ]>>, <<>>), <<>>,
<<test -z "<<$>>CONFIG_HEADERS" || echo timestamp > patsubst(<<$1>>, <<^\([^:]*/\)?.*>>, <<\1>>)stamp-h<<>>dnl>>,
<<am_indx=1
for am_file in <<$1>>; do
case " <<$>>CONFIG_HEADERS " in
*" <<$>>am_file "*<<)>>
echo timestamp > `echo <<$>>am_file | sed -e 's%:.*%%' -e 's%[^/]*$%%'`stamp-h$am_indx
;;
esac
am_indx=`expr "<<$>>am_indx" + 1`
done<<>>dnl>>)
changequote([,]))])
# Configure paths for GLIB
# Owen Taylor 97-11-3
dnl AM_PATH_GLIB([MINIMUM-VERSION, [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND [, MODULES]]]])
dnl Test for GLIB, and define GLIB_CFLAGS and GLIB_LIBS, if "gmodule" or
dnl gthread is specified in MODULES, pass to glib-config
dnl
AC_DEFUN(AM_PATH_GLIB,
[dnl
dnl Get the cflags and libraries from the glib-config script
dnl
AC_ARG_WITH(glib-prefix,[ --with-glib-prefix=PFX Prefix where GLIB is installed (optional)],
glib_config_prefix="$withval", glib_config_prefix="")
AC_ARG_WITH(glib-exec-prefix,[ --with-glib-exec-prefix=PFX Exec prefix where GLIB is installed (optional)],
glib_config_exec_prefix="$withval", glib_config_exec_prefix="")
AC_ARG_ENABLE(glibtest, [ --disable-glibtest Do not try to compile and run a test GLIB program],
, enable_glibtest=yes)
if test x$glib_config_exec_prefix != x ; then
glib_config_args="$glib_config_args --exec-prefix=$glib_config_exec_prefix"
if test x${GLIB_CONFIG+set} != xset ; then
GLIB_CONFIG=$glib_config_exec_prefix/bin/glib-config
fi
fi
if test x$glib_config_prefix != x ; then
glib_config_args="$glib_config_args --prefix=$glib_config_prefix"
if test x${GLIB_CONFIG+set} != xset ; then
GLIB_CONFIG=$glib_config_prefix/bin/glib-config
fi
fi
for module in . $4
do
case "$module" in
gmodule)
glib_config_args="$glib_config_args gmodule"
;;
gthread)
glib_config_args="$glib_config_args gthread"
;;
esac
done
AC_PATH_PROG(GLIB_CONFIG, glib-config, no)
min_glib_version=ifelse([$1], ,0.99.7,$1)
AC_MSG_CHECKING(for GLIB - version >= $min_glib_version)
no_glib=""
if test "$GLIB_CONFIG" = "no" ; then
no_glib=yes
else
GLIB_CFLAGS=`$GLIB_CONFIG $glib_config_args --cflags`
GLIB_LIBS=`$GLIB_CONFIG $glib_config_args --libs`
glib_config_major_version=`$GLIB_CONFIG $glib_config_args --version | \
sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\1/'`
glib_config_minor_version=`$GLIB_CONFIG $glib_config_args --version | \
sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\2/'`
glib_config_micro_version=`$GLIB_CONFIG $glib_config_args --version | \
sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\3/'`
if test "x$enable_glibtest" = "xyes" ; then
ac_save_CFLAGS="$CFLAGS"
ac_save_LIBS="$LIBS"
CFLAGS="$CFLAGS $GLIB_CFLAGS"
LIBS="$GLIB_LIBS $LIBS"
dnl
dnl Now check if the installed GLIB is sufficiently new. (Also sanity
dnl checks the results of glib-config to some extent
dnl
rm -f conf.glibtest
AC_TRY_RUN([
#include <glib.h>
#include <stdio.h>
#include <stdlib.h>
int
main ()
{
int major, minor, micro;
char *tmp_version;
system ("touch conf.glibtest");
/* HP/UX 9 (%@#!) writes to sscanf strings */
tmp_version = g_strdup("$min_glib_version");
if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, &micro) != 3) {
printf("%s, bad version string\n", "$min_glib_version");
exit(1);
}
if ((glib_major_version != $glib_config_major_version) ||
(glib_minor_version != $glib_config_minor_version) ||
(glib_micro_version != $glib_config_micro_version))
{
printf("\n*** 'glib-config --version' returned %d.%d.%d, but GLIB (%d.%d.%d)\n",
$glib_config_major_version, $glib_config_minor_version, $glib_config_micro_version,
glib_major_version, glib_minor_version, glib_micro_version);
printf ("*** was found! If glib-config was correct, then it is best\n");
printf ("*** to remove the old version of GLIB. You may also be able to fix the error\n");
printf("*** by modifying your LD_LIBRARY_PATH enviroment variable, or by editing\n");
printf("*** /etc/ld.so.conf. Make sure you have run ldconfig if that is\n");
printf("*** required on your system.\n");
printf("*** If glib-config was wrong, set the environment variable GLIB_CONFIG\n");
printf("*** to point to the correct copy of glib-config, and remove the file config.cache\n");
printf("*** before re-running configure\n");
}
else if ((glib_major_version != GLIB_MAJOR_VERSION) ||
(glib_minor_version != GLIB_MINOR_VERSION) ||
(glib_micro_version != GLIB_MICRO_VERSION))
{
printf("*** GLIB header files (version %d.%d.%d) do not match\n",
GLIB_MAJOR_VERSION, GLIB_MINOR_VERSION, GLIB_MICRO_VERSION);
printf("*** library (version %d.%d.%d)\n",
glib_major_version, glib_minor_version, glib_micro_version);
}
else
{
if ((glib_major_version > major) ||
((glib_major_version == major) && (glib_minor_version > minor)) ||
((glib_major_version == major) && (glib_minor_version == minor) && (glib_micro_version >= micro)))
{
return 0;
}
else
{
printf("\n*** An old version of GLIB (%d.%d.%d) was found.\n",
glib_major_version, glib_minor_version, glib_micro_version);
printf("*** You need a version of GLIB newer than %d.%d.%d. The latest version of\n",
major, minor, micro);
printf("*** GLIB is always available from ftp://ftp.gtk.org.\n");
printf("***\n");
printf("*** If you have already installed a sufficiently new version, this error\n");
printf("*** probably means that the wrong copy of the glib-config shell script is\n");
printf("*** being found. The easiest way to fix this is to remove the old version\n");
printf("*** of GLIB, but you can also set the GLIB_CONFIG environment to point to the\n");
printf("*** correct copy of glib-config. (In this case, you will have to\n");
printf("*** modify your LD_LIBRARY_PATH enviroment variable, or edit /etc/ld.so.conf\n");
printf("*** so that the correct libraries are found at run-time))\n");
}
}
return 1;
}
],, no_glib=yes,[echo $ac_n "cross compiling; assumed OK... $ac_c"])
CFLAGS="$ac_save_CFLAGS"
LIBS="$ac_save_LIBS"
fi
fi
if test "x$no_glib" = x ; then
AC_MSG_RESULT(yes)
ifelse([$2], , :, [$2])
else
AC_MSG_RESULT(no)
if test "$GLIB_CONFIG" = "no" ; then
echo "*** The glib-config script installed by GLIB could not be found"
echo "*** If GLIB was installed in PREFIX, make sure PREFIX/bin is in"
echo "*** your path, or set the GLIB_CONFIG environment variable to the"
echo "*** full path to glib-config."
else
if test -f conf.glibtest ; then
:
else
echo "*** Could not run GLIB test program, checking why..."
CFLAGS="$CFLAGS $GLIB_CFLAGS"
LIBS="$LIBS $GLIB_LIBS"
AC_TRY_LINK([
#include <glib.h>
#include <stdio.h>
], [ return ((glib_major_version) || (glib_minor_version) || (glib_micro_version)); ],
[ echo "*** The test program compiled, but did not run. This usually means"
echo "*** that the run-time linker is not finding GLIB or finding the wrong"
echo "*** version of GLIB. If it is not finding GLIB, you'll need to set your"
echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point"
echo "*** to the installed location Also, make sure you have run ldconfig if that"
echo "*** is required on your system"
echo "***"
echo "*** If you have an old version installed, it is best to remove it, although"
echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH"
echo "***"
echo "*** If you have a RedHat 5.0 system, you should remove the GTK package that"
echo "*** came with the system with the command"
echo "***"
echo "*** rpm --erase --nodeps gtk gtk-devel" ],
[ echo "*** The test program failed to compile or link. See the file config.log for the"
echo "*** exact error that occured. This usually means GLIB was incorrectly installed"
echo "*** or that you have moved GLIB since it was installed. In the latter case, you"
echo "*** may want to edit the glib-config script: $GLIB_CONFIG" ])
CFLAGS="$ac_save_CFLAGS"
LIBS="$ac_save_LIBS"
fi
fi
GLIB_CFLAGS=""
GLIB_LIBS=""
ifelse([$3], , :, [$3])
fi
AC_SUBST(GLIB_CFLAGS)
AC_SUBST(GLIB_LIBS)
rm -f conf.glibtest
])
# Macro to add for using GNU gettext.
# Ulrich Drepper <drepper@cygnus.com>, 1995.
#
# This file can be copied and used freely without restrictions. It can
# be used in projects which are not available under the GNU Public License
# but which still want to provide support for the GNU gettext functionality.
# Please note that the actual code is *not* freely available.
# serial 5
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_CHECK_LIB(intl, gettext,
gt_cv_func_gettext_libintl=yes,
gt_cv_func_gettext_libintl=no)],
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='$(top_builddir)/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='$(top_builddir)/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 program 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
AC_LINK_FILES($nls_cv_header_libgt, $nls_cv_header_intl)
AC_OUTPUT_COMMANDS(
[case "$CONFIG_FILES" in *po/Makefile.in*)
sed -e "/POTFILES =/r po/POTFILES" po/Makefile.in > po/Makefile
esac])
# 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_ISC_POSIX])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 sys/param.h])
AC_CHECK_FUNCS([getcwd munmap putenv setenv setlocale strchr strcasecmp \
strdup __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 The reference to <locale.h> in the installed <libintl.h> file
dnl must be resolved because we cannot expect the users of this
dnl to define HAVE_LOCALE_H.
if test $ac_cv_header_locale_h = yes; then
INCLUDE_LOCALE_H="#include <locale.h>"
else
INCLUDE_LOCALE_H="\
/* The system does not provide the header <locale.h>. Take care yourself. */"
fi
AC_SUBST(INCLUDE_LOCALE_H)
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 -n "$ac_aux_dir"; then
MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs"
fi
if test -z "$MKINSTALLDIRS"; then
MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs"
fi
AC_SUBST(MKINSTALLDIRS)
dnl *** For now the libtool support in intl/Makefile is not for real.
l=
AC_SUBST(l)
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
rm -f po/POTFILES
sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \
< $srcdir/po/POTFILES.in > po/POTFILES
])
# Search path for a program which passes the given test.
# Ulrich Drepper <drepper@cygnus.com>, 1996.
#
# This file can be copied and used freely without restrictions. It can
# be used in projects which are not available under the GNU Public License
# but which still want to provide support for the GNU gettext functionality.
# Please note that the actual code is *not* freely available.
# 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
])
# Check whether LC_MESSAGES is available in <locale.h>.
# Ulrich Drepper <drepper@cygnus.com>, 1995.
#
# This file can be copied and used freely without restrictions. It can
# be used in projects which are not available under the GNU Public License
# but which still want to provide support for the GNU gettext functionality.
# Please note that the actual code is *not* freely available.
# 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])

7
autogen.sh Executable file
View File

@@ -0,0 +1,7 @@
#!/bin/sh
# Generate configure & friends for CVS users.
aclocal -I ./m4
autoheader
automake --add-missing
autoconf

136
color.c Normal file
View File

@@ -0,0 +1,136 @@
/* $Id$ */
/**************************************************************************
* color.c *
* *
* Copyright (C) 1999-2002 Chris Allegretta *
* 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., 675 Mass Ave, Cambridge, MA 02139, USA. *
* *
**************************************************************************/
#include "config.h"
#include <stdlib.h>
#include <string.h>
#include <stdio.h>
#include <errno.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
#include "proto.h"
#include "nano.h"
#ifdef ENABLE_COLOR
/* For each syntax list entry, we go through the list of colors and
* assign color pairs. */
void set_colorpairs(void)
{
const syntaxtype *this_syntax = syntaxes;
for(; this_syntax != NULL; this_syntax = this_syntax->next) {
colortype *this_color = this_syntax->color;
int color_pair = 1;
for(; this_color != NULL; this_color = this_color->next) {
const colortype *beforenow = this_syntax->color;
for(; beforenow != NULL && beforenow != this_color &&
(beforenow->fg != this_color->fg ||
beforenow->bg != this_color->bg ||
beforenow->bright != this_color->bright);
beforenow = beforenow->next)
;
if (beforenow != NULL && beforenow != this_color)
this_color->pairnum = beforenow->pairnum;
else {
this_color->pairnum = color_pair;
color_pair++;
}
}
}
}
void do_colorinit(void)
{
if (has_colors()) {
const colortype *tmpcolor = NULL;
#ifdef HAVE_USE_DEFAULT_COLORS
int defok;
#endif
start_color();
/* Add in colors, if available */
#ifdef HAVE_USE_DEFAULT_COLORS
defok = use_default_colors() != ERR;
#endif
for (tmpcolor = colorstrings; tmpcolor != NULL;
tmpcolor = tmpcolor->next) {
short background = tmpcolor->bg;
if (background == -1)
#ifdef HAVE_USE_DEFAULT_COLORS
if (!defok)
#endif
background = COLOR_BLACK;
init_pair(tmpcolor->pairnum, tmpcolor->fg, background);
#ifdef DEBUG
fprintf(stderr, _("Running init_pair with fg = %d and bg = %d\n"), tmpcolor->fg, tmpcolor->bg);
#endif
}
}
}
/* Update the color information based on the current filename */
void update_color(void)
{
const syntaxtype *tmpsyntax;
colorstrings = NULL;
for (tmpsyntax = syntaxes; tmpsyntax != NULL; tmpsyntax = tmpsyntax->next) {
const exttype *e;
for (e = tmpsyntax->extensions; e != NULL; e = e->next) {
regex_t syntaxfile_regexp;
regcomp(&syntaxfile_regexp, e->val, REG_EXTENDED | REG_NOSUB);
/* Set colorstrings if we matched the extension regex */
if (!regexec(&syntaxfile_regexp, filename, 0, NULL, 0))
colorstrings = tmpsyntax->color;
regfree(&syntaxfile_regexp);
if (colorstrings != NULL)
break;
}
}
/* if we haven't found a match, use the override string */
if (colorstrings == NULL && syntaxstr != NULL) {
for (tmpsyntax = syntaxes; tmpsyntax != NULL;
tmpsyntax = tmpsyntax->next) {
if (!strcasecmp(tmpsyntax->desc, syntaxstr))
colorstrings = tmpsyntax->color;
}
}
do_colorinit();
edit_refresh();
}
#endif /* ENABLE_COLOR */

View File

@@ -1,210 +0,0 @@
/* config.h.in. Generated automatically from configure.in by autoheader. */
/* Define if using alloca.c. */
#undef C_ALLOCA
/* Define to empty if the keyword does not work. */
#undef const
/* Define to one of _getb67, GETB67, getb67 for Cray-2 and Cray-YMP systems.
This function is required for alloca.c support on those systems. */
#undef CRAY_STACKSEG_END
/* Define if you have alloca, as a function or macro. */
#undef HAVE_ALLOCA
/* Define if you have <alloca.h> and it should be used (not on Ultrix). */
#undef HAVE_ALLOCA_H
/* Define if you don't have vprintf but do have _doprnt. */
#undef HAVE_DOPRNT
/* Define if you have a working `mmap' system call. */
#undef HAVE_MMAP
/* Define if you have the vprintf function. */
#undef HAVE_VPRINTF
/* Define as __inline if that's what the C compiler calls it. */
#undef inline
/* Define to `long' if <sys/types.h> doesn't define. */
#undef off_t
/* Define if you need to in order for stat and other things to work. */
#undef _POSIX_SOURCE
/* Define as the return type of signal handlers (int or void). */
#undef RETSIGTYPE
/* Define to `unsigned' if <sys/types.h> doesn't define. */
#undef size_t
/* If using the C implementation of alloca, define if you know the
direction of stack growth for your system; otherwise it will be
automatically deduced at run-time.
STACK_DIRECTION > 0 => grows toward higher addresses
STACK_DIRECTION < 0 => grows toward lower addresses
STACK_DIRECTION = 0 => direction of growth unknown
*/
#undef STACK_DIRECTION
/* Define if you have the ANSI C header files. */
#undef STDC_HEADERS
/* Define this if you have the wresize function in your ncurses-type library */
#undef HAVE_WRESIZE
/* Define this if you have the resizeterm function in your ncurses-type library */
#undef HAVE_RESIZETERM
/* Define this if your curses lib has the _use_keypad flag */
#undef HAVE_USEKEYPAD
/* Define this if you have NLS */
#undef ENABLE_NLS
/* Define this is you have the catgets command */
#undef HAVE_CATGETS
/* Define this is you have GNU gettext */
#undef HAVE_GETTEXT
/* Define this for HAVE_LC_MESSAGES */
#undef HAVE_LC_MESSAGES
/* Define this if you have the stpcpy function (cool) */
#undef HAVE_STPCPY
/* Define this to make the nano executable as small as possible */
#undef NANO_SMALL
/* Define to use the slang wrappers for curses instead of native curses */
#undef USE_SLANG
/* Define this to enable the extra stuff */
#undef NANO_EXTRA
/* Define to disable the tab completion code Chris worked so hard on! */
#undef DISABLE_TABCOMP
/* Define this to disable the justify routine */
#undef DISABLE_JUSTIFY
/* Define this to disable the use(full|less) spelling functions */
#undef DISABLE_SPELLER
/* Define this to disable the ^G help menu */
#undef DISABLE_HELP
/* Define this to disable the built-in (crappy) file browser */
#undef DISABLE_BROWSER
/* Define this to disable any and all text wrapping */
#undef DISABLE_WRAPPING
/* Define if you have the __argz_count function. */
#undef HAVE___ARGZ_COUNT
/* Define if you have the __argz_next function. */
#undef HAVE___ARGZ_NEXT
/* Define if you have the __argz_stringify function. */
#undef HAVE___ARGZ_STRINGIFY
/* Define if you have the dcgettext function. */
#undef HAVE_DCGETTEXT
/* Define if you have the getcwd function. */
#undef HAVE_GETCWD
/* Define if you have the getopt_long function. */
#undef HAVE_GETOPT_LONG
/* Define if you have the getpagesize function. */
#undef HAVE_GETPAGESIZE
/* Define if you have the munmap function. */
#undef HAVE_MUNMAP
/* Define if you have the putenv function. */
#undef HAVE_PUTENV
/* Define if you have the setenv function. */
#undef HAVE_SETENV
/* Define if you have the setlocale function. */
#undef HAVE_SETLOCALE
/* Define if you have the snprintf function. */
#undef HAVE_SNPRINTF
/* Define if you have the stpcpy function. */
#undef HAVE_STPCPY
/* Define if you have the strcasecmp function. */
#undef HAVE_STRCASECMP
/* Define if you have the strchr function. */
#undef HAVE_STRCHR
/* Define if you have the strdup function. */
#undef HAVE_STRDUP
/* Define if you have the vsnprintf function. */
#undef HAVE_VSNPRINTF
/* Define if you have the <argz.h> header file. */
#undef HAVE_ARGZ_H
/* Define if you have the <curses.h> header file. */
#undef HAVE_CURSES_H
/* Define if you have the <fcntl.h> header file. */
#undef HAVE_FCNTL_H
/* Define if you have the <getopt.h> header file. */
#undef HAVE_GETOPT_H
/* Define if you have the <limits.h> header file. */
#undef HAVE_LIMITS_H
/* Define if you have the <locale.h> header file. */
#undef HAVE_LOCALE_H
/* Define if you have the <malloc.h> header file. */
#undef HAVE_MALLOC_H
/* Define if you have the <ncurses.h> header file. */
#undef HAVE_NCURSES_H
/* Define if you have the <nl_types.h> header file. */
#undef HAVE_NL_TYPES_H
/* Define if you have the <regex.h> header file. */
#undef HAVE_REGEX_H
/* Define if you have the <string.h> header file. */
#undef HAVE_STRING_H
/* Define if you have the <sys/param.h> header file. */
#undef HAVE_SYS_PARAM_H
/* Define if you have the <termio.h> header file. */
#undef HAVE_TERMIO_H
/* Define if you have the <termios.h> header file. */
#undef HAVE_TERMIOS_H
/* Define if you have the <unistd.h> header file. */
#undef HAVE_UNISTD_H
/* Define if you have the i library (-li). */
#undef HAVE_LIBI
/* Name of package */
#undef PACKAGE
/* Version number of package */
#undef VERSION

513
config.rpath Executable file
View File

@@ -0,0 +1,513 @@
#! /bin/sh
# Output a system dependent set of variables, describing how to set the
# run time search path of shared libraries in an executable.
#
# Copyright 1996-2002 Free Software Foundation, Inc.
# Taken from GNU libtool, 2001
# Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
#
# 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 of the License, 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.
#
# As a special exception to the GNU General Public License, if you
# distribute this file as part of a program that contains a
# configuration script generated by Autoconf, you may include it under
# the same distribution terms that you use for the rest of that program.
#
# The first argument passed to this file is the canonical host specification,
# CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM
# or
# CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM
# The environment variables CC, GCC, LDFLAGS, LD, with_gnu_ld
# should be set by the caller.
#
# The set of defined variables is at the end of this script.
# All known linkers require a `.a' archive for static linking (except M$VC,
# which needs '.lib').
libext=a
shlibext=
host="$1"
host_cpu=`echo "$host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
host_vendor=`echo "$host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
host_os=`echo "$host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
wl=
if test "$GCC" = yes; then
wl='-Wl,'
else
case "$host_os" in
aix3* | aix4* | aix5*)
wl='-Wl,'
;;
hpux9* | hpux10* | hpux11*)
wl='-Wl,'
;;
irix5* | irix6*)
wl='-Wl,'
;;
linux*)
echo '__INTEL_COMPILER' > conftest.$ac_ext
if $CC -E conftest.$ac_ext >/dev/null | grep __INTEL_COMPILER >/dev/null
then
:
else
# Intel icc
wl='-Qoption,ld,'
fi
;;
osf3* | osf4* | osf5*)
wl='-Wl,'
;;
solaris*)
wl='-Wl,'
;;
sunos4*)
wl='-Qoption ld '
;;
sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
if test "x$host_vendor" = xsni; then
wl='-LD'
else
wl='-Wl,'
fi
;;
esac
fi
hardcode_libdir_flag_spec=
hardcode_libdir_separator=
hardcode_direct=no
hardcode_minus_L=no
case "$host_os" in
cygwin* | mingw* | pw32*)
# FIXME: the MSVC++ port hasn't been tested in a loooong time
# When not using gcc, we currently assume that we are using
# Microsoft Visual C++.
if test "$GCC" != yes; then
with_gnu_ld=no
fi
;;
openbsd*)
with_gnu_ld=no
;;
esac
ld_shlibs=yes
if test "$with_gnu_ld" = yes; then
case "$host_os" in
aix3* | aix4* | aix5*)
# On AIX, the GNU linker is very broken
ld_shlibs=no
;;
amigaos*)
hardcode_libdir_flag_spec='-L$libdir'
hardcode_minus_L=yes
# Samuel A. Falvo II <kc5tja@dolphin.openprojects.net> reports
# that the semantics of dynamic libraries on AmigaOS, at least up
# to version 4, is to share data among multiple programs linked
# with the same dynamic library. Since this doesn't match the
# behavior of shared libraries on other platforms, we can use
# them.
ld_shlibs=no
;;
beos*)
if $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then
:
else
ld_shlibs=no
fi
;;
cygwin* | mingw* | pw32*)
# hardcode_libdir_flag_spec is actually meaningless, as there is
# no search path for DLLs.
hardcode_libdir_flag_spec='-L$libdir'
;;
solaris* | sysv5*)
if $LD -v 2>&1 | egrep 'BFD 2\.8' > /dev/null; then
ld_shlibs=no
elif $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then
:
else
ld_shlibs=no
fi
;;
sunos4*)
hardcode_direct=yes
;;
*)
if $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then
:
else
ld_shlibs=no
fi
;;
esac
if test "$ld_shlibs" = yes; then
hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
fi
else
case "$host_os" in
aix3*)
# Note: this linker hardcodes the directories in LIBPATH if there
# are no directories specified by -L.
hardcode_minus_L=yes
if test "$GCC" = yes; then
# Neither direct hardcoding nor static linking is supported with a
# broken collect2.
hardcode_direct=unsupported
fi
;;
aix4* | aix5*)
if test "$host_cpu" = ia64; then
# On IA64, the linker does run time linking by default, so we don't
# have to do anything special.
aix_use_runtimelinking=no
else
aix_use_runtimelinking=no
# Test if we are trying to use run time linking or normal
# AIX style linking. If -brtl is somewhere in LDFLAGS, we
# need to do runtime linking.
case $host_os in aix4.[23]|aix4.[23].*|aix5*)
for ld_flag in $LDFLAGS; do
if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
aix_use_runtimelinking=yes
break
fi
done
esac
fi
hardcode_direct=yes
hardcode_libdir_separator=':'
if test "$GCC" = yes; then
case $host_os in aix4.[012]|aix4.[012].*)
collect2name=`${CC} -print-prog-name=collect2`
if test -f "$collect2name" && \
strings "$collect2name" | grep resolve_lib_name >/dev/null
then
# We have reworked collect2
hardcode_direct=yes
else
# We have old collect2
hardcode_direct=unsupported
hardcode_minus_L=yes
hardcode_libdir_flag_spec='-L$libdir'
hardcode_libdir_separator=
fi
esac
fi
if test "$aix_use_runtimelinking" = yes; then
hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:/usr/lib:/lib'
else
if test "$host_cpu" = ia64; then
hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib'
else
hardcode_libdir_flag_spec='${wl}-bnolibpath ${wl}-blibpath:$libdir:/usr/lib:/lib'
fi
fi
;;
amigaos*)
hardcode_libdir_flag_spec='-L$libdir'
hardcode_minus_L=yes
# see comment about different semantics on the GNU ld section
ld_shlibs=no
;;
cygwin* | mingw* | pw32*)
# When not using gcc, we currently assume that we are using
# Microsoft Visual C++.
# hardcode_libdir_flag_spec is actually meaningless, as there is
# no search path for DLLs.
hardcode_libdir_flag_spec=' '
libext=lib
;;
darwin* | rhapsody*)
hardcode_direct=yes
;;
freebsd1*)
ld_shlibs=no
;;
freebsd2.2*)
hardcode_libdir_flag_spec='-R$libdir'
hardcode_direct=yes
;;
freebsd2*)
hardcode_direct=yes
hardcode_minus_L=yes
;;
freebsd*)
hardcode_libdir_flag_spec='-R$libdir'
hardcode_direct=yes
;;
hpux9* | hpux10* | hpux11*)
hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
hardcode_libdir_separator=:
hardcode_direct=yes
hardcode_minus_L=yes # Not in the search PATH, but as the default
# location of the library.
;;
irix5* | irix6*)
hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
hardcode_libdir_separator=:
;;
netbsd*)
hardcode_libdir_flag_spec='-R$libdir'
hardcode_direct=yes
;;
newsos6)
hardcode_direct=yes
hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
hardcode_libdir_separator=:
;;
openbsd*)
hardcode_direct=yes
if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
else
case "$host_os" in
openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
hardcode_libdir_flag_spec='-R$libdir'
;;
*)
hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
;;
esac
fi
;;
os2*)
hardcode_libdir_flag_spec='-L$libdir'
hardcode_minus_L=yes
;;
osf3*)
hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
hardcode_libdir_separator=:
;;
osf4* | osf5*)
if test "$GCC" = yes; then
hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
else
# Both cc and cxx compiler support -rpath directly
hardcode_libdir_flag_spec='-rpath $libdir'
fi
hardcode_libdir_separator=:
;;
sco3.2v5*)
;;
solaris*)
hardcode_libdir_flag_spec='-R$libdir'
;;
sunos4*)
hardcode_libdir_flag_spec='-L$libdir'
hardcode_direct=yes
hardcode_minus_L=yes
;;
sysv4)
if test "x$host_vendor" = xsno; then
hardcode_direct=yes # is this really true???
else
hardcode_direct=no # Motorola manual says yes, but my tests say they lie
fi
;;
sysv4.3*)
;;
sysv5*)
hardcode_libdir_flag_spec=
;;
uts4*)
hardcode_libdir_flag_spec='-L$libdir'
;;
dgux*)
hardcode_libdir_flag_spec='-L$libdir'
;;
sysv4*MP*)
if test -d /usr/nec; then
ld_shlibs=yes
fi
;;
sysv4.2uw2*)
hardcode_direct=yes
hardcode_minus_L=no
;;
sysv5uw7* | unixware7*)
;;
*)
ld_shlibs=no
;;
esac
fi
# Check dynamic linker characteristics
libname_spec='lib$name'
sys_lib_dlsearch_path_spec="/lib /usr/lib"
sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
case "$host_os" in
aix3*)
shlibext=so
;;
aix4* | aix5*)
shlibext=so
;;
amigaos*)
shlibext=ixlibrary
;;
beos*)
shlibext=so
;;
bsdi4*)
shlibext=so
sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
;;
cygwin* | mingw* | pw32*)
case $GCC,$host_os in
yes,cygwin*)
shlibext=dll.a
;;
yes,mingw*)
shlibext=dll
sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | sed -e "s/^libraries://" -e "s/;/ /g"`
;;
yes,pw32*)
shlibext=dll
;;
*)
shlibext=dll
;;
esac
;;
darwin* | rhapsody*)
shlibext=dylib
;;
freebsd1*)
;;
freebsd*)
shlibext=so
;;
gnu*)
shlibext=so
;;
hpux9* | hpux10* | hpux11*)
shlibext=sl
;;
irix5* | irix6*)
shlibext=so
case "$host_os" in
irix5*)
libsuff= shlibsuff=
;;
*)
case $LD in
*-32|*"-32 ") libsuff= shlibsuff= ;;
*-n32|*"-n32 ") libsuff=32 shlibsuff=N32 ;;
*-64|*"-64 ") libsuff=64 shlibsuff=64 ;;
*) libsuff= shlibsuff= ;;
esac
;;
esac
sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
;;
linux-gnuoldld* | linux-gnuaout* | linux-gnucoff*)
;;
linux-gnu*)
shlibext=so
;;
netbsd*)
shlibext=so
;;
newsos6)
shlibext=so
;;
openbsd*)
shlibext=so
;;
os2*)
libname_spec='$name'
shlibext=dll
;;
osf3* | osf4* | osf5*)
shlibext=so
sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
;;
sco3.2v5*)
shlibext=so
;;
solaris*)
shlibext=so
;;
sunos4*)
shlibext=so
;;
sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
shlibext=so
case "$host_vendor" in
motorola)
sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
;;
esac
;;
uts4*)
shlibext=so
;;
dgux*)
shlibext=so
;;
sysv4*MP*)
if test -d /usr/nec; then
shlibext=so
fi
;;
esac
sed_quote_subst='s/\(["`$\\]\)/\\\1/g'
escaped_wl=`echo "X$wl" | sed -e 's/^X//' -e "$sed_quote_subst"`
escaped_hardcode_libdir_flag_spec=`echo "X$hardcode_libdir_flag_spec" | sed -e 's/^X//' -e "$sed_quote_subst"`
escaped_sys_lib_search_path_spec=`echo "X$sys_lib_search_path_spec" | sed -e 's/^X//' -e "$sed_quote_subst"`
escaped_sys_lib_dlsearch_path_spec=`echo "X$sys_lib_dlsearch_path_spec" | sed -e 's/^X//' -e "$sed_quote_subst"`
sed -e 's/^\([a-zA-Z0-9_]*\)=/acl_cv_\1=/' <<EOF
# How to pass a linker flag through the compiler.
wl="$escaped_wl"
# Static library suffix (normally "a").
libext="$libext"
# Shared library suffix (normally "so").
shlibext="$shlibext"
# Flag to hardcode \$libdir into a binary during linking.
# This must work even if \$libdir does not exist.
hardcode_libdir_flag_spec="$escaped_hardcode_libdir_flag_spec"
# Whether we need a single -rpath flag with a separated argument.
hardcode_libdir_separator="$hardcode_libdir_separator"
# Set to yes if using DIR/libNAME.so during linking hardcodes DIR into the
# resulting binary.
hardcode_direct="$hardcode_direct"
# Set to yes if using the -LDIR flag during linking hardcodes DIR into the
# resulting binary.
hardcode_minus_L="$hardcode_minus_L"
# Compile-time system search path for libraries
sys_lib_search_path_spec="$escaped_sys_lib_search_path_spec"
# Run-time system search path for libraries
sys_lib_dlsearch_path_spec="$escaped_sys_lib_dlsearch_path_spec"
EOF

4813
configure vendored

File diff suppressed because it is too large Load Diff

View File

@@ -1,71 +1,127 @@
# $Id$
dnl Process this file with autoconf to produce a configure script.
AC_INIT(nano.c)
AM_INIT_AUTOMAKE(nano, 1.0.1)
AC_INIT
AC_CONFIG_SRCDIR([nano.c])
AC_PREREQ(2.52)
AM_INIT_AUTOMAKE(nano, 1.1.12)
AM_CONFIG_HEADER(config.h:config.h.in)
ALL_LINGUAS="es de fr it id fi hu ca cs"
dnl AM_ACLOCAL_INCLUDE(m4)
ALL_LINGUAS="es de fr it id fi hu ca cs gl uk ru sv nn nl da pl nb ms pt_BR"
dnl Checks for programs.
AC_PROG_CC
AC_ISC_POSIX
AC_SYS_LARGEFILE
dnl Checks for header files.
AC_HEADER_STDC
AC_CHECK_HEADERS(fcntl.h unistd.h malloc.h termios.h termio.h limits.h getopt.h regex.h)
AC_CHECK_HEADERS(fcntl.h getopt.h libintl.h limits.h regex.h termio.h termios.h unistd.h)
dnl options
AC_ARG_ENABLE(tiny,
[ --enable-tiny Disables features for the sake of size
(currently disables detailed help and i18n)],
[if test x$enableval = xyes; then
AC_DEFINE(NANO_SMALL) tiny_support=yes
AC_DEFINE(DISABLE_TABCOMP)
AC_DEFINE(DISABLE_SPELLER)
AC_DEFINE(DISABLE_HELP)
AC_DEFINE(DISABLE_JUSTIFY)
AC_DEFINE(DISABLE_BROWSER)
AC_ARG_ENABLE(debug,
[ --enable-debug Enable debugging (disabled by default)],
[if test x$enableval = xyes; then
AC_DEFINE(DEBUG, 1, [Define this to enable nano debug messages and assert warnings.])
debug_support=yes
fi])
if test "$debug_support" != "yes"; then
AC_DEFINE(NDEBUG, 1, [Shut up the assert warnings :-)])
fi
AC_ARG_ENABLE(extra,
[ --enable-extra Enable extra (optional) functions, including easter eggs],
[if test x$enableval = xyes; then
AC_DEFINE(NANO_EXTRA) extra_support=yes
AC_DEFINE(NANO_EXTRA, 1, [Define this to enable the extra stuff.]) extra_support=yes
AC_DEFINE(ENABLE_MULTIBUFFER, 1, [Define this to enable multiple file buffers.]) multibuffer_support=yes
fi])
AC_ARG_ENABLE(tabcomp,
[ --disable-tabcomp Disables tab completion code for a smaller binary],
AC_ARG_ENABLE(tiny,
[ --enable-tiny Disable features for the sake of size
(currently disables detailed help and i18n)],
[if test x$enableval = xyes; then
AC_DEFINE(NANO_SMALL, 1, [Define this to make the nano executable as small as possible.]) tiny_support=yes
AC_DEFINE(DISABLE_BROWSER, 1, [Define this to disable the built-in (crappy) file browser.])
AC_DEFINE(DISABLE_HELP, 1, [Define this to disable the ^G help menu.])
AC_DEFINE(DISABLE_JUSTIFY, 1, [Define this to disable the justify routine.])
AC_DEFINE(DISABLE_MOUSE, 1, [Define this to disable the mouse functions.])
AC_DEFINE(DISABLE_OPERATINGDIR, 1, [Define this to disable setting of the operating directory (chroot of sorts).])
AC_DEFINE(DISABLE_SPELLER, 1, [Define this to disable the use(full|less) spelling functions.])
AC_DEFINE(DISABLE_TABCOMP, 1, [Define to disable the tab completion code Chris worked so hard on!])
fi])
AC_ARG_ENABLE(browser,
[ --disable-browser Disable mini file browser],
[if test x$enableval != xyes; then
AC_DEFINE(DISABLE_TABCOMP)
AC_DEFINE(DISABLE_BROWSER, 1, [Define this to disable the built-in (crappy) file browser.])
fi])
AC_ARG_ENABLE(help,
[ --disable-help Disable help function (^G)],
[if test x$enableval != xyes; then
AC_DEFINE(DISABLE_HELP, 1, [Define this to disable the ^G help menu.])
fi])
AC_ARG_ENABLE(justify,
[ --disable-justify Disable justify/unjustify function],
[if test x$enableval != xyes; then
AC_DEFINE(DISABLE_JUSTIFY)
AC_DEFINE(DISABLE_JUSTIFY, 1, [Define this to disable the justify routine.])
fi])
AC_ARG_ENABLE(mouse,
[ --disable-mouse Disable mouse support (and -m flag)],
[if test x$enableval != xyes; then
AC_DEFINE(DISABLE_MOUSE, 1, [Define this to disable the mouse functions.])
fi])
AC_ARG_ENABLE(operatingdir,
[ --disable-operatingdir Disable setting of operating directory (chroot of sorts)],
[if test x$enableval != xyes; then
AC_DEFINE(DISABLE_OPERATINGDIR, 1, [Define this to disable setting of the operating directory (chroot of sorts).])
fi])
AC_ARG_ENABLE(speller,
[ --disable-speller Disables spell checker function],
[ --disable-speller Disable spell checker function],
[if test x$enableval != xyes; then
AC_DEFINE(DISABLE_SPELLER)
AC_DEFINE(DISABLE_SPELLER, 1, [Define this to disable the use(full|less) spelling functions.])
fi])
AC_ARG_ENABLE(help,
[ --disable-help Disables help function (^G)],
AC_ARG_ENABLE(tabcomp,
[ --disable-tabcomp Disable tab completion code for a smaller binary],
[if test x$enableval != xyes; then
AC_DEFINE(DISABLE_HELP)
fi])
AC_ARG_ENABLE(browser,
[ --disable-browser Disables mini file browser],
[if test x$enableval != xyes; then
AC_DEFINE(DISABLE_BROWSER)
AC_DEFINE(DISABLE_TABCOMP, 1, [Define to disable the tab completion code Chris worked so hard on!])
fi])
AC_ARG_ENABLE(wrapping,
[ --disable-wrapping Disables all wrapping of text (and -w flag)],
[ --disable-wrapping Disable all wrapping of text (and -w flag)],
[if test x$enableval != xyes; then
AC_DEFINE(DISABLE_WRAPPING)
AC_DEFINE(DISABLE_WRAPPING, 1, [Define this to disable any and all text wrapping.])
fi])
AC_ARG_ENABLE(color,
[ --enable-color Enable color and syntax highlighting],
[if test x$enableval = xyes; then
AC_DEFINE(ENABLE_NANORC, 1, [Define this to use the .nanorc file.]) nanorc_support=yes
AC_DEFINE(ENABLE_COLOR, 1, [Define this to have syntax highlighting, requires ENABLE_NANORC too!]) color_support=yes
AC_MSG_WARN([
***********************************************************************
*** WARNING: Color support is far from perfect, but functional. ***
*** Be careful with syntax in your .nanorc or nano may malfunction. ***
***********************************************************************
])
fi])
AC_ARG_ENABLE(multibuffer,
[ --enable-multibuffer Enable multiple file buffers],
[if test x$enableval = xyes; then
AC_DEFINE(ENABLE_MULTIBUFFER, 1, [Define this to enable multiple file buffers.]) multibuffer_support=yes
fi])
AC_ARG_ENABLE(nanorc,
[ --enable-nanorc Enable use of .nanorc file],
[if test x$enableval = xyes; then
AC_DEFINE(ENABLE_NANORC, 1, [Define this to use the .nanorc file.]) nanorc_support=yes
fi])
AC_MSG_CHECKING([whether to use slang])
@@ -94,7 +150,7 @@ AC_ARG_WITH(slang,
#include <slcurses.h>
int main () { SLtt_initialize (NULL); return 0; }],
[AC_MSG_RESULT(yes)
AC_DEFINE(USE_SLANG)
AC_DEFINE(USE_SLANG, 1, [Define to use the slang wrappers for curses instead of native curses.])
slang_support=yes
if test "$with_slang" != "yes"; then
CURSES_LIB="-L${with_slang}/lib -lslang"
@@ -116,7 +172,7 @@ int main () { SLtt_initialize (NULL); return 0; }],
#include <slcurses.h>
int main () { SLtt_initialize (NULL); return 0; }],
[AC_MSG_RESULT(yes)
AC_DEFINE(USE_SLANG)
AC_DEFINE(USE_SLANG, 1, [Define to use the slang wrappers for curses instead of native curses.])
slang_support=yes
if test "$with_slang" != "yes"; then
CURSES_LIB="-L${with_slang}/lib -lslang $tcap"
@@ -133,7 +189,7 @@ int main () { SLtt_initialize (NULL); return 0; }],
#include <slcurses.h>
int main () { SLtt_initialize (NULL); return 0; }],
[AC_MSG_RESULT(yes)
AC_DEFINE(USE_SLANG)
AC_DEFINE(USE_SLANG, 1, [Define to use the slang wrappers for curses instead of native curses.])
slang_support=yes
if test "$with_slang" != "yes"; then
CURSES_LIB="-L${with_slang}/lib -lslang $tcap -lm"
@@ -161,7 +217,11 @@ AC_MSG_WARN([*** Can not use slang when cross-compiling])),
esac], [AC_MSG_RESULT(no)])
dnl Checks for functions
AC_CHECK_FUNCS(snprintf vsnprintf)
AC_CHECK_FUNCS(ngettext snprintf vsnprintf)
if test "x$ac_cv_func_ngettext" = "xno"
then
AC_DEFINE(NO_NGETTEXT, 1, [Defined if ngettext() is unavailable])
fi
if test "x$ac_cv_func_snprintf" = "xno" -o "xac_cv_func_vsnprintf" = "xno"
then
AM_PATH_GLIB(1.2.4,,
@@ -217,9 +277,10 @@ else
fi
AC_CHECK_LIB([$CURSES_LIB_NAME], use_default_colors, AC_DEFINE(HAVE_USE_DEFAULT_COLORS, 1, [Define this if your curses library has the use_default_colors command.]))
if test x$slang_support != xyes; then
AC_CHECK_LIB([$CURSES_LIB_NAME], wresize, [AC_DEFINE(HAVE_WRESIZE)])
AC_CHECK_LIB([$CURSES_LIB_NAME], resizeterm, [AC_DEFINE(HAVE_RESIZETERM)])
AC_CHECK_LIB([$CURSES_LIB_NAME], wresize, AC_DEFINE(HAVE_WRESIZE, 1, [Define this if you have the wresize function in your ncurses-type library.]))
AC_CHECK_LIB([$CURSES_LIB_NAME], resizeterm, AC_DEFINE(HAVE_RESIZETERM, 1, [Define this if you have the resizeterm function in your ncurses-type library.]))
# Taken from aumix (can't tell form the variable name?)
AC_CACHE_CHECK([for private member _use_keypad in WINDOW],
@@ -232,7 +293,7 @@ if test x$slang_support != xyes; then
aumix_cv_struct_window_usekeypad=yes, aumix_cv_struct_window_usekeypad=no)])
if test $aumix_cv_struct_window_usekeypad = yes; then
AC_DEFINE(HAVE_USEKEYPAD)
AC_DEFINE(HAVE_USEKEYPAD, 1, [Define this if your curses lib has the _use_keypad flag.])
fi
fi
@@ -240,8 +301,6 @@ dnl Parse any configure options
LIBS="$LIBS $CURSES_LIB"
AC_ARG_ENABLE(debug, [ --enable-debug Enable debugging (def disabled)],)
AC_SUBST(CURSES_LIB)
if test "x$glib_cflags" != "x"
@@ -254,6 +313,7 @@ then
fi
dnl i18n stuff - pretty incomplete for now
AM_GNU_GETTEXT
AM_GNU_GETTEXT([external])
AC_OUTPUT([Makefile intl/Makefile po/Makefile.in])
AC_CONFIG_FILES([Makefile m4/Makefile po/Makefile.in nano.spec])
AC_OUTPUT

432
cut.c
View File

@@ -2,10 +2,10 @@
/**************************************************************************
* cut.c *
* *
* Copyright (C) 1999 Chris Allegretta *
* Copyright (C) 1999-2002 Chris Allegretta *
* 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 1, or (at your option) *
* 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, *
@@ -19,34 +19,30 @@
* *
**************************************************************************/
#include "config.h"
#include <stdlib.h>
#include <string.h>
#include <stdio.h>
#include "config.h"
#include <assert.h>
#include "proto.h"
#include "nano.h"
#ifndef NANO_SMALL
#include <libintl.h>
#define _(string) gettext(string)
#else
#define _(string) (string)
#endif
static int marked_cut; /* Is the cutbuffer from a mark? */
static filestruct *cutbottom = NULL; /* Pointer to end of cutbuffer */
static int marked_cut; /* Is the cutbuffer from a mark */
static filestruct *cutbottom = NULL; /* Pointer to end of cutbuffer */
void add_to_cutbuffer(filestruct * inptr)
filestruct *get_cutbottom(void)
{
filestruct *tmp;
return cutbottom;
}
void add_to_cutbuffer(filestruct *inptr)
{
#ifdef DEBUG
fprintf(stderr, _("add_to_cutbuffer called with inptr->data = %s\n"),
inptr->data);
#endif
totsize -= strlen(inptr->data);
tmp = cutbuffer;
if (cutbuffer == NULL) {
cutbuffer = inptr;
inptr->prev = NULL;
@@ -60,104 +56,170 @@ void add_to_cutbuffer(filestruct * inptr)
}
#ifndef NANO_SMALL
void cut_marked_segment(filestruct * top, int top_x, filestruct * bot,
int bot_x)
/* Cut a marked segment instead of a whole line.
* The first cut character is top->data[top_x]. Unless top == bot, the
* last cut line has length bot_x. That is, if bot_x > 0 then we cut to
* bot->data[bot_x - 1].
*
* destructive is whether to actually modify the file structure, if not
* then just copy the buffer into cutbuffer and don't pull it from the
* file.
*
* If destructive, then we maintain totsize, totlines, filebot, the
* magic line, and line numbers. Also, we set current and current_x so
* the cursor will be on the first character after what was cut. We do
* not do any screen updates. */
void cut_marked_segment(filestruct *top, size_t top_x, filestruct *bot,
size_t bot_x, int destructive)
{
filestruct *tmp, *next;
char *tmpstr;
size_t newsize;
/* Set up the beginning of the cutbuffer */
tmp = copy_node(top);
tmpstr = nmalloc(strlen(&top->data[top_x]) + 1);
strcpy(tmpstr, &top->data[top_x]);
free(tmp->data);
tmp->data = tmpstr;
/* Chop off the end of the first line */
tmpstr = nmalloc(top_x + 1);
strncpy(tmpstr, top->data, top_x);
free(top->data);
top->data = tmpstr;
do {
next = tmp->next;
add_to_cutbuffer(tmp);
totlines--;
totsize--; /* newline (add_to_cutbuffer doesn't count newlines) */
tmp = next;
}
while (next != bot && next != NULL);
dump_buffer(cutbuffer);
if (next == NULL)
if (top == bot && top_x == bot_x)
return;
/* Now, paste bot[bot_x] into top[top_x] */
tmpstr = nmalloc(strlen(top->data) + strlen(&bot->data[bot_x]));
strncpy(tmpstr, top->data, top_x);
strcpy(&tmpstr[top_x], &bot->data[bot_x]);
free(top->data);
top->data = tmpstr;
assert(top != NULL && bot != NULL);
null_at(bot->data, bot_x);
next = bot->next;
/* Make top be no later than bot. */
if (top->lineno > bot->lineno) {
filestruct *swap = top;
int swap2 = top_x;
/* We explicitly don't decrement totlines here because we don't snarf
* up a newline when we're grabbing the last line of the mark. For
* the same reason we don't do an extra totsize decrement */
top = bot;
bot = swap;
add_to_cutbuffer(bot);
top->next = next;
if (next != NULL)
next->prev = top;
top_x = bot_x;
bot_x = swap2;
} else if (top == bot && top_x > bot_x) {
/* And bot_x can't be an earlier character than top_x. */
int swap = top_x;
dump_buffer(cutbuffer);
renumber(top);
current = top;
current_x = top_x;
top_x = bot_x;
bot_x = swap;
}
/* If we're hitting the end of the buffer we should clean that up. */
if (bot == filebot) {
if (next != NULL) {
filebot = next;
/* Make the first cut line manually. */
tmp = copy_node(top);
newsize = (top == bot ? bot_x - top_x : strlen(top->data + top_x));
memmove(tmp->data, top->data + top_x, newsize);
null_at(&tmp->data, newsize);
add_to_cutbuffer(tmp);
/* And make the remainder line manually too. */
if (destructive) {
current_x = top_x;
totsize -= newsize;
totlines -= bot->lineno - top->lineno;
newsize = top_x + strlen(bot->data + bot_x) + 1;
if (top == bot) {
/* In this case, the remainder line is shorter, so we must
move text from the end forward first. */
memmove(top->data + top_x, bot->data + bot_x,
newsize - top_x);
top->data = (char *)nrealloc(top->data,
sizeof(char) * newsize);
} else {
filebot = top;
totsize -= bot_x + 1;
/* Here, the remainder line might get longer, so we realloc
it first. */
top->data = (char *)nrealloc(top->data,
sizeof(char) * newsize);
memmove(top->data + top_x, bot->data + bot_x,
newsize - top_x);
}
}
if (top == bot) {
#ifdef DEBUG
dump_buffer(cutbuffer);
#endif
return;
}
tmp = top->next;
while (tmp != bot) {
next = tmp->next;
if (!destructive)
tmp = copy_node(tmp);
else
totsize -= strlen(tmp->data) + 1;
add_to_cutbuffer(tmp);
tmp = next;
}
/* Make the last cut line manually. */
tmp = copy_node(bot);
null_at(&tmp->data, bot_x);
add_to_cutbuffer(tmp);
#ifdef DEBUG
dump_buffer(cutbuffer);
#endif
if (destructive) {
top->next = bot->next;
if (top->next != NULL)
top->next->prev = top;
delete_node(bot);
renumber(top);
current = top;
if (bot == filebot) {
filebot = top;
assert(bot_x == 0);
if (top_x > 0)
new_magicline();
}
}
if (top->lineno < edittop->lineno)
edit_update(top, CENTER);
}
#endif
int do_cut_text(void)
{
filestruct *tmp, *fileptr = current;
filestruct *fileptr;
#ifndef NANO_SMALL
char *tmpstr;
int newsize, cuttingtoend = 0;
int dontupdate = 0;
#endif
check_statblank();
if (fileptr == NULL || fileptr->data == NULL)
return 0;
assert(current != NULL && current->data != NULL);
tmp = fileptr->next;
check_statblank();
if (!ISSET(KEEP_CUTBUFFER)) {
free_filestruct(cutbuffer);
cutbuffer = NULL;
marked_cut = 0;
#ifdef DEBUG
fprintf(stderr, _("Blew away cutbuffer =)\n"));
#endif
}
/* Must let cutbuffer get blown away first before we do this... */
if (fileptr == filebot && !ISSET(MARK_ISSET))
/* You can't cut the magic line except with the mark. But
trying does clear the cutbuffer if KEEP_CUTBUFFER is not set. */
if (current == filebot
#ifndef NANO_SMALL
&& !ISSET(MARK_ISSET)
#endif
)
return 0;
#ifndef NANO_SMALL
if (ISSET(CUT_TO_END) && !ISSET(MARK_ISSET)) {
if (current_x == strlen(current->data)) {
assert(current_x >= 0 && current_x <= strlen(current->data));
if (current->data[current_x] == '\0') {
/* If the line is empty and we didn't just cut a non-blank
line, create a dummy line and add it to the cutbuffer */
if (marked_cut != 1 && current->next != filebot) {
filestruct *junk = make_new_node(current);
junk->data = charalloc(1);
junk->data[0] = '\0';
add_to_cutbuffer(junk);
#ifdef DEBUG
dump_buffer(cutbuffer);
#endif
}
do_delete();
SET(KEEP_CUTBUFFER);
marked_cut = 2;
@@ -168,109 +230,69 @@ int do_cut_text(void)
mark_beginx = strlen(current->data);
mark_beginbuf = current;
cuttingtoend = 1;
dontupdate = 1;
}
}
if (ISSET(MARK_ISSET)) {
if (current->lineno == mark_beginbuf->lineno) {
tmp = copy_node(current);
newsize = abs(mark_beginx - current_x) + 1;
tmpstr = nmalloc(newsize + 1);
if (current_x < mark_beginx) {
strncpy(tmpstr, &current->data[current_x], newsize);
memmove(&current->data[current_x],
&current->data[mark_beginx],
strlen(&current->data[mark_beginx]) + 1);
} else {
strncpy(tmpstr, &current->data[mark_beginx], newsize);
memmove(&current->data[mark_beginx],
&current->data[current_x],
strlen(&current->data[current_x]) + 1);
current_x = mark_beginx;
update_cursor();
}
tmpstr[newsize - 1] = 0;
tmp->data = tmpstr;
add_to_cutbuffer(tmp);
dump_buffer(cutbuffer);
align(&current->data);
} else if (current->lineno < mark_beginbuf->lineno)
cut_marked_segment(current, current_x, mark_beginbuf,
mark_beginx);
else
cut_marked_segment(mark_beginbuf, mark_beginx, current,
current_x);
if (ISSET(MARK_ISSET)) {
/* Don't do_update() and move the screen position if the marked
area lies entirely within the screen buffer */
dontupdate |= current->lineno >= edittop->lineno &&
current->lineno <= editbot->lineno &&
mark_beginbuf->lineno >= edittop->lineno &&
mark_beginbuf->lineno <= editbot->lineno;
cut_marked_segment(current, current_x, mark_beginbuf,
mark_beginx, 1);
placewewant = xplustabs();
UNSET(MARK_ISSET);
marked_cut = 1;
set_modified();
if (cuttingtoend)
if (dontupdate) {
fix_editbot();
edit_refresh();
else
} else
edit_update(current, CENTER);
return 1;
#else
if (0) {
#endif
} else if (fileptr == fileage) {
/* we're cutting the first line */
if (fileptr->next != NULL) {
fileptr = fileptr->next;
tmp = fileptr;
fileage = fileptr;
add_to_cutbuffer(fileptr->prev);
totsize--; /* get the newline */
totlines--;
fileptr->prev = NULL;
current = fileptr;
edit_update(fileage, CENTER);
} else {
add_to_cutbuffer(fileptr);
fileage = make_new_node(NULL);
fileage->data = nmalloc(1);
fileage->data[0] = '\0';
current = fileage;
}
} else {
if (fileptr->prev != NULL)
fileptr->prev->next = fileptr->next;
if (fileptr->next != NULL) {
(fileptr->next)->prev = fileptr->prev;
current = fileptr->next;
totlines--;
totsize--; /* get the newline */
}
/* No longer an else here, because we never get here anymore...
No need to cut the magic line, as it's empty */
add_to_cutbuffer(fileptr);
}
#endif /* !NANO_SMALL */
totlines--;
totsize -= strlen(current->data) + 1;
fileptr = current;
current = current->next;
current->prev = fileptr->prev;
add_to_cutbuffer(fileptr);
#ifdef DEBUG
dump_buffer(cutbuffer);
#endif
if (fileptr == fileage)
fileage = current;
else
current->prev->next = current;
if (fileptr == edittop)
edittop = current;
renumber(current);
edit_refresh();
dump_buffer(cutbuffer);
reset_cursor();
set_modified();
marked_cut = 0;
current_x = 0;
placewewant = 0;
update_cursor();
renumber(tmp);
reset_cursor();
SET(KEEP_CUTBUFFER);
return 1;
}
int do_uncut_text(void)
{
filestruct *tmp = current, *fileptr = current, *newbuf, *newend;
filestruct *tmp = current, *fileptr = current;
filestruct *newbuf = NULL;
filestruct *newend = NULL;
#ifndef NANO_SMALL
char *tmpstr, *tmpstr2;
filestruct *hold = current;
@@ -282,40 +304,52 @@ int do_uncut_text(void)
if (cutbuffer == NULL || fileptr == NULL)
return 0; /* AIEEEEEEEEEEEE */
newbuf = copy_filestruct(cutbuffer);
for (newend = newbuf; newend->next != NULL && newend != NULL;
newend = newend->next) {
totlines++;
#ifndef NANO_SMALL
if (!marked_cut || cutbuffer->next != NULL)
#endif
{
newbuf = copy_filestruct(cutbuffer);
for (newend = newbuf; newend->next != NULL && newend != NULL;
newend = newend->next)
totlines++;
}
/* Hook newbuf into fileptr */
#ifndef NANO_SMALL
if (marked_cut) {
int recenter_me = 0;
/* Should we eventually use edit_update(CENTER)? */
/* If there's only one line in the cutbuffer */
if (cutbuffer->next == NULL) {
tmpstr =
nmalloc(strlen(current->data) + strlen(cutbuffer->data) +
1);
strncpy(tmpstr, current->data, current_x);
strcpy(&tmpstr[current_x], cutbuffer->data);
strcat(tmpstr, &current->data[current_x]);
free(current->data);
current->data = tmpstr;
current_x += strlen(cutbuffer->data);
totsize += strlen(cutbuffer->data);
size_t buf_len = strlen(cutbuffer->data);
size_t cur_len = strlen(current->data);
current->data = nrealloc(current->data, cur_len + buf_len + 1);
memmove(current->data + current_x + buf_len,
current->data + current_x, cur_len - current_x + 1);
strncpy(current->data + current_x, cutbuffer->data, buf_len);
/* Use strncpy to not copy the terminal '\0'. */
current_x += buf_len;
totsize += buf_len;
/* If we've uncut a line, make sure there's a magicline after
it */
if (current->next == NULL)
new_magicline();
placewewant = xplustabs();
update_cursor();
} else { /* yuck -- no kidding! */
tmp = current->next;
/* New beginning */
tmpstr = nmalloc(current_x + strlen(newbuf->data) + 1);
tmpstr = charalloc(current_x + strlen(newbuf->data) + 1);
strncpy(tmpstr, current->data, current_x);
strcpy(&tmpstr[current_x], newbuf->data);
totsize += strlen(newbuf->data) + strlen(newend->data) + 1;
/* New end */
tmpstr2 = nmalloc(strlen(newend->data) +
tmpstr2 = charalloc(strlen(newend->data) +
strlen(&current->data[current_x]) + 1);
strcpy(tmpstr2, newend->data);
strcat(tmpstr2, &current->data[current_x]);
@@ -334,8 +368,8 @@ int do_uncut_text(void)
newend->next = tmp;
/* If tmp isn't null, we're in the middle: update the
* prev pointer. If it IS null, we're at the end, update
* the filebot pointer */
prev pointer. If it IS null, we're at the end; update
the filebot pointer */
if (tmp != NULL)
tmp->prev = newend;
@@ -351,48 +385,55 @@ int do_uncut_text(void)
for (tmp = current->next; tmp != newend; tmp = tmp->next)
totsize += strlen(tmp->data) + 1;
i = editbot->lineno;
current = newend;
if (i <= newend->lineno)
edit_update(current, CENTER);
if (editbot->lineno < newend->lineno)
recenter_me = 1;
}
/* If marked cut == 2, that means that we're doing a cut to end
and we don't want anything else on the line, so we have to
screw up all the work we just did and separate the line. There
must be a better way to do this, but not at 1AM on a work night. */
screw up all the work we just did and separate the line.
There must be a better way to do this, but not at 1AM on a
work night. */
if (marked_cut == 2 && current_x != strlen(current->data)) {
if (marked_cut == 2) {
tmp = make_new_node(current);
tmp->data = nmalloc(strlen(&current->data[current_x]) + 1);
tmp->data = charalloc(strlen(&current->data[current_x]) + 1);
strcpy(tmp->data, &current->data[current_x]);
splice_node(current, tmp, current->next);
null_at(current->data, current_x);
null_at(&current->data, current_x);
current = current->next;
current_x = 0;
placewewant = 0;
/* Extra line added, update stuff */
totlines++;
totsize++;
}
/* Renumber from BEFORE where we pasted ;) */
renumber(hold);
#ifdef DEBUG
dump_buffer(fileage);
dump_buffer(cutbuffer);
set_modified();
edit_refresh();
return 0;
#else
if (0) {
#endif
} else if (fileptr != fileage) {
set_modified();
if (recenter_me)
edit_update(current, CENTER);
else
edit_refresh();
UNSET(KEEP_CUTBUFFER);
return 0;
}
#endif
if (fileptr != fileage) {
tmp = fileptr->prev;
tmp->next = newbuf;
newbuf->prev = tmp;
totlines++; /* Unmarked uncuts don't split lines */
} else {
} else
fileage = newbuf;
totlines++; /* Unmarked uncuts don't split lines */
}
totlines++; /* Unmarked uncuts don't split lines */
/* This is so uncutting at the top of the buffer will work => */
if (current_y == 0)
@@ -402,7 +443,7 @@ int do_uncut_text(void)
newend->next = fileptr;
fileptr->prev = newend;
/* recalculate size *sigh* */
/* Recalculate size *sigh* */
for (tmp = newbuf; tmp != fileptr; tmp = tmp->next)
totsize += strlen(tmp->data) + 1;
@@ -410,11 +451,14 @@ int do_uncut_text(void)
renumber(newbuf);
if (i < newend->lineno)
edit_update(fileptr, CENTER);
else
edit_refresh();
dump_buffer_reverse(fileptr);
#ifdef DEBUG
dump_buffer_reverse();
#endif
set_modified();
UNSET(KEEP_CUTBUFFER);
edit_refresh();
return 1;
}

229
faq.html
View File

@@ -24,7 +24,7 @@ nano?</a></font>
TIP?</a></font>
<br><font color="#330000"><a href="#1.6">1.6. What is the current version
of nano?</a></font>
<br><font color="#330000"><a href="#1.7">1.7. I want to read the man page
<br><font color="#330000"><a href="#1.7">1.7. I want to read the manpage
without having to download the program!</a></font></blockquote>
<h2>
@@ -45,14 +45,18 @@ packages.</a></font>
RPM or DEB package?</a></font>
<br><font color="#330000"><a href="#3.2">3.2. Compiling from source: WHAT
THE HECK DO I DO NOW?</a></font>
<br><font color="#330000"><a href="#3.2">3.3. Why does everything go into
<br><font color="#330000"><a href="#3.3">3.3. Why does everything go into
/usr/local?</a></font>
<br><font color="#330000"><a href="#3.4">3.4. I get errors about 'bindtextdomain',
'gettext' and/or 'gettextdomain'.&nbsp; What can I do about it?</a></font>
<br><font color="#330000"><a href="#3.5">3.5. Nano should automatically
run strip on the binary when installing it!</a></font>
<br><font color="#330000"><a href="#3.6">3.6. How can I make the
executable smaller? This is too bloated!</a></font></blockquote>
executable smaller? This is too bloated!</a></font>
<br><font color="#330000"><a href="#3.7">3.7. Tell me more about this
multibuffer stuff!</a></font>
<br><font color="#330000"><a href="#3.8">3.8. How do I make a .nanorc file
that nano will read when I start it?</a></font></blockquote>
<h2>
<font color="#330000"><a href="#4">4. Running</a></font></h2>
@@ -63,11 +67,11 @@ bucky/meta key doesn't seem to work!&nbsp; What can I do?</a></font>
&lt;insert keystroke here>!</a></font>
<br><font color="#330000"><a href="#4.3">4.3. Nano crashes when I resize
my window.&nbsp;&nbsp; How can I fix that?</a></font>
<br><font color="#330000"><a href="#4.4">4.4. Why does nano show ^\ and
^_ in the shortcut list instead of ^G and ^J?</a></font>
<br><font color="#330000"><a href="#4.4">4.4. Why does nano show ^\
in the shortcut list instead of ^J?</a></font>
<br><font color="#330000"><a href="#4.5">4.5. When I type in a
search string, the string I last searched for is already in front of
my cursor! !What happened?!</a></font>
my cursor! What happened?!</a></font>
<br><font color="#330000"><a href="#4.6">4.6. I get the message "NumLock
glitch detected. Keypad will malfunction with NumLock off." What
gives?</a></font>
@@ -90,7 +94,7 @@ nano instead of Pico?</a></font>
<br><font color="#330000"><a href="#6.2">6.2. Why should I use Pico instead
of nano?</a></font>
<br><font color="#330000"><a href="#6.3">6.3. What is so bad about the
PINE license?</a></font>
Pine license?</a></font>
<br><font color="#330000"><a href="#6.4">6.4. Okay, well what mail program
should I use then?</a></font>
<br><font color="#330000"><a href="#6.5">6.5. Why doesn't UW simply change
@@ -138,7 +142,7 @@ it is useful enough it will be included in future versions.</font></blockquote>
<a NAME="1.3"></a><font color="#330000">1.3. What is GNU nano?</font></h2>
<blockquote><font color="#330000">GNU Nano is designed to be a free
replacement for the Pico text editor, part of the PINE email suite from <a
replacement for the Pico text editor, part of the Pine email suite from <a
href="http://www.washington.edu/pine">The University of
Washington</a>.&nbsp; It aims to "emulate Pico as closely as possible and
perhaps include extra functionality.</font></blockquote>
@@ -156,8 +160,8 @@ to Unix flocked to Pico and Pine because of their well organized, easy
to use interfaces.&nbsp; With the proliferation of GNU/Linux in the mid to
late 90's, many University students became intimately familiar with the
strengths (and weaknesses) of Pine and Pico.</font>
<p><b><font color="#330000">Then came debian...</font></b>
<p><font color="#330000">The <a href="http://www.debian.org">debian GNU/Linux</a>
<p><b><font color="#330000">Then came Debian...</font></b>
<p><font color="#330000">The <a href="http://www.debian.org">Debian GNU/Linux</a>
distribution, known for its strict standards in distributing truly "free"
software (i.e. had no restrictions on redistribution), would not include
a binary package for Pine or Pico.&nbsp; Many people had a serious dilemma:&nbsp;
@@ -167,9 +171,9 @@ sense of the word.</font>
<p><b><font color="#330000">The event...</font></b>
<p><font color="#330000">It was in late 1999 when Chris Allegretta (our
hero) was yet again complaining to himself about the less-than-perfect
license Pico was distributed under, the 1.0.1 makefiles that came with
license Pico was distributed under, the 1000 makefiles that came with
it and how just a few small improvements could make it the Best Editor
in the World (TM).&nbsp; Having been a convert from Slackware to debian,
in the World (TM).&nbsp; Having been a convert from Slackware to Debian,
he missed having a simple binary package that included Pine and Pico, and
had grown tired of downloading them himself.</font>
<p><font color="#330000">Finally something snapped inside and Chris coded
@@ -177,12 +181,11 @@ and hacked like a madman for many hours straight one weekend to make a
(barely usable) Pico clone, at the time called TIP (Tip Isn't Pico).&nbsp;
The program could not be invoked without a filename, could not save files,
had no help menu, spell checker, and so forth.&nbsp; But over time it improved,
and with the help of a few great coders it matured to the almost stable
and with the help of a few great coders it matured to the (hopefully) stable
state it is today.
<p><font color="#330000">In February 2001, nano has been declared an
official GNU program by Richard Stallman. Nano is also nearing its 1.0
release as of this writing (Valentine's Day 2001).
</font></blockquote>
official GNU program by Richard Stallman. Nano also reached its first
production release on March 22, 2001.</font></blockquote>
<h2>
<a NAME="1.5"></a><font color="#330000">1.5. Why the name change from TIP?</font></h2>
@@ -200,7 +203,7 @@ nano was developed).</font></blockquote>
of nano?</font></h2>
<blockquote><font color="#330000">The current version of nano *should*
be 1.0.1.&nbsp; Of course you should always check the nano hompage to
be 1.1.12.&nbsp; Of course you should always check the nano homepage to
see what the latest and greatest version is.</font></blockquote>
<h2>
@@ -226,12 +229,9 @@ at the following fine web and ftp sites:</font>
<li>
<font color="#330000"><a href="http://www.ewtoo.org/~astyanax/nano/dist">http://www.ewtoo.org/~astyanax/nano/dist</a></font></li>
<li>
<font color="#330000"><a href="ftp://ftp.nano-editor.org/pub/nano">ftp://ftp.nano-editor.org/pub/nano</a></font></li>
<font color="#330000"><a href="ftp://ftp.gnu.org/pub/gnu/nano">ftp://ftp.gnu.org/pub/gnu/nano</a></font></li>
<li>
<font color="#330000"><a href="ftp://nano.sourceforge.net/pub/nano/">ftp://nano.sourceforge.net/pub/nano</a></font></li>
</ul>
</blockquote>
@@ -247,39 +247,40 @@ packages.</font></h2>
<li>
<font color="#330000"><a href="http://www.ewtoo.org/~astyanax/nano/dist/RPMS">http://www.ewtoo.org/~astyanax/nano/dist/RPMS</a></font></li>
<li>
<font color="#330000"><a href="ftp://ftp.nano-editor.org/pub/nano/RPMS">ftp://ftp.nano-editor.org/pub/nano/RPMS</a></font></li>
<li>
<font color="#330000"><a href="ftp://nano.sourceforge.net/pub/nano/RPMS">ftp://nano.sourceforge.net/pub/nano/RPMS</a></font></li>
</ul>
<font color="#330000">Additionally, check out the Redhat contribs section
at:</font>
<ul>
<li>
<font color="#330000"><a href="http://metalab.unc.edu/pub/Linux/distributions/redhat/contrib/libc6/i386">http://metalab.unc.edu/pub/Linux/distributions/redhat/contrib/libc6/i386</a></font></li>
<font color="#330000"><a href="http://distro.ibiblio.org/pub/Linux/distributions/redhat/contrib/libc6/i386">http://metalab.unc.edu/pub/Linux/distributions/redhat/contrib/libc6/i386</a></font></li>
<li>
<font color="#330000"><a href="ftp://metalab.unc.edu/pub/Linux/distributions/redhat/contrib/libc6/i386">ftp://metalab.unc.edu/pub/Linux/distributions/redhat/contrib/libc6/i386</a></font></li>
<font color="#330000"><a href="ftp://distro.ibiblio.org/pub/Linux/distributions/redhat/contrib/libc6/i386">ftp://metalab.unc.edu/pub/Linux/distributions/redhat/contrib/libc6/i386</a></font></li>
</ul>
</blockquote>
<h2>
<a NAME="2.3"></a><font color="#330000">2.3. Debian (.deb) packages.</font></h2>
<blockquote><font color="#330000">For debian users, you can check out the
<blockquote><font color="#330000">For Debian users, you can check out the
current nano packages for:</font>
<ul>
<li>
<font color="#330000"><a href="http://www.debian.org/Packages/stable/editors/nano.html">stable</a></font></li>
<li>
<font color="#330000"><a href="http://www.debian.org/Packages/testing/editors/nano.html">testing</a></font></li>
<li>
<font color="#330000"><a href="http://www.debian.org/Packages/unstable/editors/nano.html">unstable</a></font></li>
</ul>
<p><font color="#330000">You can also have a look at the</font>
<font color="#330000"><a href="ftp://ftp.debian.org/debian/pool/main/n/nano/">Package Pool</a> to see all the available binary and source packages.</font></p>
<font color="#330000">Note that versions &lt; 0.9.10 are probably not for
those wanting to get serious work done, so until the stable distribution
has an updated version of nano, you are best off using the one in unstable
for now.</font></blockquote>
those wanting to get serious work done, so if you are using Debian 2.2, check
that you have updated to 2.2r3, which comes with nano 0.9.23. If you're
tracking unstable, you probably have the newest version already.</font></blockquote>
<h2>
<a NAME="2.4"></a><font color="#330000">2.4. By CVS (for the brave).</font></h2>
@@ -288,7 +289,7 @@ for now.</font></blockquote>
of nano, you can use CVS to download the current source code.&nbsp; <b>Note:</b>
believe it or not, by downloading code that has not yet stabilized into
an official release, there could quite possibly be bugs, in fact the code
may not even compile!&nbsp; Anyway, see <a href="https://sourceforge.net/cvs/?group_id=1304">the
may not even compile!&nbsp; Anyway, see <a href="http://savannah.gnu.org/cvs/?group_id=1025">the
nano CVS page</a> for info on anonymous CVS access to the nano source.</font></blockquote>
<hr WIDTH="100%">
@@ -341,7 +342,7 @@ install</b>.</font></blockquote>
'gettext' and/or 'gettextdomain'.&nbsp; What can I do about it?</font></h2>
<blockquote><font color="#330000">Try doing a <b>./configure --with-included-gettext</b>
and see if that solves your problem.&nbsp; You make need to do a <b>make
and see if that solves your problem.&nbsp; You may need to do a <b>make
clean ; make</b> to get it to work fully.</font></blockquote>
<h2>
@@ -367,6 +368,9 @@ list:
<b>--disable-speller</b> Disables spell checker function
<b>--disable-help</b> Disables help function (^G)
<b>--disable-browser</b> Disables mini file browser
<b>--disable-wrapping</b> Disables all wrapping of text (and -w flag)
<b>--disable-mouse</b> Disables mouse support (and -m flag)
<b>--disable-operatingdir</b> Disable setting of operating directory
</pre><br>
There's also the <b>--enable-tiny</b> option which disables everything
above, as well as some larger chunks of the program (like the marker code
@@ -376,8 +380,49 @@ disable internationalization and save a few K to a few dozen K depending
on if you have locale support on your system. And finally there's always
good old <b>strip</b> to strip all debugging code and code that exists in
libraries on your system.
</font></blockquote> <hr WIDTH="100%"> <h1>
<a NAME="4"></a><font color="#330000">4. Running</font></h1>
<p>If, in the other hand, you can't live without bells and whistles, you could
try:
<pre>
<b>--enable-extra</b> Enable extra functions, including easter eggs
<b>--enable-nanorc</b> Enable use of .nanorc file
<b>--enable-color</b> Enables color and syntax highlighting
<b>--enable-multibuffer</b> Enables having multiple file buffers open
</font></blockquote>
<h2>
<a NAME="3.7"></a><font color="#330000">
3.7. Tell me more about this multibuffer stuff!</font></h2>
<blockquote><font color="#330000"> To use multiple file buffers, you must
be using nano 1.1.12 or newer, and you must have configured nano with
<b>--enable-multibuffer</b> or <b>--enable-extra</b> (use nano -V to check).
Then when you want to enable inserting a file into its own buffer instead of
into the current file, just hit <b>Meta-F</b>, then insert the file as normal
with <b>^R</b>. If you always want files to be loaded into their own buffers,
use the <b>--multibuffer</b> or <b>-F</b> flag when you invoke nano. <P>
You can move between the buffers you have open with the <b>Meta-&lt;</b> and
<b>Meta-&gt;</b> keys, or more easily with <b>Meta-,</b> and <b>Meta-.</b>
(clear as mud, right? =-). When you have more than one file buffer open,
the ^X shortcut will say "Close", instead of the normal "Exit" when only one
buffer is open.
</font></blockquote>
<h2>
<a NAME="3.8"></a><font color="#330000">
3.8. How do I make a .nanorc file that nano will read when I start it?</font></h2>
<blockquote><font color="#330000"> It's not hard at all! But, your version
of nano must have been compiled with <b>--enable-nanorc</b>, and again must
be version 1.1.12 or newer (use nano -V to check your version and compiled
features). Then simply copy the <b>nanorc.sample</b>
that came with the nano source or your nano package (most likely in
/usr/doc/nano) to .nanorc in your home directory. If you didn't get one,
the syntax is simple. Flags are turned on and off by using the word
<b>set</b> and the getopt_long flag for the feature, for example "set
pico" or "set nowrap". </font></blockquote> <hr WIDTH="100%">
<h1><a NAME="4"></a><font color="#330000">4. Running</font></h1>
<h2>
<a NAME="4.1"></a><font color="#330000">4.1. Ack!&nbsp; My backspace/delete/enter/double
@@ -395,7 +440,8 @@ keystroke here>!</font></h2>
<blockquote><font color="#330000">If you aren't trying some bizarre keystroke
combination with some bizarre $TERM entry, chances are you have found a
bug.&nbsp;&nbsp; You are welcome to submit it to the nano-devel list or
bug.&nbsp;&nbsp; You are welcome to submit it to the
<a href="mailto:nano-devel@gnu.org">nano-devel</a> list or
to <a href="mailto:nano@nano-editor.org">nano@nano-editor.org</a>.</font></blockquote>
<h2>
@@ -407,26 +453,28 @@ please upgrade to a newer version (at least 0.9.9 would be great, 0.9.12
is recommended).</font></blockquote>
<h2>
<a NAME="4.4"></a><font color="#330000">4.4. Why does nano show ^\ and
^_ in the shortcut list instead of ^G and ^J?</font></h2>
<a NAME="4.4"></a><font color="#330000">4.4. Why does nano show ^\ in the
shortcut list instead of ^J?</font></h2>
<blockquote><font color="#330000">The help (^G) and justify (^J) functions
<blockquote><font color="#330000">The help (^G) and justify (^J) function
were among the last to be written.&nbsp; To show the improvements that
nano had over Pico (goto line # and replace), ^_ and ^\ were put on the
shortcut list.&nbsp;&nbsp; If you use the <b>-p</b> option to nano you
will get the same shortcuts at the bottom as Pico.</font></blockquote>
shortcut list.&nbsp;&nbsp; Later, ^G came back in place of ^_ as it proved
to be very valuable for new UNIX users. If you use the <b>-p</b> option to
nano (or hit Meta-P) you will get the same shortcuts at the bottom as
Pico.</font></blockquote>
<h2>
<a name="4.5"><font color="#330000">4.5. When I type in a search
string, the string I last searched for is already in front of my
cursor! !What happened?!</font></h2>
cursor! What happened?!</font></h2>
<blockquote><font color="#330000">In nano version 0.9.20, the default is
to have a completely consistent user interface across all user input
functions. This means that regardless of whether you're being asked for
a filename to insert or write, or a string to search for, the
previous value is already inserted before the cursor. If you prefer the
old behavior, use the pico emulation mode (-p or --pico) or just hit
old behavior, use the Pico emulation mode (-p or --pico) or just hit
Meta-P while in nano (see the ^G help text for more
details).</font></blockquote>
@@ -455,7 +503,7 @@ mutt, etc)?</h2>
<blockquote>You need to make nano your $EDITOR.&nbsp; If you want this
to be saved, you should put a line like this in your <b>.bashrc</b> if
you use bash:
you use bash (or <b>.zshrc</b> if you believe in zsh):
<p><b>export EDITOR=/usr/local/bin/nano</b>
<p>or if you use tcsh put this in your <b>.cshrc</b> file:
<p><b>setenv EDITOR /usr/local/bin/nano</b>
@@ -484,20 +532,32 @@ this in your <b>.muttrc</b>:
<a NAME="5.1"></a><font color="#330000">5.1. There's no translation for
my language!</font></h2>
<blockquote><font color="#330000">So, uh, get someone who speaks your native
language to write one =-).&nbsp; Just grab the <b>nano.pot</b> file from
the latest and greatest nano distribution (it's in the <b>po/</b> directory)
and translate each line into your native language on the <b>msgstr</b>
line.&nbsp; Then send it to the nano devel list or <a href="mailto:nano@nano-editor.org">nano@nano-editor.org</a>.</font></blockquote>
<blockquote><font color="#330000">On June of 2001, GNU nano entered the
<a href="www.iro.umontreal.ca/contrib/po/HTML">Free Translation Project</a>
and since then, translations should be managed from there.
<p>If there isn't a translation for your language, you could ask
<a href="http://www.iro.umontreal.ca/contrib/po/HTML/teams.html">your language
team</a> to tranlate nano, or better still, join your team and do it yourself.
Joining a team is easy. You just need to ask the
<a href="mailto:translation@iro.umontreal.ca">TP coordinator</a> to add you
to your team, and send a <a href="http://www.iro.umontreal.ca/contrib/po/HTML/disclaim.html">translation disclaimer to the FSF</a> (this is necessary as
nano is an official GNU package, but it does <strong>not</strong> mean that
you transfer the rights of your work to the FSF, it's just so the FSF can
legaly manage them).</p>
<p>In any case, translating nano is very easy.&nbsp; Just grab the
<b>nano.pot</b> file from the latest and greatest nano distribution
(it's in the <b>po/</b> directory) and translate each line into your native
language on the <b>msgstr</b> line.&nbsp; When you're done, you should
send it to the TP's central po repository.
<h2>
<a NAME="5.2"></a><font color="#330000">5.2. I don't like the translation
for &lt;x> in my language.&nbsp;&nbsp; How can I fix it?</font></h2>
<blockquote><font color="#330000">The best way would probably be to e-mail
the person listed in the <b>&lt;your_language>.po</b> file with your suggested
corrections and they can in turn forward it to the nano email address,
or the devel list.</font></blockquote>
the person listed in the <code>Last-Translator:</code> field in
<b>&lt;your_language&gt;.po</b> file with your suggested corrections and
they can make the changes reach the nano devel list.</font></blockquote>
<hr WIDTH="100%">
<h1>
@@ -521,11 +581,11 @@ of personal preference as to which editor you should use.&nbsp; If you're
the type of person who likes using the original version of a program, then
Pico is the editor for you.&nbsp;&nbsp; If you're looking for a few more
features and a 'better' license as far as adding your own changes (sacrificing
mailer integration and a little stability), nano is the way to go.
mailer integration with Pine), nano is the way to go.
</blockquote>
<h2>
<a NAME="6.3"></a><font color="#330000">6.3. What is so bad about the PINE
<a NAME="6.3"></a><font color="#330000">6.3. What is so bad about the Pine
license?</font></h2>
<blockquote><font color="#330000">The U of W license for Pine and
@@ -534,7 +594,7 @@ Software Foundation and the the <a
href="http://www.debian.org/social_contract#guidelines">Debian
Free Software Guidelines</a>.&nbsp; The main problem regards the
limitations on distributing derived works: according to UW, you can
distribute their software, and you can modfify it, but you can not do
distribute their software, and you can modify it, but you can not do
both, i.e. distribute modified binaries.</blockquote>
<h2>
@@ -542,7 +602,7 @@ both, i.e. distribute modified binaries.</blockquote>
should I use then?</font></h2>
<blockquote><font color="#330000"> If you are looking to use a Free
Software program similar to PINE and emacs is not your things, you should
Software program similar to Pine and emacs is not your thing, you should
definitely take a look at <a href="http://www.mutt.org">mutt</a>.&nbsp; It
is a full-screen, console based mail program that actually has a lot more
flexibility than Pine, but has a keymap included in the distribution that
@@ -576,21 +636,33 @@ any changes in the past few years in a positive direction.</font></blockquote>
<h2>
<a NAME="7.1"></a><font color="#330000">7.1. Nano related mailing lists.</font></h2>
<blockquote><font color="#330000">There are two mailing lists for nano
hosted at <a href="http://www.sourceforge.net">SourceForge</a>, nano-announce
<blockquote><font color="#330000">There are three mailing lists for nano
hosted at <a href="http://savannah.gnu.org">Savannah</a>, info-nano, help-nano
and nano-devel.&nbsp; Nano-announce is a very low traffic list where new
versions of nano are announced (surprise!)&nbsp; Nano-devel is a normally
low, sometimes very high traffic list for dicussing the present and future
development of nano.&nbsp; Here are links to where you can sign up for
low, sometimes high traffic list for discussing the present and future
development of nano.&nbsp; Help-nano is for getting help with the editor
without needing to hear all of the development issues surrunding it.
&nbsp; Here are links to where you can sign up for
a given list:</font><font color="#330000"></font>
<p><font color="#330000">nano-announce - <a href="http://lists.sourceforge.net/mailman/listinfo/nano-announce">http://lists.sourceforge.net/mailman/listinfo/nano-announce</a></font>
<br><font color="#330000">nano-devel - <a href="http://lists.sourceforge.net/mailman/listinfo/nano-devel">http://lists.sourceforge.net/mailman/listinfo/nano-devel</a></font></blockquote>
<p><font color="#330000">info-nano - <a href="
http://mail.gnu.org/mailman/listinfo/info-nano">
http://mail.gnu.org/mailman/listinfo/info-nano</a></font>
<br>
<font color="#330000">help-nano -
<a href="http://mail.gnu.org/mailman/listinfo/help-nano">
http://mail.gnu.org/mailman/listinfo/help-nano</a></font>
<br>
<font color="#330000">nano-devel -
<a href="http://mail.gnu.org/mailman/listinfo/nano-devel">
http://mail.gnu.org/mailman/listinfo/nano-devel</a></font>
</blockquote>
<h2>
<a NAME="7.2"></a><font color="#330000">7.2. I want to send the development
team a big load of cash (or just a thank you).</font></h2>
<blockquote><font color="#330000">That's fine.&nbsp; Send it <a href="mailto:nano-devel@lists.sourceforge.net">our
<blockquote><font color="#330000">That's fine.&nbsp; Send it <a href="mailto:nano-devel@gnu.org">our
way</a>!&nbsp; Better yet, fix a <a href="http://www.nano-editor.org/dist/BUGS">bug</a>
in the program or implement a <a href="http://www.nano-editor.org/dist/TODO">cool
feature</a> and send us that instead (though cash is fine too).</font></blockquote>
@@ -607,7 +679,7 @@ team?</font></h2>
<blockquote><font color="#330000">The easiest way is to consistently send
in good patches that add some needed functionality, fix a bug or two and/or
make the program more optimized/efficient.&nbsp; Then ask nicely and you
will probably be added to the SourceForge development list and be given
will probably be added to the Savannah development list and be given
CVS write after awhile.&nbsp; There is a lot of responsibility that goes
along with being a team member, so don't think it's just something to add
to your resume.</font></blockquote>
@@ -618,10 +690,31 @@ to your resume.</font></blockquote>
<blockquote><font color="#330000">Re-read Section </font><a href="#7.4">7.4</a><font color="#330000">
and you should know the answer.</font></blockquote>
<h1>
<a NAME="8"></a>8. ChangeLog</h1>
<h2>
<a NAME="8"></a><font color="#330000">8. ChangeLog</font>
</h2>
<blockquote>06/31/2000 - Initial framework.</blockquote>
<blockquote>2002/09/10 - Another typo fix (DLR).</blockquote>
<blockquote>2002/05/15 - Typo fix (DLR).</blockquote>
<blockquote>2001/12/26 - Misc. fixes (Aaron S. Hawley, DLR).</blockquote>
<blockquote>2001/10/02 - Update for Free Translation Project.</blockquote>
<blockquote>2001/10/02 - Assorted fixes, Debian additions.</blockquote>
<blockquote>2001/06/30 - Silly typo fix.</blockquote>
<blockquote>2001/05/05 - Spelling fixes by David Lawrence Ramsey.</blockquote>
<blockquote>2001/05/02 - Misc fixes.</blockquote>
<blockquote>2001/03/26 - Typo fix in an URL.</blockquote>
<blockquote>2001/02/17 - Advocacy updates.</blockquote>
<blockquote>2001/02/15 - Added GNU notes for 0.9.99pre3.</blockquote>
<blockquote>2001/02/06 - Typo fixes.</blockquote>
<blockquote>2001/01/14 - Added note about numlock glitch.</blockquote>
<blockquote>2001/01/10 - Linux --&gt; GNU/Linux.</blockquote>
<blockquote>2001/01/09 - Added "making exe smaller section.</blockquote>
<blockquote>2000/12/19 - Typo and assorted error fixes.</blockquote>
<blockquote>2000/11/28 - Added blurb about make install-strip.</blockquote>
<blockquote>2000/11/19 - Changed Debian frozen to stable.</blockquote>
<blockquote>2000/11/18 - Previous string display (4.5).</blockquote>
<blockquote>2000/09/27 - Moved addresses to nano-editor.org.</blockquote>
<blockquote>2000/06/31 - Initial framework.</blockquote>
<P>
$Id$
</body>

2282
files.c

File diff suppressed because it is too large Load Diff

922
global.c

File diff suppressed because it is too large Load Diff

View File

@@ -1,251 +0,0 @@
#!/bin/sh
#
# install - install a program, script, or datafile
# This comes from X11R5 (mit/util/scripts/install.sh).
#
# Copyright 1991 by the Massachusetts Institute of Technology
#
# Permission to use, copy, modify, distribute, and sell this software and its
# documentation for any purpose is hereby granted without fee, provided that
# the above copyright notice appear in all copies and that both that
# copyright notice and this permission notice appear in supporting
# documentation, and that the name of M.I.T. not be used in advertising or
# publicity pertaining to distribution of the software without specific,
# written prior permission. M.I.T. makes no representations about the
# suitability of this software for any purpose. It is provided "as is"
# without express or implied warranty.
#
# Calling this script install-sh is preferred over install.sh, to prevent
# `make' implicit rules from creating a file called install from it
# when there is no Makefile.
#
# This script is compatible with the BSD install script, but was written
# from scratch. It can only install one file at a time, a restriction
# shared with many OS's install programs.
# set DOITPROG to echo to test this script
# Don't use :- since 4.3BSD and earlier shells don't like it.
doit="${DOITPROG-}"
# put in absolute paths if you don't have them in your path; or use env. vars.
mvprog="${MVPROG-mv}"
cpprog="${CPPROG-cp}"
chmodprog="${CHMODPROG-chmod}"
chownprog="${CHOWNPROG-chown}"
chgrpprog="${CHGRPPROG-chgrp}"
stripprog="${STRIPPROG-strip}"
rmprog="${RMPROG-rm}"
mkdirprog="${MKDIRPROG-mkdir}"
transformbasename=""
transform_arg=""
instcmd="$mvprog"
chmodcmd="$chmodprog 0755"
chowncmd=""
chgrpcmd=""
stripcmd=""
rmcmd="$rmprog -f"
mvcmd="$mvprog"
src=""
dst=""
dir_arg=""
while [ x"$1" != x ]; do
case $1 in
-c) instcmd="$cpprog"
shift
continue;;
-d) dir_arg=true
shift
continue;;
-m) chmodcmd="$chmodprog $2"
shift
shift
continue;;
-o) chowncmd="$chownprog $2"
shift
shift
continue;;
-g) chgrpcmd="$chgrpprog $2"
shift
shift
continue;;
-s) stripcmd="$stripprog"
shift
continue;;
-t=*) transformarg=`echo $1 | sed 's/-t=//'`
shift
continue;;
-b=*) transformbasename=`echo $1 | sed 's/-b=//'`
shift
continue;;
*) if [ x"$src" = x ]
then
src=$1
else
# this colon is to work around a 386BSD /bin/sh bug
:
dst=$1
fi
shift
continue;;
esac
done
if [ x"$src" = x ]
then
echo "install: no input file specified"
exit 1
else
true
fi
if [ x"$dir_arg" != x ]; then
dst=$src
src=""
if [ -d $dst ]; then
instcmd=:
chmodcmd=""
else
instcmd=mkdir
fi
else
# Waiting for this to be detected by the "$instcmd $src $dsttmp" command
# might cause directories to be created, which would be especially bad
# if $src (and thus $dsttmp) contains '*'.
if [ -f $src -o -d $src ]
then
true
else
echo "install: $src does not exist"
exit 1
fi
if [ x"$dst" = x ]
then
echo "install: no destination specified"
exit 1
else
true
fi
# If destination is a directory, append the input filename; if your system
# does not like double slashes in filenames, you may need to add some logic
if [ -d $dst ]
then
dst="$dst"/`basename $src`
else
true
fi
fi
## this sed command emulates the dirname command
dstdir=`echo $dst | sed -e 's,[^/]*$,,;s,/$,,;s,^$,.,'`
# Make sure that the destination directory exists.
# this part is taken from Noah Friedman's mkinstalldirs script
# Skip lots of stat calls in the usual case.
if [ ! -d "$dstdir" ]; then
defaultIFS='
'
IFS="${IFS-${defaultIFS}}"
oIFS="${IFS}"
# Some sh's can't handle IFS=/ for some reason.
IFS='%'
set - `echo ${dstdir} | sed -e 's@/@%@g' -e 's@^%@/@'`
IFS="${oIFS}"
pathcomp=''
while [ $# -ne 0 ] ; do
pathcomp="${pathcomp}${1}"
shift
if [ ! -d "${pathcomp}" ] ;
then
$mkdirprog "${pathcomp}"
else
true
fi
pathcomp="${pathcomp}/"
done
fi
if [ x"$dir_arg" != x ]
then
$doit $instcmd $dst &&
if [ x"$chowncmd" != x ]; then $doit $chowncmd $dst; else true ; fi &&
if [ x"$chgrpcmd" != x ]; then $doit $chgrpcmd $dst; else true ; fi &&
if [ x"$stripcmd" != x ]; then $doit $stripcmd $dst; else true ; fi &&
if [ x"$chmodcmd" != x ]; then $doit $chmodcmd $dst; else true ; fi
else
# If we're going to rename the final executable, determine the name now.
if [ x"$transformarg" = x ]
then
dstfile=`basename $dst`
else
dstfile=`basename $dst $transformbasename |
sed $transformarg`$transformbasename
fi
# don't allow the sed command to completely eliminate the filename
if [ x"$dstfile" = x ]
then
dstfile=`basename $dst`
else
true
fi
# Make a temp file name in the proper directory.
dsttmp=$dstdir/#inst.$$#
# Move or copy the file name to the temp name
$doit $instcmd $src $dsttmp &&
trap "rm -f ${dsttmp}" 0 &&
# and set any options; do chmod last to preserve setuid bits
# If any of these fail, we abort the whole thing. If we want to
# ignore errors from any of these, just make sure not to ignore
# errors from the above "$doit $instcmd $src $dsttmp" command.
if [ x"$chowncmd" != x ]; then $doit $chowncmd $dsttmp; else true;fi &&
if [ x"$chgrpcmd" != x ]; then $doit $chgrpcmd $dsttmp; else true;fi &&
if [ x"$stripcmd" != x ]; then $doit $stripcmd $dsttmp; else true;fi &&
if [ x"$chmodcmd" != x ]; then $doit $chmodcmd $dsttmp; else true;fi &&
# Now rename the file to the real destination.
$doit $rmcmd -f $dstdir/$dstfile &&
$doit $mvcmd $dsttmp $dstdir/$dstfile
fi &&
exit 0

View File

@@ -1,3 +0,0 @@
Makefile
libintl.h
po2tbl.sed

File diff suppressed because it is too large Load Diff

View File

@@ -1,214 +0,0 @@
# Makefile for directory with message catalog handling in GNU NLS Utilities.
# Copyright (C) 1995, 1996, 1997 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.
PACKAGE = @PACKAGE@
VERSION = @VERSION@
SHELL = /bin/sh
srcdir = @srcdir@
top_srcdir = @top_srcdir@
top_builddir = ..
VPATH = @srcdir@
prefix = @prefix@
exec_prefix = @exec_prefix@
transform = @program_transform_name@
libdir = $(exec_prefix)/lib
includedir = $(prefix)/include
datadir = $(prefix)/@DATADIRNAME@
localedir = $(datadir)/locale
gnulocaledir = $(prefix)/share/locale
gettextsrcdir = @datadir@/gettext/intl
aliaspath = $(localedir):.
subdir = intl
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
MKINSTALLDIRS = @MKINSTALLDIRS@
l = @l@
AR = ar
CC = @CC@
LIBTOOL = @LIBTOOL@
RANLIB = @RANLIB@
DEFS = -DLOCALEDIR=\"$(localedir)\" -DGNULOCALEDIR=\"$(gnulocaledir)\" \
-DLOCALE_ALIAS_PATH=\"$(aliaspath)\" @DEFS@
CPPFLAGS = @CPPFLAGS@
CFLAGS = @CFLAGS@
LDFLAGS = @LDFLAGS@
COMPILE = $(CC) -c $(DEFS) $(INCLUDES) $(CPPFLAGS) $(CFLAGS) $(XCFLAGS)
HEADERS = $(COMHDRS) libgettext.h loadinfo.h
COMHDRS = gettext.h gettextP.h hash-string.h
SOURCES = $(COMSRCS) intl-compat.c cat-compat.c
COMSRCS = bindtextdom.c dcgettext.c dgettext.c gettext.c \
finddomain.c loadmsgcat.c localealias.c textdomain.c l10nflist.c \
explodename.c
OBJECTS = @INTLOBJS@ bindtextdom.$lo dcgettext.$lo dgettext.$lo gettext.$lo \
finddomain.$lo loadmsgcat.$lo localealias.$lo textdomain.$lo l10nflist.$lo \
explodename.$lo
CATOBJS = cat-compat.$lo ../po/cat-id-tbl.$lo
GETTOBJS = intl-compat.$lo
DISTFILES.common = ChangeLog Makefile.in linux-msg.sed po2tbl.sed.in \
xopen-msg.sed $(HEADERS) $(SOURCES)
DISTFILES.normal = VERSION
DISTFILES.gettext = libintl.glibc intlh.inst.in
.SUFFIXES:
.SUFFIXES: .c .o .lo
.c.o:
$(COMPILE) $<
.c.lo:
$(LIBTOOL) --mode=compile $(COMPILE) $<
INCLUDES = -I.. -I. -I$(top_srcdir)/intl -I$(top_srcdir)/lib
all: all-@USE_INCLUDED_LIBINTL@
all-yes: libintl.$la intlh.inst
all-no:
libintl.a: $(OBJECTS)
rm -f $@
$(AR) cru $@ $(OBJECTS)
$(RANLIB) $@
libintl.la: $(OBJECTS)
$(LIBTOOL) --mode=link $(CC) $(LDFLAGS) -o $@ $(OBJECTS) \
-version-info 1:0 -rpath $(libdir)
../po/cat-id-tbl.$lo: ../po/cat-id-tbl.c $(top_srcdir)/po/$(PACKAGE).pot
cd ../po && $(MAKE) cat-id-tbl.$lo
check: all
# This installation goal is only used in GNU gettext. Packages which
# only use the library should use install instead.
# We must not install the libintl.h/libintl.a files if we are on a
# system which has the gettext() function in its C library or in a
# separate library or use the catgets interface. A special case is
# where configure found a previously installed GNU gettext library.
# If you want to use the one which comes with this version of the
# package, you have to use `configure --with-included-gettext'.
install: install-exec install-data
install-exec: all
if test "$(PACKAGE)" = "gettext" \
&& test '@INTLOBJS@' = '$(GETTOBJS)'; then \
if test -r $(MKINSTALLDIRS); then \
$(MKINSTALLDIRS) $(libdir) $(includedir); \
else \
$(top_srcdir)/mkinstalldirs $(libdir) $(includedir); \
fi; \
$(INSTALL_DATA) intlh.inst $(includedir)/libintl.h; \
$(INSTALL_DATA) libintl.a $(libdir)/libintl.a; \
else \
: ; \
fi
install-data: all
if test "$(PACKAGE)" = "gettext"; then \
if test -r $(MKINSTALLDIRS); then \
$(MKINSTALLDIRS) $(gettextsrcdir); \
else \
$(top_srcdir)/mkinstalldirs $(gettextsrcdir); \
fi; \
$(INSTALL_DATA) VERSION $(gettextsrcdir)/VERSION; \
dists="$(DISTFILES.common)"; \
for file in $$dists; do \
$(INSTALL_DATA) $(srcdir)/$$file $(gettextsrcdir)/$$file; \
done; \
else \
: ; \
fi
# Define this as empty until I found a useful application.
installcheck:
uninstall:
dists="$(DISTFILES.common)"; \
for file in $$dists; do \
rm -f $(gettextsrcdir)/$$file; \
done
info dvi:
$(OBJECTS): ../config.h libgettext.h
bindtextdom.$lo finddomain.$lo loadmsgcat.$lo: gettextP.h gettext.h loadinfo.h
dcgettext.$lo: gettextP.h gettext.h hash-string.h loadinfo.h
tags: TAGS
TAGS: $(HEADERS) $(SOURCES)
here=`pwd`; cd $(srcdir) && etags -o $$here/TAGS $(HEADERS) $(SOURCES)
id: ID
ID: $(HEADERS) $(SOURCES)
here=`pwd`; cd $(srcdir) && mkid -f$$here/ID $(HEADERS) $(SOURCES)
mostlyclean:
rm -f *.a *.o *.lo core core.*
clean: mostlyclean
distclean: clean
rm -f Makefile ID TAGS po2msg.sed po2tbl.sed libintl.h
maintainer-clean: distclean
@echo "This command is intended for maintainers to use;"
@echo "it deletes files that may require special tools to rebuild."
# GNU gettext needs not contain the file `VERSION' but contains some
# other files which should not be distributed in other packages.
distdir = ../$(PACKAGE)-$(VERSION)/$(subdir)
dist distdir: Makefile $(DISTFILES)
if test "$(PACKAGE)" = gettext; then \
additional="$(DISTFILES.gettext)"; \
else \
additional="$(DISTFILES.normal)"; \
fi; \
for file in $(DISTFILES.common) $$additional; do \
ln $(srcdir)/$$file $(distdir) 2> /dev/null \
|| cp -p $(srcdir)/$$file $(distdir); \
done
dist-libc:
tar zcvf intl-glibc.tar.gz $(COMSRCS) $(COMHDRS) libintl.h.glibc
Makefile: Makefile.in ../config.status
cd .. \
&& CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status
# The dependency for intlh.inst is different in gettext and all other
# packages. Because we cannot you GNU make features we have to solve
# the problem while rewriting Makefile.in.
@GT_YES@intlh.inst: intlh.inst.in ../config.status
@GT_YES@ cd .. \
@GT_YES@ && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= \
@GT_YES@ $(SHELL) ./config.status
@GT_NO@.PHONY: intlh.inst
@GT_NO@intlh.inst:
# Tell versions [3.59,3.63) of GNU make not to export all variables.
# Otherwise a system limit (for SysV at least) may be exceeded.
.NOEXPORT:

View File

@@ -1 +0,0 @@
GNU gettext library from gettext-0.10.35

View File

@@ -1,203 +0,0 @@
/* Implementation of the bindtextdomain(3) function
Copyright (C) 1995, 1996, 1997, 1998 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
#if defined STDC_HEADERS || defined _LIBC
# include <stdlib.h>
#else
# ifdef HAVE_MALLOC_H
# include <malloc.h>
# else
void free ();
# endif
#endif
#if defined HAVE_STRING_H || defined _LIBC
# include <string.h>
#else
# include <strings.h>
# ifndef memcpy
# define memcpy(Dst, Src, Num) bcopy (Src, Dst, Num)
# endif
#endif
#ifdef _LIBC
# include <libintl.h>
#else
# include "libgettext.h"
#endif
#include "gettext.h"
#include "gettextP.h"
/* @@ end of prolog @@ */
/* Contains the default location of the message catalogs. */
extern const char _nl_default_dirname[];
/* List with bindings of specific domains. */
extern struct binding *_nl_domain_bindings;
/* Names for the libintl functions are a problem. They must not clash
with existing names and they should follow ANSI C. But this source
code is also used in GNU C Library where the names have a __
prefix. So we have to make a difference here. */
#ifdef _LIBC
# define BINDTEXTDOMAIN __bindtextdomain
# ifndef strdup
# define strdup(str) __strdup (str)
# endif
#else
# define BINDTEXTDOMAIN bindtextdomain__
#endif
/* Specify that the DOMAINNAME message catalog will be found
in DIRNAME rather than in the system locale data base. */
char *
BINDTEXTDOMAIN (domainname, dirname)
const char *domainname;
const char *dirname;
{
struct binding *binding;
/* Some sanity checks. */
if (domainname == NULL || domainname[0] == '\0')
return NULL;
for (binding = _nl_domain_bindings; binding != NULL; binding = binding->next)
{
int compare = strcmp (domainname, binding->domainname);
if (compare == 0)
/* We found it! */
break;
if (compare < 0)
{
/* It is not in the list. */
binding = NULL;
break;
}
}
if (dirname == NULL)
/* The current binding has be to returned. */
return binding == NULL ? (char *) _nl_default_dirname : binding->dirname;
if (binding != NULL)
{
/* The domain is already bound. If the new value and the old
one are equal we simply do nothing. Otherwise replace the
old binding. */
if (strcmp (dirname, binding->dirname) != 0)
{
char *new_dirname;
if (strcmp (dirname, _nl_default_dirname) == 0)
new_dirname = (char *) _nl_default_dirname;
else
{
#if defined _LIBC || defined HAVE_STRDUP
new_dirname = strdup (dirname);
if (new_dirname == NULL)
return NULL;
#else
size_t len = strlen (dirname) + 1;
new_dirname = (char *) malloc (len);
if (new_dirname == NULL)
return NULL;
memcpy (new_dirname, dirname, len);
#endif
}
if (binding->dirname != _nl_default_dirname)
free (binding->dirname);
binding->dirname = new_dirname;
}
}
else
{
/* We have to create a new binding. */
#if !defined _LIBC && !defined HAVE_STRDUP
size_t len;
#endif
struct binding *new_binding =
(struct binding *) malloc (sizeof (*new_binding));
if (new_binding == NULL)
return NULL;
#if defined _LIBC || defined HAVE_STRDUP
new_binding->domainname = strdup (domainname);
if (new_binding->domainname == NULL)
return NULL;
#else
len = strlen (domainname) + 1;
new_binding->domainname = (char *) malloc (len);
if (new_binding->domainname == NULL)
return NULL;
memcpy (new_binding->domainname, domainname, len);
#endif
if (strcmp (dirname, _nl_default_dirname) == 0)
new_binding->dirname = (char *) _nl_default_dirname;
else
{
#if defined _LIBC || defined HAVE_STRDUP
new_binding->dirname = strdup (dirname);
if (new_binding->dirname == NULL)
return NULL;
#else
len = strlen (dirname) + 1;
new_binding->dirname = (char *) malloc (len);
if (new_binding->dirname == NULL)
return NULL;
memcpy (new_binding->dirname, dirname, len);
#endif
}
/* Now enqueue it. */
if (_nl_domain_bindings == NULL
|| strcmp (domainname, _nl_domain_bindings->domainname) < 0)
{
new_binding->next = _nl_domain_bindings;
_nl_domain_bindings = new_binding;
}
else
{
binding = _nl_domain_bindings;
while (binding->next != NULL
&& strcmp (domainname, binding->next->domainname) > 0)
binding = binding->next;
new_binding->next = binding->next;
binding->next = new_binding;
}
binding = new_binding;
}
return binding->dirname;
}
#ifdef _LIBC
/* Alias for function name in GNU C Library. */
weak_alias (__bindtextdomain, bindtextdomain);
#endif

View File

@@ -1,262 +0,0 @@
/* Compatibility code for gettext-using-catgets interface.
Copyright (C) 1995, 1997 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
#include <stdio.h>
#ifdef STDC_HEADERS
# include <stdlib.h>
# include <string.h>
#else
char *getenv ();
# ifdef HAVE_MALLOC_H
# include <malloc.h>
# endif
#endif
#ifdef HAVE_NL_TYPES_H
# include <nl_types.h>
#endif
#include "libgettext.h"
/* @@ end of prolog @@ */
/* XPG3 defines the result of `setlocale (category, NULL)' as:
``Directs `setlocale()' to query `category' and return the current
setting of `local'.''
However it does not specify the exact format. And even worse: POSIX
defines this not at all. So we can use this feature only on selected
system (e.g. those using GNU C Library). */
#ifdef _LIBC
# define HAVE_LOCALE_NULL
#endif
/* The catalog descriptor. */
static nl_catd catalog = (nl_catd) -1;
/* Name of the default catalog. */
static const char default_catalog_name[] = "messages";
/* Name of currently used catalog. */
static const char *catalog_name = default_catalog_name;
/* Get ID for given string. If not found return -1. */
static int msg_to_cat_id PARAMS ((const char *msg));
/* Substitution for systems lacking this function in their C library. */
#if !_LIBC && !HAVE_STPCPY
static char *stpcpy PARAMS ((char *dest, const char *src));
#endif
/* Set currently used domain/catalog. */
char *
textdomain (domainname)
const char *domainname;
{
nl_catd new_catalog;
char *new_name;
size_t new_name_len;
char *lang;
#if defined HAVE_SETLOCALE && defined HAVE_LC_MESSAGES \
&& defined HAVE_LOCALE_NULL
lang = setlocale (LC_MESSAGES, NULL);
#else
lang = getenv ("LC_ALL");
if (lang == NULL || lang[0] == '\0')
{
lang = getenv ("LC_MESSAGES");
if (lang == NULL || lang[0] == '\0')
lang = getenv ("LANG");
}
#endif
if (lang == NULL || lang[0] == '\0')
lang = "C";
/* See whether name of currently used domain is asked. */
if (domainname == NULL)
return (char *) catalog_name;
if (domainname[0] == '\0')
domainname = default_catalog_name;
/* Compute length of added path element. */
new_name_len = sizeof (LOCALEDIR) - 1 + 1 + strlen (lang)
+ sizeof ("/LC_MESSAGES/") - 1 + sizeof (PACKAGE) - 1
+ sizeof (".cat");
new_name = (char *) malloc (new_name_len);
if (new_name == NULL)
return NULL;
strcpy (new_name, PACKAGE);
new_catalog = catopen (new_name, 0);
if (new_catalog == (nl_catd) -1)
{
/* NLSPATH search didn't work, try absolute path */
sprintf (new_name, "%s/%s/LC_MESSAGES/%s.cat", LOCALEDIR, lang,
PACKAGE);
new_catalog = catopen (new_name, 0);
if (new_catalog == (nl_catd) -1)
{
free (new_name);
return (char *) catalog_name;
}
}
/* Close old catalog. */
if (catalog != (nl_catd) -1)
catclose (catalog);
if (catalog_name != default_catalog_name)
free ((char *) catalog_name);
catalog = new_catalog;
catalog_name = new_name;
return (char *) catalog_name;
}
char *
bindtextdomain (domainname, dirname)
const char *domainname;
const char *dirname;
{
#if HAVE_SETENV || HAVE_PUTENV
char *old_val, *new_val, *cp;
size_t new_val_len;
/* This does not make much sense here but to be compatible do it. */
if (domainname == NULL)
return NULL;
/* Compute length of added path element. If we use setenv we don't need
the first byts for NLSPATH=, but why complicate the code for this
peanuts. */
new_val_len = sizeof ("NLSPATH=") - 1 + strlen (dirname)
+ sizeof ("/%L/LC_MESSAGES/%N.cat");
old_val = getenv ("NLSPATH");
if (old_val == NULL || old_val[0] == '\0')
{
old_val = NULL;
new_val_len += 1 + sizeof (LOCALEDIR) - 1
+ sizeof ("/%L/LC_MESSAGES/%N.cat");
}
else
new_val_len += strlen (old_val);
new_val = (char *) malloc (new_val_len);
if (new_val == NULL)
return NULL;
# if HAVE_SETENV
cp = new_val;
# else
cp = stpcpy (new_val, "NLSPATH=");
# endif
cp = stpcpy (cp, dirname);
cp = stpcpy (cp, "/%L/LC_MESSAGES/%N.cat:");
if (old_val == NULL)
{
# if __STDC__
stpcpy (cp, LOCALEDIR "/%L/LC_MESSAGES/%N.cat");
# else
cp = stpcpy (cp, LOCALEDIR);
stpcpy (cp, "/%L/LC_MESSAGES/%N.cat");
# endif
}
else
stpcpy (cp, old_val);
# if HAVE_SETENV
setenv ("NLSPATH", new_val, 1);
free (new_val);
# else
putenv (new_val);
/* Do *not* free the environment entry we just entered. It is used
from now on. */
# endif
#endif
return (char *) domainname;
}
#undef gettext
char *
gettext (msg)
const char *msg;
{
int msgid;
if (msg == NULL || catalog == (nl_catd) -1)
return (char *) msg;
/* Get the message from the catalog. We always use set number 1.
The message ID is computed by the function `msg_to_cat_id'
which works on the table generated by `po-to-tbl'. */
msgid = msg_to_cat_id (msg);
if (msgid == -1)
return (char *) msg;
return catgets (catalog, 1, msgid, (char *) msg);
}
/* Look through the table `_msg_tbl' which has `_msg_tbl_length' entries
for the one equal to msg. If it is found return the ID. In case when
the string is not found return -1. */
static int
msg_to_cat_id (msg)
const char *msg;
{
int cnt;
for (cnt = 0; cnt < _msg_tbl_length; ++cnt)
if (strcmp (msg, _msg_tbl[cnt]._msg) == 0)
return _msg_tbl[cnt]._msg_number;
return -1;
}
/* @@ begin of epilog @@ */
/* We don't want libintl.a to depend on any other library. So we
avoid the non-standard function stpcpy. In GNU C Library this
function is available, though. Also allow the symbol HAVE_STPCPY
to be defined. */
#if !_LIBC && !HAVE_STPCPY
static char *
stpcpy (dest, src)
char *dest;
const char *src;
{
while ((*dest++ = *src++) != '\0')
/* Do nothing. */ ;
return dest - 1;
}
#endif

View File

@@ -1,655 +0,0 @@
/* Implementation of the dcgettext(3) function.
Copyright (C) 1995, 1996, 1997, 1998 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
#include <sys/types.h>
#if defined __GNUC__ && !defined C_ALLOCA
# define alloca __builtin_alloca
# define HAVE_ALLOCA 1
#else
# if (defined HAVE_ALLOCA_H || defined _LIBC) && !defined C_ALLOCA
# include <alloca.h>
# else
# ifdef _AIX
#pragma alloca
# else
# ifndef alloca
char *alloca ();
# endif
# endif
# endif
#endif
#include <errno.h>
#ifndef errno
extern int errno;
#endif
#ifndef __set_errno
# define __set_errno(val) errno = (val)
#endif
#if defined STDC_HEADERS || defined _LIBC
# include <stdlib.h>
#else
char *getenv ();
# ifdef HAVE_MALLOC_H
# include <malloc.h>
# else
void free ();
# endif
#endif
#if defined HAVE_STRING_H || defined _LIBC
# ifndef _GNU_SOURCE
# define _GNU_SOURCE 1
# endif
# include <string.h>
#else
# include <strings.h>
#endif
#if !HAVE_STRCHR && !defined _LIBC
# ifndef strchr
# define strchr index
# endif
#endif
#if defined HAVE_UNISTD_H || defined _LIBC
# include <unistd.h>
#endif
#include "gettext.h"
#include "gettextP.h"
#ifdef _LIBC
# include <libintl.h>
#else
# include "libgettext.h"
#endif
#include "hash-string.h"
/* @@ end of prolog @@ */
#ifdef _LIBC
/* Rename the non ANSI C functions. This is required by the standard
because some ANSI C functions will require linking with this object
file and the name space must not be polluted. */
# define getcwd __getcwd
# ifndef stpcpy
# define stpcpy __stpcpy
# endif
#else
# if !defined HAVE_GETCWD
char *getwd ();
# define getcwd(buf, max) getwd (buf)
# else
char *getcwd ();
# endif
# ifndef HAVE_STPCPY
static char *stpcpy PARAMS ((char *dest, const char *src));
# endif
#endif
/* Amount to increase buffer size by in each try. */
#define PATH_INCR 32
/* The following is from pathmax.h. */
/* Non-POSIX BSD systems might have gcc's limits.h, which doesn't define
PATH_MAX but might cause redefinition warnings when sys/param.h is
later included (as on MORE/BSD 4.3). */
#if defined(_POSIX_VERSION) || (defined(HAVE_LIMITS_H) && !defined(__GNUC__))
# include <limits.h>
#endif
#ifndef _POSIX_PATH_MAX
# define _POSIX_PATH_MAX 255
#endif
#if !defined(PATH_MAX) && defined(_PC_PATH_MAX)
# define PATH_MAX (pathconf ("/", _PC_PATH_MAX) < 1 ? 1024 : pathconf ("/", _PC_PATH_MAX))
#endif
/* Don't include sys/param.h if it already has been. */
#if defined(HAVE_SYS_PARAM_H) && !defined(PATH_MAX) && !defined(MAXPATHLEN)
# include <sys/param.h>
#endif
#if !defined(PATH_MAX) && defined(MAXPATHLEN)
# define PATH_MAX MAXPATHLEN
#endif
#ifndef PATH_MAX
# define PATH_MAX _POSIX_PATH_MAX
#endif
/* XPG3 defines the result of `setlocale (category, NULL)' as:
``Directs `setlocale()' to query `category' and return the current
setting of `local'.''
However it does not specify the exact format. And even worse: POSIX
defines this not at all. So we can use this feature only on selected
system (e.g. those using GNU C Library). */
#ifdef _LIBC
# define HAVE_LOCALE_NULL
#endif
/* Name of the default domain used for gettext(3) prior any call to
textdomain(3). The default value for this is "messages". */
const char _nl_default_default_domain[] = "messages";
/* Value used as the default domain for gettext(3). */
const char *_nl_current_default_domain = _nl_default_default_domain;
/* Contains the default location of the message catalogs. */
const char _nl_default_dirname[] = GNULOCALEDIR;
/* List with bindings of specific domains created by bindtextdomain()
calls. */
struct binding *_nl_domain_bindings;
/* Prototypes for local functions. */
static char *find_msg PARAMS ((struct loaded_l10nfile *domain_file,
const char *msgid)) internal_function;
static const char *category_to_name PARAMS ((int category)) internal_function;
static const char *guess_category_value PARAMS ((int category,
const char *categoryname))
internal_function;
/* For those loosing systems which don't have `alloca' we have to add
some additional code emulating it. */
#ifdef HAVE_ALLOCA
/* Nothing has to be done. */
# define ADD_BLOCK(list, address) /* nothing */
# define FREE_BLOCKS(list) /* nothing */
#else
struct block_list
{
void *address;
struct block_list *next;
};
# define ADD_BLOCK(list, addr) \
do { \
struct block_list *newp = (struct block_list *) malloc (sizeof (*newp)); \
/* If we cannot get a free block we cannot add the new element to \
the list. */ \
if (newp != NULL) { \
newp->address = (addr); \
newp->next = (list); \
(list) = newp; \
} \
} while (0)
# define FREE_BLOCKS(list) \
do { \
while (list != NULL) { \
struct block_list *old = list; \
list = list->next; \
free (old); \
} \
} while (0)
# undef alloca
# define alloca(size) (malloc (size))
#endif /* have alloca */
/* Names for the libintl functions are a problem. They must not clash
with existing names and they should follow ANSI C. But this source
code is also used in GNU C Library where the names have a __
prefix. So we have to make a difference here. */
#ifdef _LIBC
# define DCGETTEXT __dcgettext
#else
# define DCGETTEXT dcgettext__
#endif
/* Checking whether the binaries runs SUID must be done and glibc provides
easier methods therefore we make a difference here. */
#ifdef _LIBC
# define ENABLE_SECURE __libc_enable_secure
# define DETERMINE_SECURE
#else
static int enable_secure;
# define ENABLE_SECURE (enable_secure == 1)
# define DETERMINE_SECURE \
if (enable_secure == 0) \
{ \
if (getuid () != geteuid () || getgid () != getegid ()) \
enable_secure = 1; \
else \
enable_secure = -1; \
}
#endif
/* Look up MSGID in the DOMAINNAME message catalog for the current CATEGORY
locale. */
char *
DCGETTEXT (domainname, msgid, category)
const char *domainname;
const char *msgid;
int category;
{
#ifndef HAVE_ALLOCA
struct block_list *block_list = NULL;
#endif
struct loaded_l10nfile *domain;
struct binding *binding;
const char *categoryname;
const char *categoryvalue;
char *dirname, *xdomainname;
char *single_locale;
char *retval;
int saved_errno = errno;
/* If no real MSGID is given return NULL. */
if (msgid == NULL)
return NULL;
/* See whether this is a SUID binary or not. */
DETERMINE_SECURE;
/* If DOMAINNAME is NULL, we are interested in the default domain. If
CATEGORY is not LC_MESSAGES this might not make much sense but the
definition left this undefined. */
if (domainname == NULL)
domainname = _nl_current_default_domain;
/* First find matching binding. */
for (binding = _nl_domain_bindings; binding != NULL; binding = binding->next)
{
int compare = strcmp (domainname, binding->domainname);
if (compare == 0)
/* We found it! */
break;
if (compare < 0)
{
/* It is not in the list. */
binding = NULL;
break;
}
}
if (binding == NULL)
dirname = (char *) _nl_default_dirname;
else if (binding->dirname[0] == '/')
dirname = binding->dirname;
else
{
/* We have a relative path. Make it absolute now. */
size_t dirname_len = strlen (binding->dirname) + 1;
size_t path_max;
char *ret;
path_max = (unsigned int) PATH_MAX;
path_max += 2; /* The getcwd docs say to do this. */
dirname = (char *) alloca (path_max + dirname_len);
ADD_BLOCK (block_list, dirname);
__set_errno (0);
while ((ret = getcwd (dirname, path_max)) == NULL && errno == ERANGE)
{
path_max += PATH_INCR;
dirname = (char *) alloca (path_max + dirname_len);
ADD_BLOCK (block_list, dirname);
__set_errno (0);
}
if (ret == NULL)
{
/* We cannot get the current working directory. Don't signal an
error but simply return the default string. */
FREE_BLOCKS (block_list);
__set_errno (saved_errno);
return (char *) msgid;
}
stpcpy (stpcpy (strchr (dirname, '\0'), "/"), binding->dirname);
}
/* Now determine the symbolic name of CATEGORY and its value. */
categoryname = category_to_name (category);
categoryvalue = guess_category_value (category, categoryname);
xdomainname = (char *) alloca (strlen (categoryname)
+ strlen (domainname) + 5);
ADD_BLOCK (block_list, xdomainname);
stpcpy (stpcpy (stpcpy (stpcpy (xdomainname, categoryname), "/"),
domainname),
".mo");
/* Creating working area. */
single_locale = (char *) alloca (strlen (categoryvalue) + 1);
ADD_BLOCK (block_list, single_locale);
/* Search for the given string. This is a loop because we perhaps
got an ordered list of languages to consider for the translation. */
while (1)
{
/* Make CATEGORYVALUE point to the next element of the list. */
while (categoryvalue[0] != '\0' && categoryvalue[0] == ':')
++categoryvalue;
if (categoryvalue[0] == '\0')
{
/* The whole contents of CATEGORYVALUE has been searched but
no valid entry has been found. We solve this situation
by implicitly appending a "C" entry, i.e. no translation
will take place. */
single_locale[0] = 'C';
single_locale[1] = '\0';
}
else
{
char *cp = single_locale;
while (categoryvalue[0] != '\0' && categoryvalue[0] != ':')
*cp++ = *categoryvalue++;
*cp = '\0';
/* When this is a SUID binary we must not allow accessing files
outside the dedicated directories. */
if (ENABLE_SECURE
&& (memchr (single_locale, '/',
_nl_find_language (single_locale) - single_locale)
!= NULL))
/* Ingore this entry. */
continue;
}
/* If the current locale value is C (or POSIX) we don't load a
domain. Return the MSGID. */
if (strcmp (single_locale, "C") == 0
|| strcmp (single_locale, "POSIX") == 0)
{
FREE_BLOCKS (block_list);
__set_errno (saved_errno);
return (char *) msgid;
}
/* Find structure describing the message catalog matching the
DOMAINNAME and CATEGORY. */
domain = _nl_find_domain (dirname, single_locale, xdomainname);
if (domain != NULL)
{
retval = find_msg (domain, msgid);
if (retval == NULL)
{
int cnt;
for (cnt = 0; domain->successor[cnt] != NULL; ++cnt)
{
retval = find_msg (domain->successor[cnt], msgid);
if (retval != NULL)
break;
}
}
if (retval != NULL)
{
FREE_BLOCKS (block_list);
__set_errno (saved_errno);
return retval;
}
}
}
/* NOTREACHED */
}
#ifdef _LIBC
/* Alias for function name in GNU C Library. */
weak_alias (__dcgettext, dcgettext);
#endif
static char *
internal_function
find_msg (domain_file, msgid)
struct loaded_l10nfile *domain_file;
const char *msgid;
{
size_t act = 0;
size_t top, bottom;
struct loaded_domain *domain;
if (domain_file->decided == 0)
_nl_load_domain (domain_file);
if (domain_file->data == NULL)
return NULL;
domain = (struct loaded_domain *) domain_file->data;
/* Locate the MSGID and its translation. */
if (domain->hash_size > 2 && domain->hash_tab != NULL)
{
/* Use the hashing table. */
nls_uint32 len = strlen (msgid);
nls_uint32 hash_val = hash_string (msgid);
nls_uint32 idx = hash_val % domain->hash_size;
nls_uint32 incr = 1 + (hash_val % (domain->hash_size - 2));
nls_uint32 nstr = W (domain->must_swap, domain->hash_tab[idx]);
if (nstr == 0)
/* Hash table entry is empty. */
return NULL;
if (W (domain->must_swap, domain->orig_tab[nstr - 1].length) == len
&& strcmp (msgid,
domain->data + W (domain->must_swap,
domain->orig_tab[nstr - 1].offset)) == 0)
return (char *) domain->data + W (domain->must_swap,
domain->trans_tab[nstr - 1].offset);
while (1)
{
if (idx >= domain->hash_size - incr)
idx -= domain->hash_size - incr;
else
idx += incr;
nstr = W (domain->must_swap, domain->hash_tab[idx]);
if (nstr == 0)
/* Hash table entry is empty. */
return NULL;
if (W (domain->must_swap, domain->orig_tab[nstr - 1].length) == len
&& strcmp (msgid,
domain->data + W (domain->must_swap,
domain->orig_tab[nstr - 1].offset))
== 0)
return (char *) domain->data
+ W (domain->must_swap, domain->trans_tab[nstr - 1].offset);
}
/* NOTREACHED */
}
/* Now we try the default method: binary search in the sorted
array of messages. */
bottom = 0;
top = domain->nstrings;
while (bottom < top)
{
int cmp_val;
act = (bottom + top) / 2;
cmp_val = strcmp (msgid, domain->data
+ W (domain->must_swap,
domain->orig_tab[act].offset));
if (cmp_val < 0)
top = act;
else if (cmp_val > 0)
bottom = act + 1;
else
break;
}
/* If an translation is found return this. */
return bottom >= top ? NULL : (char *) domain->data
+ W (domain->must_swap,
domain->trans_tab[act].offset);
}
/* Return string representation of locale CATEGORY. */
static const char *
internal_function
category_to_name (category)
int category;
{
const char *retval;
switch (category)
{
#ifdef LC_COLLATE
case LC_COLLATE:
retval = "LC_COLLATE";
break;
#endif
#ifdef LC_CTYPE
case LC_CTYPE:
retval = "LC_CTYPE";
break;
#endif
#ifdef LC_MONETARY
case LC_MONETARY:
retval = "LC_MONETARY";
break;
#endif
#ifdef LC_NUMERIC
case LC_NUMERIC:
retval = "LC_NUMERIC";
break;
#endif
#ifdef LC_TIME
case LC_TIME:
retval = "LC_TIME";
break;
#endif
#ifdef LC_MESSAGES
case LC_MESSAGES:
retval = "LC_MESSAGES";
break;
#endif
#ifdef LC_RESPONSE
case LC_RESPONSE:
retval = "LC_RESPONSE";
break;
#endif
#ifdef LC_ALL
case LC_ALL:
/* This might not make sense but is perhaps better than any other
value. */
retval = "LC_ALL";
break;
#endif
default:
/* If you have a better idea for a default value let me know. */
retval = "LC_XXX";
}
return retval;
}
/* Guess value of current locale from value of the environment variables. */
static const char *
internal_function
guess_category_value (category, categoryname)
int category;
const char *categoryname;
{
const char *retval;
/* The highest priority value is the `LANGUAGE' environment
variable. This is a GNU extension. */
retval = getenv ("LANGUAGE");
if (retval != NULL && retval[0] != '\0')
return retval;
/* `LANGUAGE' is not set. So we have to proceed with the POSIX
methods of looking to `LC_ALL', `LC_xxx', and `LANG'. On some
systems this can be done by the `setlocale' function itself. */
#if defined HAVE_SETLOCALE && defined HAVE_LC_MESSAGES && defined HAVE_LOCALE_NULL
return setlocale (category, NULL);
#else
/* Setting of LC_ALL overwrites all other. */
retval = getenv ("LC_ALL");
if (retval != NULL && retval[0] != '\0')
return retval;
/* Next comes the name of the desired category. */
retval = getenv (categoryname);
if (retval != NULL && retval[0] != '\0')
return retval;
/* Last possibility is the LANG environment variable. */
retval = getenv ("LANG");
if (retval != NULL && retval[0] != '\0')
return retval;
/* We use C as the default domain. POSIX says this is implementation
defined. */
return "C";
#endif
}
/* @@ begin of epilog @@ */
/* We don't want libintl.a to depend on any other library. So we
avoid the non-standard function stpcpy. In GNU C Library this
function is available, though. Also allow the symbol HAVE_STPCPY
to be defined. */
#if !_LIBC && !HAVE_STPCPY
static char *
stpcpy (dest, src)
char *dest;
const char *src;
{
while ((*dest++ = *src++) != '\0')
/* Do nothing. */ ;
return dest - 1;
}
#endif
#ifdef _LIBC
/* If we want to free all resources we have to do some work at
program's end. */
static void __attribute__ ((unused))
free_mem (void)
{
struct binding *runp;
for (runp = _nl_domain_bindings; runp != NULL; runp = runp->next)
{
free (runp->domainname);
if (runp->dirname != _nl_default_dirname)
/* Yes, this is a pointer comparison. */
free (runp->dirname);
}
if (_nl_current_default_domain != _nl_default_default_domain)
/* Yes, again a pointer comparison. */
free ((char *) _nl_current_default_domain);
}
text_set_element (__libc_subfreeres, free_mem);
#endif

View File

@@ -1,59 +0,0 @@
/* Implementation of the dgettext(3) function
Copyright (C) 1995, 1996, 1997 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
#if defined HAVE_LOCALE_H || defined _LIBC
# include <locale.h>
#endif
#ifdef _LIBC
# include <libintl.h>
#else
# include "libgettext.h"
#endif
/* @@ end of prolog @@ */
/* Names for the libintl functions are a problem. They must not clash
with existing names and they should follow ANSI C. But this source
code is also used in GNU C Library where the names have a __
prefix. So we have to make a difference here. */
#ifdef _LIBC
# define DGETTEXT __dgettext
# define DCGETTEXT __dcgettext
#else
# define DGETTEXT dgettext__
# define DCGETTEXT dcgettext__
#endif
/* Look up MSGID in the DOMAINNAME message catalog of the current
LC_MESSAGES locale. */
char *
DGETTEXT (domainname, msgid)
const char *domainname;
const char *msgid;
{
return DCGETTEXT (domainname, msgid, LC_MESSAGES);
}
#ifdef _LIBC
/* Alias for function name in GNU C Library. */
weak_alias (__dgettext, dgettext);
#endif

View File

@@ -1,198 +0,0 @@
/* Copyright (C) 1995, 1996, 1997, 1998 Free Software Foundation, Inc.
Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1995.
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
#if defined STDC_HEADERS || defined _LIBC
# include <stdlib.h>
#endif
#if defined HAVE_STRING_H || defined _LIBC
# include <string.h>
#else
# include <strings.h>
#endif
#include <sys/types.h>
#include "loadinfo.h"
/* On some strange systems still no definition of NULL is found. Sigh! */
#ifndef NULL
# if defined __STDC__ && __STDC__
# define NULL ((void *) 0)
# else
# define NULL 0
# endif
#endif
/* @@ end of prolog @@ */
char *
_nl_find_language (name)
const char *name;
{
while (name[0] != '\0' && name[0] != '_' && name[0] != '@'
&& name[0] != '+' && name[0] != ',')
++name;
return (char *) name;
}
int
_nl_explode_name (name, language, modifier, territory, codeset,
normalized_codeset, special, sponsor, revision)
char *name;
const char **language;
const char **modifier;
const char **territory;
const char **codeset;
const char **normalized_codeset;
const char **special;
const char **sponsor;
const char **revision;
{
enum { undecided, xpg, cen } syntax;
char *cp;
int mask;
*modifier = NULL;
*territory = NULL;
*codeset = NULL;
*normalized_codeset = NULL;
*special = NULL;
*sponsor = NULL;
*revision = NULL;
/* Now we determine the single parts of the locale name. First
look for the language. Termination symbols are `_' and `@' if
we use XPG4 style, and `_', `+', and `,' if we use CEN syntax. */
mask = 0;
syntax = undecided;
*language = cp = name;
cp = _nl_find_language (*language);
if (*language == cp)
/* This does not make sense: language has to be specified. Use
this entry as it is without exploding. Perhaps it is an alias. */
cp = strchr (*language, '\0');
else if (cp[0] == '_')
{
/* Next is the territory. */
cp[0] = '\0';
*territory = ++cp;
while (cp[0] != '\0' && cp[0] != '.' && cp[0] != '@'
&& cp[0] != '+' && cp[0] != ',' && cp[0] != '_')
++cp;
mask |= TERRITORY;
if (cp[0] == '.')
{
/* Next is the codeset. */
syntax = xpg;
cp[0] = '\0';
*codeset = ++cp;
while (cp[0] != '\0' && cp[0] != '@')
++cp;
mask |= XPG_CODESET;
if (*codeset != cp && (*codeset)[0] != '\0')
{
*normalized_codeset = _nl_normalize_codeset (*codeset,
cp - *codeset);
if (strcmp (*codeset, *normalized_codeset) == 0)
free ((char *) *normalized_codeset);
else
mask |= XPG_NORM_CODESET;
}
}
}
if (cp[0] == '@' || (syntax != xpg && cp[0] == '+'))
{
/* Next is the modifier. */
syntax = cp[0] == '@' ? xpg : cen;
cp[0] = '\0';
*modifier = ++cp;
while (syntax == cen && cp[0] != '\0' && cp[0] != '+'
&& cp[0] != ',' && cp[0] != '_')
++cp;
mask |= XPG_MODIFIER | CEN_AUDIENCE;
}
if (syntax != xpg && (cp[0] == '+' || cp[0] == ',' || cp[0] == '_'))
{
syntax = cen;
if (cp[0] == '+')
{
/* Next is special application (CEN syntax). */
cp[0] = '\0';
*special = ++cp;
while (cp[0] != '\0' && cp[0] != ',' && cp[0] != '_')
++cp;
mask |= CEN_SPECIAL;
}
if (cp[0] == ',')
{
/* Next is sponsor (CEN syntax). */
cp[0] = '\0';
*sponsor = ++cp;
while (cp[0] != '\0' && cp[0] != '_')
++cp;
mask |= CEN_SPONSOR;
}
if (cp[0] == '_')
{
/* Next is revision (CEN syntax). */
cp[0] = '\0';
*revision = ++cp;
mask |= CEN_REVISION;
}
}
/* For CEN syntax values it might be important to have the
separator character in the file name, not for XPG syntax. */
if (syntax == xpg)
{
if (*territory != NULL && (*territory)[0] == '\0')
mask &= ~TERRITORY;
if (*codeset != NULL && (*codeset)[0] == '\0')
mask &= ~XPG_CODESET;
if (*modifier != NULL && (*modifier)[0] == '\0')
mask &= ~XPG_MODIFIER;
}
return mask;
}

View File

@@ -1,216 +0,0 @@
/* Handle list of needed message catalogs
Copyright (C) 1995, 1996, 1997, 1998 Free Software Foundation, Inc.
Written by Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1995.
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
#include <ctype.h>
#include <errno.h>
#include <stdio.h>
#include <sys/types.h>
#if defined STDC_HEADERS || defined _LIBC
# include <stdlib.h>
#else
# ifdef HAVE_MALLOC_H
# include <malloc.h>
# else
void free ();
# endif
#endif
#if defined HAVE_STRING_H || defined _LIBC
# include <string.h>
#else
# include <strings.h>
# ifndef memcpy
# define memcpy(Dst, Src, Num) bcopy (Src, Dst, Num)
# endif
#endif
#if !HAVE_STRCHR && !defined _LIBC
# ifndef strchr
# define strchr index
# endif
#endif
#if defined HAVE_UNISTD_H || defined _LIBC
# include <unistd.h>
#endif
#include "gettext.h"
#include "gettextP.h"
#ifdef _LIBC
# include <libintl.h>
#else
# include "libgettext.h"
#endif
/* @@ end of prolog @@ */
/* List of already loaded domains. */
static struct loaded_l10nfile *_nl_loaded_domains;
/* Return a data structure describing the message catalog described by
the DOMAINNAME and CATEGORY parameters with respect to the currently
established bindings. */
struct loaded_l10nfile *
internal_function
_nl_find_domain (dirname, locale, domainname)
const char *dirname;
char *locale;
const char *domainname;
{
struct loaded_l10nfile *retval;
const char *language;
const char *modifier;
const char *territory;
const char *codeset;
const char *normalized_codeset;
const char *special;
const char *sponsor;
const char *revision;
const char *alias_value;
int mask;
/* LOCALE can consist of up to four recognized parts for the XPG syntax:
language[_territory[.codeset]][@modifier]
and six parts for the CEN syntax:
language[_territory][+audience][+special][,[sponsor][_revision]]
Beside the first part all of them are allowed to be missing. If
the full specified locale is not found, the less specific one are
looked for. The various parts will be stripped off according to
the following order:
(1) revision
(2) sponsor
(3) special
(4) codeset
(5) normalized codeset
(6) territory
(7) audience/modifier
*/
/* If we have already tested for this locale entry there has to
be one data set in the list of loaded domains. */
retval = _nl_make_l10nflist (&_nl_loaded_domains, dirname,
strlen (dirname) + 1, 0, locale, NULL, NULL,
NULL, NULL, NULL, NULL, NULL, domainname, 0);
if (retval != NULL)
{
/* We know something about this locale. */
int cnt;
if (retval->decided == 0)
_nl_load_domain (retval);
if (retval->data != NULL)
return retval;
for (cnt = 0; retval->successor[cnt] != NULL; ++cnt)
{
if (retval->successor[cnt]->decided == 0)
_nl_load_domain (retval->successor[cnt]);
if (retval->successor[cnt]->data != NULL)
break;
}
return cnt >= 0 ? retval : NULL;
/* NOTREACHED */
}
/* See whether the locale value is an alias. If yes its value
*overwrites* the alias name. No test for the original value is
done. */
alias_value = _nl_expand_alias (locale);
if (alias_value != NULL)
{
#if defined _LIBC || defined HAVE_STRDUP
locale = strdup (alias_value);
if (locale == NULL)
return NULL;
#else
size_t len = strlen (alias_value) + 1;
locale = (char *) malloc (len);
if (locale == NULL)
return NULL;
memcpy (locale, alias_value, len);
#endif
}
/* Now we determine the single parts of the locale name. First
look for the language. Termination symbols are `_' and `@' if
we use XPG4 style, and `_', `+', and `,' if we use CEN syntax. */
mask = _nl_explode_name (locale, &language, &modifier, &territory,
&codeset, &normalized_codeset, &special,
&sponsor, &revision);
/* Create all possible locale entries which might be interested in
generalization. */
retval = _nl_make_l10nflist (&_nl_loaded_domains, dirname,
strlen (dirname) + 1, mask, language, territory,
codeset, normalized_codeset, modifier, special,
sponsor, revision, domainname, 1);
if (retval == NULL)
/* This means we are out of core. */
return NULL;
if (retval->decided == 0)
_nl_load_domain (retval);
if (retval->data == NULL)
{
int cnt;
for (cnt = 0; retval->successor[cnt] != NULL; ++cnt)
{
if (retval->successor[cnt]->decided == 0)
_nl_load_domain (retval->successor[cnt]);
if (retval->successor[cnt]->data != NULL)
break;
}
}
/* The room for an alias was dynamically allocated. Free it now. */
if (alias_value != NULL)
free (locale);
return retval;
}
#ifdef _LIBC
static void __attribute__ ((unused))
free_mem (void)
{
struct loaded_l10nfile *runp = _nl_loaded_domains;
while (runp != NULL)
{
struct loaded_l10nfile *here = runp;
if (runp->data != NULL)
_nl_unload_domain ((struct loaded_domain *) runp->data);
runp = runp->next;
free (here);
}
}
text_set_element (__libc_subfreeres, free_mem);
#endif

View File

@@ -1,70 +0,0 @@
/* Implementation of gettext(3) function.
Copyright (C) 1995, 1997 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
#ifdef _LIBC
# define __need_NULL
# include <stddef.h>
#else
# ifdef STDC_HEADERS
# include <stdlib.h> /* Just for NULL. */
# else
# ifdef HAVE_STRING_H
# include <string.h>
# else
# define NULL ((void *) 0)
# endif
# endif
#endif
#ifdef _LIBC
# include <libintl.h>
#else
# include "libgettext.h"
#endif
/* @@ end of prolog @@ */
/* Names for the libintl functions are a problem. They must not clash
with existing names and they should follow ANSI C. But this source
code is also used in GNU C Library where the names have a __
prefix. So we have to make a difference here. */
#ifdef _LIBC
# define GETTEXT __gettext
# define DGETTEXT __dgettext
#else
# define GETTEXT gettext__
# define DGETTEXT dgettext__
#endif
/* Look up MSGID in the current default message catalog for the current
LC_MESSAGES locale. If not found, returns MSGID itself (the default
text). */
char *
GETTEXT (msgid)
const char *msgid;
{
return DGETTEXT (NULL, msgid);
}
#ifdef _LIBC
/* Alias for function name in GNU C Library. */
weak_alias (__gettext, gettext);
#endif

View File

@@ -1,105 +0,0 @@
/* Internal header for GNU gettext internationalization functions.
Copyright (C) 1995, 1997 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 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 _GETTEXT_H
#define _GETTEXT_H 1
#include <stdio.h>
#if HAVE_LIMITS_H || _LIBC
# include <limits.h>
#endif
/* @@ end of prolog @@ */
/* The magic number of the GNU message catalog format. */
#define _MAGIC 0x950412de
#define _MAGIC_SWAPPED 0xde120495
/* Revision number of the currently used .mo (binary) file format. */
#define MO_REVISION_NUMBER 0
/* The following contortions are an attempt to use the C preprocessor
to determine an unsigned integral type that is 32 bits wide. An
alternative approach is to use autoconf's AC_CHECK_SIZEOF macro, but
doing that would require that the configure script compile and *run*
the resulting executable. Locally running cross-compiled executables
is usually not possible. */
#if __STDC__
# define UINT_MAX_32_BITS 4294967295U
#else
# define UINT_MAX_32_BITS 0xFFFFFFFF
#endif
/* If UINT_MAX isn't defined, assume it's a 32-bit type.
This should be valid for all systems GNU cares about because
that doesn't include 16-bit systems, and only modern systems
(that certainly have <limits.h>) have 64+-bit integral types. */
#ifndef UINT_MAX
# define UINT_MAX UINT_MAX_32_BITS
#endif
#if UINT_MAX == UINT_MAX_32_BITS
typedef unsigned nls_uint32;
#else
# if USHRT_MAX == UINT_MAX_32_BITS
typedef unsigned short nls_uint32;
# else
# if ULONG_MAX == UINT_MAX_32_BITS
typedef unsigned long nls_uint32;
# else
/* The following line is intended to throw an error. Using #error is
not portable enough. */
"Cannot determine unsigned 32-bit data type."
# endif
# endif
#endif
/* Header for binary .mo file format. */
struct mo_file_header
{
/* The magic number. */
nls_uint32 magic;
/* The revision number of the file format. */
nls_uint32 revision;
/* The number of strings pairs. */
nls_uint32 nstrings;
/* Offset of table with start offsets of original strings. */
nls_uint32 orig_tab_offset;
/* Offset of table with start offsets of translation strings. */
nls_uint32 trans_tab_offset;
/* Size of hashing table. */
nls_uint32 hash_tab_size;
/* Offset of first hashing entry. */
nls_uint32 hash_tab_offset;
};
struct string_desc
{
/* Length of addressed string. */
nls_uint32 length;
/* Offset of string in file. */
nls_uint32 offset;
};
/* @@ begin of epilog @@ */
#endif /* gettext.h */

View File

@@ -1,89 +0,0 @@
/* Header describing internals of gettext library
Copyright (C) 1995, 1996, 1997, 1998 Free Software Foundation, Inc.
Written by Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1995.
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. */
#ifndef _GETTEXTP_H
#define _GETTEXTP_H
#include "loadinfo.h"
/* @@ end of prolog @@ */
#ifndef PARAMS
# if __STDC__
# define PARAMS(args) args
# else
# define PARAMS(args) ()
# endif
#endif
#ifndef internal_function
# define internal_function
#endif
#ifndef W
# define W(flag, data) ((flag) ? SWAP (data) : (data))
#endif
#ifdef _LIBC
# include <byteswap.h>
# define SWAP(i) bswap_32 (i)
#else
static nls_uint32 SWAP PARAMS ((nls_uint32 i));
static inline nls_uint32
SWAP (i)
nls_uint32 i;
{
return (i << 24) | ((i & 0xff00) << 8) | ((i >> 8) & 0xff00) | (i >> 24);
}
#endif
struct loaded_domain
{
const char *data;
int use_mmap;
size_t mmap_size;
int must_swap;
nls_uint32 nstrings;
struct string_desc *orig_tab;
struct string_desc *trans_tab;
nls_uint32 hash_size;
nls_uint32 *hash_tab;
};
struct binding
{
struct binding *next;
char *domainname;
char *dirname;
};
struct loaded_l10nfile *_nl_find_domain PARAMS ((const char *__dirname,
char *__locale,
const char *__domainname))
internal_function;
void _nl_load_domain PARAMS ((struct loaded_l10nfile *__domain))
internal_function;
void _nl_unload_domain PARAMS ((struct loaded_domain *__domain))
internal_function;
/* @@ begin of epilog @@ */
#endif /* gettextP.h */

View File

@@ -1,59 +0,0 @@
/* Implements a string hashing function.
Copyright (C) 1995, 1997 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 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. */
/* @@ end of prolog @@ */
#ifndef PARAMS
# if __STDC__
# define PARAMS(Args) Args
# else
# define PARAMS(Args) ()
# endif
#endif
/* We assume to have `unsigned long int' value with at least 32 bits. */
#define HASHWORDBITS 32
/* Defines the so called `hashpjw' function by P.J. Weinberger
[see Aho/Sethi/Ullman, COMPILERS: Principles, Techniques and Tools,
1986, 1987 Bell Telephone Laboratories, Inc.] */
static unsigned long int hash_string PARAMS ((const char *__str_param));
static inline unsigned long int
hash_string (str_param)
const char *str_param;
{
unsigned long int hval, g;
const char *str = str_param;
/* Compute the hash value for the given string. */
hval = 0;
while (*str != '\0')
{
hval <<= 4;
hval += (unsigned long int) *str++;
g = hval & ((unsigned long int) 0xf << (HASHWORDBITS - 4));
if (g != 0)
{
hval ^= g >> (HASHWORDBITS - 8);
hval ^= g;
}
}
return hval;
}

View File

@@ -1,76 +0,0 @@
/* intl-compat.c - Stub functions to call gettext functions from GNU gettext
Library.
Copyright (C) 1995 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
#include "libgettext.h"
/* @@ end of prolog @@ */
#undef gettext
#undef dgettext
#undef dcgettext
#undef textdomain
#undef bindtextdomain
char *
bindtextdomain (domainname, dirname)
const char *domainname;
const char *dirname;
{
return bindtextdomain__ (domainname, dirname);
}
char *
dcgettext (domainname, msgid, category)
const char *domainname;
const char *msgid;
int category;
{
return dcgettext__ (domainname, msgid, category);
}
char *
dgettext (domainname, msgid)
const char *domainname;
const char *msgid;
{
return dgettext__ (domainname, msgid);
}
char *
gettext (msgid)
const char *msgid;
{
return gettext__ (msgid);
}
char *
textdomain (domainname)
const char *domainname;
{
return textdomain__ (domainname);
}

View File

@@ -1,411 +0,0 @@
/* Handle list of needed message catalogs
Copyright (C) 1995, 1996, 1997 Free Software Foundation, Inc.
Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1995.
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
#if defined HAVE_STRING_H || defined _LIBC
# ifndef _GNU_SOURCE
# define _GNU_SOURCE 1
# endif
# include <string.h>
#else
# include <strings.h>
# ifndef memcpy
# define memcpy(Dst, Src, Num) bcopy (Src, Dst, Num)
# endif
#endif
#if !HAVE_STRCHR && !defined _LIBC
# ifndef strchr
# define strchr index
# endif
#endif
#if defined _LIBC || defined HAVE_ARGZ_H
# include <argz.h>
#endif
#include <ctype.h>
#include <sys/types.h>
#if defined STDC_HEADERS || defined _LIBC
# include <stdlib.h>
#endif
#include "loadinfo.h"
/* On some strange systems still no definition of NULL is found. Sigh! */
#ifndef NULL
# if defined __STDC__ && __STDC__
# define NULL ((void *) 0)
# else
# define NULL 0
# endif
#endif
/* @@ end of prolog @@ */
#ifdef _LIBC
/* Rename the non ANSI C functions. This is required by the standard
because some ANSI C functions will require linking with this object
file and the name space must not be polluted. */
# ifndef stpcpy
# define stpcpy(dest, src) __stpcpy(dest, src)
# endif
#else
# ifndef HAVE_STPCPY
static char *stpcpy PARAMS ((char *dest, const char *src));
# endif
#endif
/* Define function which are usually not available. */
#if !defined _LIBC && !defined HAVE___ARGZ_COUNT
/* Returns the number of strings in ARGZ. */
static size_t argz_count__ PARAMS ((const char *argz, size_t len));
static size_t
argz_count__ (argz, len)
const char *argz;
size_t len;
{
size_t count = 0;
while (len > 0)
{
size_t part_len = strlen (argz);
argz += part_len + 1;
len -= part_len + 1;
count++;
}
return count;
}
# undef __argz_count
# define __argz_count(argz, len) argz_count__ (argz, len)
#endif /* !_LIBC && !HAVE___ARGZ_COUNT */
#if !defined _LIBC && !defined HAVE___ARGZ_STRINGIFY
/* Make '\0' separated arg vector ARGZ printable by converting all the '\0's
except the last into the character SEP. */
static void argz_stringify__ PARAMS ((char *argz, size_t len, int sep));
static void
argz_stringify__ (argz, len, sep)
char *argz;
size_t len;
int sep;
{
while (len > 0)
{
size_t part_len = strlen (argz);
argz += part_len;
len -= part_len + 1;
if (len > 0)
*argz++ = sep;
}
}
# undef __argz_stringify
# define __argz_stringify(argz, len, sep) argz_stringify__ (argz, len, sep)
#endif /* !_LIBC && !HAVE___ARGZ_STRINGIFY */
#if !defined _LIBC && !defined HAVE___ARGZ_NEXT
static char *argz_next__ PARAMS ((char *argz, size_t argz_len,
const char *entry));
static char *
argz_next__ (argz, argz_len, entry)
char *argz;
size_t argz_len;
const char *entry;
{
if (entry)
{
if (entry < argz + argz_len)
entry = strchr (entry, '\0') + 1;
return entry >= argz + argz_len ? NULL : (char *) entry;
}
else
if (argz_len > 0)
return argz;
else
return 0;
}
# undef __argz_next
# define __argz_next(argz, len, entry) argz_next__ (argz, len, entry)
#endif /* !_LIBC && !HAVE___ARGZ_NEXT */
/* Return number of bits set in X. */
static int pop PARAMS ((int x));
static inline int
pop (x)
int x;
{
/* We assume that no more than 16 bits are used. */
x = ((x & ~0x5555) >> 1) + (x & 0x5555);
x = ((x & ~0x3333) >> 2) + (x & 0x3333);
x = ((x >> 4) + x) & 0x0f0f;
x = ((x >> 8) + x) & 0xff;
return x;
}
struct loaded_l10nfile *
_nl_make_l10nflist (l10nfile_list, dirlist, dirlist_len, mask, language,
territory, codeset, normalized_codeset, modifier, special,
sponsor, revision, filename, do_allocate)
struct loaded_l10nfile **l10nfile_list;
const char *dirlist;
size_t dirlist_len;
int mask;
const char *language;
const char *territory;
const char *codeset;
const char *normalized_codeset;
const char *modifier;
const char *special;
const char *sponsor;
const char *revision;
const char *filename;
int do_allocate;
{
char *abs_filename;
struct loaded_l10nfile *last = NULL;
struct loaded_l10nfile *retval;
char *cp;
size_t entries;
int cnt;
/* Allocate room for the full file name. */
abs_filename = (char *) malloc (dirlist_len
+ strlen (language)
+ ((mask & TERRITORY) != 0
? strlen (territory) + 1 : 0)
+ ((mask & XPG_CODESET) != 0
? strlen (codeset) + 1 : 0)
+ ((mask & XPG_NORM_CODESET) != 0
? strlen (normalized_codeset) + 1 : 0)
+ (((mask & XPG_MODIFIER) != 0
|| (mask & CEN_AUDIENCE) != 0)
? strlen (modifier) + 1 : 0)
+ ((mask & CEN_SPECIAL) != 0
? strlen (special) + 1 : 0)
+ (((mask & CEN_SPONSOR) != 0
|| (mask & CEN_REVISION) != 0)
? (1 + ((mask & CEN_SPONSOR) != 0
? strlen (sponsor) + 1 : 0)
+ ((mask & CEN_REVISION) != 0
? strlen (revision) + 1 : 0)) : 0)
+ 1 + strlen (filename) + 1);
if (abs_filename == NULL)
return NULL;
retval = NULL;
last = NULL;
/* Construct file name. */
memcpy (abs_filename, dirlist, dirlist_len);
__argz_stringify (abs_filename, dirlist_len, ':');
cp = abs_filename + (dirlist_len - 1);
*cp++ = '/';
cp = stpcpy (cp, language);
if ((mask & TERRITORY) != 0)
{
*cp++ = '_';
cp = stpcpy (cp, territory);
}
if ((mask & XPG_CODESET) != 0)
{
*cp++ = '.';
cp = stpcpy (cp, codeset);
}
if ((mask & XPG_NORM_CODESET) != 0)
{
*cp++ = '.';
cp = stpcpy (cp, normalized_codeset);
}
if ((mask & (XPG_MODIFIER | CEN_AUDIENCE)) != 0)
{
/* This component can be part of both syntaces but has different
leading characters. For CEN we use `+', else `@'. */
*cp++ = (mask & CEN_AUDIENCE) != 0 ? '+' : '@';
cp = stpcpy (cp, modifier);
}
if ((mask & CEN_SPECIAL) != 0)
{
*cp++ = '+';
cp = stpcpy (cp, special);
}
if ((mask & (CEN_SPONSOR | CEN_REVISION)) != 0)
{
*cp++ = ',';
if ((mask & CEN_SPONSOR) != 0)
cp = stpcpy (cp, sponsor);
if ((mask & CEN_REVISION) != 0)
{
*cp++ = '_';
cp = stpcpy (cp, revision);
}
}
*cp++ = '/';
stpcpy (cp, filename);
/* Look in list of already loaded domains whether it is already
available. */
last = NULL;
for (retval = *l10nfile_list; retval != NULL; retval = retval->next)
if (retval->filename != NULL)
{
int compare = strcmp (retval->filename, abs_filename);
if (compare == 0)
/* We found it! */
break;
if (compare < 0)
{
/* It's not in the list. */
retval = NULL;
break;
}
last = retval;
}
if (retval != NULL || do_allocate == 0)
{
free (abs_filename);
return retval;
}
retval = (struct loaded_l10nfile *)
malloc (sizeof (*retval) + (__argz_count (dirlist, dirlist_len)
* (1 << pop (mask))
* sizeof (struct loaded_l10nfile *)));
if (retval == NULL)
return NULL;
retval->filename = abs_filename;
retval->decided = (__argz_count (dirlist, dirlist_len) != 1
|| ((mask & XPG_CODESET) != 0
&& (mask & XPG_NORM_CODESET) != 0));
retval->data = NULL;
if (last == NULL)
{
retval->next = *l10nfile_list;
*l10nfile_list = retval;
}
else
{
retval->next = last->next;
last->next = retval;
}
entries = 0;
/* If the DIRLIST is a real list the RETVAL entry corresponds not to
a real file. So we have to use the DIRLIST separation mechanism
of the inner loop. */
cnt = __argz_count (dirlist, dirlist_len) == 1 ? mask - 1 : mask;
for (; cnt >= 0; --cnt)
if ((cnt & ~mask) == 0
&& ((cnt & CEN_SPECIFIC) == 0 || (cnt & XPG_SPECIFIC) == 0)
&& ((cnt & XPG_CODESET) == 0 || (cnt & XPG_NORM_CODESET) == 0))
{
/* Iterate over all elements of the DIRLIST. */
char *dir = NULL;
while ((dir = __argz_next ((char *) dirlist, dirlist_len, dir))
!= NULL)
retval->successor[entries++]
= _nl_make_l10nflist (l10nfile_list, dir, strlen (dir) + 1, cnt,
language, territory, codeset,
normalized_codeset, modifier, special,
sponsor, revision, filename, 1);
}
retval->successor[entries] = NULL;
return retval;
}
/* Normalize codeset name. There is no standard for the codeset
names. Normalization allows the user to use any of the common
names. */
const char *
_nl_normalize_codeset (codeset, name_len)
const char *codeset;
size_t name_len;
{
int len = 0;
int only_digit = 1;
char *retval;
char *wp;
size_t cnt;
for (cnt = 0; cnt < name_len; ++cnt)
if (isalnum (codeset[cnt]))
{
++len;
if (isalpha (codeset[cnt]))
only_digit = 0;
}
retval = (char *) malloc ((only_digit ? 3 : 0) + len + 1);
if (retval != NULL)
{
if (only_digit)
wp = stpcpy (retval, "iso");
else
wp = retval;
for (cnt = 0; cnt < name_len; ++cnt)
if (isalpha (codeset[cnt]))
*wp++ = tolower (codeset[cnt]);
else if (isdigit (codeset[cnt]))
*wp++ = codeset[cnt];
*wp = '\0';
}
return (const char *) retval;
}
/* @@ begin of epilog @@ */
/* We don't want libintl.a to depend on any other library. So we
avoid the non-standard function stpcpy. In GNU C Library this
function is available, though. Also allow the symbol HAVE_STPCPY
to be defined. */
#if !_LIBC && !HAVE_STPCPY
static char *
stpcpy (dest, src)
char *dest;
const char *src;
{
while ((*dest++ = *src++) != '\0')
/* Do nothing. */ ;
return dest - 1;
}
#endif

View File

@@ -1,182 +0,0 @@
/* Message catalogs for internationalization.
Copyright (C) 1995, 1996, 1997, 1998 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. */
/* Because on some systems (e.g. Solaris) we sometimes have to include
the systems libintl.h as well as this file we have more complex
include protection above. But the systems header might perhaps also
define _LIBINTL_H and therefore we have to protect the definition here. */
#if !defined _LIBINTL_H || !defined _LIBGETTEXT_H
#ifndef _LIBINTL_H
# define _LIBINTL_H 1
#endif
#define _LIBGETTEXT_H 1
/* We define an additional symbol to signal that we use the GNU
implementation of gettext. */
#define __USE_GNU_GETTEXT 1
#include <sys/types.h>
#if HAVE_LOCALE_H
# include <locale.h>
#endif
#ifdef __cplusplus
extern "C" {
#endif
/* @@ end of prolog @@ */
#ifndef PARAMS
# if __STDC__ || defined __cplusplus
# define PARAMS(args) args
# else
# define PARAMS(args) ()
# endif
#endif
#ifndef NULL
# if !defined __cplusplus || defined __GNUC__
# define NULL ((void *) 0)
# else
# define NULL (0)
# endif
#endif
#if !HAVE_LC_MESSAGES
/* This value determines the behaviour of the gettext() and dgettext()
function. But some system does not have this defined. Define it
to a default value. */
# define LC_MESSAGES (-1)
#endif
/* Declarations for gettext-using-catgets interface. Derived from
Jim Meyering's libintl.h. */
struct _msg_ent
{
const char *_msg;
int _msg_number;
};
#if HAVE_CATGETS
/* These two variables are defined in the automatically by po-to-tbl.sed
generated file `cat-id-tbl.c'. */
extern const struct _msg_ent _msg_tbl[];
extern int _msg_tbl_length;
#endif
/* For automatical extraction of messages sometimes no real
translation is needed. Instead the string itself is the result. */
#define gettext_noop(Str) (Str)
/* Look up MSGID in the current default message catalog for the current
LC_MESSAGES locale. If not found, returns MSGID itself (the default
text). */
extern char *gettext PARAMS ((const char *__msgid));
extern char *gettext__ PARAMS ((const char *__msgid));
/* Look up MSGID in the DOMAINNAME message catalog for the current
LC_MESSAGES locale. */
extern char *dgettext PARAMS ((const char *__domainname, const char *__msgid));
extern char *dgettext__ PARAMS ((const char *__domainname,
const char *__msgid));
/* Look up MSGID in the DOMAINNAME message catalog for the current CATEGORY
locale. */
extern char *dcgettext PARAMS ((const char *__domainname, const char *__msgid,
int __category));
extern char *dcgettext__ PARAMS ((const char *__domainname,
const char *__msgid, int __category));
/* Set the current default message catalog to DOMAINNAME.
If DOMAINNAME is null, return the current default.
If DOMAINNAME is "", reset to the default of "messages". */
extern char *textdomain PARAMS ((const char *__domainname));
extern char *textdomain__ PARAMS ((const char *__domainname));
/* Specify that the DOMAINNAME message catalog will be found
in DIRNAME rather than in the system locale data base. */
extern char *bindtextdomain PARAMS ((const char *__domainname,
const char *__dirname));
extern char *bindtextdomain__ PARAMS ((const char *__domainname,
const char *__dirname));
#if ENABLE_NLS
/* Solaris 2.3 has the gettext function but dcgettext is missing.
So we omit this optimization for Solaris 2.3. BTW, Solaris 2.4
has dcgettext. */
# if !HAVE_CATGETS && (!HAVE_GETTEXT || HAVE_DCGETTEXT)
# define gettext(Msgid) \
dgettext (NULL, Msgid)
# define dgettext(Domainname, Msgid) \
dcgettext (Domainname, Msgid, LC_MESSAGES)
# if defined __GNUC__ && __GNUC__ == 2 && __GNUC_MINOR__ >= 7
/* This global variable is defined in loadmsgcat.c. We need a sign,
whether a new catalog was loaded, which can be associated with all
translations. */
extern int _nl_msg_cat_cntr;
# define dcgettext(Domainname, Msgid, Category) \
(__extension__ \
({ \
char *__result; \
if (__builtin_constant_p (Msgid)) \
{ \
static char *__translation__; \
static int __catalog_counter__; \
if (! __translation__ || __catalog_counter__ != _nl_msg_cat_cntr) \
{ \
__translation__ = \
dcgettext__ (Domainname, Msgid, Category); \
__catalog_counter__ = _nl_msg_cat_cntr; \
} \
__result = __translation__; \
} \
else \
__result = dcgettext__ (Domainname, Msgid, Category); \
__result; \
}))
# endif
# endif
#else
# define gettext(Msgid) (Msgid)
# define dgettext(Domainname, Msgid) (Msgid)
# define dcgettext(Domainname, Msgid, Category) (Msgid)
# define textdomain(Domainname) ((char *) Domainname)
# define bindtextdomain(Domainname, Dirname) ((char *) Dirname)
#endif
/* @@ begin of epilog @@ */
#ifdef __cplusplus
}
#endif
#endif

View File

@@ -1,100 +0,0 @@
# po2msg.sed - Convert Uniforum style .po file to Linux style .msg file
# Copyright (C) 1995 Free Software Foundation, Inc.
# Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1995.
#
# 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.
#
#
# The first directive in the .msg should be the definition of the
# message set number. We use always set number 1.
#
1 {
i\
$set 1 # Automatically created by po2msg.sed
h
s/.*/0/
x
}
#
# Mitch's old catalog format does not allow comments.
#
# We copy the original message as a comment into the .msg file.
#
/^msgid/ {
s/msgid[ ]*"//
#
# This does not work now with the new format.
# /"$/! {
# s/\\$//
# s/$/ ... (more lines following)"/
# }
x
# The following nice solution is by
# Bruno <Haible@ma2s2.mathematik.uni-karlsruhe.de>
td
# Increment a decimal number in pattern space.
# First hide trailing `9' digits.
:d
s/9\(_*\)$/_\1/
td
# Assure at least one digit is available.
s/^\(_*\)$/0\1/
# Increment the last digit.
s/8\(_*\)$/9\1/
s/7\(_*\)$/8\1/
s/6\(_*\)$/7\1/
s/5\(_*\)$/6\1/
s/4\(_*\)$/5\1/
s/3\(_*\)$/4\1/
s/2\(_*\)$/3\1/
s/1\(_*\)$/2\1/
s/0\(_*\)$/1\1/
# Convert the hidden `9' digits to `0's.
s/_/0/g
x
G
s/\(.*\)"\n\([0-9]*\)/$ #\2 Original Message:(\1)/p
}
#
# The .msg file contains, other then the .po file, only the translations
# but each given a unique ID. Starting from 1 and incrementing by 1 for
# each message we assign them to the messages.
# It is important that the .po file used to generate the cat-id-tbl.c file
# (with po-to-tbl) is the same as the one used here. (At least the order
# of declarations must not be changed.)
#
/^msgstr/ {
s/msgstr[ ]*"\(.*\)"/# \1/
# Clear substitution flag.
tb
# Append the next line.
:b
N
# Look whether second part is continuation line.
s/\(.*\n\)"\(.*\)"/\1\2/
# Yes, then branch.
ta
P
D
# Note that D includes a jump to the start!!
# We found a continuation line. But before printing insert '\'.
:a
s/\(.*\)\(\n.*\)/\1\\\2/
P
# We cannot use D here.
s/.*\n\(.*\)/\1/
tb
}
d

View File

@@ -1,78 +0,0 @@
/* Copyright (C) 1996, 1997 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@cygnus.com>, 1996.
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. */
#ifndef PARAMS
# if __STDC__
# define PARAMS(args) args
# else
# define PARAMS(args) ()
# endif
#endif
/* Encoding of locale name parts. */
#define CEN_REVISION 1
#define CEN_SPONSOR 2
#define CEN_SPECIAL 4
#define XPG_NORM_CODESET 8
#define XPG_CODESET 16
#define TERRITORY 32
#define CEN_AUDIENCE 64
#define XPG_MODIFIER 128
#define CEN_SPECIFIC (CEN_REVISION|CEN_SPONSOR|CEN_SPECIAL|CEN_AUDIENCE)
#define XPG_SPECIFIC (XPG_CODESET|XPG_NORM_CODESET|XPG_MODIFIER)
struct loaded_l10nfile
{
const char *filename;
int decided;
const void *data;
struct loaded_l10nfile *next;
struct loaded_l10nfile *successor[1];
};
extern const char *_nl_normalize_codeset PARAMS ((const char *codeset,
size_t name_len));
extern struct loaded_l10nfile *
_nl_make_l10nflist PARAMS ((struct loaded_l10nfile **l10nfile_list,
const char *dirlist, size_t dirlist_len, int mask,
const char *language, const char *territory,
const char *codeset,
const char *normalized_codeset,
const char *modifier, const char *special,
const char *sponsor, const char *revision,
const char *filename, int do_allocate));
extern const char *_nl_expand_alias PARAMS ((const char *name));
extern int _nl_explode_name PARAMS ((char *name, const char **language,
const char **modifier,
const char **territory,
const char **codeset,
const char **normalized_codeset,
const char **special,
const char **sponsor,
const char **revision));
extern char *_nl_find_language PARAMS ((const char *name));

View File

@@ -1,220 +0,0 @@
/* Load needed message catalogs.
Copyright (C) 1995, 1996, 1997, 1998 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
#include <fcntl.h>
#include <sys/types.h>
#include <sys/stat.h>
#if defined STDC_HEADERS || defined _LIBC
# include <stdlib.h>
#endif
#if defined HAVE_UNISTD_H || defined _LIBC
# include <unistd.h>
#endif
#if (defined HAVE_MMAP && defined HAVE_MUNMAP && !defined DISALLOW_MMAP) \
|| (defined _LIBC && defined _POSIX_MAPPED_FILES)
# include <sys/mman.h>
# undef HAVE_MMAP
# define HAVE_MMAP 1
#else
# undef HAVE_MMAP
#endif
#include "gettext.h"
#include "gettextP.h"
/* @@ end of prolog @@ */
#ifdef _LIBC
/* Rename the non ISO C functions. This is required by the standard
because some ISO C functions will require linking with this object
file and the name space must not be polluted. */
# define open __open
# define close __close
# define read __read
# define mmap __mmap
# define munmap __munmap
#endif
/* We need a sign, whether a new catalog was loaded, which can be associated
with all translations. This is important if the translations are
cached by one of GCC's features. */
int _nl_msg_cat_cntr = 0;
/* Load the message catalogs specified by FILENAME. If it is no valid
message catalog do nothing. */
void
internal_function
_nl_load_domain (domain_file)
struct loaded_l10nfile *domain_file;
{
int fd;
size_t size;
struct stat st;
struct mo_file_header *data = (struct mo_file_header *) -1;
int use_mmap = 0;
struct loaded_domain *domain;
domain_file->decided = 1;
domain_file->data = NULL;
/* If the record does not represent a valid locale the FILENAME
might be NULL. This can happen when according to the given
specification the locale file name is different for XPG and CEN
syntax. */
if (domain_file->filename == NULL)
return;
/* Try to open the addressed file. */
fd = open (domain_file->filename, O_RDONLY);
if (fd == -1)
return;
/* We must know about the size of the file. */
if (fstat (fd, &st) != 0
|| (size = (size_t) st.st_size) != st.st_size
|| size < sizeof (struct mo_file_header))
{
/* Something went wrong. */
close (fd);
return;
}
#ifdef HAVE_MMAP
/* Now we are ready to load the file. If mmap() is available we try
this first. If not available or it failed we try to load it. */
data = (struct mo_file_header *) mmap (NULL, size, PROT_READ,
MAP_PRIVATE, fd, 0);
if (data != (struct mo_file_header *) -1)
{
/* mmap() call was successful. */
close (fd);
use_mmap = 1;
}
#endif
/* If the data is not yet available (i.e. mmap'ed) we try to load
it manually. */
if (data == (struct mo_file_header *) -1)
{
size_t to_read;
char *read_ptr;
data = (struct mo_file_header *) malloc (size);
if (data == NULL)
return;
to_read = size;
read_ptr = (char *) data;
do
{
long int nb = (long int) read (fd, read_ptr, to_read);
if (nb == -1)
{
close (fd);
return;
}
read_ptr += nb;
to_read -= nb;
}
while (to_read > 0);
close (fd);
}
/* Using the magic number we can test whether it really is a message
catalog file. */
if (data->magic != _MAGIC && data->magic != _MAGIC_SWAPPED)
{
/* The magic number is wrong: not a message catalog file. */
#ifdef HAVE_MMAP
if (use_mmap)
munmap ((caddr_t) data, size);
else
#endif
free (data);
return;
}
domain_file->data
= (struct loaded_domain *) malloc (sizeof (struct loaded_domain));
if (domain_file->data == NULL)
return;
domain = (struct loaded_domain *) domain_file->data;
domain->data = (char *) data;
domain->use_mmap = use_mmap;
domain->mmap_size = size;
domain->must_swap = data->magic != _MAGIC;
/* Fill in the information about the available tables. */
switch (W (domain->must_swap, data->revision))
{
case 0:
domain->nstrings = W (domain->must_swap, data->nstrings);
domain->orig_tab = (struct string_desc *)
((char *) data + W (domain->must_swap, data->orig_tab_offset));
domain->trans_tab = (struct string_desc *)
((char *) data + W (domain->must_swap, data->trans_tab_offset));
domain->hash_size = W (domain->must_swap, data->hash_tab_size);
domain->hash_tab = (nls_uint32 *)
((char *) data + W (domain->must_swap, data->hash_tab_offset));
break;
default:
/* This is an invalid revision. */
#ifdef HAVE_MMAP
if (use_mmap)
munmap ((caddr_t) data, size);
else
#endif
free (data);
free (domain);
domain_file->data = NULL;
return;
}
/* Show that one domain is changed. This might make some cached
translations invalid. */
++_nl_msg_cat_cntr;
}
#ifdef _LIBC
void
internal_function
_nl_unload_domain (domain)
struct loaded_domain *domain;
{
#ifdef _POSIX_MAPPED_FILES
if (domain->use_mmap)
munmap ((caddr_t) domain->data, domain->mmap_size);
else
#endif /* _POSIX_MAPPED_FILES */
free ((void *) domain->data);
free (domain);
}
#endif

View File

@@ -1,438 +0,0 @@
/* Handle aliases for locale names.
Copyright (C) 1995, 1996, 1997, 1998 Free Software Foundation, Inc.
Written by Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1995.
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
#include <ctype.h>
#include <stdio.h>
#include <sys/types.h>
#ifdef __GNUC__
# define alloca __builtin_alloca
# define HAVE_ALLOCA 1
#else
# if defined HAVE_ALLOCA_H || defined _LIBC
# include <alloca.h>
# else
# ifdef _AIX
#pragma alloca
# else
# ifndef alloca
char *alloca ();
# endif
# endif
# endif
#endif
#if defined STDC_HEADERS || defined _LIBC
# include <stdlib.h>
#else
char *getenv ();
# ifdef HAVE_MALLOC_H
# include <malloc.h>
# else
void free ();
# endif
#endif
#if defined HAVE_STRING_H || defined _LIBC
# ifndef _GNU_SOURCE
# define _GNU_SOURCE 1
# endif
# include <string.h>
#else
# include <strings.h>
# ifndef memcpy
# define memcpy(Dst, Src, Num) bcopy (Src, Dst, Num)
# endif
#endif
#if !HAVE_STRCHR && !defined _LIBC
# ifndef strchr
# define strchr index
# endif
#endif
#include "gettext.h"
#include "gettextP.h"
/* @@ end of prolog @@ */
#ifdef _LIBC
/* Rename the non ANSI C functions. This is required by the standard
because some ANSI C functions will require linking with this object
file and the name space must not be polluted. */
# define strcasecmp __strcasecmp
# ifndef mempcpy
# define mempcpy __mempcpy
# endif
# define HAVE_MEMPCPY 1
/* We need locking here since we can be called from different places. */
# include <bits/libc-lock.h>
__libc_lock_define_initialized (static, lock);
#endif
#ifndef internal_function
# define internal_function
#endif
/* For those loosing systems which don't have `alloca' we have to add
some additional code emulating it. */
#ifdef HAVE_ALLOCA
/* Nothing has to be done. */
# define ADD_BLOCK(list, address) /* nothing */
# define FREE_BLOCKS(list) /* nothing */
#else
struct block_list
{
void *address;
struct block_list *next;
};
# define ADD_BLOCK(list, addr) \
do { \
struct block_list *newp = (struct block_list *) malloc (sizeof (*newp)); \
/* If we cannot get a free block we cannot add the new element to \
the list. */ \
if (newp != NULL) { \
newp->address = (addr); \
newp->next = (list); \
(list) = newp; \
} \
} while (0)
# define FREE_BLOCKS(list) \
do { \
while (list != NULL) { \
struct block_list *old = list; \
list = list->next; \
free (old); \
} \
} while (0)
# undef alloca
# define alloca(size) (malloc (size))
#endif /* have alloca */
#if defined _LIBC_REENTRANT || defined HAVE_FGETS_UNLOCKED
# undef fgets
# define fgets(buf, len, s) fgets_unlocked (buf, len, s)
#endif
#if defined _LIBC_REENTRANT || defined HAVE_FEOF_UNLOCKED
# undef feof
# define feof(s) feof_unlocked (s)
#endif
struct alias_map
{
const char *alias;
const char *value;
};
static char *string_space = NULL;
static size_t string_space_act = 0;
static size_t string_space_max = 0;
static struct alias_map *map;
static size_t nmap = 0;
static size_t maxmap = 0;
/* Prototypes for local functions. */
static size_t read_alias_file PARAMS ((const char *fname, int fname_len))
internal_function;
static void extend_alias_table PARAMS ((void));
static int alias_compare PARAMS ((const struct alias_map *map1,
const struct alias_map *map2));
const char *
_nl_expand_alias (name)
const char *name;
{
static const char *locale_alias_path = LOCALE_ALIAS_PATH;
struct alias_map *retval;
const char *result = NULL;
size_t added;
#ifdef _LIBC
__libc_lock_lock (lock);
#endif
do
{
struct alias_map item;
item.alias = name;
if (nmap > 0)
retval = (struct alias_map *) bsearch (&item, map, nmap,
sizeof (struct alias_map),
(int (*) PARAMS ((const void *,
const void *))
) alias_compare);
else
retval = NULL;
/* We really found an alias. Return the value. */
if (retval != NULL)
{
result = retval->value;
break;
}
/* Perhaps we can find another alias file. */
added = 0;
while (added == 0 && locale_alias_path[0] != '\0')
{
const char *start;
while (locale_alias_path[0] == ':')
++locale_alias_path;
start = locale_alias_path;
while (locale_alias_path[0] != '\0' && locale_alias_path[0] != ':')
++locale_alias_path;
if (start < locale_alias_path)
added = read_alias_file (start, locale_alias_path - start);
}
}
while (added != 0);
#ifdef _LIBC
__libc_lock_unlock (lock);
#endif
return result;
}
static size_t
internal_function
read_alias_file (fname, fname_len)
const char *fname;
int fname_len;
{
#ifndef HAVE_ALLOCA
struct block_list *block_list = NULL;
#endif
FILE *fp;
char *full_fname;
size_t added;
static const char aliasfile[] = "/locale.alias";
full_fname = (char *) alloca (fname_len + sizeof aliasfile);
ADD_BLOCK (block_list, full_fname);
#ifdef HAVE_MEMPCPY
mempcpy (mempcpy (full_fname, fname, fname_len),
aliasfile, sizeof aliasfile);
#else
memcpy (full_fname, fname, fname_len);
memcpy (&full_fname[fname_len], aliasfile, sizeof aliasfile);
#endif
fp = fopen (full_fname, "r");
if (fp == NULL)
{
FREE_BLOCKS (block_list);
return 0;
}
added = 0;
while (!feof (fp))
{
/* It is a reasonable approach to use a fix buffer here because
a) we are only interested in the first two fields
b) these fields must be usable as file names and so must not
be that long
*/
char buf[BUFSIZ];
char *alias;
char *value;
char *cp;
if (fgets (buf, sizeof buf, fp) == NULL)
/* EOF reached. */
break;
/* Possibly not the whole line fits into the buffer. Ignore
the rest of the line. */
if (strchr (buf, '\n') == NULL)
{
char altbuf[BUFSIZ];
do
if (fgets (altbuf, sizeof altbuf, fp) == NULL)
/* Make sure the inner loop will be left. The outer loop
will exit at the `feof' test. */
break;
while (strchr (altbuf, '\n') == NULL);
}
cp = buf;
/* Ignore leading white space. */
while (isspace (cp[0]))
++cp;
/* A leading '#' signals a comment line. */
if (cp[0] != '\0' && cp[0] != '#')
{
alias = cp++;
while (cp[0] != '\0' && !isspace (cp[0]))
++cp;
/* Terminate alias name. */
if (cp[0] != '\0')
*cp++ = '\0';
/* Now look for the beginning of the value. */
while (isspace (cp[0]))
++cp;
if (cp[0] != '\0')
{
size_t alias_len;
size_t value_len;
value = cp++;
while (cp[0] != '\0' && !isspace (cp[0]))
++cp;
/* Terminate value. */
if (cp[0] == '\n')
{
/* This has to be done to make the following test
for the end of line possible. We are looking for
the terminating '\n' which do not overwrite here. */
*cp++ = '\0';
*cp = '\n';
}
else if (cp[0] != '\0')
*cp++ = '\0';
if (nmap >= maxmap)
extend_alias_table ();
alias_len = strlen (alias) + 1;
value_len = strlen (value) + 1;
if (string_space_act + alias_len + value_len > string_space_max)
{
/* Increase size of memory pool. */
size_t new_size = (string_space_max
+ (alias_len + value_len > 1024
? alias_len + value_len : 1024));
char *new_pool = (char *) realloc (string_space, new_size);
if (new_pool == NULL)
{
FREE_BLOCKS (block_list);
return added;
}
string_space = new_pool;
string_space_max = new_size;
}
map[nmap].alias = memcpy (&string_space[string_space_act],
alias, alias_len);
string_space_act += alias_len;
map[nmap].value = memcpy (&string_space[string_space_act],
value, value_len);
string_space_act += value_len;
++nmap;
++added;
}
}
}
/* Should we test for ferror()? I think we have to silently ignore
errors. --drepper */
fclose (fp);
if (added > 0)
qsort (map, nmap, sizeof (struct alias_map),
(int (*) PARAMS ((const void *, const void *))) alias_compare);
FREE_BLOCKS (block_list);
return added;
}
static void
extend_alias_table ()
{
size_t new_size;
struct alias_map *new_map;
new_size = maxmap == 0 ? 100 : 2 * maxmap;
new_map = (struct alias_map *) realloc (map, (new_size
* sizeof (struct alias_map)));
if (new_map == NULL)
/* Simply don't extend: we don't have any more core. */
return;
map = new_map;
maxmap = new_size;
}
#ifdef _LIBC
static void __attribute__ ((unused))
free_mem (void)
{
if (string_space != NULL)
free (string_space);
if (map != NULL)
free (map);
}
text_set_element (__libc_subfreeres, free_mem);
#endif
static int
alias_compare (map1, map2)
const struct alias_map *map1;
const struct alias_map *map2;
{
#if defined _LIBC || defined HAVE_STRCASECMP
return strcasecmp (map1->alias, map2->alias);
#else
const unsigned char *p1 = (const unsigned char *) map1->alias;
const unsigned char *p2 = (const unsigned char *) map2->alias;
unsigned char c1, c2;
if (p1 == p2)
return 0;
do
{
/* I know this seems to be odd but the tolower() function in
some systems libc cannot handle nonalpha characters. */
c1 = isupper (*p1) ? tolower (*p1) : *p1;
c2 = isupper (*p2) ? tolower (*p2) : *p2;
if (c1 == '\0')
break;
++p1;
++p2;
}
while (c1 == c2);
return c1 - c2;
#endif
}

View File

@@ -1,102 +0,0 @@
# po2tbl.sed - Convert Uniforum style .po file to lookup table for catgets
# Copyright (C) 1995 Free Software Foundation, Inc.
# Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1995.
#
# 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.
#
1 {
i\
/* Automatically generated by po2tbl.sed from @PACKAGE NAME@.pot. */\
\
#if HAVE_CONFIG_H\
# include <config.h>\
#endif\
\
#include "libgettext.h"\
\
const struct _msg_ent _msg_tbl[] = {
h
s/.*/0/
x
}
#
# Write msgid entries in C array form.
#
/^msgid/ {
s/msgid[ ]*\(".*"\)/ {\1/
tb
# Append the next line
:b
N
# Look whether second part is continuation line.
s/\(.*\)"\(\n\)"\(.*"\)/\1\2\3/
# Yes, then branch.
ta
# Because we assume that the input file correctly formed the line
# just read cannot be again be a msgid line. So it's safe to ignore
# it.
s/\(.*\)\n.*/\1/
bc
# We found a continuation line. But before printing insert '\'.
:a
s/\(.*\)\(\n.*\)/\1\\\2/
P
# We cannot use D here.
s/.*\n\(.*\)/\1/
# Some buggy seds do not clear the `successful substitution since last ``t'''
# flag on `N', so we do a `t' here to clear it.
tb
# Not reached
:c
x
# The following nice solution is by
# Bruno <Haible@ma2s2.mathematik.uni-karlsruhe.de>
td
# Increment a decimal number in pattern space.
# First hide trailing `9' digits.
:d
s/9\(_*\)$/_\1/
td
# Assure at least one digit is available.
s/^\(_*\)$/0\1/
# Increment the last digit.
s/8\(_*\)$/9\1/
s/7\(_*\)$/8\1/
s/6\(_*\)$/7\1/
s/5\(_*\)$/6\1/
s/4\(_*\)$/5\1/
s/3\(_*\)$/4\1/
s/2\(_*\)$/3\1/
s/1\(_*\)$/2\1/
s/0\(_*\)$/1\1/
# Convert the hidden `9' digits to `0's.
s/_/0/g
x
G
s/\(.*\)\n\([0-9]*\)/\1, \2},/
s/\(.*\)"$/\1/
p
}
#
# Last line.
#
$ {
i\
};\
g
s/0*\(.*\)/int _msg_tbl_length = \1;/p
}
d

View File

@@ -1,108 +0,0 @@
/* Implementation of the textdomain(3) function.
Copyright (C) 1995, 1996, 1997, 1998 Free Software Foundation, Inc.
Written by Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1995.
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
#if defined STDC_HEADERS || defined _LIBC
# include <stdlib.h>
#endif
#if defined STDC_HEADERS || defined HAVE_STRING_H || defined _LIBC
# include <string.h>
#else
# include <strings.h>
# ifndef memcpy
# define memcpy(Dst, Src, Num) bcopy (Src, Dst, Num)
# endif
#endif
#ifdef _LIBC
# include <libintl.h>
#else
# include "libgettext.h"
#endif
/* @@ end of prolog @@ */
/* Name of the default text domain. */
extern const char _nl_default_default_domain[];
/* Default text domain in which entries for gettext(3) are to be found. */
extern const char *_nl_current_default_domain;
/* Names for the libintl functions are a problem. They must not clash
with existing names and they should follow ANSI C. But this source
code is also used in GNU C Library where the names have a __
prefix. So we have to make a difference here. */
#ifdef _LIBC
# define TEXTDOMAIN __textdomain
# ifndef strdup
# define strdup(str) __strdup (str)
# endif
#else
# define TEXTDOMAIN textdomain__
#endif
/* Set the current default message catalog to DOMAINNAME.
If DOMAINNAME is null, return the current default.
If DOMAINNAME is "", reset to the default of "messages". */
char *
TEXTDOMAIN (domainname)
const char *domainname;
{
char *old;
/* A NULL pointer requests the current setting. */
if (domainname == NULL)
return (char *) _nl_current_default_domain;
old = (char *) _nl_current_default_domain;
/* If domain name is the null string set to default domain "messages". */
if (domainname[0] == '\0'
|| strcmp (domainname, _nl_default_default_domain) == 0)
_nl_current_default_domain = _nl_default_default_domain;
else
{
/* If the following malloc fails `_nl_current_default_domain'
will be NULL. This value will be returned and so signals we
are out of core. */
#if defined _LIBC || defined HAVE_STRDUP
_nl_current_default_domain = strdup (domainname);
#else
size_t len = strlen (domainname) + 1;
char *cp = (char *) malloc (len);
if (cp != NULL)
memcpy (cp, domainname, len);
_nl_current_default_domain = cp;
#endif
}
if (old != _nl_default_default_domain)
free (old);
return (char *) _nl_current_default_domain;
}
#ifdef _LIBC
/* Alias for function name in GNU C Library. */
weak_alias (__textdomain, textdomain);
#endif

View File

@@ -1,104 +0,0 @@
# po2msg.sed - Convert Uniforum style .po file to X/Open style .msg file
# Copyright (C) 1995 Free Software Foundation, Inc.
# Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1995.
#
# 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.
#
#
# The first directive in the .msg should be the definition of the
# message set number. We use always set number 1.
#
1 {
i\
$set 1 # Automatically created by po2msg.sed
h
s/.*/0/
x
}
#
# We copy all comments into the .msg file. Perhaps they can help.
#
/^#/ s/^#[ ]*/$ /p
#
# We copy the original message as a comment into the .msg file.
#
/^msgid/ {
# Does not work now
# /"$/! {
# s/\\$//
# s/$/ ... (more lines following)"/
# }
s/^msgid[ ]*"\(.*\)"$/$ Original Message: \1/
p
}
#
# The .msg file contains, other then the .po file, only the translations
# but each given a unique ID. Starting from 1 and incrementing by 1 for
# each message we assign them to the messages.
# It is important that the .po file used to generate the cat-id-tbl.c file
# (with po-to-tbl) is the same as the one used here. (At least the order
# of declarations must not be changed.)
#
/^msgstr/ {
s/msgstr[ ]*"\(.*\)"/\1/
x
# The following nice solution is by
# Bruno <Haible@ma2s2.mathematik.uni-karlsruhe.de>
td
# Increment a decimal number in pattern space.
# First hide trailing `9' digits.
:d
s/9\(_*\)$/_\1/
td
# Assure at least one digit is available.
s/^\(_*\)$/0\1/
# Increment the last digit.
s/8\(_*\)$/9\1/
s/7\(_*\)$/8\1/
s/6\(_*\)$/7\1/
s/5\(_*\)$/6\1/
s/4\(_*\)$/5\1/
s/3\(_*\)$/4\1/
s/2\(_*\)$/3\1/
s/1\(_*\)$/2\1/
s/0\(_*\)$/1\1/
# Convert the hidden `9' digits to `0's.
s/_/0/g
x
# Bring the line in the format `<number> <message>'
G
s/^[^\n]*$/& /
s/\(.*\)\n\([0-9]*\)/\2 \1/
# Clear flag from last substitution.
tb
# Append the next line.
:b
N
# Look whether second part is a continuation line.
s/\(.*\n\)"\(.*\)"/\1\2/
# Yes, then branch.
ta
P
D
# Note that `D' includes a jump to the start!!
# We found a continuation line. But before printing insert '\'.
:a
s/\(.*\)\(\n.*\)/\1\\\2/
P
# We cannot use the sed command `D' here
s/.*\n\(.*\)/\1/
tb
}
d

2
m4/.cvsignore Normal file
View File

@@ -0,0 +1,2 @@
Makefile.in
Makefile

29
m4/ChangeLog Normal file
View File

@@ -0,0 +1,29 @@
2002-08-21 gettextize <bug-gnu-gettext@gnu.org>
* gettext.m4: Upgrade to gettext-0.11.5.
* ulonglong.m4: New file, from gettext-0.11.5.
* iconv.m4: Upgrade to gettext-0.11.5.
* intdiv0.m4: New file, from gettext-0.11.5.
* inttypes.m4: New file, from gettext-0.11.5.
* inttypes_h.m4: New file, from gettext-0.11.5.
* inttypes-pri.m4: New file, from gettext-0.11.5.
* lcmessage.m4: Upgrade to gettext-0.11.5.
* lib-link.m4: Upgrade to gettext-0.11.5.
* stdint_h.m4: New file, from gettext-0.11.5.
* uintmax_t.m4: New file, from gettext-0.11.5.
* Makefile.am (EXTRA_DIST): Add the new files.
2002-06-03 gettextize <bug-gnu-gettext@gnu.org>
* codeset.m4: Upgrade to gettext-0.11.2.
* gettext.m4: Upgrade to gettext-0.11.2.
* glibc21.m4: Upgrade to gettext-0.11.2.
* iconv.m4: Upgrade to gettext-0.11.2.
* isc-posix.m4: New file, from gettext-0.11.2.
* lcmessage.m4: Upgrade to gettext-0.11.2.
* lib-ld.m4: New file, from gettext-0.11.2.
* lib-link.m4: New file, from gettext-0.11.2.
* lib-prefix.m4: New file, from gettext-0.11.2.
* progtest.m4: Upgrade to gettext-0.11.2.
* Makefile.am (EXTRA_DIST): Add the new files.

4
m4/Makefile.am Normal file
View File

@@ -0,0 +1,4 @@
EXTRA_DIST = ulonglong.m4 intdiv0.m4 inttypes.m4 inttypes_h.m4 inttypes-pri.m4 \
stdint_h.m4 uintmax_t.m4 isc-posix.m4 lib-ld.m4 lib-link.m4 \
lib-prefix.m4 codeset.m4 glibc21.m4 progtest.m4 gettext.m4 \
iconv.m4 lcmessage.m4

23
m4/codeset.m4 Normal file
View File

@@ -0,0 +1,23 @@
# codeset.m4 serial AM1 (gettext-0.10.40)
dnl Copyright (C) 2000-2002 Free Software Foundation, Inc.
dnl This file is free software, distributed under the terms of the GNU
dnl General Public License. As a special exception to the GNU General
dnl Public License, this file may be distributed as part of a program
dnl that contains a configuration script generated by Autoconf, under
dnl the same distribution terms as the rest of that program.
dnl From Bruno Haible.
AC_DEFUN([AM_LANGINFO_CODESET],
[
AC_CACHE_CHECK([for nl_langinfo and CODESET], am_cv_langinfo_codeset,
[AC_TRY_LINK([#include <langinfo.h>],
[char* cs = nl_langinfo(CODESET);],
am_cv_langinfo_codeset=yes,
am_cv_langinfo_codeset=no)
])
if test $am_cv_langinfo_codeset = yes; then
AC_DEFINE(HAVE_LANGINFO_CODESET, 1,
[Define if you have <langinfo.h> and nl_langinfo(CODESET).])
fi
])

587
m4/gettext.m4 Normal file
View File

@@ -0,0 +1,587 @@
# gettext.m4 serial 17 (gettext-0.11.5)
dnl Copyright (C) 1995-2002 Free Software Foundation, Inc.
dnl This file is free software, distributed under the terms of the GNU
dnl General Public License. As a special exception to the GNU General
dnl Public License, this file may be distributed as part of a program
dnl that contains a configuration script generated by Autoconf, under
dnl the same distribution terms as the rest of that program.
dnl
dnl This file can can be used in projects which are not available under
dnl the GNU General Public License or the GNU Library General Public
dnl License but which still want to provide support for the GNU gettext
dnl functionality.
dnl Please note that the actual code of the GNU gettext library is covered
dnl by the GNU Library General Public License, and the rest of the GNU
dnl gettext package package is covered by the GNU General Public License.
dnl They are *not* in the public domain.
dnl Authors:
dnl Ulrich Drepper <drepper@cygnus.com>, 1995-2000.
dnl Bruno Haible <haible@clisp.cons.org>, 2000-2002.
dnl Macro to add for using GNU gettext.
dnl Usage: AM_GNU_GETTEXT([INTLSYMBOL], [NEEDSYMBOL], [INTLDIR]).
dnl INTLSYMBOL can be one of 'external', 'no-libtool', 'use-libtool'. The
dnl default (if it is not specified or empty) is 'no-libtool'.
dnl INTLSYMBOL should be 'external' for packages with no intl directory,
dnl and 'no-libtool' or 'use-libtool' for packages with an intl directory.
dnl If INTLSYMBOL is 'use-libtool', then a libtool library
dnl $(top_builddir)/intl/libintl.la will be created (shared and/or static,
dnl depending on --{enable,disable}-{shared,static} and on the presence of
dnl AM-DISABLE-SHARED). If INTLSYMBOL is 'no-libtool', a static library
dnl $(top_builddir)/intl/libintl.a will be created.
dnl If NEEDSYMBOL is specified and is 'need-ngettext', then GNU gettext
dnl implementations (in libc or libintl) without the ngettext() function
dnl will be ignored. If NEEDSYMBOL is specified and is
dnl 'need-formatstring-macros', then GNU gettext implementations that don't
dnl support the ISO C 99 <inttypes.h> formatstring macros will be ignored.
dnl INTLDIR is used to find the intl libraries. If empty,
dnl the value `$(top_builddir)/intl/' is used.
dnl
dnl The result of the configuration is one of three cases:
dnl 1) GNU gettext, as included in the intl subdirectory, will be compiled
dnl and used.
dnl Catalog format: GNU --> install in $(datadir)
dnl Catalog extension: .mo after installation, .gmo in source tree
dnl 2) GNU gettext has been found in the system's C library.
dnl Catalog format: GNU --> install in $(datadir)
dnl Catalog extension: .mo after installation, .gmo in source tree
dnl 3) No internationalization, always use English msgid.
dnl Catalog format: none
dnl Catalog extension: none
dnl If INTLSYMBOL is 'external', only cases 2 and 3 can occur.
dnl The use of .gmo is historical (it was needed to avoid overwriting the
dnl GNU format catalogs when building on a platform with an X/Open gettext),
dnl but we keep it in order not to force irrelevant filename changes on the
dnl maintainers.
dnl
AC_DEFUN([AM_GNU_GETTEXT],
[
dnl Argument checking.
ifelse([$1], [], , [ifelse([$1], [external], , [ifelse([$1], [no-libtool], , [ifelse([$1], [use-libtool], ,
[errprint([ERROR: invalid first argument to AM_GNU_GETTEXT
])])])])])
ifelse([$2], [], , [ifelse([$2], [need-ngettext], , [ifelse([$2], [need-formatstring-macros], ,
[errprint([ERROR: invalid second argument to AM_GNU_GETTEXT
])])])])
define(gt_included_intl, ifelse([$1], [external], [no], [yes]))
define(gt_libtool_suffix_prefix, ifelse([$1], [use-libtool], [l], []))
AC_REQUIRE([AM_PO_SUBDIRS])dnl
ifelse(gt_included_intl, yes, [
AC_REQUIRE([AM_INTL_SUBDIR])dnl
])
dnl Prerequisites of AC_LIB_LINKFLAGS_BODY.
AC_REQUIRE([AC_LIB_PREPARE_PREFIX])
AC_REQUIRE([AC_LIB_RPATH])
dnl Sometimes libintl requires libiconv, so first search for libiconv.
dnl Ideally we would do this search only after the
dnl if test "$USE_NLS" = "yes"; then
dnl if test "$gt_cv_func_gnugettext_libc" != "yes"; then
dnl tests. But if configure.in invokes AM_ICONV after AM_GNU_GETTEXT
dnl the configure script would need to contain the same shell code
dnl again, outside any 'if'. There are two solutions:
dnl - Invoke AM_ICONV_LINKFLAGS_BODY here, outside any 'if'.
dnl - Control the expansions in more detail using AC_PROVIDE_IFELSE.
dnl Since AC_PROVIDE_IFELSE is only in autoconf >= 2.52 and not
dnl documented, we avoid it.
ifelse(gt_included_intl, yes, , [
AC_REQUIRE([AM_ICONV_LINKFLAGS_BODY])
])
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)
ifelse(gt_included_intl, yes, [
BUILD_INCLUDED_LIBINTL=no
USE_INCLUDED_LIBINTL=no
])
LIBINTL=
LTLIBINTL=
POSUB=
dnl If we use NLS figure out what method
if test "$USE_NLS" = "yes"; then
gt_use_preinstalled_gnugettext=no
ifelse(gt_included_intl, yes, [
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 GNU gettext is available we use this. Else we have
dnl to fall back to GNU NLS library.
dnl Add a version number to the cache macros.
define([gt_api_version], ifelse([$2], [need-formatstring-macros], 3, ifelse([$2], [need-ngettext], 2, 1)))
define([gt_cv_func_gnugettext_libc], [gt_cv_func_gnugettext]gt_api_version[_libc])
define([gt_cv_func_gnugettext_libintl], [gt_cv_func_gnugettext]gt_api_version[_libintl])
AC_CACHE_CHECK([for GNU gettext in libc], gt_cv_func_gnugettext_libc,
[AC_TRY_LINK([#include <libintl.h>
]ifelse([$2], [need-formatstring-macros],
[#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
#define __GNU_GETTEXT_SUPPORTED_REVISION(major) ((major) == 0 ? 0 : -1)
#endif
changequote(,)dnl
typedef int array [2 * (__GNU_GETTEXT_SUPPORTED_REVISION(0) >= 1) - 1];
changequote([,])dnl
], [])[extern int _nl_msg_cat_cntr;
extern int *_nl_domain_bindings;],
[bindtextdomain ("", "");
return (int) gettext ("")]ifelse([$2], [need-ngettext], [ + (int) ngettext ("", "", 0)], [])[ + _nl_msg_cat_cntr + *_nl_domain_bindings],
gt_cv_func_gnugettext_libc=yes,
gt_cv_func_gnugettext_libc=no)])
if test "$gt_cv_func_gnugettext_libc" != "yes"; then
dnl Sometimes libintl requires libiconv, so first search for libiconv.
ifelse(gt_included_intl, yes, , [
AM_ICONV_LINK
])
dnl Search for libintl and define LIBINTL, LTLIBINTL and INCINTL
dnl accordingly. Don't use AC_LIB_LINKFLAGS_BODY([intl],[iconv])
dnl because that would add "-liconv" to LIBINTL and LTLIBINTL
dnl even if libiconv doesn't exist.
AC_LIB_LINKFLAGS_BODY([intl])
AC_CACHE_CHECK([for GNU gettext in libintl],
gt_cv_func_gnugettext_libintl,
[gt_save_CPPFLAGS="$CPPFLAGS"
CPPFLAGS="$CPPFLAGS $INCINTL"
gt_save_LIBS="$LIBS"
LIBS="$LIBS $LIBINTL"
dnl Now see whether libintl exists and does not depend on libiconv.
AC_TRY_LINK([#include <libintl.h>
]ifelse([$2], [need-formatstring-macros],
[#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
#define __GNU_GETTEXT_SUPPORTED_REVISION(major) ((major) == 0 ? 0 : -1)
#endif
changequote(,)dnl
typedef int array [2 * (__GNU_GETTEXT_SUPPORTED_REVISION(0) >= 1) - 1];
changequote([,])dnl
], [])[extern int _nl_msg_cat_cntr;
extern
#ifdef __cplusplus
"C"
#endif
const char *_nl_expand_alias ();],
[bindtextdomain ("", "");
return (int) gettext ("")]ifelse([$2], [need-ngettext], [ + (int) ngettext ("", "", 0)], [])[ + _nl_msg_cat_cntr + *_nl_expand_alias (0)],
gt_cv_func_gnugettext_libintl=yes,
gt_cv_func_gnugettext_libintl=no)
dnl Now see whether libintl exists and depends on libiconv.
if test "$gt_cv_func_gnugettext_libintl" != yes && test -n "$LIBICONV"; then
LIBS="$LIBS $LIBICONV"
AC_TRY_LINK([#include <libintl.h>
]ifelse([$2], [need-formatstring-macros],
[#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
#define __GNU_GETTEXT_SUPPORTED_REVISION(major) ((major) == 0 ? 0 : -1)
#endif
changequote(,)dnl
typedef int array [2 * (__GNU_GETTEXT_SUPPORTED_REVISION(0) >= 1) - 1];
changequote([,])dnl
], [])[extern int _nl_msg_cat_cntr;
extern
#ifdef __cplusplus
"C"
#endif
const char *_nl_expand_alias ();],
[bindtextdomain ("", "");
return (int) gettext ("")]ifelse([$2], [need-ngettext], [ + (int) ngettext ("", "", 0)], [])[ + _nl_msg_cat_cntr + *_nl_expand_alias (0)],
[LIBINTL="$LIBINTL $LIBICONV"
LTLIBINTL="$LTLIBINTL $LTLIBICONV"
gt_cv_func_gnugettext_libintl=yes
])
fi
CPPFLAGS="$gt_save_CPPFLAGS"
LIBS="$gt_save_LIBS"])
fi
dnl If an already present or preinstalled GNU gettext() is found,
dnl use it. But if this macro is used in GNU gettext, and GNU
dnl gettext is already preinstalled in libintl, we update this
dnl libintl. (Cf. the install rule in intl/Makefile.in.)
if test "$gt_cv_func_gnugettext_libc" = "yes" \
|| { test "$gt_cv_func_gnugettext_libintl" = "yes" \
&& test "$PACKAGE" != gettext; }; then
gt_use_preinstalled_gnugettext=yes
else
dnl Reset the values set by searching for libintl.
LIBINTL=
LTLIBINTL=
INCINTL=
fi
ifelse(gt_included_intl, yes, [
if test "$gt_use_preinstalled_gnugettext" != "yes"; then
dnl GNU gettext is not found in the C library.
dnl Fall back on included 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)"
BUILD_INCLUDED_LIBINTL=yes
USE_INCLUDED_LIBINTL=yes
LIBINTL="ifelse([$3],[],\${top_builddir}/intl,[$3])/libintl.[]gt_libtool_suffix_prefix[]a $LIBICONV"
LTLIBINTL="ifelse([$3],[],\${top_builddir}/intl,[$3])/libintl.[]gt_libtool_suffix_prefix[]a $LTLIBICONV"
LIBS=`echo " $LIBS " | sed -e 's/ -lintl / /' -e 's/^ //' -e 's/ $//'`
fi
if test "$gt_use_preinstalled_gnugettext" = "yes" \
|| test "$nls_cv_use_gnu_gettext" = "yes"; then
dnl Mark actions to use GNU gettext tools.
CATOBJEXT=.gmo
fi
])
if test "$gt_use_preinstalled_gnugettext" = "yes" \
|| test "$nls_cv_use_gnu_gettext" = "yes"; then
AC_DEFINE(ENABLE_NLS, 1,
[Define to 1 if translation of program messages to the user's native language
is requested.])
else
USE_NLS=no
fi
fi
if test "$USE_NLS" = "yes"; then
if test "$gt_use_preinstalled_gnugettext" = "yes"; then
if test "$gt_cv_func_gnugettext_libintl" = "yes"; then
AC_MSG_CHECKING([how to link with libintl])
AC_MSG_RESULT([$LIBINTL])
AC_LIB_APPENDTOVAR([CPPFLAGS], [$INCINTL])
fi
dnl For backward compatibility. Some packages may be using this.
AC_DEFINE(HAVE_GETTEXT, 1,
[Define if the GNU gettext() function is already present or preinstalled.])
AC_DEFINE(HAVE_DCGETTEXT, 1,
[Define if the GNU dcgettext() function is already present or preinstalled.])
fi
dnl We need to process the po/ directory.
POSUB=po
fi
ifelse(gt_included_intl, yes, [
dnl If this is used in GNU gettext we have to set BUILD_INCLUDED_LIBINTL
dnl to 'yes' because some of the testsuite requires it.
if test "$PACKAGE" = gettext; then
BUILD_INCLUDED_LIBINTL=yes
fi
dnl Make all variables we use known to autoconf.
AC_SUBST(BUILD_INCLUDED_LIBINTL)
AC_SUBST(USE_INCLUDED_LIBINTL)
AC_SUBST(CATOBJEXT)
AC_SUBST(INTLOBJS)
dnl For backward compatibility. Some configure.ins may be using this.
nls_cv_header_intl=
nls_cv_header_libgt=
dnl For backward compatibility. Some Makefiles may be using this.
DATADIRNAME=share
AC_SUBST(DATADIRNAME)
dnl For backward compatibility. Some Makefiles may be using this.
INSTOBJEXT=.mo
AC_SUBST(INSTOBJEXT)
dnl For backward compatibility. Some Makefiles may be using this.
GENCAT=gencat
AC_SUBST(GENCAT)
dnl Enable libtool support if the surrounding package wishes it.
INTL_LIBTOOL_SUFFIX_PREFIX=gt_libtool_suffix_prefix
AC_SUBST(INTL_LIBTOOL_SUFFIX_PREFIX)
])
dnl For backward compatibility. Some Makefiles may be using this.
INTLLIBS="$LIBINTL"
AC_SUBST(INTLLIBS)
dnl Make all documented variables known to autoconf.
AC_SUBST(LIBINTL)
AC_SUBST(LTLIBINTL)
AC_SUBST(POSUB)
])
dnl Checks for all prerequisites of the po subdirectory,
dnl except for USE_NLS.
AC_DEFUN([AM_PO_SUBDIRS],
[
AC_REQUIRE([AC_PROG_MAKE_SET])dnl
AC_REQUIRE([AC_PROG_INSTALL])dnl
AC_REQUIRE([AM_MKINSTALLDIRS])dnl
dnl Perform the following tests also if --disable-nls has been given,
dnl because they are needed for "make dist" to work.
dnl Search for GNU msgfmt in the PATH.
dnl The first test excludes Solaris msgfmt and early GNU msgfmt versions.
dnl The second test excludes FreeBSD msgfmt.
AM_PATH_PROG_WITH_TEST(MSGFMT, msgfmt,
[$ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1 &&
(if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi)],
:)
AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT)
dnl Search for GNU xgettext 0.11 or newer in the PATH.
dnl The first test excludes Solaris xgettext and early GNU xgettext versions.
dnl The second test excludes FreeBSD xgettext.
AM_PATH_PROG_WITH_TEST(XGETTEXT, xgettext,
[$ac_dir/$ac_word --omit-header --copyright-holder= /dev/null >/dev/null 2>&1 &&
(if $ac_dir/$ac_word --omit-header --copyright-holder= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi)],
:)
dnl Remove leftover from FreeBSD xgettext call.
rm -f messages.po
dnl Search for GNU msgmerge 0.11 or newer in the PATH.
AM_PATH_PROG_WITH_TEST(MSGMERGE, msgmerge,
[$ac_dir/$ac_word --update -q /dev/null /dev/null >/dev/null 2>&1], :)
dnl This could go away some day; the PATH_PROG_WITH_TEST already does it.
dnl Test whether we really found GNU msgfmt.
if test "$GMSGFMT" != ":"; then
dnl If it is no GNU msgfmt we define it as : so that the
dnl Makefiles still can work.
if $GMSGFMT --statistics /dev/null >/dev/null 2>&1 &&
(if $GMSGFMT --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
: ;
else
GMSGFMT=`echo "$GMSGFMT" | sed -e 's,^.*/,,'`
AC_MSG_RESULT(
[found $GMSGFMT program is not GNU msgfmt; ignore it])
GMSGFMT=":"
fi
fi
dnl This could go away some day; the PATH_PROG_WITH_TEST already does it.
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 --copyright-holder= /dev/null >/dev/null 2>&1 &&
(if $XGETTEXT --omit-header --copyright-holder= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
: ;
else
AC_MSG_RESULT(
[found xgettext program is not GNU xgettext; ignore it])
XGETTEXT=":"
fi
dnl Remove leftover from FreeBSD xgettext call.
rm -f messages.po
fi
AC_OUTPUT_COMMANDS([
for ac_file in $CONFIG_FILES; do
# Support "outfile[:infile[:infile...]]"
case "$ac_file" in
*:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
esac
# PO directories have a Makefile.in generated from Makefile.in.in.
case "$ac_file" in */Makefile.in)
# Adjust a relative srcdir.
ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
ac_dir_suffix="/`echo "$ac_dir"|sed 's%^\./%%'`"
ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
# In autoconf-2.13 it is called $ac_given_srcdir.
# In autoconf-2.50 it is called $srcdir.
test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
case "$ac_given_srcdir" in
.) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;;
/*) top_srcdir="$ac_given_srcdir" ;;
*) top_srcdir="$ac_dots$ac_given_srcdir" ;;
esac
if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then
rm -f "$ac_dir/POTFILES"
test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES"
cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ]*\$/d" -e "s,.*, $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES"
# ALL_LINGUAS, POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES depend
# on $ac_dir but don't depend on user-specified configuration
# parameters.
if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then
# The LINGUAS file contains the set of available languages.
if test -n "$ALL_LINGUAS"; then
test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.in is obsolete" || echo "setting ALL_LINGUAS in configure.in is obsolete"
fi
ALL_LINGUAS_=`sed -e "/^#/d" "$ac_given_srcdir/$ac_dir/LINGUAS"`
# Hide the ALL_LINGUAS assigment from automake.
eval 'ALL_LINGUAS''=$ALL_LINGUAS_'
fi
case "$ac_given_srcdir" in
.) srcdirpre= ;;
*) srcdirpre='$(srcdir)/' ;;
esac
POFILES=
GMOFILES=
UPDATEPOFILES=
DUMMYPOFILES=
for lang in $ALL_LINGUAS; do
POFILES="$POFILES $srcdirpre$lang.po"
GMOFILES="$GMOFILES $srcdirpre$lang.gmo"
UPDATEPOFILES="$UPDATEPOFILES $lang.po-update"
DUMMYPOFILES="$DUMMYPOFILES $lang.nop"
done
# CATALOGS depends on both $ac_dir and the user's LINGUAS
# environment variable.
INST_LINGUAS=
if test -n "$ALL_LINGUAS"; then
for presentlang in $ALL_LINGUAS; do
useit=no
if test "%UNSET%" != "$LINGUAS"; then
desiredlanguages="$LINGUAS"
else
desiredlanguages="$ALL_LINGUAS"
fi
for desiredlang in $desiredlanguages; do
# Use the presentlang catalog if desiredlang is
# a. equal to presentlang, or
# b. a variant of presentlang (because in this case,
# presentlang can be used as a fallback for messages
# which are not translated in the desiredlang catalog).
case "$desiredlang" in
"$presentlang"*) useit=yes;;
esac
done
if test $useit = yes; then
INST_LINGUAS="$INST_LINGUAS $presentlang"
fi
done
fi
CATALOGS=
if test -n "$INST_LINGUAS"; then
for lang in $INST_LINGUAS; do
CATALOGS="$CATALOGS $lang.gmo"
done
fi
test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile"
sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile"
for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do
if test -f "$f"; then
case "$f" in
*.orig | *.bak | *~) ;;
*) cat "$f" >> "$ac_dir/Makefile" ;;
esac
fi
done
fi
;;
esac
done],
[# Capture the value of obsolete ALL_LINGUAS because we need it to compute
# POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES, CATALOGS. But hide it
# from automake.
eval 'ALL_LINGUAS''="$ALL_LINGUAS"'
# Capture the value of LINGUAS because we need it to compute CATALOGS.
LINGUAS="${LINGUAS-%UNSET%}"
])
])
dnl Checks for all prerequisites of the intl subdirectory,
dnl except for INTL_LIBTOOL_SUFFIX_PREFIX (and possibly LIBTOOL), INTLOBJS,
dnl USE_INCLUDED_LIBINTL, BUILD_INCLUDED_LIBINTL.
AC_DEFUN([AM_INTL_SUBDIR],
[
AC_REQUIRE([AC_PROG_INSTALL])dnl
AC_REQUIRE([AM_MKINSTALLDIRS])dnl
AC_REQUIRE([AC_PROG_CC])dnl
AC_REQUIRE([AC_CANONICAL_HOST])dnl
AC_REQUIRE([AC_PROG_RANLIB])dnl
AC_REQUIRE([AC_ISC_POSIX])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_REQUIRE([jm_GLIBC21])dnl
AC_REQUIRE([gt_INTDIV0])dnl
AC_REQUIRE([jm_AC_TYPE_UINTMAX_T])dnl
AC_REQUIRE([gt_HEADER_INTTYPES_H])dnl
AC_REQUIRE([gt_INTTYPES_PRI])dnl
AC_CHECK_HEADERS([argz.h limits.h locale.h nl_types.h malloc.h stddef.h \
stdlib.h string.h unistd.h sys/param.h])
AC_CHECK_FUNCS([feof_unlocked fgets_unlocked getc_unlocked getcwd getegid \
geteuid getgid getuid mempcpy munmap putenv setenv setlocale stpcpy \
strcasecmp strdup strtoul tsearch __argz_count __argz_stringify __argz_next])
AM_ICONV
AM_LANGINFO_CODESET
if test $ac_cv_header_locale_h = yes; then
AM_LC_MESSAGES
fi
dnl intl/plural.c is generated from intl/plural.y. It requires bison,
dnl because plural.y uses bison specific features. It requires at least
dnl bison-1.26 because earlier versions generate a plural.c that doesn't
dnl compile.
dnl bison is only needed for the maintainer (who touches plural.y). But in
dnl order to avoid separate Makefiles or --enable-maintainer-mode, we put
dnl the rule in general Makefile. Now, some people carelessly touch the
dnl files or have a broken "make" program, hence the plural.c rule will
dnl sometimes fire. To avoid an error, defines BISON to ":" if it is not
dnl present or too old.
AC_CHECK_PROGS([INTLBISON], [bison])
if test -z "$INTLBISON"; then
ac_verc_fail=yes
else
dnl Found it, now check the version.
AC_MSG_CHECKING([version of bison])
changequote(<<,>>)dnl
ac_prog_version=`$INTLBISON --version 2>&1 | sed -n 's/^.*GNU Bison.* \([0-9]*\.[0-9.]*\).*$/\1/p'`
case $ac_prog_version in
'') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
1.2[6-9]* | 1.[3-9][0-9]* | [2-9].*)
changequote([,])dnl
ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;;
*) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
esac
AC_MSG_RESULT([$ac_prog_version])
fi
if test $ac_verc_fail = yes; then
INTLBISON=:
fi
])
AC_DEFUN([AM_MKINSTALLDIRS],
[
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 -n "$ac_aux_dir"; then
MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs"
fi
if test -z "$MKINSTALLDIRS"; then
MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs"
fi
AC_SUBST(MKINSTALLDIRS)
])
dnl Usage: AM_GNU_GETTEXT_VERSION([gettext-version])
AC_DEFUN([AM_GNU_GETTEXT_VERSION], [])

32
m4/glibc21.m4 Normal file
View File

@@ -0,0 +1,32 @@
# glibc21.m4 serial 2 (fileutils-4.1.3, gettext-0.10.40)
dnl Copyright (C) 2000-2002 Free Software Foundation, Inc.
dnl This file is free software, distributed under the terms of the GNU
dnl General Public License. As a special exception to the GNU General
dnl Public License, this file may be distributed as part of a program
dnl that contains a configuration script generated by Autoconf, under
dnl the same distribution terms as the rest of that program.
# Test for the GNU C Library, version 2.1 or newer.
# From Bruno Haible.
AC_DEFUN([jm_GLIBC21],
[
AC_CACHE_CHECK(whether we are using the GNU C Library 2.1 or newer,
ac_cv_gnu_library_2_1,
[AC_EGREP_CPP([Lucky GNU user],
[
#include <features.h>
#ifdef __GNU_LIBRARY__
#if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2)
Lucky GNU user
#endif
#endif
],
ac_cv_gnu_library_2_1=yes,
ac_cv_gnu_library_2_1=no)
]
)
AC_SUBST(GLIBC21)
GLIBC21="$ac_cv_gnu_library_2_1"
]
)

103
m4/iconv.m4 Normal file
View File

@@ -0,0 +1,103 @@
# iconv.m4 serial AM4 (gettext-0.11.3)
dnl Copyright (C) 2000-2002 Free Software Foundation, Inc.
dnl This file is free software, distributed under the terms of the GNU
dnl General Public License. As a special exception to the GNU General
dnl Public License, this file may be distributed as part of a program
dnl that contains a configuration script generated by Autoconf, under
dnl the same distribution terms as the rest of that program.
dnl From Bruno Haible.
AC_DEFUN([AM_ICONV_LINKFLAGS_BODY],
[
dnl Prerequisites of AC_LIB_LINKFLAGS_BODY.
AC_REQUIRE([AC_LIB_PREPARE_PREFIX])
AC_REQUIRE([AC_LIB_RPATH])
dnl Search for libiconv and define LIBICONV, LTLIBICONV and INCICONV
dnl accordingly.
AC_LIB_LINKFLAGS_BODY([iconv])
])
AC_DEFUN([AM_ICONV_LINK],
[
dnl Some systems have iconv in libc, some have it in libiconv (OSF/1 and
dnl those with the standalone portable GNU libiconv installed).
dnl Search for libiconv and define LIBICONV, LTLIBICONV and INCICONV
dnl accordingly.
AC_REQUIRE([AM_ICONV_LINKFLAGS_BODY])
dnl Add $INCICONV to CPPFLAGS before performing the following checks,
dnl because if the user has installed libiconv and not disabled its use
dnl via --without-libiconv-prefix, he wants to use it. The first
dnl AC_TRY_LINK will then fail, the second AC_TRY_LINK will succeed.
am_save_CPPFLAGS="$CPPFLAGS"
AC_LIB_APPENDTOVAR([CPPFLAGS], [$INCICONV])
AC_CACHE_CHECK(for iconv, am_cv_func_iconv, [
am_cv_func_iconv="no, consider installing GNU libiconv"
am_cv_lib_iconv=no
AC_TRY_LINK([#include <stdlib.h>
#include <iconv.h>],
[iconv_t cd = iconv_open("","");
iconv(cd,NULL,NULL,NULL,NULL);
iconv_close(cd);],
am_cv_func_iconv=yes)
if test "$am_cv_func_iconv" != yes; then
am_save_LIBS="$LIBS"
LIBS="$LIBS $LIBICONV"
AC_TRY_LINK([#include <stdlib.h>
#include <iconv.h>],
[iconv_t cd = iconv_open("","");
iconv(cd,NULL,NULL,NULL,NULL);
iconv_close(cd);],
am_cv_lib_iconv=yes
am_cv_func_iconv=yes)
LIBS="$am_save_LIBS"
fi
])
if test "$am_cv_func_iconv" = yes; then
AC_DEFINE(HAVE_ICONV, 1, [Define if you have the iconv() function.])
fi
if test "$am_cv_lib_iconv" = yes; then
AC_MSG_CHECKING([how to link with libiconv])
AC_MSG_RESULT([$LIBICONV])
else
dnl If $LIBICONV didn't lead to a usable library, we don't need $INCICONV
dnl either.
CPPFLAGS="$am_save_CPPFLAGS"
LIBICONV=
LTLIBICONV=
fi
AC_SUBST(LIBICONV)
AC_SUBST(LTLIBICONV)
])
AC_DEFUN([AM_ICONV],
[
AM_ICONV_LINK
if test "$am_cv_func_iconv" = yes; then
AC_MSG_CHECKING([for iconv declaration])
AC_CACHE_VAL(am_cv_proto_iconv, [
AC_TRY_COMPILE([
#include <stdlib.h>
#include <iconv.h>
extern
#ifdef __cplusplus
"C"
#endif
#if defined(__STDC__) || defined(__cplusplus)
size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);
#else
size_t iconv();
#endif
], [], am_cv_proto_iconv_arg1="", am_cv_proto_iconv_arg1="const")
am_cv_proto_iconv="extern size_t iconv (iconv_t cd, $am_cv_proto_iconv_arg1 char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);"])
am_cv_proto_iconv=`echo "[$]am_cv_proto_iconv" | tr -s ' ' | sed -e 's/( /(/'`
AC_MSG_RESULT([$]{ac_t:-
}[$]am_cv_proto_iconv)
AC_DEFINE_UNQUOTED(ICONV_CONST, $am_cv_proto_iconv_arg1,
[Define as const if the declaration of iconv() needs const.])
fi
])

72
m4/intdiv0.m4 Normal file
View File

@@ -0,0 +1,72 @@
# intdiv0.m4 serial 1 (gettext-0.11.3)
dnl Copyright (C) 2002 Free Software Foundation, Inc.
dnl This file is free software, distributed under the terms of the GNU
dnl General Public License. As a special exception to the GNU General
dnl Public License, this file may be distributed as part of a program
dnl that contains a configuration script generated by Autoconf, under
dnl the same distribution terms as the rest of that program.
dnl From Bruno Haible.
AC_DEFUN([gt_INTDIV0],
[
AC_REQUIRE([AC_PROG_CC])dnl
AC_REQUIRE([AC_CANONICAL_HOST])dnl
AC_CACHE_CHECK([whether integer division by zero raises SIGFPE],
gt_cv_int_divbyzero_sigfpe,
[
AC_TRY_RUN([
#include <stdlib.h>
#include <signal.h>
static void
#ifdef __cplusplus
sigfpe_handler (int sig)
#else
sigfpe_handler (sig) int sig;
#endif
{
/* Exit with code 0 if SIGFPE, with code 1 if any other signal. */
exit (sig != SIGFPE);
}
int x = 1;
int y = 0;
int z;
int nan;
int main ()
{
signal (SIGFPE, sigfpe_handler);
/* IRIX and AIX (when "xlc -qcheck" is used) yield signal SIGTRAP. */
#if (defined (__sgi) || defined (_AIX)) && defined (SIGTRAP)
signal (SIGTRAP, sigfpe_handler);
#endif
/* Linux/SPARC yields signal SIGILL. */
#if defined (__sparc__) && defined (__linux__)
signal (SIGILL, sigfpe_handler);
#endif
z = x / y;
nan = y / y;
exit (1);
}
], gt_cv_int_divbyzero_sigfpe=yes, gt_cv_int_divbyzero_sigfpe=no,
[
# Guess based on the CPU.
case "$host_cpu" in
alpha* | i[34567]86 | m68k | s390*)
gt_cv_int_divbyzero_sigfpe="guessing yes";;
*)
gt_cv_int_divbyzero_sigfpe="guessing no";;
esac
])
])
case "$gt_cv_int_divbyzero_sigfpe" in
*yes) value=1;;
*) value=0;;
esac
AC_DEFINE_UNQUOTED(INTDIV0_RAISES_SIGFPE, $value,
[Define if integer division by zero raises signal SIGFPE.])
])

32
m4/inttypes-pri.m4 Normal file
View File

@@ -0,0 +1,32 @@
# inttypes-pri.m4 serial 1 (gettext-0.11.4)
dnl Copyright (C) 1997-2002 Free Software Foundation, Inc.
dnl This file is free software, distributed under the terms of the GNU
dnl General Public License. As a special exception to the GNU General
dnl Public License, this file may be distributed as part of a program
dnl that contains a configuration script generated by Autoconf, under
dnl the same distribution terms as the rest of that program.
dnl From Bruno Haible.
# Define PRI_MACROS_BROKEN if <inttypes.h> exists and defines the PRI*
# macros to non-string values. This is the case on AIX 4.3.3.
AC_DEFUN([gt_INTTYPES_PRI],
[
AC_REQUIRE([gt_HEADER_INTTYPES_H])
if test $gt_cv_header_inttypes_h = yes; then
AC_CACHE_CHECK([whether the inttypes.h PRIxNN macros are broken],
gt_cv_inttypes_pri_broken,
[
AC_TRY_COMPILE([#include <inttypes.h>
#ifdef PRId32
char *p = PRId32;
#endif
], [], gt_cv_inttypes_pri_broken=no, gt_cv_inttypes_pri_broken=yes)
])
fi
if test "$gt_cv_inttypes_pri_broken" = yes; then
AC_DEFINE_UNQUOTED(PRI_MACROS_BROKEN, 1,
[Define if <inttypes.h> exists and defines unusable PRI* macros.])
fi
])

27
m4/inttypes.m4 Normal file
View File

@@ -0,0 +1,27 @@
# inttypes.m4 serial 1 (gettext-0.11.4)
dnl Copyright (C) 1997-2002 Free Software Foundation, Inc.
dnl This file is free software, distributed under the terms of the GNU
dnl General Public License. As a special exception to the GNU General
dnl Public License, this file may be distributed as part of a program
dnl that contains a configuration script generated by Autoconf, under
dnl the same distribution terms as the rest of that program.
dnl From Paul Eggert.
# Define HAVE_INTTYPES_H if <inttypes.h> exists and doesn't clash with
# <sys/types.h>.
AC_DEFUN([gt_HEADER_INTTYPES_H],
[
AC_CACHE_CHECK([for inttypes.h], gt_cv_header_inttypes_h,
[
AC_TRY_COMPILE(
[#include <sys/types.h>
#include <inttypes.h>],
[], gt_cv_header_inttypes_h=yes, gt_cv_header_inttypes_h=no)
])
if test $gt_cv_header_inttypes_h = yes; then
AC_DEFINE_UNQUOTED(HAVE_INTTYPES_H, 1,
[Define if <inttypes.h> exists and doesn't clash with <sys/types.h>.])
fi
])

28
m4/inttypes_h.m4 Normal file
View File

@@ -0,0 +1,28 @@
# inttypes_h.m4 serial 4 (gettext-0.11.4)
dnl Copyright (C) 1997-2002 Free Software Foundation, Inc.
dnl This file is free software, distributed under the terms of the GNU
dnl General Public License. As a special exception to the GNU General
dnl Public License, this file may be distributed as part of a program
dnl that contains a configuration script generated by Autoconf, under
dnl the same distribution terms as the rest of that program.
dnl From Paul Eggert.
# Define HAVE_INTTYPES_H_WITH_UINTMAX if <inttypes.h> exists,
# doesn't clash with <sys/types.h>, and declares uintmax_t.
AC_DEFUN([jm_AC_HEADER_INTTYPES_H],
[
AC_CACHE_CHECK([for inttypes.h], jm_ac_cv_header_inttypes_h,
[AC_TRY_COMPILE(
[#include <sys/types.h>
#include <inttypes.h>],
[uintmax_t i = (uintmax_t) -1;],
jm_ac_cv_header_inttypes_h=yes,
jm_ac_cv_header_inttypes_h=no)])
if test $jm_ac_cv_header_inttypes_h = yes; then
AC_DEFINE_UNQUOTED(HAVE_INTTYPES_H_WITH_UINTMAX, 1,
[Define if <inttypes.h> exists, doesn't clash with <sys/types.h>,
and declares uintmax_t. ])
fi
])

26
m4/isc-posix.m4 Normal file
View File

@@ -0,0 +1,26 @@
# isc-posix.m4 serial 2 (gettext-0.11.2)
dnl Copyright (C) 1995-2002 Free Software Foundation, Inc.
dnl This file is free software, distributed under the terms of the GNU
dnl General Public License. As a special exception to the GNU General
dnl Public License, this file may be distributed as part of a program
dnl that contains a configuration script generated by Autoconf, under
dnl the same distribution terms as the rest of that program.
# This file is not needed with autoconf-2.53 and newer. Remove it in 2005.
# This test replaces the one in autoconf.
# Currently this macro should have the same name as the autoconf macro
# because gettext's gettext.m4 (distributed in the automake package)
# still uses it. Otherwise, the use in gettext.m4 makes autoheader
# give these diagnostics:
# configure.in:556: AC_TRY_COMPILE was called before AC_ISC_POSIX
# configure.in:556: AC_TRY_RUN was called before AC_ISC_POSIX
undefine([AC_ISC_POSIX])
AC_DEFUN([AC_ISC_POSIX],
[
dnl This test replaces the obsolescent AC_ISC_POSIX kludge.
AC_CHECK_LIB(cposix, strerror, [LIBS="$LIBS -lcposix"])
]
)

32
m4/lcmessage.m4 Normal file
View File

@@ -0,0 +1,32 @@
# lcmessage.m4 serial 3 (gettext-0.11.3)
dnl Copyright (C) 1995-2002 Free Software Foundation, Inc.
dnl This file is free software, distributed under the terms of the GNU
dnl General Public License. As a special exception to the GNU General
dnl Public License, this file may be distributed as part of a program
dnl that contains a configuration script generated by Autoconf, under
dnl the same distribution terms as the rest of that program.
dnl
dnl This file can can be used in projects which are not available under
dnl the GNU General Public License or the GNU Library General Public
dnl License but which still want to provide support for the GNU gettext
dnl functionality.
dnl Please note that the actual code of the GNU gettext library is covered
dnl by the GNU Library General Public License, and the rest of the GNU
dnl gettext package package is covered by the GNU General Public License.
dnl They are *not* in the public domain.
dnl Authors:
dnl Ulrich Drepper <drepper@cygnus.com>, 1995.
# Check whether LC_MESSAGES is available in <locale.h>.
AC_DEFUN([AM_LC_MESSAGES],
[
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, 1,
[Define if your <locale.h> file defines LC_MESSAGES.])
fi
])

97
m4/lib-ld.m4 Normal file
View File

@@ -0,0 +1,97 @@
# lib-ld.m4 serial 1 (gettext-0.11)
dnl Copyright (C) 1996-2002 Free Software Foundation, Inc.
dnl This file is free software, distributed under the terms of the GNU
dnl General Public License. As a special exception to the GNU General
dnl Public License, this file may be distributed as part of a program
dnl that contains a configuration script generated by Autoconf, under
dnl the same distribution terms as the rest of that program.
dnl Subroutines of libtool.m4,
dnl with replacements s/AC_/AC_LIB/ and s/lt_cv/acl_cv/ to avoid collision
dnl with libtool.m4.
dnl From libtool-1.4. Sets the variable with_gnu_ld to yes or no.
AC_DEFUN([AC_LIB_PROG_LD_GNU],
[AC_CACHE_CHECK([if the linker ($LD) is GNU ld], acl_cv_prog_gnu_ld,
[# I'd rather use --version here, but apparently some GNU ld's only accept -v.
if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
acl_cv_prog_gnu_ld=yes
else
acl_cv_prog_gnu_ld=no
fi])
with_gnu_ld=$acl_cv_prog_gnu_ld
])
dnl From libtool-1.4. Sets the variable LD.
AC_DEFUN([AC_LIB_PROG_LD],
[AC_ARG_WITH(gnu-ld,
[ --with-gnu-ld assume the C compiler uses GNU ld [default=no]],
test "$withval" = no || with_gnu_ld=yes, with_gnu_ld=no)
AC_REQUIRE([AC_PROG_CC])dnl
AC_REQUIRE([AC_CANONICAL_HOST])dnl
ac_prog=ld
if test "$GCC" = yes; then
# Check if gcc -print-prog-name=ld gives a path.
AC_MSG_CHECKING([for ld used by GCC])
case $host in
*-*-mingw*)
# gcc leaves a trailing carriage return which upsets mingw
ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
*)
ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
esac
case $ac_prog in
# Accept absolute paths.
[[\\/]* | [A-Za-z]:[\\/]*)]
[re_direlt='/[^/][^/]*/\.\./']
# Canonicalize the path of ld
ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
done
test -z "$LD" && LD="$ac_prog"
;;
"")
# If it fails, then pretend we aren't using GCC.
ac_prog=ld
;;
*)
# If it is relative, then search for the first ld in PATH.
with_gnu_ld=unknown
;;
esac
elif test "$with_gnu_ld" = yes; then
AC_MSG_CHECKING([for GNU ld])
else
AC_MSG_CHECKING([for non-GNU ld])
fi
AC_CACHE_VAL(acl_cv_path_LD,
[if test -z "$LD"; then
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
for ac_dir in $PATH; do
test -z "$ac_dir" && ac_dir=.
if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
acl_cv_path_LD="$ac_dir/$ac_prog"
# Check to see if the program is GNU ld. I'd rather use --version,
# but apparently some GNU ld's only accept -v.
# Break only if it was the GNU/non-GNU ld that we prefer.
if "$acl_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
test "$with_gnu_ld" != no && break
else
test "$with_gnu_ld" != yes && break
fi
fi
done
IFS="$ac_save_ifs"
else
acl_cv_path_LD="$LD" # Let the user override the test with a path.
fi])
LD="$acl_cv_path_LD"
if test -n "$LD"; then
AC_MSG_RESULT($LD)
else
AC_MSG_RESULT(no)
fi
test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
AC_LIB_PROG_LD_GNU
])

554
m4/lib-link.m4 Normal file
View File

@@ -0,0 +1,554 @@
# lib-link.m4 serial 3 (gettext-0.11.3)
dnl Copyright (C) 2001-2002 Free Software Foundation, Inc.
dnl This file is free software, distributed under the terms of the GNU
dnl General Public License. As a special exception to the GNU General
dnl Public License, this file may be distributed as part of a program
dnl that contains a configuration script generated by Autoconf, under
dnl the same distribution terms as the rest of that program.
dnl From Bruno Haible.
dnl AC_LIB_LINKFLAGS(name [, dependencies]) searches for libname and
dnl the libraries corresponding to explicit and implicit dependencies.
dnl Sets and AC_SUBSTs the LIB${NAME} and LTLIB${NAME} variables and
dnl augments the CPPFLAGS variable.
AC_DEFUN([AC_LIB_LINKFLAGS],
[
AC_REQUIRE([AC_LIB_PREPARE_PREFIX])
AC_REQUIRE([AC_LIB_RPATH])
define([Name],[translit([$1],[./-], [___])])
define([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-],
[ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])
AC_CACHE_CHECK([how to link with lib[]$1], [ac_cv_lib[]Name[]_libs], [
AC_LIB_LINKFLAGS_BODY([$1], [$2])
ac_cv_lib[]Name[]_libs="$LIB[]NAME"
ac_cv_lib[]Name[]_ltlibs="$LTLIB[]NAME"
ac_cv_lib[]Name[]_cppflags="$INC[]NAME"
])
LIB[]NAME="$ac_cv_lib[]Name[]_libs"
LTLIB[]NAME="$ac_cv_lib[]Name[]_ltlibs"
INC[]NAME="$ac_cv_lib[]Name[]_cppflags"
AC_LIB_APPENDTOVAR([CPPFLAGS], [$INC]NAME)
AC_SUBST([LIB]NAME)
AC_SUBST([LTLIB]NAME)
dnl Also set HAVE_LIB[]NAME so that AC_LIB_HAVE_LINKFLAGS can reuse the
dnl results of this search when this library appears as a dependency.
HAVE_LIB[]NAME=yes
undefine([Name])
undefine([NAME])
])
dnl AC_LIB_HAVE_LINKFLAGS(name, dependencies, includes, testcode)
dnl searches for libname and the libraries corresponding to explicit and
dnl implicit dependencies, together with the specified include files and
dnl the ability to compile and link the specified testcode. If found, it
dnl sets and AC_SUBSTs HAVE_LIB${NAME}=yes and the LIB${NAME} and
dnl LTLIB${NAME} variables and augments the CPPFLAGS variable, and
dnl #defines HAVE_LIB${NAME} to 1. Otherwise, it sets and AC_SUBSTs
dnl HAVE_LIB${NAME}=no and LIB${NAME} and LTLIB${NAME} to empty.
AC_DEFUN([AC_LIB_HAVE_LINKFLAGS],
[
AC_REQUIRE([AC_LIB_PREPARE_PREFIX])
AC_REQUIRE([AC_LIB_RPATH])
define([Name],[translit([$1],[./-], [___])])
define([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-],
[ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])
dnl Search for lib[]Name and define LIB[]NAME, LTLIB[]NAME and INC[]NAME
dnl accordingly.
AC_LIB_LINKFLAGS_BODY([$1], [$2])
dnl Add $INC[]NAME to CPPFLAGS before performing the following checks,
dnl because if the user has installed lib[]Name and not disabled its use
dnl via --without-lib[]Name-prefix, he wants to use it.
ac_save_CPPFLAGS="$CPPFLAGS"
AC_LIB_APPENDTOVAR([CPPFLAGS], [$INC]NAME)
AC_CACHE_CHECK([for lib[]$1], [ac_cv_lib[]Name], [
ac_save_LIBS="$LIBS"
LIBS="$LIBS $LIB[]NAME"
AC_TRY_LINK([$3], [$4], [ac_cv_lib[]Name=yes], [ac_cv_lib[]Name=no])
LIBS="$ac_save_LIBS"
])
if test "$ac_cv_lib[]Name" = yes; then
HAVE_LIB[]NAME=yes
AC_DEFINE([HAVE_LIB]NAME, 1, [Define if you have the $1 library.])
AC_MSG_CHECKING([how to link with lib[]$1])
AC_MSG_RESULT([$LIB[]NAME])
else
HAVE_LIB[]NAME=no
dnl If $LIB[]NAME didn't lead to a usable library, we don't need
dnl $INC[]NAME either.
CPPFLAGS="$ac_save_CPPFLAGS"
LIB[]NAME=
LTLIB[]NAME=
fi
AC_SUBST([HAVE_LIB]NAME)
AC_SUBST([LIB]NAME)
AC_SUBST([LTLIB]NAME)
undefine([Name])
undefine([NAME])
])
dnl Determine the platform dependent parameters needed to use rpath:
dnl libext, shlibext, hardcode_libdir_flag_spec, hardcode_libdir_separator,
dnl hardcode_direct, hardcode_minus_L,
dnl sys_lib_search_path_spec, sys_lib_dlsearch_path_spec.
AC_DEFUN([AC_LIB_RPATH],
[
AC_REQUIRE([AC_PROG_CC]) dnl we use $CC, $GCC, $LDFLAGS
AC_REQUIRE([AC_LIB_PROG_LD]) dnl we use $LD, $with_gnu_ld
AC_REQUIRE([AC_CANONICAL_HOST]) dnl we use $host
AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT]) dnl we use $ac_aux_dir
AC_CACHE_CHECK([for shared library run path origin], acl_cv_rpath, [
CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \
${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh
. ./conftest.sh
rm -f ./conftest.sh
acl_cv_rpath=done
])
wl="$acl_cv_wl"
libext="$acl_cv_libext"
shlibext="$acl_cv_shlibext"
hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec"
hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator"
hardcode_direct="$acl_cv_hardcode_direct"
hardcode_minus_L="$acl_cv_hardcode_minus_L"
sys_lib_search_path_spec="$acl_cv_sys_lib_search_path_spec"
sys_lib_dlsearch_path_spec="$acl_cv_sys_lib_dlsearch_path_spec"
dnl Determine whether the user wants rpath handling at all.
AC_ARG_ENABLE(rpath,
[ --disable-rpath do not hardcode runtime library paths],
:, enable_rpath=yes)
])
dnl AC_LIB_LINKFLAGS_BODY(name [, dependencies]) searches for libname and
dnl the libraries corresponding to explicit and implicit dependencies.
dnl Sets the LIB${NAME}, LTLIB${NAME} and INC${NAME} variables.
AC_DEFUN([AC_LIB_LINKFLAGS_BODY],
[
define([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-],
[ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])
dnl By default, look in $includedir and $libdir.
use_additional=yes
AC_LIB_WITH_FINAL_PREFIX([
eval additional_includedir=\"$includedir\"
eval additional_libdir=\"$libdir\"
])
AC_ARG_WITH([lib$1-prefix],
[ --with-lib$1-prefix[=DIR] search for lib$1 in DIR/include and DIR/lib
--without-lib$1-prefix don't search for lib$1 in includedir and libdir],
[
if test "X$withval" = "Xno"; then
use_additional=no
else
if test "X$withval" = "X"; then
AC_LIB_WITH_FINAL_PREFIX([
eval additional_includedir=\"$includedir\"
eval additional_libdir=\"$libdir\"
])
else
additional_includedir="$withval/include"
additional_libdir="$withval/lib"
fi
fi
])
dnl Search the library and its dependencies in $additional_libdir and
dnl $LDFLAGS. Using breadth-first-seach.
LIB[]NAME=
LTLIB[]NAME=
INC[]NAME=
rpathdirs=
ltrpathdirs=
names_already_handled=
names_next_round='$1 $2'
while test -n "$names_next_round"; do
names_this_round="$names_next_round"
names_next_round=
for name in $names_this_round; do
already_handled=
for n in $names_already_handled; do
if test "$n" = "$name"; then
already_handled=yes
break
fi
done
if test -z "$already_handled"; then
names_already_handled="$names_already_handled $name"
dnl See if it was already located by an earlier AC_LIB_LINKFLAGS
dnl or AC_LIB_HAVE_LINKFLAGS call.
uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
eval value=\"\$HAVE_LIB$uppername\"
if test -n "$value"; then
if test "$value" = yes; then
eval value=\"\$LIB$uppername\"
test -z "$value" || LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$value"
eval value=\"\$LTLIB$uppername\"
test -z "$value" || LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }$value"
else
dnl An earlier call to AC_LIB_HAVE_LINKFLAGS has determined
dnl that this library doesn't exist. So just drop it.
:
fi
else
dnl Search the library lib$name in $additional_libdir and $LDFLAGS
dnl and the already constructed $LIBNAME/$LTLIBNAME.
found_dir=
found_la=
found_so=
found_a=
if test $use_additional = yes; then
if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then
found_dir="$additional_libdir"
found_so="$additional_libdir/lib$name.$shlibext"
if test -f "$additional_libdir/lib$name.la"; then
found_la="$additional_libdir/lib$name.la"
fi
else
if test -f "$additional_libdir/lib$name.$libext"; then
found_dir="$additional_libdir"
found_a="$additional_libdir/lib$name.$libext"
if test -f "$additional_libdir/lib$name.la"; then
found_la="$additional_libdir/lib$name.la"
fi
fi
fi
fi
if test "X$found_dir" = "X"; then
for x in $LDFLAGS $LTLIB[]NAME; do
AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
case "$x" in
-L*)
dir=`echo "X$x" | sed -e 's/^X-L//'`
if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then
found_dir="$dir"
found_so="$dir/lib$name.$shlibext"
if test -f "$dir/lib$name.la"; then
found_la="$dir/lib$name.la"
fi
else
if test -f "$dir/lib$name.$libext"; then
found_dir="$dir"
found_a="$dir/lib$name.$libext"
if test -f "$dir/lib$name.la"; then
found_la="$dir/lib$name.la"
fi
fi
fi
;;
esac
if test "X$found_dir" != "X"; then
break
fi
done
fi
if test "X$found_dir" != "X"; then
dnl Found the library.
LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-L$found_dir -l$name"
if test "X$found_so" != "X"; then
dnl Linking with a shared library. We attempt to hardcode its
dnl directory into the executable's runpath, unless it's the
dnl standard /usr/lib.
if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
dnl No hardcoding is needed.
LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so"
else
dnl Use an explicit option to hardcode DIR into the resulting
dnl binary.
dnl Potentially add DIR to ltrpathdirs.
dnl The ltrpathdirs will be appended to $LTLIBNAME at the end.
haveit=
for x in $ltrpathdirs; do
if test "X$x" = "X$found_dir"; then
haveit=yes
break
fi
done
if test -z "$haveit"; then
ltrpathdirs="$ltrpathdirs $found_dir"
fi
dnl The hardcoding into $LIBNAME is system dependent.
if test "$hardcode_direct" = yes; then
dnl Using DIR/libNAME.so during linking hardcodes DIR into the
dnl resulting binary.
LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so"
else
if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
dnl Use an explicit option to hardcode DIR into the resulting
dnl binary.
LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so"
dnl Potentially add DIR to rpathdirs.
dnl The rpathdirs will be appended to $LIBNAME at the end.
haveit=
for x in $rpathdirs; do
if test "X$x" = "X$found_dir"; then
haveit=yes
break
fi
done
if test -z "$haveit"; then
rpathdirs="$rpathdirs $found_dir"
fi
else
dnl Rely on "-L$found_dir".
dnl But don't add it if it's already contained in the LDFLAGS
dnl or the already constructed $LIBNAME
haveit=
for x in $LDFLAGS $LIB[]NAME; do
AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
if test "X$x" = "X-L$found_dir"; then
haveit=yes
break
fi
done
if test -z "$haveit"; then
LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-L$found_dir"
fi
if test "$hardcode_minus_L" != no; then
dnl FIXME: Not sure whether we should use
dnl "-L$found_dir -l$name" or "-L$found_dir $found_so"
dnl here.
LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so"
else
dnl We cannot use $hardcode_runpath_var and LD_RUN_PATH
dnl here, because this doesn't fit in flags passed to the
dnl compiler. So give up. No hardcoding. This affects only
dnl very old systems.
dnl FIXME: Not sure whether we should use
dnl "-L$found_dir -l$name" or "-L$found_dir $found_so"
dnl here.
LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-l$name"
fi
fi
fi
fi
else
if test "X$found_a" != "X"; then
dnl Linking with a static library.
LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_a"
else
dnl We shouldn't come here, but anyway it's good to have a
dnl fallback.
LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-L$found_dir -l$name"
fi
fi
dnl Assume the include files are nearby.
additional_includedir=
case "$found_dir" in
*/lib | */lib/)
basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
additional_includedir="$basedir/include"
;;
esac
if test "X$additional_includedir" != "X"; then
dnl Potentially add $additional_includedir to $INCNAME.
dnl But don't add it
dnl 1. if it's the standard /usr/include,
dnl 2. if it's /usr/local/include and we are using GCC on Linux,
dnl 3. if it's already present in $CPPFLAGS or the already
dnl constructed $INCNAME,
dnl 4. if it doesn't exist as a directory.
if test "X$additional_includedir" != "X/usr/include"; then
haveit=
if test "X$additional_includedir" = "X/usr/local/include"; then
if test -n "$GCC"; then
case $host_os in
linux*) haveit=yes;;
esac
fi
fi
if test -z "$haveit"; then
for x in $CPPFLAGS $INC[]NAME; do
AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
if test "X$x" = "X-I$additional_includedir"; then
haveit=yes
break
fi
done
if test -z "$haveit"; then
if test -d "$additional_includedir"; then
dnl Really add $additional_includedir to $INCNAME.
INC[]NAME="${INC[]NAME}${INC[]NAME:+ }-I$additional_includedir"
fi
fi
fi
fi
fi
dnl Look for dependencies.
if test -n "$found_la"; then
dnl Read the .la file. It defines the variables
dnl dlname, library_names, old_library, dependency_libs, current,
dnl age, revision, installed, dlopen, dlpreopen, libdir.
save_libdir="$libdir"
case "$found_la" in
*/* | *\\*) . "$found_la" ;;
*) . "./$found_la" ;;
esac
libdir="$save_libdir"
dnl We use only dependency_libs.
for dep in $dependency_libs; do
case "$dep" in
-L*)
additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
dnl Potentially add $additional_libdir to $LIBNAME and $LTLIBNAME.
dnl But don't add it
dnl 1. if it's the standard /usr/lib,
dnl 2. if it's /usr/local/lib and we are using GCC on Linux,
dnl 3. if it's already present in $LDFLAGS or the already
dnl constructed $LIBNAME,
dnl 4. if it doesn't exist as a directory.
if test "X$additional_libdir" != "X/usr/lib"; then
haveit=
if test "X$additional_libdir" = "X/usr/local/lib"; then
if test -n "$GCC"; then
case $host_os in
linux*) haveit=yes;;
esac
fi
fi
if test -z "$haveit"; then
haveit=
for x in $LDFLAGS $LIB[]NAME; do
AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
if test "X$x" = "X-L$additional_libdir"; then
haveit=yes
break
fi
done
if test -z "$haveit"; then
if test -d "$additional_libdir"; then
dnl Really add $additional_libdir to $LIBNAME.
LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-L$additional_libdir"
fi
fi
haveit=
for x in $LDFLAGS $LTLIB[]NAME; do
AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
if test "X$x" = "X-L$additional_libdir"; then
haveit=yes
break
fi
done
if test -z "$haveit"; then
if test -d "$additional_libdir"; then
dnl Really add $additional_libdir to $LTLIBNAME.
LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-L$additional_libdir"
fi
fi
fi
fi
;;
-R*)
dir=`echo "X$dep" | sed -e 's/^X-R//'`
if test "$enable_rpath" != no; then
dnl Potentially add DIR to rpathdirs.
dnl The rpathdirs will be appended to $LIBNAME at the end.
haveit=
for x in $rpathdirs; do
if test "X$x" = "X$dir"; then
haveit=yes
break
fi
done
if test -z "$haveit"; then
rpathdirs="$rpathdirs $dir"
fi
dnl Potentially add DIR to ltrpathdirs.
dnl The ltrpathdirs will be appended to $LTLIBNAME at the end.
haveit=
for x in $ltrpathdirs; do
if test "X$x" = "X$dir"; then
haveit=yes
break
fi
done
if test -z "$haveit"; then
ltrpathdirs="$ltrpathdirs $dir"
fi
fi
;;
-l*)
dnl Handle this in the next round.
names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
;;
*.la)
dnl Handle this in the next round. Throw away the .la's
dnl directory; it is already contained in a preceding -L
dnl option.
names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
;;
*)
dnl Most likely an immediate library name.
LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$dep"
LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }$dep"
;;
esac
done
fi
else
dnl Didn't find the library; assume it is in the system directories
dnl known to the linker and runtime loader. (All the system
dnl directories known to the linker should also be known to the
dnl runtime loader, otherwise the system is severely misconfigured.)
LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-l$name"
LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-l$name"
fi
fi
fi
done
done
if test "X$rpathdirs" != "X"; then
if test -n "$hardcode_libdir_separator"; then
dnl Weird platform: only the last -rpath option counts, the user must
dnl pass all path elements in one option. We can arrange that for a
dnl single library, but not when more than one $LIBNAMEs are used.
alldirs=
for found_dir in $rpathdirs; do
alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
done
dnl Note: hardcode_libdir_flag_spec uses $libdir and $wl.
acl_save_libdir="$libdir"
libdir="$alldirs"
eval flag=\"$hardcode_libdir_flag_spec\"
libdir="$acl_save_libdir"
LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$flag"
else
dnl The -rpath options are cumulative.
for found_dir in $rpathdirs; do
acl_save_libdir="$libdir"
libdir="$found_dir"
eval flag=\"$hardcode_libdir_flag_spec\"
libdir="$acl_save_libdir"
LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$flag"
done
fi
fi
if test "X$ltrpathdirs" != "X"; then
dnl When using libtool, the option that works for both libraries and
dnl executables is -R. The -R options are cumulative.
for found_dir in $ltrpathdirs; do
LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-R$found_dir"
done
fi
])
dnl AC_LIB_APPENDTOVAR(VAR, CONTENTS) appends the elements of CONTENTS to VAR,
dnl unless already present in VAR.
dnl Works only for CPPFLAGS, not for LIB* variables because that sometimes
dnl contains two or three consecutive elements that belong together.
AC_DEFUN([AC_LIB_APPENDTOVAR],
[
for element in [$2]; do
haveit=
for x in $[$1]; do
AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
if test "X$x" = "X$element"; then
haveit=yes
break
fi
done
if test -z "$haveit"; then
[$1]="${[$1]}${[$1]:+ }$element"
fi
done
])

148
m4/lib-prefix.m4 Normal file
View File

@@ -0,0 +1,148 @@
# lib-prefix.m4 serial 1 (gettext-0.11)
dnl Copyright (C) 2001-2002 Free Software Foundation, Inc.
dnl This file is free software, distributed under the terms of the GNU
dnl General Public License. As a special exception to the GNU General
dnl Public License, this file may be distributed as part of a program
dnl that contains a configuration script generated by Autoconf, under
dnl the same distribution terms as the rest of that program.
dnl From Bruno Haible.
dnl AC_LIB_PREFIX adds to the CPPFLAGS and LDFLAGS the flags that are needed
dnl to access previously installed libraries. The basic assumption is that
dnl a user will want packages to use other packages he previously installed
dnl with the same --prefix option.
dnl This macro is not needed if only AC_LIB_LINKFLAGS is used to locate
dnl libraries, but is otherwise very convenient.
AC_DEFUN([AC_LIB_PREFIX],
[
AC_BEFORE([$0], [AC_LIB_LINKFLAGS])
AC_REQUIRE([AC_PROG_CC])
AC_REQUIRE([AC_CANONICAL_HOST])
AC_REQUIRE([AC_LIB_PREPARE_PREFIX])
dnl By default, look in $includedir and $libdir.
use_additional=yes
AC_LIB_WITH_FINAL_PREFIX([
eval additional_includedir=\"$includedir\"
eval additional_libdir=\"$libdir\"
])
AC_ARG_WITH([lib-prefix],
[ --with-lib-prefix[=DIR] search for libraries in DIR/include and DIR/lib
--without-lib-prefix don't search for libraries in includedir and libdir],
[
if test "X$withval" = "Xno"; then
use_additional=no
else
if test "X$withval" = "X"; then
AC_LIB_WITH_FINAL_PREFIX([
eval additional_includedir=\"$includedir\"
eval additional_libdir=\"$libdir\"
])
else
additional_includedir="$withval/include"
additional_libdir="$withval/lib"
fi
fi
])
if test $use_additional = yes; then
dnl Potentially add $additional_includedir to $CPPFLAGS.
dnl But don't add it
dnl 1. if it's the standard /usr/include,
dnl 2. if it's already present in $CPPFLAGS,
dnl 3. if it's /usr/local/include and we are using GCC on Linux,
dnl 4. if it doesn't exist as a directory.
if test "X$additional_includedir" != "X/usr/include"; then
haveit=
for x in $CPPFLAGS; do
AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
if test "X$x" = "X-I$additional_includedir"; then
haveit=yes
break
fi
done
if test -z "$haveit"; then
if test "X$additional_includedir" = "X/usr/local/include"; then
if test -n "$GCC"; then
case $host_os in
linux*) haveit=yes;;
esac
fi
fi
if test -z "$haveit"; then
if test -d "$additional_includedir"; then
dnl Really add $additional_includedir to $CPPFLAGS.
CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }-I$additional_includedir"
fi
fi
fi
fi
dnl Potentially add $additional_libdir to $LDFLAGS.
dnl But don't add it
dnl 1. if it's the standard /usr/lib,
dnl 2. if it's already present in $LDFLAGS,
dnl 3. if it's /usr/local/lib and we are using GCC on Linux,
dnl 4. if it doesn't exist as a directory.
if test "X$additional_libdir" != "X/usr/lib"; then
haveit=
for x in $LDFLAGS; do
AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
if test "X$x" = "X-L$additional_libdir"; then
haveit=yes
break
fi
done
if test -z "$haveit"; then
if test "X$additional_libdir" = "X/usr/local/lib"; then
if test -n "$GCC"; then
case $host_os in
linux*) haveit=yes;;
esac
fi
fi
if test -z "$haveit"; then
if test -d "$additional_libdir"; then
dnl Really add $additional_libdir to $LDFLAGS.
LDFLAGS="${LDFLAGS}${LDFLAGS:+ }-L$additional_libdir"
fi
fi
fi
fi
fi
])
dnl AC_LIB_PREPARE_PREFIX creates variables acl_final_prefix,
dnl acl_final_exec_prefix, containing the values to which $prefix and
dnl $exec_prefix will expand at the end of the configure script.
AC_DEFUN([AC_LIB_PREPARE_PREFIX],
[
dnl Unfortunately, prefix and exec_prefix get only finally determined
dnl at the end of configure.
if test "X$prefix" = "XNONE"; then
acl_final_prefix="$ac_default_prefix"
else
acl_final_prefix="$prefix"
fi
if test "X$exec_prefix" = "XNONE"; then
acl_final_exec_prefix='${prefix}'
else
acl_final_exec_prefix="$exec_prefix"
fi
acl_save_prefix="$prefix"
prefix="$acl_final_prefix"
eval acl_final_exec_prefix=\"$acl_final_exec_prefix\"
prefix="$acl_save_prefix"
])
dnl AC_LIB_WITH_FINAL_PREFIX([statement]) evaluates statement, with the
dnl variables prefix and exec_prefix bound to the values they will have
dnl at the end of the configure script.
AC_DEFUN([AC_LIB_WITH_FINAL_PREFIX],
[
acl_save_prefix="$prefix"
prefix="$acl_final_prefix"
acl_save_exec_prefix="$exec_prefix"
exec_prefix="$acl_final_exec_prefix"
$1
exec_prefix="$acl_save_exec_prefix"
prefix="$acl_save_prefix"
])

59
m4/progtest.m4 Normal file
View File

@@ -0,0 +1,59 @@
# progtest.m4 serial 2 (gettext-0.10.40)
dnl Copyright (C) 1996-2002 Free Software Foundation, Inc.
dnl This file is free software, distributed under the terms of the GNU
dnl General Public License. As a special exception to the GNU General
dnl Public License, this file may be distributed as part of a program
dnl that contains a configuration script generated by Autoconf, under
dnl the same distribution terms as the rest of that program.
dnl
dnl This file can can be used in projects which are not available under
dnl the GNU General Public License or the GNU Library General Public
dnl License but which still want to provide support for the GNU gettext
dnl functionality.
dnl Please note that the actual code of the GNU gettext library is covered
dnl by the GNU Library General Public License, and the rest of the GNU
dnl gettext package package is covered by the GNU General Public License.
dnl They are *not* in the public domain.
dnl Authors:
dnl Ulrich Drepper <drepper@cygnus.com>, 1996.
# Search path for a program which passes the given test.
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 ifelse([$4], , [-n "[$]$1"], ["[$]$1" != "$4"]); then
AC_MSG_RESULT([$]$1)
else
AC_MSG_RESULT(no)
fi
AC_SUBST($1)dnl
])

28
m4/stdint_h.m4 Normal file
View File

@@ -0,0 +1,28 @@
# stdint_h.m4 serial 2 (gettext-0.11.4)
dnl Copyright (C) 1997-2002 Free Software Foundation, Inc.
dnl This file is free software, distributed under the terms of the GNU
dnl General Public License. As a special exception to the GNU General
dnl Public License, this file may be distributed as part of a program
dnl that contains a configuration script generated by Autoconf, under
dnl the same distribution terms as the rest of that program.
dnl From Paul Eggert.
# Define HAVE_STDINT_H_WITH_UINTMAX if <stdint.h> exists,
# doesn't clash with <sys/types.h>, and declares uintmax_t.
AC_DEFUN([jm_AC_HEADER_STDINT_H],
[
AC_CACHE_CHECK([for stdint.h], jm_ac_cv_header_stdint_h,
[AC_TRY_COMPILE(
[#include <sys/types.h>
#include <stdint.h>],
[uintmax_t i = (uintmax_t) -1;],
jm_ac_cv_header_stdint_h=yes,
jm_ac_cv_header_stdint_h=no)])
if test $jm_ac_cv_header_stdint_h = yes; then
AC_DEFINE_UNQUOTED(HAVE_STDINT_H_WITH_UINTMAX, 1,
[Define if <stdint.h> exists, doesn't clash with <sys/types.h>,
and declares uintmax_t. ])
fi
])

29
m4/uintmax_t.m4 Normal file
View File

@@ -0,0 +1,29 @@
# uintmax_t.m4 serial 6 (gettext-0.11)
dnl Copyright (C) 1997-2002 Free Software Foundation, Inc.
dnl This file is free software, distributed under the terms of the GNU
dnl General Public License. As a special exception to the GNU General
dnl Public License, this file may be distributed as part of a program
dnl that contains a configuration script generated by Autoconf, under
dnl the same distribution terms as the rest of that program.
dnl From Paul Eggert.
AC_PREREQ(2.13)
# Define uintmax_t to `unsigned long' or `unsigned long long'
# if <inttypes.h> does not exist.
AC_DEFUN([jm_AC_TYPE_UINTMAX_T],
[
AC_REQUIRE([jm_AC_HEADER_INTTYPES_H])
AC_REQUIRE([jm_AC_HEADER_STDINT_H])
if test $jm_ac_cv_header_inttypes_h = no && test $jm_ac_cv_header_stdint_h = no; then
AC_REQUIRE([jm_AC_TYPE_UNSIGNED_LONG_LONG])
test $ac_cv_type_unsigned_long_long = yes \
&& ac_type='unsigned long long' \
|| ac_type='unsigned long'
AC_DEFINE_UNQUOTED(uintmax_t, $ac_type,
[Define to unsigned long or unsigned long long
if <inttypes.h> and <stdint.h> don't define.])
fi
])

23
m4/ulonglong.m4 Normal file
View File

@@ -0,0 +1,23 @@
# ulonglong.m4 serial 2 (fileutils-4.0.32, gettext-0.10.40)
dnl Copyright (C) 1999-2002 Free Software Foundation, Inc.
dnl This file is free software, distributed under the terms of the GNU
dnl General Public License. As a special exception to the GNU General
dnl Public License, this file may be distributed as part of a program
dnl that contains a configuration script generated by Autoconf, under
dnl the same distribution terms as the rest of that program.
dnl From Paul Eggert.
AC_DEFUN([jm_AC_TYPE_UNSIGNED_LONG_LONG],
[
AC_CACHE_CHECK([for unsigned long long], ac_cv_type_unsigned_long_long,
[AC_TRY_LINK([unsigned long long ull = 1; int i = 63;],
[unsigned long long ullmax = (unsigned long long) -1;
return ull << i | ull >> i | ullmax / ull | ullmax % ull;],
ac_cv_type_unsigned_long_long=yes,
ac_cv_type_unsigned_long_long=no)])
if test $ac_cv_type_unsigned_long_long = yes; then
AC_DEFINE(HAVE_UNSIGNED_LONG_LONG, 1,
[Define if you have the unsigned long long type.])
fi
])

190
missing
View File

@@ -1,190 +0,0 @@
#! /bin/sh
# Common stub for a few missing GNU programs while installing.
# Copyright (C) 1996, 1997 Free Software Foundation, Inc.
# Franc,ois Pinard <pinard@iro.umontreal.ca>, 1996.
# 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.
if test $# -eq 0; then
echo 1>&2 "Try \`$0 --help' for more information"
exit 1
fi
case "$1" in
-h|--h|--he|--hel|--help)
echo "\
$0 [OPTION]... PROGRAM [ARGUMENT]...
Handle \`PROGRAM [ARGUMENT]...' for when PROGRAM is missing, or return an
error status if there is no known handling for PROGRAM.
Options:
-h, --help display this help and exit
-v, --version output version information and exit
Supported PROGRAM values:
aclocal touch file \`aclocal.m4'
autoconf touch file \`configure'
autoheader touch file \`config.h.in'
automake touch all \`Makefile.in' files
bison create \`y.tab.[ch]', if possible, from existing .[ch]
flex create \`lex.yy.c', if possible, from existing .c
lex create \`lex.yy.c', if possible, from existing .c
makeinfo touch the output file
yacc create \`y.tab.[ch]', if possible, from existing .[ch]"
;;
-v|--v|--ve|--ver|--vers|--versi|--versio|--version)
echo "missing - GNU libit 0.0"
;;
-*)
echo 1>&2 "$0: Unknown \`$1' option"
echo 1>&2 "Try \`$0 --help' for more information"
exit 1
;;
aclocal)
echo 1>&2 "\
WARNING: \`$1' is missing on your system. You should only need it if
you modified \`acinclude.m4' or \`configure.in'. You might want
to install the \`Automake' and \`Perl' packages. Grab them from
any GNU archive site."
touch aclocal.m4
;;
autoconf)
echo 1>&2 "\
WARNING: \`$1' is missing on your system. You should only need it if
you modified \`configure.in'. You might want to install the
\`Autoconf' and \`GNU m4' packages. Grab them from any GNU
archive site."
touch configure
;;
autoheader)
echo 1>&2 "\
WARNING: \`$1' is missing on your system. You should only need it if
you modified \`acconfig.h' or \`configure.in'. You might want
to install the \`Autoconf' and \`GNU m4' packages. Grab them
from any GNU archive site."
files=`sed -n 's/^[ ]*A[CM]_CONFIG_HEADER(\([^)]*\)).*/\1/p' configure.in`
test -z "$files" && files="config.h"
touch_files=
for f in $files; do
case "$f" in
*:*) touch_files="$touch_files "`echo "$f" |
sed -e 's/^[^:]*://' -e 's/:.*//'`;;
*) touch_files="$touch_files $f.in";;
esac
done
touch $touch_files
;;
automake)
echo 1>&2 "\
WARNING: \`$1' is missing on your system. You should only need it if
you modified \`Makefile.am', \`acinclude.m4' or \`configure.in'.
You might want to install the \`Automake' and \`Perl' packages.
Grab them from any GNU archive site."
find . -type f -name Makefile.am -print |
sed 's/\.am$/.in/' |
while read f; do touch "$f"; done
;;
bison|yacc)
echo 1>&2 "\
WARNING: \`$1' is missing on your system. You should only need it if
you modified a \`.y' file. You may need the \`Bison' package
in order for those modifications to take effect. You can get
\`Bison' from any GNU archive site."
rm -f y.tab.c y.tab.h
if [ $# -ne 1 ]; then
eval LASTARG="\${$#}"
case "$LASTARG" in
*.y)
SRCFILE=`echo "$LASTARG" | sed 's/y$/c/'`
if [ -f "$SRCFILE" ]; then
cp "$SRCFILE" y.tab.c
fi
SRCFILE=`echo "$LASTARG" | sed 's/y$/h/'`
if [ -f "$SRCFILE" ]; then
cp "$SRCFILE" y.tab.h
fi
;;
esac
fi
if [ ! -f y.tab.h ]; then
echo >y.tab.h
fi
if [ ! -f y.tab.c ]; then
echo 'main() { return 0; }' >y.tab.c
fi
;;
lex|flex)
echo 1>&2 "\
WARNING: \`$1' is missing on your system. You should only need it if
you modified a \`.l' file. You may need the \`Flex' package
in order for those modifications to take effect. You can get
\`Flex' from any GNU archive site."
rm -f lex.yy.c
if [ $# -ne 1 ]; then
eval LASTARG="\${$#}"
case "$LASTARG" in
*.l)
SRCFILE=`echo "$LASTARG" | sed 's/l$/c/'`
if [ -f "$SRCFILE" ]; then
cp "$SRCFILE" lex.yy.c
fi
;;
esac
fi
if [ ! -f lex.yy.c ]; then
echo 'main() { return 0; }' >lex.yy.c
fi
;;
makeinfo)
echo 1>&2 "\
WARNING: \`$1' is missing on your system. You should only need it if
you modified a \`.texi' or \`.texinfo' file, or any other file
indirectly affecting the aspect of the manual. The spurious
call might also be the consequence of using a buggy \`make' (AIX,
DU, IRIX). You might want to install the \`Texinfo' package or
the \`GNU make' package. Grab either from any GNU archive site."
file=`echo "$*" | sed -n 's/.*-o \([^ ]*\).*/\1/p'`
if test -z "$file"; then
file=`echo "$*" | sed 's/.* \([^ ]*\) *$/\1/'`
file=`sed -n '/^@setfilename/ { s/.* \([^ ]*\) *$/\1/; p; q; }' $file`
fi
touch $file
;;
*)
echo 1>&2 "\
WARNING: \`$1' is needed, and you do not seem to have it handy on your
system. You might have modified some files without having the
proper tools for further handling them. Check the \`README' file,
it often tells you about the needed prerequirements for installing
this package. You may also peek at any GNU archive site, in case
some other package would contain this missing \`$1' program."
exit 1
;;
esac
exit 0

View File

@@ -1,40 +0,0 @@
#! /bin/sh
# mkinstalldirs --- make directory hierarchy
# Author: Noah Friedman <friedman@prep.ai.mit.edu>
# Created: 1993-05-16
# Public domain
# $Id$
errstatus=0
for file
do
set fnord `echo ":$file" | sed -ne 's/^:\//#/;s/^://;s/\// /g;s/^#/\//;p'`
shift
pathcomp=
for d
do
pathcomp="$pathcomp$d"
case "$pathcomp" in
-* ) pathcomp=./$pathcomp ;;
esac
if test ! -d "$pathcomp"; then
echo "mkdir $pathcomp"
mkdir "$pathcomp" || lasterr=$?
if test ! -d "$pathcomp"; then
errstatus=$lasterr
fi
fi
pathcomp="$pathcomp/"
done
done
exit $errstatus
# mkinstalldirs ends here

273
move.c
View File

@@ -2,10 +2,10 @@
/**************************************************************************
* move.c *
* *
* Copyright (C) 1999 Chris Allegretta *
* Copyright (C) 1999-2002 Chris Allegretta *
* 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 1, or (at your option) *
* 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, *
@@ -19,34 +19,82 @@
* *
**************************************************************************/
#include "config.h"
#include <stdlib.h>
#include <string.h>
#include <stdio.h>
#include "config.h"
#include <assert.h>
#include "proto.h"
#include "nano.h"
#ifndef NANO_SMALL
#include <libintl.h>
#define _(string) gettext(string)
#else
#define _(string) (string)
#endif
void page_down_center(void)
int do_home(void)
{
if (editbot != filebot) {
edit_update(editbot->next, CENTER);
center_cursor();
} else {
while (current != filebot)
current = current->next;
edit_update(current, CENTER);
}
UNSET(KEEP_CUTBUFFER);
current_x = 0;
placewewant = 0;
update_line(current, current_x);
return 1;
}
int do_end(void)
{
UNSET(KEEP_CUTBUFFER);
current_x = strlen(current->data);
placewewant = xplustabs();
update_line(current, current_x);
return 1;
}
void page_up(void)
{
if (edittop != fileage) {
#ifndef NANO_SMALL
if (ISSET(SMOOTHSCROLL))
edit_update(edittop->prev, TOP);
else
#endif
{
edit_update(edittop, CENTER);
/* Now that we've updated the edit window, edittop might be
at the top of the file; if so, just move the cursor up one
line and don't center it. */
if (edittop != fileage)
center_cursor();
else
reset_cursor();
}
} else
current_y = 0;
update_cursor();
}
int page_down(void)
int do_page_up(void)
{
int i;
wrap_reset();
current_x = 0;
placewewant = 0;
if (current == fileage)
return 0;
current_y = 0;
current = edittop;
for (i = 0; i <= editwinrows - 3 && current->prev != NULL; i++)
current = current->prev;
edit_update(current, TOP);
update_cursor();
UNSET(KEEP_CUTBUFFER);
check_statblank();
return 1;
}
int do_page_down(void)
{
wrap_reset();
current_x = 0;
@@ -55,8 +103,8 @@ int page_down(void)
if (current == filebot)
return 0;
/* AHEM, if we only have a screen or less of text, DONT do an
edit_update, just move the cursor to editbot! */
/* AHEM, if we only have a screen or less of text, DON'T do an
edit_update, just move the cursor to editbot! */
if (edittop == fileage && editbot == filebot && totlines < editwinrows) {
current = editbot;
reset_cursor();
@@ -83,129 +131,62 @@ int page_down(void)
return 1;
}
int do_home(void)
{
current_x = 0;
placewewant = 0;
update_line(current, current_x);
return 1;
}
int do_end(void)
{
current_x = strlen(current->data);
placewewant = xplustabs();
update_line(current, current_x);
return 1;
}
/* What happens when we want to go past the bottom of the buffer */
int do_down(void)
{
wrap_reset();
if (current->next != NULL) {
update_line(current->prev, 0);
if (placewewant > 0)
current_x = actual_x(current->next, placewewant);
if (current_x > strlen(current->next->data))
current_x = strlen(current->next->data);
} else {
UNSET(KEEP_CUTBUFFER);
check_statblank();
return 0;
}
if (current_y < editwinrows - 1 && current != editbot)
current_y++;
else
page_down_center();
update_cursor();
update_line(current->prev, 0);
update_line(current, current_x);
UNSET(KEEP_CUTBUFFER);
check_statblank();
return 1;
}
void page_up_center(void)
{
if (edittop != fileage) {
edit_update(edittop, CENTER);
center_cursor();
} else
current_y = 0;
update_cursor();
}
int page_up(void)
{
filestruct *fileptr = edittop;
wrap_reset();
current_x = 0;
placewewant = 0;
if (current == fileage)
return 0;
current_y = 0;
if (fileptr->next != NULL)
fileptr = fileptr->next;
if (fileptr->next != NULL)
fileptr = fileptr->next;
current = edittop;
edit_update(fileptr, BOTTOM);
update_cursor();
UNSET(KEEP_CUTBUFFER);
check_statblank();
return 1;
}
int do_up(void)
{
wrap_reset();
if (current->prev != NULL) {
if (placewewant > 0)
current_x = actual_x(current->prev, placewewant);
if (current_x > strlen(current->prev->data))
current_x = strlen(current->prev->data);
current_x = actual_x(current->prev, placewewant);
current = current->prev;
if (current_y > 0) {
update_line(current->next, 0);
/* It is necessary to change current first, so the mark
display will change! */
current_y--;
update_line(current, current_x);
} else
page_up();
UNSET(KEEP_CUTBUFFER);
check_statblank();
}
if (current_y > 0)
current_y--;
else
page_up_center();
update_cursor();
update_line(current->next, 0);
update_line(current, current_x);
UNSET(KEEP_CUTBUFFER);
check_statblank();
return 1;
}
int do_right(void)
{
if (current_x < strlen(current->data)) {
current_x++;
} else {
if (do_down())
current_x = 0;
}
placewewant = xplustabs();
update_cursor();
update_line(current, current_x);
/* Return value 1 means we moved down, 0 means we were already at the
* bottom. */
int do_down(void) {
wrap_reset();
UNSET(KEEP_CUTBUFFER);
check_statblank();
if (current->next == NULL)
return 0;
current = current->next;
current_x = actual_x(current, placewewant);
/* Note current_y is zero-based. This test checks for the cursor
* being on the last row of the edit window. */
if (current_y == editwinrows - 1) {
#ifndef NANO_SMALL
if (ISSET(SMOOTHSCROLL)) {
/* In this case current_y does not change. The cursor
* remains at the bottom of the edit window. */
edittop = edittop->next;
editbot = editbot->next;
edit_refresh();
} else
#endif
{
/* Set edittop so editbot->next (or else editbot) is
* centered, and set current_y = editwinrows / 2. */
edit_update(editbot->next != NULL ? editbot->next : editbot, CENTER);
center_cursor();
}
} else {
update_line(current->prev, 0);
update_line(current, current_x);
current_y++;
}
return 1;
}
@@ -214,13 +195,27 @@ int do_left(void)
if (current_x > 0)
current_x--;
else if (current != fileage) {
placewewant = 0;
current_x = strlen(current->prev->data);
do_up();
current_x = strlen(current->data);
}
placewewant = xplustabs();
update_line(current, current_x);
UNSET(KEEP_CUTBUFFER);
check_statblank();
return 1;
}
int do_right(void)
{
assert(current_x <= strlen(current->data));
if (current->data[current_x] != '\0')
current_x++;
else if (current->next) {
do_down();
current_x = 0;
}
placewewant = xplustabs();
update_cursor();
update_line(current, current_x);
UNSET(KEEP_CUTBUFFER);
check_statblank();

132
nano.1
View File

@@ -1,78 +1,123 @@
.\" Hey, EMACS: -*- nroff -*-
.\" nano.1 is copyright 1999-2000 by
.\" nano.1 is copyright 1999-2002 by
.\" Chris Allegretta <chrisa@asty.org>
.\"
.\" This is free documentation, see the latest version of the GNU General
.\" Public License for copying conditions. There is NO warranty.
.\"
.\" First parameter, NAME, should be all caps
.\" Second parameter, SECTION, should be 1-8, maybe w/ subsection
.\" other parameters are allowed: see man(7), man(1)
.TH NANO 1 "December 2, 2000"
.\" $Id$
.TH NANO 1 "July 30, 2002"
.\" Please adjust this date whenever revising the manpage.
.\"
.SH NAME
nano \- Nano's ANOther editor, an enhanced free Pico Clone
.SH SYNOPSIS
.B nano
.RI [options]\ [+LINE] " file"
.I [\+LINE]\ [options]\ [file]
.br
.SH DESCRIPTION
This manual page documents briefly the
.B nano
command.
This manual page documents briefly the \fBnano\fP command.
.PP
.\" TeX users may be more comfortable with the \fB<whatever>\fP and
.\" \fI<whatever>\fP escape sequences to invode bold face and italics,
.\" \fI<whatever>\fP escape sequences to invoke bold face and italics,
.\" respectively.
\fBnano\fP is a small, free and friendly editor which aims to replace
Pico, the default editor included in the non-free Pine package. Rather
than just copying Pico's look and feel,
.B nano
also implements some missing (or disabled by default) features in Pico,
such as "search and replace" and "goto line number".
than just copying Pico's look and feel, \fBnano\fP also implements some
missing (or disabled by default) features in Pico, such as "search and
replace" and "go to line number".
.SH OPTIONS
.TP
.B \-T (\-\-tabsize)
Set the size (width) of a tab.
.B \+\fILINE\fP
Places cursor at \fILINE\fP on startup.
.TP
.B \-B (\-\-backup)
When saving a file, back up the previous version of it to the current
filename suffixed with a ~.
.TP
.B \-D (\-\-dos)
Write file in DOS format.
.TP
.B \-F (\-\-multibuffer)
Enable multiple file buffers, if available.
.TP
.B \-I (\-\-ignorercfiles)
Don't look at /etc/nanorc or ~/.nanorc, if nanorc support is available.
.TP
.B \-K (\-\-keypad)
Do not use the ncurses keypad() call unless necessary. Try this flag if
you find that the arrow keys on the numeric keypad do not work for you
under nano.
.TP
.B \-M (\-\-mac)
Write file in Mac format.
.TP
.B \-N (\-\-noconvert)
Disable automatic conversion of files from DOS/Mac format.
.TP
.B \-Q \fI[str]\fP (\-\-quotestr=\fI[str]\fP)
Set the quoting string for justifying. The default is
"^([ \\t]*[|>:}#])+" if regular expression support is available, or
"> " otherwise.
.TP
.B \-R (\-\-regexp)
Enable regular expression matching for search strings, as well as
\\n subexpression replacement for replace strings, if available.
.TP
.B \-S (\-\-smooth)
Enable smooth scrolling. Text will scroll line-by-line, instead of the
usual chunk-by-chunk behavior.
.TP
.B \-T \fI[num]\fP (\-\-tabsize=\fI[num]\fP)
Set the size (width) of a tab.
.TP
.B \-V (\-\-version)
Show the current version number and author.
.TP
.B \-h (\-\-help)
Display a summary of commandline options.
.B \-Y \fI[str]\fP (\-\-syntax=\fI[str]\fP)
Specify a specific syntax highlighting from the .nanorc to use, if
available.
.TP
.B \-c (\-\-const)
Constantly show the cursor position.
.TP
.B \-k (\-\-cut)
Enable cut from cursor to end of line with ^K.
.B \-h (\-\-help)
Display a summary of command line options.
.TP
.B \-i (\-\-autoindent)
Indent new lines to the previous line's indentation. Useful when editing
source code.
.TP
.B \-k (\-\-cut)
Enable cut from cursor to end of line with ^K.
.TP
.B \-l (\-\-nofollow)
If the file being edited is a symbolic link, replace the link with a
a new file, do not follow it. Good for editing files in /tmp perhaps?
If the file being edited is a symbolic link, replace the link with
a new file, do not follow it. Good for editing files in /tmp, perhaps?
.TP
.B \-m (\-\-mouse)
Enable mouse support (if available for your system).
.TP
.B \-p (\-\-pico)
Emulate Pico as closely as possible. This affects both the "shortcut list"
at the bottom of the screen, as well as the display and entry of previous
search and replace strings.
.B \-o \fI[dir]\fP (\-\-operatingdir=\fI[dir]\fP)
Set operating directory. Makes nano set up something similar to a
chroot.
.TP
.B \-s (\-\-speller)
.B \-p (\-\-pico)
Emulate Pico as closely as possible. This affects both the "shortcut
list" at the bottom of the screen, as well as the display and entry of
previous search and replace strings.
.TP
.B \-r \fI[#cols]\fP (\-\-fill=\fI[#cols]\fP)
Wrap lines at column #cols. By default, this is the width of the
screen, less eight. If this value is negative, wrapping will occur at
#cols from the right of the screen, allowing it to vary along with the
screen width if the screen is resized.
.TP
.B \-s \fI[prog]\fP (\-\-speller=\fI[prog]\fP)
Enable alternative spell checker command.
.TP
.B \-t (\-\-tempfile)
Always save changed buffer without prompting. Same as Pico -t option.
Always save changed buffer without prompting. Same as Pico -t option.
.TP
.B \-v (\-\-view)
View file (read only) mode.
@@ -86,32 +131,33 @@ Disable help screen at bottom of editor.
.B \-z (\-\-suspend)
Enable suspend ability.
.TP
.B \-b, \-e, \-f
.B \-a, \-b, \-e, \-f, \-g, \-j
Ignored, for compatibility with Pico.
.TP
.B \+LINE
Places cursor at LINE on startup.
.SH NOTES
Nano will try to dump the buffer into an emergency file in some cases.
Mainly, this will happen if Nano recieves a SIGHUP or runs out of
memory, when it will write the buffer into a file named "nano.save" if the
buffer didn't have a name already, or will add a ".save" suffix to the
current finename. Nano will \fBnot\fP write this file if a previous one
exists in the current directory.
\fBnano\fP will try to dump the buffer into an emergency file in some
cases. Mainly, this will happen if \fBnano\fP receives a SIGHUP or
SIGTERM or runs out of memory, when it will write the buffer into a file
named "nano.save" if the buffer didn't have a name already, or will add
a ".save" suffix to the current filename. If an emergency file with that
name already exists in the current directory, ".save" and a number (e.g.
".save.1") will be suffixed to the current filename in order to make it
unique. In multibuffer mode, \fBnano\fP will write all the open buffers
to the respective emergency files.
.SH BUGS
Please send any comments or bug reports to
.br
.B nano@nano-editor.org.
.br
The nano mailing list is available from
The \fBnano\fP mailing list is available from
.br
.B nano-devel@lists.sourceforge.net.
To subscribe, email to nano-devel-request@lists.sourceforge.net with a
.B nano-devel@gnu.org.
To subscribe, email to nano-devel-request@gnu.org with a
subject of "subscribe".
.SH HOMEPAGE
http://www.nano-editor.org
.SH AUTHOR
Chris Allegretta <chrisa@asty.org>, et al (see AUTHORS for details).
Chris Allegretta <chrisa@asty.org>, et al (see AUTHORS and THANKS for
details).
This manual page was originally written by Jordi Mallach
<jordi@sindominio.net>, for the Debian GNU/Linux system (but may be
<jordi@sindominio.net>, for the Debian GNU system (but may be
used by others).

View File

@@ -3,7 +3,7 @@ Content-type: text/html
<HTML><HEAD><TITLE>Manpage of NANO</TITLE>
</HEAD><BODY>
<H1>NANO</H1>
Section: User Commands (1)<BR>Updated: December 2, 2000<BR><A HREF="#index">Index</A>
Section: User Commands (1)<BR>Updated: October 13, 2002<BR><A HREF="#index">Index</A>
<A HREF="http://localhost/cgi-bin/man/man2html">Return to Main Contents</A><HR>
@@ -17,17 +17,14 @@ nano - Nano's ANOther editor, an enhanced free Pico Clone
<B>nano</B>
[options]&nbsp;[+LINE]<I> file</I>
<I>[+LINE]&nbsp;[options]&nbsp;[file]</I>
<BR>
<A NAME="lbAD">&nbsp;</A>
<H2>DESCRIPTION</H2>
This manual page documents briefly the
<B>nano</B>
command.
This manual page documents briefly the <B>nano</B> command.
<P>
@@ -35,68 +32,129 @@ command.
<B>nano</B> is a small, free and friendly editor which aims to replace
Pico, the default editor included in the non-free Pine package. Rather
than just copying Pico's look and feel,
<B>nano</B>
also implements some missing (or disabled by default) features in Pico,
such as &quot;search and replace&quot; and &quot;goto line number&quot;.
than just copying Pico's look and feel, <B>nano</B> also implements some
missing (or disabled by default) features in Pico, such as &quot;search and
replace&quot; and &quot;go to line number&quot;.
<A NAME="lbAE">&nbsp;</A>
<H2>OPTIONS</H2>
<DL COMPACT>
<DT><B>-T (--tabsize)</B>
<DT><B>+</B><I>LINE</I>
<DD>
Set the size (width) of a tab.
Places cursor at <I>LINE</I> on startup.
<DT><B>-B (--backup)</B>
<DD>
When saving a file, back up the previous version of it to the current
filename suffixed with a ~.
<DT><B>-D (--dos)</B>
<DD>
Write file in DOS format.
<DT><B>-F (--multibuffer)</B>
<DD>
Enable multiple file buffers, if available.
<DT><B>-I (--ignorercfiles)</B>
<DD>
Don't look at /etc/nanorc or ~/.nanorc, if nanorc support is available.
<DT><B>-K (--keypad)</B>
<DD>
Do not use the ncurses keypad() call unless necessary. Try this flag if
you find that the arrow keys on the numeric keypad do not work for you
under nano.
<DT><B>-M (--mac)</B>
<DD>
Write file in Mac format.
<DT><B>-N (--noconvert)</B>
<DD>
Disable automatic conversion of files from DOS/Mac format.
<DT><B>-Q </B><I>[str]</I> (--quotestr=<I>[str]</I>)
<DD>
Set the quoting string for justifying. The default is
&quot;^([ \t]*[|&gt;:}#])+&quot; if regular expression support is available, or
&quot;&gt; &quot; otherwise.
<DT><B>-R (--regexp)</B>
<DD>
Enable regular expression matching for search strings, as well as
\n subexpression replacement for replace strings, if available.
<DT><B>-S (--smooth)</B>
<DD>
Enable smooth scrolling. Text will scroll line-by-line, instead of the
usual chunk-by-chunk behavior.
<DT><B>-T </B><I>[num]</I> (--tabsize=<I>[num]</I>)
<DD>
Set the size (width) of a tab.
<DT><B>-V (--version)</B>
<DD>
Show the current version number and author.
<DT><B>-h (--help)</B>
<DT><B>-Y </B><I>[str]</I> (--syntax=<I>[str]</I>)
<DD>
Display a summary of commandline options.
Specify a specific syntax highlighting from the .nanorc to use, if
available.
<DT><B>-c (--const)</B>
<DD>
Constantly show the cursor position.
<DT><B>-k (--cut)</B>
<DT><B>-h (--help)</B>
<DD>
Enable cut from cursor to end of line with ^K.
Display a summary of command line options.
<DT><B>-i (--autoindent)</B>
<DD>
Indent new lines to the previous line's indentation. Useful when editing
source code.
<DT><B>-k (--cut)</B>
<DD>
Enable cut from cursor to end of line with ^K.
<DT><B>-l (--nofollow)</B>
<DD>
If the file being edited is a symbolic link, replace the link with a
a new file, do not follow it. Good for editing files in /tmp perhaps?
If the file being edited is a symbolic link, replace the link with
a new file, do not follow it. Good for editing files in /tmp, perhaps?
<DT><B>-m (--mouse)</B>
<DD>
Enable mouse support (if available for your system).
<DT><B>-o </B><I>[dir]</I> (--operatingdir=<I>[dir]</I>)
<DD>
Set operating directory. Makes nano set up something similar to a
chroot.
<DT><B>-p (--pico)</B>
<DD>
Emulate Pico as closely as possible. This affects both the &quot;shortcut list&quot;
at the bottom of the screen, as well as the display and entry of previous
search and replace strings.
<DT><B>-s (--speller)</B>
Emulate Pico as closely as possible. This affects both the &quot;shortcut
list&quot; at the bottom of the screen, as well as the display and entry of
previous search and replace strings.
<DT><B>-r </B><I>[#cols]</I> (--fill=<I>[#cols]</I>)
<DD>
Wrap lines at column #cols. By default, this is the width of the
screen, less eight. If this value is negative, wrapping will occur at
#cols from the right of the screen, allowing it to vary along with the
screen width if the screen is resized.
<DT><B>-s </B><I>[prog]</I> (--speller=<I>[prog]</I>)
<DD>
Enable alternative spell checker command.
<DT><B>-t (--tempfile)</B>
<DD>
Always save changed buffer without prompting. Same as Pico -t option.
Always save changed buffer without prompting. Same as Pico -t option.
<DT><B>-v (--view)</B>
<DD>
@@ -113,24 +171,23 @@ Disable help screen at bottom of editor.
<DD>
Enable suspend ability.
<DT><B>-b, -e, -f</B>
<DT><B>-a, -b, -e, -f, -g, -j</B>
<DD>
Ignored, for compatibility with Pico.
<DT><B>+LINE</B>
<DD>
Places cursor at LINE on startup.
</DL>
<A NAME="lbAF">&nbsp;</A>
<H2>NOTES</H2>
Nano will try to dump the buffer into an emergency file in some cases.
Mainly, this will happen if Nano recieves a SIGHUP or runs out of
memory, when it will write the buffer into a file named &quot;nano.save&quot; if the
buffer didn't have a name already, or will add a &quot;.save&quot; suffix to the
current finename. Nano will <B>not</B> write this file if a previous one
exists in the current directory.
<B>nano</B> will try to dump the buffer into an emergency file in some
cases. Mainly, this will happen if <B>nano</B> receives a SIGHUP or
SIGTERM or runs out of memory, when it will write the buffer into a file
named &quot;nano.save&quot; if the buffer didn't have a name already, or will add
a &quot;.save&quot; suffix to the current filename. If an emergency file with that
name already exists in the current directory, &quot;.save&quot; and a number (e.g.
&quot;.save.1&quot;) will be suffixed to the current filename in order to make it
unique. In multibuffer mode, <B>nano</B> will write all the open buffers
to the respective emergency files.
<A NAME="lbAG">&nbsp;</A>
<H2>BUGS</H2>
@@ -141,12 +198,12 @@ Please send any comments or bug reports to
<BR>
The nano mailing list is available from
The <B>nano</B> mailing list is available from
<BR>
<B><A HREF="mailto:nano-devel@lists.sourceforge.net">nano-devel@lists.sourceforge.net</A>.</B>
<B><A HREF="mailto:nano-devel@gnu.org">nano-devel@gnu.org</A>.</B>
To subscribe, email to <A HREF="mailto:nano-devel-request@lists.sourceforge.net">nano-devel-request@lists.sourceforge.net</A> with a
To subscribe, email to <A HREF="mailto:nano-devel-request@gnu.org">nano-devel-request@gnu.org</A> with a
subject of &quot;subscribe&quot;.
<A NAME="lbAH">&nbsp;</A>
<H2>HOMEPAGE</H2>
@@ -155,9 +212,10 @@ subject of &quot;subscribe&quot;.
<A NAME="lbAI">&nbsp;</A>
<H2>AUTHOR</H2>
Chris Allegretta &lt;<A HREF="mailto:chrisa@asty.org">chrisa@asty.org</A>&gt;, et al (see AUTHORS for details).
Chris Allegretta &lt;<A HREF="mailto:chrisa@asty.org">chrisa@asty.org</A>&gt;, et al (see AUTHORS and THANKS for
details).
This manual page was originally written by Jordi Mallach
&lt;<A HREF="mailto:jordi@sindominio.net">jordi@sindominio.net</A>&gt;, for the Debian GNU/Linux system (but may be
&lt;<A HREF="mailto:jordi@sindominio.net">jordi@sindominio.net</A>&gt;, for the Debian GNU system (but may be
used by others).
<P>
@@ -177,6 +235,6 @@ used by others).
This document was created by
<A HREF="http://localhost/cgi-bin/man/man2html">man2html</A>,
using the manual pages.<BR>
Time: 02:16:52 GMT, December 18, 2000
Time: 16:04:40 GMT, October 13, 2002
</BODY>
</HTML>

4098
nano.c

File diff suppressed because it is too large Load Diff

208
nano.h
View File

@@ -2,10 +2,10 @@
/**************************************************************************
* nano.h *
* *
* Copyright (C) 1999 Chris Allegretta *
* Copyright (C) 1999-2002 Chris Allegretta *
* 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 1, or (at your option) *
* 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, *
@@ -19,10 +19,6 @@
* *
**************************************************************************/
#ifdef HAVE_MALLOC_H
#include <malloc.h>
#endif
#ifdef HAVE_LIMITS_H
#include <limits.h>
#endif
@@ -34,7 +30,12 @@
#define SET(bit) flags |= bit
#define UNSET(bit) flags &= ~bit
#define ISSET(bit) (flags & bit)
#define TOGGLE(bit) flags ^= bit
#ifndef NANO_SMALL
/* For the backup file copy ... */
# define COPYFILEBLOCKSIZE 1024
#endif
#ifdef USE_SLANG /* Slang support enabled */
#include <slcurses.h>
@@ -45,10 +46,21 @@
#include <curses.h>
#endif /* CURSES_H */
#ifdef HAVE_LIBINTL_H
#include <libintl.h>
#ifdef ENABLE_NLS
# ifdef HAVE_LIBINTL_H
# include <libintl.h>
# endif
# define _(string) gettext(string)
# ifdef NO_NGETTEXT
# define ngettext(singular, plural, number) gettext(number == 1 ? singular : plural)
# endif
#else
# define _(string) (string)
# define ngettext(singular, plural, number) number == 1 ? singular : plural
#endif
#include <sys/types.h>
#include <sys/stat.h>
#include "config.h"
#if !defined(HAVE_SNPRINTF) || !defined(HAVE_VSNPRINTF)
@@ -61,16 +73,58 @@
# endif
#endif
/* HP-UX 10 & 11 do not seem to support KEY_HOME and KEY_END */
#ifndef KEY_HOME
#define KEY_HOME -1
#endif /* KEY_HOME */
#ifndef KEY_END
#define KEY_END -1
#endif /* KEY_END */
#define VERMSG "GNU nano " VERSION
#if defined(DISABLE_WRAPPING) && defined(DISABLE_JUSTIFY)
#define DISABLE_WRAPJUSTIFY 1
#endif
/* Structure types */
typedef struct filestruct {
char *data;
struct filestruct *next; /* Next node */
struct filestruct *prev; /* Previous node */
long lineno; /* The line number */
int lineno; /* The line number */
} filestruct;
#ifdef ENABLE_MULTIBUFFER
typedef struct openfilestruct {
char *filename;
#ifndef NANO_SMALL
struct stat originalfilestat;
#endif
struct openfilestruct *next; /* Next node */
struct openfilestruct *prev; /* Previous node */
struct filestruct *fileage; /* Current file */
struct filestruct *filebot; /* Current file's last line */
#ifndef NANO_SMALL
struct filestruct *file_mark_beginbuf;
/* Current file's beginning marked line */
int file_mark_beginx; /* Current file's beginning marked line's
x-coordinate position */
#endif
int file_current_x; /* Current file's x-coordinate position */
int file_current_y; /* Current file's y-coordinate position */
int file_flags; /* Current file's flags: modification
status (and marking status, if
available) */
int file_placewewant; /* Current file's place we want */
int file_totlines; /* Current file's total number of lines */
long file_totsize; /* Current file's total size */
int file_lineno; /* Current file's line number */
} openfilestruct;
#endif
typedef struct shortcut {
int val; /* Actual sequence that generates the keystroke */
int altval; /* Alt key # for this function, or 0 for none */
@@ -78,17 +132,57 @@ typedef struct shortcut {
int misc2;
int viewok; /* is this function legal in view mode? */
int (*func) (void); /* Function to call when we catch this key */
char *desc; /* Description, e.g. "Page Up" */
char *help; /* Help file entry text */
const char *desc; /* Description, e.g. "Page Up" */
#ifndef DISABLE_HELP
const char *help; /* Help file entry text */
#endif
struct shortcut *next;
} shortcut;
#ifndef NANO_SMALL
typedef struct toggle {
int val; /* Sequence to toggle the key. Should only need 1 */
char *desc; /* Description for when toggle is, uh, toggled,
e.g. "Pico Messages", we'll append Enabled or
const char *desc; /* Description for when toggle is, uh, toggled,
e.g. "Pico Messages"; we'll append Enabled or
Disabled */
int flag; /* What flag actually gets toggled */
struct toggle *next;
} toggle;
#endif /* !NANO_SMALL */
#ifdef ENABLE_NANORC
typedef struct rcoption {
const char *name;
int flag;
} rcoption;
#endif /* ENABLE_NANORC */
#ifdef ENABLE_COLOR
typedef struct colortype {
int fg; /* fg color */
int bg; /* bg color */
int bright; /* Is this color A_BOLD? */
int pairnum; /* Color pair number used for this fg/bg */
char *start; /* Start (or all) of the regex string */
char *end; /* End of the regex string */
struct colortype *next;
} colortype;
typedef struct exttype {
char *val;
struct exttype *next;
} exttype;
typedef struct syntaxtype {
char *desc; /* Name of this syntax type */
exttype *extensions; /* List of extensions that this applies to */
colortype *color; /* color struct for this syntax */
struct syntaxtype *next;
} syntaxtype;
#endif /* ENABLE_COLOR */
/* Bitwise flags so we can save space (or more correctly, not waste it) */
@@ -106,14 +200,26 @@ typedef struct toggle {
#define SAMELINEWRAP (1<<11)
#define VIEW_MODE (1<<12)
#define USE_MOUSE (1<<13)
#define USE_REGEXP (1<<14)
#define REGEXP_COMPILED (1<<15)
#define TEMP_OPT (1<<16)
#define CUT_TO_END (1<<17)
#define DISABLE_CURPOS (1<<18)
#define USE_REGEXP (1<<14)
#define REGEXP_COMPILED (1<<15)
#define TEMP_OPT (1<<16)
#define CUT_TO_END (1<<17)
#define REVERSE_SEARCH (1<<18)
#define MULTIBUFFER (1<<19)
#define CLEAR_BACKUPSTRING (1<<20)
#define DOS_FILE (1<<21)
#define MAC_FILE (1<<22)
#define SMOOTHSCROLL (1<<23)
#define DISABLE_CURPOS (1<<24) /* Damn, we still need it */
#define ALT_KEYPAD (1<<25)
#define NO_CONVERT (1<<26)
#define BACKUP_FILE (1<<27)
#define NO_RCFILE (1<<28)
#define COLOR_SYNTAX (1<<28)
/* Control key sequences, chaning these would be very very bad */
/* Control key sequences, changing these would be very very bad */
#define NANO_CONTROL_SPACE 0
#define NANO_CONTROL_A 1
#define NANO_CONTROL_B 2
#define NANO_CONTROL_C 3
@@ -172,8 +278,14 @@ typedef struct toggle {
#define NANO_ALT_X 'x'
#define NANO_ALT_Y 'y'
#define NANO_ALT_Z 'z'
#define NANO_ALT_PERIOD '.'
#define NANO_ALT_COMMA ','
#define NANO_ALT_LCARAT '<'
#define NANO_ALT_RCARAT '>'
#define NANO_ALT_BRACKET ']'
#define NANO_ALT_SPACE ' '
/* Some semi-changeable keybindings, dont play with unless you're sure you
/* Some semi-changeable keybindings; don't play with unless you're sure you
know what you're doing */
#define NANO_INSERTFILE_KEY NANO_CONTROL_R
@@ -208,7 +320,6 @@ know what you're doing */
#define NANO_FIRSTLINE_KEY NANO_PREVPAGE_KEY
#define NANO_LASTLINE_KEY NANO_NEXTPAGE_KEY
#define NANO_CANCEL_KEY NANO_CONTROL_C
#define NANO_CASE_KEY NANO_CONTROL_A
#define NANO_REFRESH_KEY NANO_CONTROL_L
#define NANO_JUSTIFY_KEY NANO_CONTROL_J
#define NANO_JUSTIFY_FKEY KEY_F(4)
@@ -218,6 +329,7 @@ know what you're doing */
#define NANO_FORWARD_KEY NANO_CONTROL_F
#define NANO_BACK_KEY NANO_CONTROL_B
#define NANO_MARK_KEY NANO_CONTROL_6
#define NANO_ALT_MARK_KEY NANO_ALT_A
#define NANO_HOME_KEY NANO_CONTROL_A
#define NANO_END_KEY NANO_CONTROL_E
#define NANO_DELETE_KEY NANO_CONTROL_D
@@ -227,7 +339,19 @@ know what you're doing */
#define NANO_ENTER_KEY NANO_CONTROL_M
#define NANO_FROMSEARCHTOGOTO_KEY NANO_CONTROL_T
#define NANO_TOFILES_KEY NANO_CONTROL_T
#define NANO_APPEND_KEY NANO_ALT_A
#define NANO_PREPEND_KEY NANO_ALT_P
#define NANO_OPENPREV_KEY NANO_ALT_LCARAT
#define NANO_OPENNEXT_KEY NANO_ALT_RCARAT
#define NANO_OPENPREV_ALTKEY NANO_ALT_COMMA
#define NANO_OPENNEXT_ALTKEY NANO_ALT_PERIOD
#define NANO_BRACKET_KEY NANO_ALT_BRACKET
#define NANO_EXTCMD_KEY NANO_CONTROL_X
#define NANO_NEXTWORD_KEY NANO_CONTROL_SPACE
#define NANO_PREVWORD_KEY NANO_ALT_SPACE
#ifndef NANO_SMALL
/* Toggles do not exist with NANO_SMALL. */
#define TOGGLE_CONST_KEY NANO_ALT_C
#define TOGGLE_AUTOINDENT_KEY NANO_ALT_I
#define TOGGLE_SUSPEND_KEY NANO_ALT_Z
@@ -235,39 +359,29 @@ know what you're doing */
#define TOGGLE_PICOMODE_KEY NANO_ALT_P
#define TOGGLE_MOUSE_KEY NANO_ALT_M
#define TOGGLE_CUTTOEND_KEY NANO_ALT_K
#define TOGGLE_REGEXP_KEY NANO_ALT_E
#define TOGGLE_REGEXP_KEY NANO_ALT_R
#define TOGGLE_WRAP_KEY NANO_ALT_W
#define TOGGLE_BACKWARDS_KEY NANO_ALT_B
#define TOGGLE_CASE_KEY NANO_ALT_C
#define TOGGLE_LOAD_KEY NANO_ALT_F
#define TOGGLE_DOS_KEY NANO_ALT_D
#define TOGGLE_MAC_KEY NANO_ALT_O
#define TOGGLE_SMOOTH_KEY NANO_ALT_S
#define TOGGLE_NOCONVERT_KEY NANO_ALT_N
#define TOGGLE_BACKUP_KEY NANO_ALT_B
#define TOGGLE_SYNTAX_KEY NANO_ALT_Y
#endif /* !NANO_SMALL */
#define MAIN_LIST_LEN 26
#define MAIN_VISIBLE 12
#define WHEREIS_LIST_LEN 6
#define REPLACE_LIST_LEN 6
#define REPLACE_LIST_2_LEN 3
#define GOTO_LIST_LEN 3
#define HELP_LIST_LEN 3
#define SPELL_LIST_LEN 1
#ifndef DISABLE_BROWSER
#define WRITEFILE_LIST_LEN 2
#define BROWSER_LIST_LEN 3
#else
#define WRITEFILE_LIST_LEN 1
#endif
#ifdef HAVE_REGEX_H
#define TOGGLE_LEN 9
#else
#define TOGGLE_LEN 8
#endif
#define VIEW 1
#define NOVIEW 0
#define TOP 2
#define CENTER 1
#define BOTTOM 0
typedef enum {
CENTER, TOP, NONE
} topmidbotnone;
/* Minimum editor window rows required for Nano to work correctly */
/* Minimum editor window rows required for nano to work correctly */
#define MIN_EDITOR_ROWS 3
/* Default number of characters from end-of-line where text wrapping occurs */
@@ -276,4 +390,4 @@ know what you're doing */
/* Minimum fill length (space available for text before wrapping occurs) */
#define MIN_FILL_LENGTH 10
#endif /* ifndef NANO_H */
#endif /* !NANO_H */

405
nano.info
View File

@@ -1,405 +0,0 @@
This is nano.info, produced by makeinfo version 4.0 from nano.texi.
INFO-DIR-SECTION Editors
START-INFO-DIR-ENTRY
* Nano: (nano). Small and friendly text editor.
END-INFO-DIR-ENTRY

File: nano.info, Node: Top, Next: Introduction, Prev: (dir), Up: (dir)
This manual documents GNU nano, a small and friendly text editor.
* Menu:
* Introduction::
* Editor Basics::
* Online Help::
* Feature Toggles::
* The File Browser::
* Pico Compatibility::
* Building and Configure Options::

File: nano.info, Node: Introduction, Next: Editor Basics, Prev: Top, Up: Top
Introduction
************
GNU `nano' is a small and friendly text editor. Besides basic text
editing, `nano' offers many extra features like an interactive search
and replace, goto line number, auto-indentation, feature toggles,
internationalization support, and filename tab completion.
* Menu:
* Overview::
* Command Line Options::

File: nano.info, Node: Overview, Next: Command Line Options, Prev: Introduction, Up: Introduction
Overview
========
`nano' [GNU long option] [option] +LINE [ FILE ... ]
The original goal for `nano' was a complete bug-for-bug compatible
emulation of Pico, but consistency is now a slightly higher priority.
There is a flag to implement (nearly) complete Pico emulation, (option
-p or GNU long option -pico). This can also be toggled from within
`nano' by typing Meta-P. *Note Pico Compatibility::, for more info.
Email bug reports to <nano@nano-editor.org>.

File: nano.info, Node: Command Line Options, Prev: Overview, Up: Introduction
Command Line Options
====================
`nano' takes the following options from the command line:
`-T [num, --tabsize=[num]'
Set the displayed tab length to [num] columns.
`-R, --regexp'
Turns on regular expression search and search/replace.
`-V, --version'
Print the version number and copyright and quit.
`-c, --const'
Constantly display the cursor posititon and line number on the
statusbar.
`-h, --help'
Print the usage and exit.
`-i, --autoindent'
Automatically indent new lines to the same number of spaces and
tabs as the previous line.
`-k, --cut'
Makes ^K cut from the current cursor position to the end of the
current line.
`-l, --nofollow'
When writing files, if the given file is a symbolic link it is
removed and a new file is created.
`-m, --mouse'
Enables the use of the mouse to select text (currently only useful
for running under the X window system).
`-p, --pico'
Emulate Pico as closely as possible, sacrificing consistency for
correct emulation. *Note Pico Compatibility::, for more info.
`-r [#cols], --fill=[#cols].'
Wrap lines at column #cols. By default this is the width of the
screen, less eight.
`-s [prog], --speller=[prog]'
Invoke [prog] as the spell checker. By default, `nano' uses its
own interactive spell checker that requires the `spell' program be
installed on your system.
`-t, --tempfile'
Do not ask whether or not to save the current contents of the file
when exiting, assume yes. This is most useful when using `nano'
as the composer of a mailer program.
`-x, --nohelp'
In Expert Mode, the Shortcut Lists will not appear at the bottom
of the screen. This affects the location of the statusbar as
well, as in Expert Mode it is located at the very bottom of the
editor.
Note: When accesing the help system, Expert Mode is temporarily
disabled to display the help system navigation keys.
`-v, --view'
Do not allow the contents of the file to be altered. Note that
this flag should NOT be used in place of correct file permissions
to implement a read-only file.
`-w, --nowrap'
Do not wrap long lines at any length. This option overrides any
value for -r.
`-z, --suspend'
Enable suspend ability of `nano' using the system's suspend
keystroke (usually ^Z).
`+LINE'
Start at line number LINE instead of the default of line 1.

File: nano.info, Node: Editor Basics, Next: Online Help, Prev: Introduction, Up: Top
Editor Basics
*************
* Menu:
* Entering Text::
* Special Functions::
* The Titlebar::
* The Statusbar::
* Shortcut Lists::

File: nano.info, Node: Entering Text, Next: Special Functions, Prev: Editor Basics, Up: Editor Basics
Entering Text
=============
All key sequences in `nano' are entered using the keyboard. `nano'
is a "modeless" editor, all keys with the exception of Control and Meta
key sequences will enter text into the file being edited.

File: nano.info, Node: Special Functions, Next: The Titlebar, Prev: Entering Text, Up: Editor Basics
Special Functions
=================
Special functions use the Control key (displayed in the help and
shotcut lists as ^) or the Meta key (displayed as M).
* Control key sequences are entered by holding down the Control key
and pressing the desired letter.
* Meta key sequences can be entered in a number of possible ways:
Pressing the Escape key, then releasing it and pressing the
desired key, or holding down the Alt key while pressing the desired
key. This varies from keyboard to keyboard, and certain commercial
operating systems "swallow" the Alt key so that it never reaches
the application. If your operating system does this, you should
use the Escape key to generate Meta key sequences.

File: nano.info, Node: The Titlebar, Next: The Statusbar, Prev: Special Functions, Up: Editor Basics
The Titlebar
============
The titlebar is the line displayed at the top of the editor. There
are three sections: left, center and right. The section on the left
displays the version of `nano' being used. The center section displays
the current file name, or "New Buffer" if the file has not yet been
named. The section on the right will display "Modified" if the file
has been modified since it ws last saved or opened.
Special modes: When nano is in "File browser" mode, the center
section will display the current directory instead of the filename.
*Note The File Browser::.

File: nano.info, Node: The Statusbar, Next: Shortcut Lists, Prev: The Titlebar, Up: Editor Basics
The Statusbar
=============
The statusbar is located three lines from the bottom of the screen
(or the bottom line in Expert Mode. *Note Expert Mode::, for more info.
The Statusbar shows important and informational messages. Any error
messages that occur from using the editor will appear on the statusbar.
Any questions that are asked of the user will be asked on the statusbar,
and any user input (serch strings, file names, etc) will be input on the
statusbar.

File: nano.info, Node: Shortcut Lists, Prev: The Statusbar, Up: Editor Basics
Shortcut Lists
==============
The Shorcut Lists are the two lines at the bottom of the screen
which show some of the more commonly used functions in the editor. The
exact functions which are displayed depend on whether Pico
Compatibility Mode mode is enabled. *Note Pico Compatibility::, for
more info.

File: nano.info, Node: Online Help, Next: Feature Toggles, Prev: Editor Basics, Up: Top
Online Help
***********
The online help system in `nano' is available by pressing ^G. It is
fairly self explanatory, documenting the various parts of the editor
and available keystrokes. Navigation is via the ^Y (Page Up) and ^V
(Page Down) keys. ^X exits the help system.

File: nano.info, Node: Feature Toggles, Next: The File Browser, Prev: Online Help, Up: Top
Feature Toggles
***************
Toggles allow you to change certain aspects of the editor that would
normally be done via command line flags. They are invoked via certain
Meta key sequenced. *Note Special Functions::, for more info. The
following toggles are available:
`Constant Update Toggle (Meta-C)'
toggles the -c (-const) command line flag.
`Regular Expressions Toggle (Meta-E)'
toggles the -R (-regexp) command line flag.
`AutoIndent Toggle (Meta-I)'
toggles the -i (-autoindent) command line flag.
`Cut To End Toggle (Meta-K)'
toggles the -k (-cut) command line flag.
`Cut To End Toggle (Meta-M)'
toggles the -m (-mouse) command line flag.
`Pico Mode Toggle (Meta-P)'
toggles the -p (-pico) command line flag. *Note Pico
Compatibility::, for more info.
`AutoWrap Toggle (Meta-W)'
toggles the -w (-nowrap) command line flag.
`Expert/Nohelp Toggle (Meta-X)'
toggles the -x (-nohelp) command line flag.
`Suspend Toggle (Meta-Z)'
toggles the -z (-suspend) command line flag.

File: nano.info, Node: The File Browser, Next: Pico Compatibility, Prev: Feature Toggles, Up: Top
The File Browser
****************
When reading or writilg files, pressing ^T will invoke the file
browser. Here, one can navigate directories in a graphical manner in
order to find the desired file.
Basic movement in the file browser is accomplished with he arrow keys
and page up/down. The behavior of the enter (or 's') key varies by what
is currently selected. If the currently selected object is a directory,
the file browser will enter and display the contects of the directory.
If the object is a file, this filename and path are copied to the
statusbar and the file browser is exited.

File: nano.info, Node: Pico Compatibility, Next: Building and Configure Options, Prev: The File Browser, Up: Top
Pico Compatibility
******************
Nano does not completely emulate Pico by default. The following
differences apply to the default mode and Pico Compatibility mode:
`Displayed Shortcuts'
By default, the following shortcuts are displayed in the Shortcut
Lists:
^G ^O ^\ ^Y ^K ^C
^X ^R ^W ^V ^U ^T
Related functions are listed above or below each other by default.
The Justify function is not listed, instead the "Replace"
function is displayed. Also, he "Read File" and "WriteOut"
functions are aligned for consistency.
In Pico Compatibility mode, the default Pico shortcuts are
displayed:
^G ^O ^R ^Y ^K ^C
^X ^J ^W ^V ^U ^T
`Previous String Text'
By default, previously entered string for a function (search
string, file name) will be placed on the statusbar, and is
editable. This is done so there is consistency across all
functions. For example: even if there is a previous replace
string, it can always be deleted if one wishes to perform an empty
string replace.
In Pico Compatibility Mode, the previously entered text in a
search or replace will appear in brackets, and is not editable.
It is not a simple matter to do an empty string replace when a
previous replace string exists, for example. When writing a file,
the previous filename will be displayed in the editable text
portion of the editor.
`Interactive Replace and Spell Checker'
It is worth noting that the `nano' replace function is interactive,
i.e. it does not stop after one search string is found and
automatically replace it. The `nano' implementation will stop at
each search string found and query whether to replace this
instance or not. The internal spell checker operates similarly.
Note that these is no way to force these functions to behave in
the Pico fashion.

File: nano.info, Node: Building and Configure Options, Prev: Pico Compatibility, Up: Top
Building and Configure Options
******************************
Building nano from source is fairly straightforward if you are
familiar with compiling programs with autoconf support:
tar xvfz nano-x.y.z.tar.gz (where x.y.z is the version of nano) cd
nano-x.y.z/ ./configure make make install
if you are looking to optimize nano for size, you may want to
consider the following command line options:
`--disable-tabcomp'
Disable the tab completion code when reading or writing files.
`--disable-justify'
Disable the justify (^J)/unjustify (^U) functions in the editor.
`--disable-speller'
Disables spell checker abillity.
`--disable-help'
Disables the help function (^G). Disabling this option maks the
binary much smaller, but makes it difficult for new users to learn
more than very basic things about using the editor.
`--disable-browser'
Disables the mini file browser (^O) when reading or writing files.
`--enable-tiny'
This options disables all the above. It also disables some of the
larger internals of the editor, like the marker code (^^) and the
cut to line (-k) option which it depends on to work properly. It
also disables the function toggles and mouse support.
`--disable-wrapping'
Disables all word wrapping in the editor. This also eliminates the
-w command line flag, as nonwrapping is then the default behavior.

Tag Table:
Node: Top199
Node: Introduction507
Node: Overview933
Node: Command Line Options1513
Ref: Expert Mode3236
Node: Editor Basics4078
Node: Entering Text4303
Node: Special Functions4643
Node: The Titlebar5497
Node: The Statusbar6194
Node: Shortcut Lists6774
Node: Online Help7166
Node: Feature Toggles7542
Node: The File Browser8685
Node: Pico Compatibility9394
Node: Building and Configure Options11436

End Tag Table

44
nano.spec.in Normal file
View File

@@ -0,0 +1,44 @@
%define name @PACKAGE@
%define ver @VERSION@
%define rel 1
Summary : Pico editor clone with enhancements
Name : %{name}
Version : %{ver}
Release : %{rel}
Copyright : GPL
Group : Console/Editors
URL : http://www.nano-editor.org
Source : http://www.nano-editor.org/dist/v1.1/%{name}-%{ver}.tar.gz
BuildRoot : /var/tmp/%{name}-buildroot
Requires : ncurses
%description
GNU nano is a small and friendly text editor. It aims to emulate the Pico
text editor while also offering a few enhancements.
%prep
%setup -q
%build
%configure --enable-extra
make RPM_OPT_FLAGS="$RPM_OPT_FLAGS"
%install
rm -rf "$RPM_BUILD_ROOT"
make DESTDIR="$RPM_BUILD_ROOT" install
%files
%defattr(-,root,root)
%doc AUTHORS BUGS COPYING ChangeLog INSTALL NEWS README THANKS TODO nanorc.sample
%{_bindir}/nano
%{_mandir}/*/*
%{_datadir}/locale/*/LC_MESSAGES/nano.mo
%{_infodir}/nano.info*
%changelog
* Sat Mar 30 2002 Chris Allegretta <chrisa@asty.org>
- Accepted into main distribution
- Added Packager and URL tage from original spec file.
* Tue Mar 06 2002 Brett Pemberton <generica@email.com>
- Initial spec-file

223
nano.texi
View File

@@ -8,12 +8,12 @@
@c Run `makeinfo' rather than `texinfo-format-buffer'.
@smallbook
@set EDITION 0.1
@set VERSION 1.0.1
@set UPDATED 12 Feb 2001
@set VERSION 1.1.12
@set UPDATED 30 Jul 2002
@dircategory Editors
@direntry
* Nano: (nano). Small and friendly text editor.
* nano: (nano). Small and friendly text editor.
@end direntry
@c tex
@@ -23,7 +23,7 @@
@titlepage
@title GNU @code{nano}
@subtitle a small and friendly text editor.
@subtitle version 1.0.1
@subtitle version 1.1.12
@author Chris Allegretta
@page
@@ -33,28 +33,28 @@ editor.
This manual is part of the GNU @code{nano} distribution.@*
@sp4
Copyright (C) 1999, 2000, 2001 Chris Allegretta.
Copyright (C) 1999, 2000, 2001, 2002 Chris Allegretta.
Permission is granted to make and distribute verbatim copies of
this manual provided the copyright notice and this permission notice
are preserved on all copies.
Permission is granted to make and distribute verbatim copies of this
manual provided the copyright notice and this permission notice are
preserved on all copies.
@iftex
Permission is granted to process this file through TeX and print the
results, provided the printed document carries copying permission
notice identical to this one except for the removal of this paragraph
(this paragraph not being relevant to the printed manual).
results, provided the printed document carries copying permission notice
identical to this one except for the removal of this paragraph (this
paragraph not being relevant to the printed manual).
@end iftex
Permission is granted to copy and distribute modified versions of this
manual under the conditions for verbatim copying, provided that the entire
resulting derived work is distributed under the terms of a permission
notice identical to this one.
manual under the conditions for verbatim copying, provided that the
entire resulting derived work is distributed under the terms of a
permission notice identical to this one.
Permission is granted to copy and distribute translations of this manual
into another language, under the above conditions for modified versions,
except that this permission notice may be stated in a translation approved
by the Foundation.
except that this permission notice may be stated in a translation
approved by the Foundation.
You may contact the author by:
e-mail: @email{chrisa@@asty.org}@*
@@ -62,7 +62,8 @@ e-mail: @email{chrisa@@asty.org}@*
@node Top, Introduction, (dir), (dir)
This manual documents GNU nano, a small and friendly text editor.
This manual documents GNU @code{nano}, a small and friendly text
editor.
@menu
* Introduction::
@@ -77,11 +78,10 @@ This manual documents GNU nano, a small and friendly text editor.
@node Introduction, Editor Basics, Top, Top
@chapter Introduction
GNU @code{nano} is a small and friendly text editor. Besides basic
text editing, @code{nano} offers many extra features like an
interactive search and replace, goto line number, auto-indentation,
feature toggles, internationalization support, and filename tab
completion.
GNU @code{nano} is a small and friendly text editor. Besides basic text
editing, @code{nano} offers many extra features like an interactive
search and replace, goto line number, auto-indentation, feature toggles,
internationalization support, and filename tab completion.
@menu
* Overview::
@@ -94,7 +94,7 @@ completion.
@code{nano} [GNU long option] [option] +LINE [ @var{ file ...} ]
The original goal for @code{nano} was a complete bug-for-bug compatible
emulation of Pico, but consistency is now a slightly higher priority.
emulation of Pico, but consistency is now a slightly higher priority.
There is a flag to implement (nearly) complete Pico emulation, (option -p
or GNU long option --pico). This can also be toggled from within
@code{nano} by typing Meta-P. @xref{Pico Compatibility}, for more
@@ -106,19 +106,58 @@ Email bug reports to @email{nano@@nano-editor.org}.
@section Command Line Options
@code{nano} takes the following options from the command line:
@table @code
@item -T [num, --tabsize=[num]
Set the displayed tab length to [num] columns.
@item -B, --backup
When saving a file, back up the previous version of it to the current
filename suffixed with a ~.
@item -D, --dos
Write file in DOS format.
@item -F, --multibuffer
Enable multiple file buffers, if available.
@item -I, --ignorercfiles
Don't look at /etc/nanorc or ~/.nanorc, if nanorc support is available.
@item -K, --keypad
Do not use the ncurses keypad() call unless necessary. Try this flag if
you find that the arrow keys on the numeric keypad do not work for you
under @code{nano}.
@item -M, --mac
Write file in Mac format.
@item -N, --noconvert
Do not convert files from DOS/Mac format.
@item -Q [str], --quotestr [str]
Set the quoting string for justifying. The default is
"^([ \t]*[|>:@}#])+" if regular expression support is available, or
"> " otherwise.
Set the quoting string for justifying. The default is "> ".
@item -R, --regexp
Turns on regular expression search and search/replace.
@item -S, --smooth
Enables smooth scrolling.
@item -T [num], --tabsize=[num]
Set the displayed tab length to [num] columns.
@item -V, --version
Print the version number and copyright and quit.
@item -Y, --syntax=[str]
Specify a specific syntax highlighting from the .nanorc to use, if
available.
@item -c, --const
Constantly display the cursor posititon and line number on the statusbar.
Constantly display the cursor position and line number on the statusbar.
@item -h, --help
Print the usage and exit.
@@ -139,13 +178,19 @@ and a new file is created.
Enables the use of the mouse to select text (currently only useful for
running under the X window system).
@item -o [dir], --operatingdir=[dir]
Set operating directory. Makes @code{nano} set up something similar to a
chroot.
@item -p, --pico
Emulate Pico as closely as possible, sacrificing consistency for correct
emulation. @xref{Pico Compatibility}, for more info.
@item -r [#cols], --fill=[#cols].
Wrap lines at column #cols. By default this is the width of the screen,
less eight.
less eight. If this value is negative, wrapping will occur at #cols from
the right of the screen, allowing it to vary along with the screen width
if the screen is resized.
@item -s [prog], --speller=[prog]
Invoke [prog] as the spell checker. By default, @code{nano} uses its
@@ -163,7 +208,7 @@ In Expert Mode, the Shortcut Lists will not appear at the bottom of the
screen. This affects the location of the statusbar as well, as in Expert
Mode it is located at the very bottom of the editor.
Note: When accesing the help system, Expert Mode is temporarily disabled
Note: When accessing the help system, Expert Mode is temporarily disabled
to display the help system navigation keys.
@item -v, --view
@@ -179,6 +224,9 @@ Do not wrap long lines at any length. This option overrides any value for
Enable suspend ability of @code{nano} using the system's suspend
keystroke (usually ^Z).
@item -a, -b, -e, -f, -g, -j
Ignored, for compatibility with Pico.
@item +LINE
Start at line number LINE instead of the default of line 1.
@end table
@@ -205,7 +253,7 @@ edited.
@section Special Functions
Special functions use the Control key (displayed in the help and
shotcut lists as ^) or the Meta key (displayed as M).
shortcut lists as ^) or the Meta key (displayed as M).
@itemize @bullet
@@ -230,31 +278,31 @@ three sections: left, center and right. The section on the left displays
the version of @code{nano} being used. The center section displays the
current file name, or "New Buffer" if the file has not yet been named.
The section on the right will display "Modified" if the file has been
modified since it ws last saved or opened.
modified since it was last saved or opened.
Special modes: When nano is in "File browser" mode, the center section
will display the current directory instead of the filename.
Special modes: When @code{nano} is in "File browser" mode, the center
section will display the current directory instead of the filename.
@xref{The File Browser}.
@node The Statusbar, Shortcut Lists, The Titlebar, Editor Basics
@section The Statusbar
The statusbar is located three lines from the bottom of the screen (or the
bottom line in Expert Mode. @xref{Expert Mode}, for more info.
The statusbar is located three lines from the bottom of the screen (or
the bottom line in Expert Mode. @xref{Expert Mode}, for more info.
The Statusbar shows important and informational messages. Any error
messages that occur from using the editor will appear on the statusbar.
Any questions that are asked of the user will be asked on the statusbar,
and any user input (serch strings, file names, etc) will be input on the
statusbar.
and any user input (search strings, file names, etc) will be input on
the statusbar.
@node Shortcut Lists, , The Statusbar, Editor Basics
@section Shortcut Lists
The Shorcut Lists are the two lines at the bottom of the screen which show
some of the more commonly used functions in the editor. The exact
functions which are displayed depend on whether Pico Compatibility Mode mode
is enabled. @xref{Pico Compatibility}, for more info.
The Shortcut Lists are the two lines at the bottom of the screen which
show some of the more commonly used functions in the editor. The exact
functions which are displayed depend on whether Pico Compatibility Mode
mode is enabled. @xref{Pico Compatibility}, for more info.
@node Online Help, Feature Toggles, Editor Basics, Top
@chapter Online Help
@@ -271,15 +319,18 @@ and ^V (Page Down) keys. ^X exits the help system.
Toggles allow you to change certain aspects of the editor that
would normally be done via command line flags. They are invoked via
certain Meta key sequenced. @xref{Special Functions}, for more info.
The following toggles are available:
The following global toggles are available:
@table @code
@item Constant Update Toggle (Meta-C)
toggles the -c (--const) command line flag.
@item Backup File Toggle (Meta-B)
toggles the -B (--backup) command line flag.
@item Regular Expressions Toggle (Meta-E)
toggles the -R (--regexp) command line flag.
@item DOS Format Toggle (Meta-D)
toggles the -D (--dos) command line flag.
@item Multiple Files Toggle (Meta-F)
toggles the -F (--multibuffer) command line flag.
@item AutoIndent Toggle (Meta-I)
toggles the -i (--autoindent) command line flag.
@@ -287,13 +338,19 @@ toggles the -i (--autoindent) command line flag.
@item Cut To End Toggle (Meta-K)
toggles the -k (--cut) command line flag.
@item Cut To End Toggle (Meta-M)
@item Mouse Toggle (Meta-M)
toggles the -m (--mouse) command line flag.
@item Mac Format Toggle (Meta-O)
toggles the -M (--mac) command line flag.
@item Pico Mode Toggle (Meta-P)
toggles the -p (--pico) command line flag.
@xref{Pico Compatibility}, for more info.
@item Smooth Scrolling Toggle (Meta-S)
toggles the -s (--smooth) command line flag.
@item AutoWrap Toggle (Meta-W)
toggles the -w (--nowrap) command line flag.
@@ -303,27 +360,34 @@ toggles the -x (--nohelp) command line flag.
@item Suspend Toggle (Meta-Z)
toggles the -z (--suspend) command line flag.
@item Open Previous File Toggle (Meta-<)
changes buffer to previously loaded file.
@item Open Next File Toggle (Meta->)
changes buffer to next loaded file.
@end table
@node The File Browser, Pico Compatibility, Feature Toggles, Top
@chapter The File Browser
When reading or writilg files, pressing ^T will invoke the file browser.
Here, one can navigate directories in a graphical manner in order to find
the desired file.
When reading or writing files, pressing ^T will invoke the file browser.
Here, one can navigate directories in a graphical manner in order to
find the desired file.
Basic movement in the file browser is accomplished with he arrow keys
and page up/down. The behavior of the enter (or 's') key varies by what
is currently selected. If the currently selected object is a directory,
the file browser will enter and display the contects of the directory. If
the object is a file, this filename and path are copied to the statusbar
and the file browser is exited.
and page up/down. The behavior of the enter (or 's') key varies by what
is currently selected. If the currently selected object is a directory,
the file browser will enter and display the contents of the directory.
If the object is a file, this filename and path are copied to the
statusbar and the file browser is exited.
@node Pico Compatibility, Building and Configure Options, The File Browser, Top
@chapter Pico Compatibility
Nano does not completely emulate Pico by default. The following differences
apply to the default mode and Pico Compatibility mode:
nano does not completely emulate Pico by default. The following
differences apply to the default mode and Pico Compatibility mode:
@table @code
@item Displayed Shortcuts
@@ -367,17 +431,17 @@ to force these functions to behave in the Pico fashion.
@node Building and Configure Options, , Pico Compatibility, Top
@chapter Building and Configure Options
Building nano from source is fairly straightforward if you are familiar
Building @code{nano} from source is fairly straightforward if you are familiar
with compiling programs with autoconf support:
tar xvfz nano-x.y.z.tar.gz (where x.y.z is the version of nano)
tar xvfz nano-x.y.z.tar.gz (where x.y.z is the version of @code{nano})
cd nano-x.y.z/
./configure
make
make install
if you are looking to optimize nano for size, you may want to consider
the following command line options:
if you are looking to optimize @code{nano} for size, you may want to
consider the following command line options:
@table @code
@@ -389,29 +453,44 @@ Disable the tab completion code when reading or writing files.
Disable the justify (^J)/unjustify (^U) functions in the editor.
@item --disable-speller
Disables spell checker abillity.
Disables spell checker ability.
@item --disable-help
Disables the help function (^G). Disabling this option maks the
binary much smaller, but makes it difficult for new users
to learn more than very basic things about using the editor.
Disables the help function (^G). Disabling this option makes the binary
much smaller, but makes it difficult for new users to learn more than
very basic things about using the editor.
@item --disable-browser
Disables the mini file browser (^O) when reading or writing files.
@item --enable-tiny
This options disables all the above. It also disables some of
the larger internals of the editor, like the marker code (^^) and
the cut to line (-k) option which it depends on to work properly.
It also disables the function toggles and mouse support.
This options disables all the above. It also disables some of the larger
internals of the editor, like the marker code (^^) and the cut to line
(-k) option which it depends on to work properly. It also disables the
function toggles and mouse support.
@item --disable-wrapping
Disables all word wrapping in the editor. This also eliminates the
-w command line flag, as nonwrapping is then the default behavior.
Disables all word wrapping in the editor. This also eliminates the -w
command line flag, as nonwrapping is then the default behavior.
@item --disable-mouse
Disables all mouse functionality. This also disables the -m command
line flag which enables the mouse functions.
@item --disable-operatingdir
Disables setting of operating directory. This also disables the -o
command line flag.
@item --disable-nls
Disables Native Language support. This will make the available GNU
@code{nano} translations unusable.
@item --with-slang
Compiling GNU @code{nano} with Slang is supported, and will make the
binary notably smaller than if compiled with ncurses or other curses
libraries.
@end table
@contents
@bye

126
nanorc.sample Normal file
View File

@@ -0,0 +1,126 @@
# Sample initialization file for GNU nano
# Please note that you must have configured nano with
# --enable-nanorc for this file to be read!
#
# To make sure a value is not enabled, use "unset <option>"
# Use auto-indentation
# set autoindent
# Backup files to filename~
# set backup
# Constantly update the cursor position
# set const
# Use cut to end of line with ^K by default
# set cut
# Use this value instead of the default
# An out-of-range negative value can make nano die complaining that the
# screen is too small
# set fill -8
# Use alternate keypad routines
# set keypad
# Allow multiple file buffers (using ^R inserts into separate buffer)
# You must have configured with --enable-multibuffer or --enable-extra
# for this to work
#
# set multibuffer
# Don't convert files from DOS/Mac format
# set noconvert
# Don't follow symlinks when writing files
# set nofollow
# Don't display the help lists at the bottom of the screen
# set nohelp
# Don't wrap text at all
# set nowrap
# Set operating directory (chroot of sorts)
# set operatingdir "~"
# Use Pico Compatibility mode for the shortcut lists and search text
# set pico
# The email-quote string. This is a "regular expression" if your
# system supports them, otherwise a literal string. Default
# set quotestr "^([ \t]*[|>:}#])+" if you have regexps, otherwise
# set quotestr "> ".
# You can get old nano quoted-justify behavior via:
# set quotestr "(> )+"
# Do regular expression searches by default
# set regexp
# Use smooth scrolling as the default
# set smooth
# Use this spelling checker instead of the default one
# set speller aspell
# Allow nano to be suspended with ^Z
# set suspend
# Use this tab size instead of the default; it must be greater than 0
# set tabsize 4
# Save automatically on exit, don't prompt
# set tempfile
# Disallow file modification, why would you want this in an rc file? ;)
# set view
# Color setup
# Format:
# syntax "short description" ["filename regex" ...]
# color foreground,background "regex" ["regex"...]
#
# Legal colors are: white, black, red, blue, green, yellow, purple, cyan
# You may use the prefix "bright" to mean a stronger color highlight
#
# To use multi-line regexes use the start="regex" end="regex" format.
#
# If your system supports transparency, not specifying a background
# color will use a transparent color. If you don't want this, be sure
# to set the background color to black or white.
# syntax "c-file" ".*\.c$" ".*\.h$"
# color red "\<[A-Z_]{2,}\>"
# color green "\<float\>" "\<char\>" "\<int\>" "\<void\>"
# color green "\<static\>" "\<const\>" "\<struct\>"
# color brightyellow "\<if\>" "\<while\>" "\<do\>" "\<else\>" "\<case\>" "\<switch\>"
# color brightcyan "#define" "#include" "#ifn*def" "#endif"
# color brightcyan "#elif" "#else" "#if"
# You will in general want your comments and strings to come last,
# because syntax highlighting rules will be applied in the order they are
# read in
# color brightyellow "<[^= ]*>" ""(\\.|[^\"])*""
# color brightyellow start=""(\\.|[^\"])*\\( | )*$" end="^(\\.|[^\"])*""
# color brightblue "//.*"
# color brightblue start="/\*" end="\*/"
# Here are some short examples for TeX files and HTML
# syntax "HTML" "\.html$"
#
# color blue start="<" end=">"
# color red "&([^; ])*;"
#
# syntax "TeX" "\.tex$"
#
# color green "\\(.|([A-Za-z]*))"
# color magenta "\{" "\}"
# color blue "%.*"
# For this you will probably want to set your editor to "nano -Y mutt"
# syntax "mutt"
# color green "^>.*"

View File

@@ -4,4 +4,7 @@ POTFILES
*.gmo
*.pot
cat-id*
messages
messages.mo
remove-potcdate.sed
stamp-cat*

View File

@@ -1 +1,314 @@
2002-10-17 Jordi Mallach <jordi@sindominio.net>
* de.po: Updated translation by Michel Piefel.
2002-10-14 Jordi Mallach <jordi@sindominio.net>
* fr.po: Updated translation by Jean-Philippe Guérard.
2002-10-13 Jordi Mallach <jordi@sindominio.net>
* es.po: Updated translation by Ricardo Javier Cárdenes Medina.
2002-10-08 Jordi Mallach <jordi@sindominio.net>
* id.po: Updated translation by Tedi Heriyanto.
* ms.po: Updated translation by Sharuzzaman Ahmat Raslan.
2002-10-07 Jordi Mallach <jordi@sindominio.net>
* de.po: Updated translation by Michel Piefel.
2002-10-07 Jordi Mallach <jordi@sindominio.net>
* ca.po: Updated translation.
2002-10-07 Jordi Mallach <jordi@sindominio.net>
* sv.po: Updated translation by Christian Rose.
* gl.po: Updated translation by Jacobo Tarrío.
* pl.po: Updated translation by Wojciech Kotwica.
2002-09-08 Jordi Mallach <jordi@sindominio.net>
* ms.po: Updated translation by Sharuzzaman Ahmat Raslan.
2002-09-08 Jordi Mallach <jordi@sindominio.net>
* fr.po: Updated translation by Jean-Philippe Guérard.
* da.po: Updated translation by Keld Simonsen.
2002-08-19 Jordi Mallach <jordi@sindominio.net>
* de.po: Updated translation by Michael Piefel.
* ms.po: Updated translation by Sharuzzaman Ahmat Raslan.
2002-07-31 Jordi Mallach <jordi@sindominio.net>
* gl.po: Updated translation by Jacobo Tarrío.
2002-07-31 Jordi Mallach <jordi@sindominio.net>
* es.po: Updated translation by Ricardo Javier Cárdenes Medina.
2002-07-31 Jordi Mallach <jordi@sindominio.net>
* fr.po: Updated translation by Jean-Philippe Guérard.
2002-07-30 Jordi Mallach <jordi@sindominio.net>
* pl.po: Updated translation by Wojciech Kotwica.
* sv.po: Upadted translation by Christian Rose.
2002-07-29 Jordi Mallach <jordi@sindominio.net>
* ca.po: Updated translation.
2002-07-29 Jordi Mallach <jordi@sindominio.net>
* sv.po: Updated translation by Christian Rose.
2002-07-27 Jordi Mallach <jordi@sindominio.net>
* pt_BR.po: New Brazilian Portuguese translation by
Claudio Neves.
2002-07-25 Jordi Mallach <jordi@sindominio.net>
* id.po: Updated translation by Tedi Heriyanto.
2002-07-09 Jordi Mallach <jordi@sindominio.net>
* de.po: Updated translation by Michael Piefel.
2002-07-07 Jordi Mallach <jordi@sindominio.net>
* da.po: Updated translation by Keld Simonsen.
2002-07-03 Jordi Mallach <jordi@sindominio.net>
* ms.po: New Bahasa Melayu translation by
Sharuzzaman Ahmat Raslan.
2002-06-03 gettextize <bug-gnu-gettext@gnu.org>
* Makefile.in.in: Upgrade to gettext-0.11.2.
* Rules-quot: New file, from gettext-0.11.2.
* boldquot.sed: New file, from gettext-0.11.2.
* en@boldquot.header: New file, from gettext-0.11.2.
* en@quot.header: New file, from gettext-0.11.2.
* insert-header.sin: New file, from gettext-0.11.2.
* quot.sed: New file, from gettext-0.11.2.
* remove-potcdate.sin: New file, from gettext-0.11.2.
2002-05-13 Jordi Mallach <jordi@sindominio.net>
* fr.po: Updated translation by Jean-Philippe Guérard.
* de.po: Updated translation by Michael Piefel.
2002-05-13 Jordi Mallach <jordi@sindominio.net>
* it.po: Updated translation by Marco Colombo.
* gl.po: Updated translation by Jacobo Tarrío.
* ca.po: Updated translation.
* es.po: Updated translation.
2002-05-13 Jordi Mallach <jordi@sindominio.net>
* sv.po: Updated translation by Christian Rose.
2002-05-05 Jordi Mallach <jordi@sindominio.net>
* sv.po: Updated translation by Christian Rose.
2002-04-25 Jordi Mallach <jordi@sindominio.net>
* id.po: Updated translation by Tedi Heriyanto.
2002-04-19 Jordi Mallach <jordi@sindominio.net>
* ru.po: Updated translation by Sergey A. Ribalchenko.
* uk.po: Updated translation by Sergey A. Ribalchenko.
2002-04-13 Jordi Mallach <jordi@sindominio.net>
* it.po: Updated translation by Marco Colombo.
2002-04-13 Jordi Mallach <jordi@sindominio.net>
* nl.po: Updated translation by Guus Sliepen.
2002-04-10 Jordi Mallach <jordi@sindominio.net>
* sv.po: Updated translation by Christian Rose.
2002-04-05 Jordi Mallach <jordi@sindominio.net>
* gl.po: Updated translation by Jacobo Tarrio.
* de.po: Updated translation by Michael Piefel.
* fr.po: Updated translation by Jean-Philippe Guérard.
* ca.po: Updated.
* es.po: Updated.
2002-03-29 Jordi Mallach <jordi@sindominio.net>
* da.po: Updated translation by Keld Simonsen.
2002-03-27 Jordi Mallach <jordi@sindominio.net>
* it.po: Updated translation by Marco Colombo.
2002-03-25 Jordi Mallach <jordi@sindominio.net>
* id.po: Updated translation by Tedi Heriyanto.
2002-03-17 Jordi Mallach <jordi@sindominio.net>
* fr.po: Updated translation by Jean-Philippe Guérard.
2002-03-15 Jordi Mallach <jordi@sindominio.net>
* pl.po: Updated translation by Wojciech Kotwica.
2002-03-14 Jordi Mallach <jordi@sindominio.net>
* uk.po, ru.po: Updated translations by Sergey A.
Ribalchenko.
2002-03-12 Jordi Mallach <jordi@sindominio.net>
* ca.po: Updated to current CVS.
* es.po: Updated to current CVS.
* gl.po: Updated translation to current CVS by Jacobo Tarrio.
2002-03-12 Jordi Mallach <jordi@sindominio.net>
* gl.po: Updated translation by Jacobo Tarrio.
2002-03-11 Jordi Mallach <jordi@sindominio.net>
* fr.po: Updated translation by Jean-Philippe Guérard.
2002-03-09 Jordi Mallach <jordi@sindominio.net>
* id.po: Updated translation by Tedi Heriyanto.
* ca.po: Updated.
* es.po: Updated.
2002-03-07 Jordi Mallach <jordi@sindominio.net>
* sv.po: Updated translation by Christian Rose.
* de.po: Updated translation by Michael Piefel.
2002-03-05 Jordi Mallach <jordi@sindominio.net>
* pl.po: Updated translation by Wojciech Kotwica.
2002-02-20 Jordi Mallach <jordi@sindominio.net>
* nl.po: Updated translation by Guus Sliepen.
2002-02-15 Jordi Mallach <jordi@sindominio.net>
* nb.po: Updated translation by Stig E Sandoe.
2002-02-15 Jordi Mallach <jordi@sindominio.net>
* nb.po: Updated translation by Stig E Sandoe.
2002-02-14 Jordi Mallach <jordi@sindominio.net>
* da.po: Updated translation by Keld Simonsen.
2002-02-10 Jordi Mallach <jordi@sindominio.net>
* hu.po: Updated translation by Gergely Nagy.
2002-02-07 Jordi Mallach <jordi@sindominio.net>
* uk.po, ru.po: Updated translations by Sergey A.
Ribalchenko.
2002-02-06 Jordi Mallach <jordi@sindominio.net>
* hu.po: Updated translation by Gergely Nagy.
2002-02-06 Jordi Mallach <jordi@sindominio.net>
* cs.po: Incomplete update by Václav Haisman.
2002-01-27 Jordi Mallach <jordi@sindominio.net>
* it.po: Updated translation by Marco Colombo.
2002-01-26 Jordi Mallach <jordi@sindominio.net>
* fr.po: Updated translation by Jean-Philippe Guérard.
* nn.po: Updated translation by Kjetil Torgrim Homme.
* de.po: Updated translation by Michael Piefel.
2002-01-25 Jordi Mallach <jordi@sindominio.net>
* sv.po: Updated translation by Christian Rose.
* fr.po: Updated translation by Jean-Philippe Guérard.
2002-01-25 Jordi Mallach <jordi@sindominio.net>
* ca.po: Updated.
* es.po: Updated.
2002-01-23 Jordi Mallach <jordi@sindominio.net>
* ca.po: Updated.
* es.po: Updated.
2002-01-19 gettextize <bug-gnu-utils@gnu.org>
* Makefile.in.in: Upgrade to gettext-0.10.40.
* cat-id-tbl.c: Remove file.
* stamp-cat-id: Remove file.
2002-01-19 Jordi Mallach <jordi@sindominio.net>
* ca.po: Updated.
* es.po: Updated.
2002-01-19 Jordi Mallach <jordi@sindominio.net>
* da.po: Updated translation by Keld Simonsen.
2002-01-17 Jordi Mallach <jordi@sindominio.net>
* no.po: Removed, replaced by nn.po.
* nn.po: Updated translation by Kjetil Torgrim Homme.
* nb.po: New Norwegian bokmål translation by Stig E Sandoe.
2002-01-12 Jordi Mallach <jordi@sindominio.net>
* fr.po: Updated translation by Jean-Philippe Guérard.
2002-01-10 Jordi Mallach <jordi@sindominio.net>
* fr.po: Updated translation by Jean-Philippe Guérard.
2002-01-08 Jordi Mallach <jordi@sindominio.net>
* ru.po, uk.po: Updated translations by Sergey A.
Ribalchenko.
* fr.po: Updated translation by Jean-Philippe Guérard.
2002-01-07 Jordi Mallach <jordi@sindominio.net>
* de.po: Updated translation by Michael Piefel.
2002-01-07 Jordi Mallach <jordi@sindominio.net>
* sv.po: Updated translation by Christian Rose.
2002-01-07 Jordi Mallach <jordi@sindominio.net>
* ca.po: Updated.
* es.po: Updated.
$Id$

View File

@@ -1,11 +1,12 @@
# $Id$
# Makefile for program source directory in GNU NLS utilities package.
# Copyright (C) 1995, 1996, 1997 by Ulrich Drepper <drepper@gnu.ai.mit.edu>
# Makefile for PO directory in any package using GNU gettext.
# Copyright (C) 1995-1997, 2000-2002 by Ulrich Drepper <drepper@gnu.ai.mit.edu>
#
# This file file be copied and used freely without restrictions. It can
# be used in projects which are not available under the GNU Public License
# but which still want to provide support for the GNU gettext functionality.
# Please note that the actual code is *not* freely available.
# This file can be copied and used freely without restrictions. It can
# be used in projects which are not available under the GNU General Public
# License but which still want to provide support for the GNU gettext
# functionality.
# Please note that the actual code of GNU gettext is covered by the GNU
# General Public License and is *not* in the public domain.
PACKAGE = @PACKAGE@
VERSION = @VERSION@
@@ -19,234 +20,298 @@ VPATH = @srcdir@
prefix = @prefix@
exec_prefix = @exec_prefix@
datadir = $(prefix)/@DATADIRNAME@
datadir = @datadir@
localedir = $(datadir)/locale
gnulocaledir = $(prefix)/share/locale
gettextsrcdir = $(prefix)/share/gettext/po
subdir = po
gettextsrcdir = $(datadir)/gettext/po
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
MKINSTALLDIRS = $(top_srcdir)/@MKINSTALLDIRS@
MKINSTALLDIRS = @MKINSTALLDIRS@
mkinstalldirs = $(SHELL) `case "$(MKINSTALLDIRS)" in /*) echo "$(MKINSTALLDIRS)" ;; *) echo "$(top_builddir)/$(MKINSTALLDIRS)" ;; esac`
CC = @CC@
GENCAT = @GENCAT@
GMSGFMT = PATH=../src:$$PATH @GMSGFMT@
GMSGFMT = @GMSGFMT@
MSGFMT = @MSGFMT@
XGETTEXT = PATH=../src:$$PATH @XGETTEXT@
MSGMERGE = PATH=../src:$$PATH msgmerge
XGETTEXT = @XGETTEXT@
MSGMERGE = msgmerge
MSGMERGE_UPDATE = @MSGMERGE@ --update
MSGINIT = msginit
MSGCONV = msgconv
MSGFILTER = msgfilter
DEFS = @DEFS@
CFLAGS = @CFLAGS@
CPPFLAGS = @CPPFLAGS@
INCLUDES = -I.. -I$(top_srcdir)/intl
COMPILE = $(CC) -c $(DEFS) $(INCLUDES) $(CPPFLAGS) $(CFLAGS) $(XCFLAGS)
SOURCES = cat-id-tbl.c
POFILES = @POFILES@
GMOFILES = @GMOFILES@
DISTFILES = ChangeLog Makefile.in.in POTFILES.in $(PACKAGE).pot \
stamp-cat-id $(POFILES) $(GMOFILES) $(SOURCES)
UPDATEPOFILES = @UPDATEPOFILES@
DUMMYPOFILES = @DUMMYPOFILES@
DISTFILES.common = Makefile.in.in Makevars remove-potcdate.sin \
$(DISTFILES.common.extra1) $(DISTFILES.common.extra2) $(DISTFILES.common.extra3)
DISTFILES = $(DISTFILES.common) POTFILES.in $(DOMAIN).pot \
$(POFILES) $(GMOFILES) \
$(DISTFILES.extra1) $(DISTFILES.extra2) $(DISTFILES.extra3)
POTFILES = \
CATALOGS = @CATALOGS@
CATOBJEXT = @CATOBJEXT@
INSTOBJEXT = @INSTOBJEXT@
# Makevars gets inserted here. (Don't remove this line!)
.SUFFIXES:
.SUFFIXES: .c .o .po .pox .gmo .mo .msg .cat
.c.o:
$(COMPILE) $<
.po.pox:
$(MAKE) $(PACKAGE).pot
$(MSGMERGE) $< $(srcdir)/$(PACKAGE).pot -o $*.pox
.SUFFIXES: .po .gmo .mo .sed .sin .nop .po-update
.po.mo:
$(MSGFMT) -o $@ $<
@echo "$(MSGFMT) -c -o $@ $<"; \
$(MSGFMT) -c -o t-$@ $< && mv t-$@ $@
.po.gmo:
file=$(srcdir)/`echo $* | sed 's,.*/,,'`.gmo \
&& rm -f $$file && $(GMSGFMT) -o $$file $<
@lang=`echo $* | sed -e 's,.*/,,'`; \
test "$(srcdir)" = . && cdcmd="" || cdcmd="cd $(srcdir) && "; \
echo "$${cdcmd}rm -f $${lang}.gmo && $(GMSGFMT) -c --statistics -o $${lang}.gmo $${lang}.po"; \
cd $(srcdir) && rm -f $${lang}.gmo && $(GMSGFMT) -c --statistics -o t-$${lang}.gmo $${lang}.po && mv t-$${lang}.gmo $${lang}.gmo
.po.cat:
sed -f ../intl/po2msg.sed < $< > $*.msg \
&& rm -f $@ && $(GENCAT) $@ $*.msg
.sin.sed:
sed -e '/^#/d' $< > t-$@
mv t-$@ $@
all: all-@USE_NLS@
all-yes: cat-id-tbl.c $(CATALOGS)
all-yes: $(CATALOGS)
all-no:
$(srcdir)/$(PACKAGE).pot: $(POTFILES)
$(XGETTEXT) --default-domain=$(PACKAGE) --directory=$(top_srcdir) \
--add-comments --keyword=_ --keyword=N_ \
--files-from=$(srcdir)/POTFILES.in \
&& test ! -f $(PACKAGE).po \
|| ( rm -f $(srcdir)/$(PACKAGE).pot \
&& mv $(PACKAGE).po $(srcdir)/$(PACKAGE).pot )
# Note: Target 'all' must not depend on target '$(DOMAIN).pot-update',
# otherwise packages like GCC can not be built if only parts of the source
# have been downloaded.
$(srcdir)/cat-id-tbl.c: stamp-cat-id; @:
$(srcdir)/stamp-cat-id: $(PACKAGE).pot
rm -f cat-id-tbl.tmp
sed -f ../intl/po2tbl.sed $(srcdir)/$(PACKAGE).pot \
| sed -e "s/@PACKAGE NAME@/$(PACKAGE)/" > cat-id-tbl.tmp
if cmp -s cat-id-tbl.tmp $(srcdir)/cat-id-tbl.c; then \
rm cat-id-tbl.tmp; \
else \
echo cat-id-tbl.c changed; \
rm -f $(srcdir)/cat-id-tbl.c; \
mv cat-id-tbl.tmp $(srcdir)/cat-id-tbl.c; \
fi
cd $(srcdir) && rm -f stamp-cat-id && echo timestamp > stamp-cat-id
$(DOMAIN).pot-update: $(POTFILES) $(srcdir)/POTFILES.in remove-potcdate.sed
$(XGETTEXT) --default-domain=$(DOMAIN) --directory=$(top_srcdir) \
--add-comments=TRANSLATORS: $(XGETTEXT_OPTIONS) \
--files-from=$(srcdir)/POTFILES.in \
--copyright-holder='$(COPYRIGHT_HOLDER)'
test ! -f $(DOMAIN).po || { \
if test -f $(srcdir)/$(DOMAIN).pot; then \
sed -f remove-potcdate.sed < $(srcdir)/$(DOMAIN).pot > $(DOMAIN).1po && \
sed -f remove-potcdate.sed < $(DOMAIN).po > $(DOMAIN).2po && \
if cmp $(DOMAIN).1po $(DOMAIN).2po >/dev/null 2>&1; then \
rm -f $(DOMAIN).1po $(DOMAIN).2po $(DOMAIN).po; \
else \
rm -f $(DOMAIN).1po $(DOMAIN).2po $(srcdir)/$(DOMAIN).pot && \
mv $(DOMAIN).po $(srcdir)/$(DOMAIN).pot; \
fi; \
else \
mv $(DOMAIN).po $(srcdir)/$(DOMAIN).pot; \
fi; \
}
$(srcdir)/$(DOMAIN).pot:
$(MAKE) $(DOMAIN).pot-update
$(POFILES): $(srcdir)/$(DOMAIN).pot
@lang=`echo $@ | sed -e 's,.*/,,' -e 's/\.po$$//'`; \
test "$(srcdir)" = . && cdcmd="" || cdcmd="cd $(srcdir) && "; \
echo "$${cdcmd}$(MSGMERGE_UPDATE) $${lang}.po $(DOMAIN).pot"; \
cd $(srcdir) && $(MSGMERGE_UPDATE) $${lang}.po $(DOMAIN).pot
install: install-exec install-data
install-exec:
install-data: install-data-@USE_NLS@
install-data-no: all
install-data-yes: all
if test -r "$(MKINSTALLDIRS)"; then \
$(MKINSTALLDIRS) $(DESTDIR)$(datadir); \
else \
$(SHELL) $(top_srcdir)/mkinstalldirs $(DESTDIR)$(datadir); \
fi
@catalogs='$(CATALOGS)'; \
for cat in $$catalogs; do \
cat=`basename $$cat`; \
case "$$cat" in \
*.gmo) destdir=$(gnulocaledir);; \
*) destdir=$(localedir);; \
esac; \
lang=`echo $$cat | sed 's/\$(CATOBJEXT)$$//'`; \
dir=$$destdir/$$lang/LC_MESSAGES; \
if test -r "$(MKINSTALLDIRS)"; then \
$(MKINSTALLDIRS) $(DESTDIR)$$dir; \
else \
$(SHELL) $(top_srcdir)/mkinstalldirs $(DESTDIR)$$dir; \
fi; \
if test -r $$cat; then \
$(INSTALL_DATA) $$cat $(DESTDIR)$$dir/$(PACKAGE)$(INSTOBJEXT); \
echo "installing $$cat as" \
"$(DESTDIR)$$dir/$(PACKAGE)$(INSTOBJEXT)"; \
else \
$(INSTALL_DATA) $(srcdir)/$$cat \
$(DESTDIR)$$dir/$(PACKAGE)$(INSTOBJEXT); \
echo "installing $(srcdir)/$$cat as" \
"$(DESTDIR)$$dir/$(PACKAGE)$(INSTOBJEXT)"; \
fi; \
if test -r $$cat.m; then \
$(INSTALL_DATA) $$cat.m $(DESTDIR)$$dir/$(PACKAGE)$(INSTOBJEXT).m; \
echo "installing $$cat.m as" \
"$(DESTDIR)$$dir/$(PACKAGE)$(INSTOBJEXT).m"; \
else \
if test -r $(srcdir)/$$cat.m ; then \
$(INSTALL_DATA) $(srcdir)/$$cat.m \
$(DESTDIR)$$dir/$(PACKAGE)$(INSTOBJEXT).m; \
echo "installing $(srcdir)/$$cat as" \
"$(DESTDIR)$$dir/$(PACKAGE)$(INSTOBJEXT).m"; \
else \
true; \
fi; \
fi; \
done
if test "$(PACKAGE)" = "gettext"; then \
if test -r "$(MKINSTALLDIRS)"; then \
$(MKINSTALLDIRS) $(DESTDIR)$(gettextsrcdir); \
else \
$(SHELL) $(top_srcdir)/mkinstalldirs $(DESTDIR)$(gettextsrcdir); \
fi; \
$(INSTALL_DATA) $(srcdir)/Makefile.in.in \
$(DESTDIR)$(gettextsrcdir)/Makefile.in.in; \
$(mkinstalldirs) $(DESTDIR)$(gettextsrcdir); \
for file in $(DISTFILES.common); do \
$(INSTALL_DATA) $(srcdir)/$$file \
$(DESTDIR)$(gettextsrcdir)/$$file; \
done; \
else \
: ; \
fi
install-data-no: all
install-data-yes: all
$(mkinstalldirs) $(DESTDIR)$(datadir)
@catalogs='$(CATALOGS)'; \
for cat in $$catalogs; do \
cat=`basename $$cat`; \
lang=`echo $$cat | sed -e 's/\.gmo$$//'`; \
dir=$(localedir)/$$lang/LC_MESSAGES; \
$(mkinstalldirs) $(DESTDIR)$$dir; \
if test -r $$cat; then realcat=$$cat; else realcat=$(srcdir)/$$cat; fi; \
$(INSTALL_DATA) $$realcat $(DESTDIR)$$dir/$(DOMAIN).mo; \
echo "installing $$realcat as $(DESTDIR)$$dir/$(DOMAIN).mo"; \
for lc in '' $(EXTRA_LOCALE_CATEGORIES); do \
if test -n "$$lc"; then \
if (cd $(DESTDIR)$(localedir)/$$lang && LC_ALL=C ls -l -d $$lc 2>/dev/null) | grep ' -> ' >/dev/null; then \
link=`cd $(DESTDIR)$(localedir)/$$lang && LC_ALL=C ls -l -d $$lc | sed -e 's/^.* -> //'`; \
mv $(DESTDIR)$(localedir)/$$lang/$$lc $(DESTDIR)$(localedir)/$$lang/$$lc.old; \
mkdir $(DESTDIR)$(localedir)/$$lang/$$lc; \
(cd $(DESTDIR)$(localedir)/$$lang/$$lc.old && \
for file in *; do \
if test -f $$file; then \
ln -s ../$$link/$$file $(DESTDIR)$(localedir)/$$lang/$$lc/$$file; \
fi; \
done); \
rm -f $(DESTDIR)$(localedir)/$$lang/$$lc.old; \
else \
if test -d $(DESTDIR)$(localedir)/$$lang/$$lc; then \
:; \
else \
rm -f $(DESTDIR)$(localedir)/$$lang/$$lc; \
mkdir $(DESTDIR)$(localedir)/$$lang/$$lc; \
fi; \
fi; \
rm -f $(DESTDIR)$(localedir)/$$lang/$$lc/$(DOMAIN).mo; \
ln -s ../LC_MESSAGES/$(DOMAIN).mo $(DESTDIR)$(localedir)/$$lang/$$lc/$(DOMAIN).mo 2>/dev/null || \
ln $(DESTDIR)$(localedir)/$$lang/LC_MESSAGES/$(DOMAIN).mo $(DESTDIR)$(localedir)/$$lang/$$lc/$(DOMAIN).mo 2>/dev/null || \
cp -p $(DESTDIR)$(localedir)/$$lang/LC_MESSAGES/$(DOMAIN).mo $(DESTDIR)$(localedir)/$$lang/$$lc/$(DOMAIN).mo; \
echo "installing $$realcat link as $(DESTDIR)$(localedir)/$$lang/$$lc/$(DOMAIN).mo"; \
fi; \
done; \
done
install-strip: install
installdirs: installdirs-exec installdirs-data
installdirs-exec:
installdirs-data: installdirs-data-@USE_NLS@
if test "$(PACKAGE)" = "gettext"; then \
$(mkinstalldirs) $(DESTDIR)$(gettextsrcdir); \
else \
: ; \
fi
installdirs-data-no:
installdirs-data-yes:
$(mkinstalldirs) $(DESTDIR)$(datadir)
@catalogs='$(CATALOGS)'; \
for cat in $$catalogs; do \
cat=`basename $$cat`; \
lang=`echo $$cat | sed -e 's/\.gmo$$//'`; \
dir=$(localedir)/$$lang/LC_MESSAGES; \
$(mkinstalldirs) $(DESTDIR)$$dir; \
for lc in '' $(EXTRA_LOCALE_CATEGORIES); do \
if test -n "$$lc"; then \
if (cd $(DESTDIR)$(localedir)/$$lang && LC_ALL=C ls -l -d $$lc 2>/dev/null) | grep ' -> ' >/dev/null; then \
link=`cd $(DESTDIR)$(localedir)/$$lang && LC_ALL=C ls -l -d $$lc | sed -e 's/^.* -> //'`; \
mv $(DESTDIR)$(localedir)/$$lang/$$lc $(DESTDIR)$(localedir)/$$lang/$$lc.old; \
mkdir $(DESTDIR)$(localedir)/$$lang/$$lc; \
(cd $(DESTDIR)$(localedir)/$$lang/$$lc.old && \
for file in *; do \
if test -f $$file; then \
ln -s ../$$link/$$file $(DESTDIR)$(localedir)/$$lang/$$lc/$$file; \
fi; \
done); \
rm -f $(DESTDIR)$(localedir)/$$lang/$$lc.old; \
else \
if test -d $(DESTDIR)$(localedir)/$$lang/$$lc; then \
:; \
else \
rm -f $(DESTDIR)$(localedir)/$$lang/$$lc; \
mkdir $(DESTDIR)$(localedir)/$$lang/$$lc; \
fi; \
fi; \
fi; \
done; \
done
# Define this as empty until I found a useful application.
installcheck:
uninstall:
uninstall: uninstall-exec uninstall-data
uninstall-exec:
uninstall-data: uninstall-data-@USE_NLS@
if test "$(PACKAGE)" = "gettext"; then \
for file in $(DISTFILES.common); do \
rm -f $(DESTDIR)$(gettextsrcdir)/$$file; \
done; \
else \
: ; \
fi
uninstall-data-no:
uninstall-data-yes:
catalogs='$(CATALOGS)'; \
for cat in $$catalogs; do \
cat=`basename $$cat`; \
lang=`echo $$cat | sed 's/\$(CATOBJEXT)$$//'`; \
rm -f $(localedir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT); \
rm -f $(localedir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT).m; \
rm -f $(gnulocaledir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT); \
rm -f $(gnulocaledir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT).m; \
lang=`echo $$cat | sed -e 's/\.gmo$$//'`; \
for lc in LC_MESSAGES $(EXTRA_LOCALE_CATEGORIES); do \
rm -f $(DESTDIR)$(localedir)/$$lang/$$lc/$(DOMAIN).mo; \
done; \
done
rm -f $(gettextsrcdir)/po-Makefile.in.in
check: all
cat-id-tbl.o: ../intl/libgettext.h
dvi info tags TAGS ID:
mostlyclean:
rm -f core core.* *.pox $(PACKAGE).po *.old.po cat-id-tbl.tmp
rm -f remove-potcdate.sed
rm -f core core.* $(DOMAIN).po $(DOMAIN).1po $(DOMAIN).2po *.new.po
rm -fr *.o
clean: mostlyclean
distclean: clean
rm -f Makefile Makefile.in POTFILES *.mo *.msg *.cat *.cat.m
rm -f Makefile Makefile.in POTFILES *.mo
maintainer-clean: distclean
@echo "This command is intended for maintainers to use;"
@echo "it deletes files that may require special tools to rebuild."
rm -f $(GMOFILES)
distdir = ../$(PACKAGE)-$(VERSION)/$(subdir)
dist distdir: update-po $(DISTFILES)
distdir = $(top_builddir)/$(PACKAGE)-$(VERSION)/$(subdir)
dist distdir:
$(MAKE) update-po
@$(MAKE) dist2
# This is a separate target because 'update-po' must be executed before.
dist2: $(DISTFILES)
dists="$(DISTFILES)"; \
if test -f $(srcdir)/ChangeLog; then dists="$$dists ChangeLog"; fi; \
if test -f $(srcdir)/LINGUAS; then dists="$$dists LINGUAS"; fi; \
for file in $$dists; do \
ln $(srcdir)/$$file $(distdir) 2> /dev/null \
|| cp -p $(srcdir)/$$file $(distdir); \
if test -f $$file; then \
cp -p $$file $(distdir); \
else \
cp -p $(srcdir)/$$file $(distdir); \
fi; \
done
update-po: Makefile
$(MAKE) $(PACKAGE).pot
PATH=`pwd`/../src:$$PATH; \
$(MAKE) $(DOMAIN).pot-update
$(MAKE) $(UPDATEPOFILES)
$(MAKE) update-gmo
# General rule for updating PO files.
.nop.po-update:
@lang=`echo $@ | sed -e 's/\.po-update$$//'`; \
if test "$(PACKAGE)" = "gettext"; then PATH=`pwd`/../src:$$PATH; fi; \
tmpdir=`pwd`; \
echo "$$lang:"; \
test "$(srcdir)" = . && cdcmd="" || cdcmd="cd $(srcdir) && "; \
echo "$${cdcmd}$(MSGMERGE) $$lang.po $(DOMAIN).pot -o $$lang.new.po"; \
cd $(srcdir); \
catalogs='$(CATALOGS)'; \
for cat in $$catalogs; do \
cat=`basename $$cat`; \
lang=`echo $$cat | sed 's/\$(CATOBJEXT)$$//'`; \
mv $$lang.po $$lang.old.po; \
echo "$$lang:"; \
if $(MSGMERGE) $$lang.old.po $(PACKAGE).pot -o $$lang.po; then \
rm -f $$lang.old.po; \
if $(MSGMERGE) $$lang.po $(DOMAIN).pot -o $$tmpdir/$$lang.new.po; then \
if cmp $$lang.po $$tmpdir/$$lang.new.po >/dev/null 2>&1; then \
rm -f $$tmpdir/$$lang.new.po; \
else \
echo "msgmerge for $$cat failed!"; \
rm -f $$lang.po; \
mv $$lang.old.po $$lang.po; \
if mv -f $$tmpdir/$$lang.new.po $$lang.po; then \
:; \
else \
echo "msgmerge for $$lang.po failed: cannot move $$tmpdir/$$lang.new.po to $$lang.po" 1>&2; \
exit 1; \
fi; \
fi; \
done
else \
echo "msgmerge for $$lang.po failed!" 1>&2; \
rm -f $$tmpdir/$$lang.new.po; \
fi
POTFILES: POTFILES.in
( if test 'x$(srcdir)' != 'x.'; then \
posrcprefix='$(top_srcdir)/'; \
else \
posrcprefix="../"; \
fi; \
rm -f $@-t $@ \
&& (sed -e '/^#/d' -e '/^[ ]*$$/d' \
-e "s@.*@ $$posrcprefix& \\\\@" < $(srcdir)/$@.in \
| sed -e '$$s/\\$$//') > $@-t \
&& chmod a-w $@-t \
&& mv $@-t $@ )
$(DUMMYPOFILES):
Makefile: Makefile.in.in ../config.status POTFILES
cd .. \
update-gmo: Makefile $(GMOFILES)
@:
Makefile: Makefile.in.in $(top_builddir)/config.status POTFILES.in
cd $(top_builddir) \
&& CONFIG_FILES=$(subdir)/$@.in CONFIG_HEADERS= \
$(SHELL) ./config.status
force:
# Tell versions [3.59,3.63) of GNU make not to export all variables.
# Otherwise a system limit (for SysV at least) may be exceeded.
.NOEXPORT:

25
po/Makevars Normal file
View File

@@ -0,0 +1,25 @@
# Makefile variables for PO directory in any package using GNU gettext.
# Usually the message domain is the same as the package name.
DOMAIN = $(PACKAGE)
# These two variables depend on the location of this directory.
subdir = po
top_builddir = ..
# These options get passed to xgettext.
XGETTEXT_OPTIONS = --keyword=_ --keyword=N_
# This is the copyright holder that gets inserted into the header of the
# $(DOMAIN).pot file. Set this to the copyright holder of the surrounding
# package. (Note that the msgstr strings, extracted from the package's
# sources, belong to the copyright holder of the package.) Translators are
# expected to transfer the copyright for their translations to this person
# or entity, or to disclaim their copyright. The empty string stands for
# the public domain; in this case the translators are expected to disclaim
# their copyright.
COPYRIGHT_HOLDER = Free Software Foundation, Inc.
# This is the list of locale categories, beyond LC_MESSAGES, for which the
# message catalogs shall be used. It is usually empty.
EXTRA_LOCALE_CATEGORIES =

View File

@@ -7,7 +7,9 @@ files.c
global.c
move.c
nano.c
rcfile.c
search.c
utils.c
winio.c
# Package header files

42
po/Rules-quot Normal file
View File

@@ -0,0 +1,42 @@
# Special Makefile rules for English message catalogs with quotation marks.
DISTFILES.common.extra1 = quot.sed boldquot.sed en@quot.header en@boldquot.header insert-header.sin Rules-quot
.SUFFIXES: .insert-header .po-update-en
en@quot.po-update: en@quot.po-update-en
en@boldquot.po-update: en@boldquot.po-update-en
.insert-header.po-update-en:
@lang=`echo $@ | sed -e 's/\.po-update-en$$//'`; \
if test "$(PACKAGE)" = "gettext"; then PATH=`pwd`/../src:$$PATH; GETTEXTLIBDIR=`cd $(top_srcdir)/src && pwd`; export GETTEXTLIBDIR; fi; \
tmpdir=`pwd`; \
echo "$$lang:"; \
ll=`echo $$lang | sed -e 's/@.*//'`; \
LC_ALL=C; export LC_ALL; \
cd $(srcdir); \
if $(MSGINIT) -i $(DOMAIN).pot --no-translator -l $$ll -o - 2>/dev/null | sed -f $$tmpdir/$$lang.insert-header | $(MSGCONV) -t UTF-8 | $(MSGFILTER) sed -f `echo $$lang | sed -e 's/.*@//'`.sed 2>/dev/null > $$tmpdir/$$lang.new.po; then \
if cmp $$lang.po $$tmpdir/$$lang.new.po >/dev/null 2>&1; then \
rm -f $$tmpdir/$$lang.new.po; \
else \
if mv -f $$tmpdir/$$lang.new.po $$lang.po; then \
:; \
else \
echo "creation of $$lang.po failed: cannot move $$tmpdir/$$lang.new.po to $$lang.po" 1>&2; \
exit 1; \
fi; \
fi; \
else \
echo "creation of $$lang.po failed!" 1>&2; \
rm -f $$tmpdir/$$lang.new.po; \
fi
en@quot.insert-header: insert-header.sin
sed -e '/^#/d' -e 's/HEADER/en@quot.header/g' $(srcdir)/insert-header.sin > en@quot.insert-header
en@boldquot.insert-header: insert-header.sin
sed -e '/^#/d' -e 's/HEADER/en@boldquot.header/g' $(srcdir)/insert-header.sin > en@boldquot.insert-header
mostlyclean: mostlyclean-quot
mostlyclean-quot:
rm -f *.insert-header

10
po/boldquot.sed Normal file
View File

@@ -0,0 +1,10 @@
s/"\([^"]*\)"/“\1”/g
s/`\([^`']*\)'/\1/g
s/ '\([^`']*\)' / \1 /g
s/ '\([^`']*\)'$/ \1/g
s/^'\([^`']*\)' /\1 /g
s/“”/""/g
s///g
s//”/g
s///g
s///g

1783
po/ca.po

File diff suppressed because it is too large Load Diff

1802
po/cs.po

File diff suppressed because it is too large Load Diff

1907
po/da.po Normal file

File diff suppressed because it is too large Load Diff

1952
po/de.po

File diff suppressed because it is too large Load Diff

25
po/en@boldquot.header Normal file
View File

@@ -0,0 +1,25 @@
# All this catalog "translates" are quotation characters.
# The msgids must be ASCII and therefore cannot contain real quotation
# characters, only substitutes like grave accent (0x60), apostrophe (0x27)
# and double quote (0x22). These substitutes look strange; see
# http://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html
#
# This catalog translates grave accent (0x60) and apostrophe (0x27) to
# left single quotation mark (U+2018) and right single quotation mark (U+2019).
# It also translates pairs of apostrophe (0x27) to
# left single quotation mark (U+2018) and right single quotation mark (U+2019)
# and pairs of quotation mark (0x22) to
# left double quotation mark (U+201C) and right double quotation mark (U+201D).
#
# When output to an UTF-8 terminal, the quotation characters appear perfectly.
# When output to an ISO-8859-1 terminal, the single quotation marks are
# transliterated to apostrophes (by iconv in glibc 2.2 or newer) or to
# grave/acute accent (by libiconv), and the double quotation marks are
# transliterated to 0x22.
# When output to an ASCII terminal, the single quotation marks are
# transliterated to apostrophes, and the double quotation marks are
# transliterated to 0x22.
#
# This catalog furthermore displays the text between the quotation marks in
# bold face, assuming the VT100/XTerm escape sequences.
#

22
po/en@quot.header Normal file
View File

@@ -0,0 +1,22 @@
# All this catalog "translates" are quotation characters.
# The msgids must be ASCII and therefore cannot contain real quotation
# characters, only substitutes like grave accent (0x60), apostrophe (0x27)
# and double quote (0x22). These substitutes look strange; see
# http://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html
#
# This catalog translates grave accent (0x60) and apostrophe (0x27) to
# left single quotation mark (U+2018) and right single quotation mark (U+2019).
# It also translates pairs of apostrophe (0x27) to
# left single quotation mark (U+2018) and right single quotation mark (U+2019)
# and pairs of quotation mark (0x22) to
# left double quotation mark (U+201C) and right double quotation mark (U+201D).
#
# When output to an UTF-8 terminal, the quotation characters appear perfectly.
# When output to an ISO-8859-1 terminal, the single quotation marks are
# transliterated to apostrophes (by iconv in glibc 2.2 or newer) or to
# grave/acute accent (by libiconv), and the double quotation marks are
# transliterated to 0x22.
# When output to an ASCII terminal, the single quotation marks are
# transliterated to apostrophes, and the double quotation marks are
# transliterated to 0x22.
#

1816
po/es.po

File diff suppressed because it is too large Load Diff

1775
po/fi.po

File diff suppressed because it is too large Load Diff

2079
po/fr.po

File diff suppressed because it is too large Load Diff

1908
po/gl.po Normal file

File diff suppressed because it is too large Load Diff

2025
po/hu.po

File diff suppressed because it is too large Load Diff

1805
po/id.po

File diff suppressed because it is too large Load Diff

23
po/insert-header.sin Normal file
View File

@@ -0,0 +1,23 @@
# Sed script that inserts the file called HEADER before the header entry.
#
# At each occurrence of a line starting with "msgid ", we execute the following
# commands. At the first occurrence, insert the file. At the following
# occurrences, do nothing. The distinction between the first and the following
# occurrences is achieved by looking at the hold space.
/^msgid /{
x
# Test if the hold space is empty.
s/m/m/
ta
# Yes it was empty. First occurrence. Read the file.
r HEADER
# Output the file's contents by reading the next line. But don't lose the
# current line while doing this.
g
N
bb
:a
# The hold space was nonempty. Following occurrences. Do nothing.
x
:b
}

Some files were not shown because too many files have changed in this diff Show More