1# Additional editing of Makefiles
2/@GMSGFMT@/ s,\$GMSGFMT,msgfmt,
3/@MSGFMT@/ s,\$MSGFMT,msgfmt,
4/@XGETTEXT@/ s,\$XGETTEXT,xgettext,
5/ac_given_INSTALL=/,/^CEOF/ {
6  /^CEOF$/ i\
7# DJGPP specific Makefile changes.\
8  /^aliaspath[ 	]*=/s,:,";",g\
9  /^lispdir[ 	]*=/ c\\\\\
10lispdir = \\$(prefix)/gnu/emacs/site-lisp\
11  /TEXINPUTS[ 	]*=/s,:,";",g\
12  /PATH[ 	]*=/s,:,";",g\
13  s,\\.new\\.,_new.,g\
14  s,\\.old\\.,_old.,g\
15  s,\\.tab\\.c,_tab.c,g\
16  s,\\.tab\\.h,_tab.h,g\
17  s,\\([1-9]\\)\\.html\\.in,\\1hi,g\
18  s,\\([1-9]\\)\\.html,\\1-html,g\
19  s,\\([1-9]\\)\\.in,\\1-in,g\
20  s,\\.sh\\.in,.sh-in,g\
21  s,config\\.h\\.in,config.h-in
22,g\
23  s,COPYING.LIB-2.0,COPYING_LIB.20
24,g\
25  s,COPYING.LIB-2.1,COPYING_LIB.21
26,g\
27  s,gettext_1.html,gettext.1-html
28,g\
29  s,gettext_10.html,gettext.10-html
30,g\
31  s,gettext_11.html,gettext.11-html
32,g\
33  s,gettext_12.html,gettext.12-html
34,g\
35  s,gettext_13.html,gettext.13-html
36,g\
37  s,gettext_14.html,gettext.14-html
38,g\
39  s,gettext_15.html,gettext.15-html
40,g\
41  s,gettext_16.html,gettext.16-html
42,g\
43  s,gettext_2.html,gettext.2-html
44,g\
45  s,gettext_3.html,gettext.3-html
46,g\
47  s,gettext_4.html,gettext.4-html
48,g\
49  s,gettext_5.html,gettext.5-html
50,g\
51  s,gettext_6.html,gettext.6-html
52,g\
53  s,gettext_7.html,gettext.7-html
54,g\
55  s,gettext_8.html,gettext.8-html
56,g\
57  s,gettext_9.html,gettext.9-html
58,g\
59  s,gettext_foot.html,gettext.foot-html
60,g\
61  s,gettext_toc.html,gettext.toc-html
62,g\
63  s,javacomp\\.sh\\.in,javacomp.sh-in
64,g\
65  s,javaexec\\.sh\\.in,javaexec.sh-in
66,g\
67  s,stdbool\\.h\\.in,stdbool.h-in
68,g\
69  s,gettext.1.in,gettext.1-in
70,g\
71  s,ngettext.1.in,ngettext.1-in
72,g\
73  s,gettext.3.in,gettext.3-in
74,g\
75  s,ngettext.3.in,ngettext.3-in
76,g\
77  s,textdomain.3.in,textdomain.3-in
78,g\
79  s,bindtextdomain.3.in,bindtextdomain.3-in
80,g\
81  s,bind_textdomain_codeset.3.in,bind_textdomain_codeset.3-in
82,g\
83  s,gettext.1.html.in,gettext.1hin
84,g\
85  s,ngettext.1.html.in,ngettext.1hin
86,g\
87  s,msgcmp.1.html,msgcmp.1-html
88,g\
89  s,msgfmt.1.html,msgfmt.1-html
90,g\
91  s,msgmerge.1.html,msgmerge.1-html
92,g\
93  s,msgunfmt.1.html,msgunfmt.1-html
94,g\
95  s,xgettext.1.html,xgettext.1-html
96,g\
97  s,msgattrib.1.html,msgattrib.1-html
98,g\
99  s,msgcat.1.html,msgcat.1-html
100,g\
101  s,msgcomm.1.html,msgcomm.1-html
102,g\
103  s,msgconv.1.html,msgconv.1-html
104,g\
105  s,msgen.1.html,msgen.1-html
106,g\
107  s,msgexec.1.html,msgexec.1-html
108,g\
109  s,msgfilter.1.html,msgfilter.1-html
110,g\
111  s,msggrep.1.html,msggrep.1-html
112,g\
113  s,msginit.1.html,msginit.1-html
114,g\
115  s,msguniq.1.html,msguniq.1-html
116,g\
117  s,gettext.3.html,gettext.3-html
118,g\
119  s,ngettext.3.html,ngettext.3-html
120,g\
121  s,textdomain.3.html,textdomain.3-html
122,g\
123  s,bindtextdomain.3.html,bindtextdomain.3-html
124,g\
125  s,bind_textdomain_codeset.3.html,bind_textdomain_codeset.3-html
126,g\
127  s,Makefile\\.in\\.in,Makefile.in-in
128,g\
129  s,format-librep.c,format_librep.c
130,g\
131  s,format-pascal.c,format_pascal.c
132,g\
133  s,blue-ball.gif,b-ball.gif
134,g\
135  s,cyan-ball.gif,c-ball.gif
136,g\
137  s,green-ball.gif,g-ball.gif
138,g\
139  s,magenta-ball.gif,m-ball.gif
140,g\
141  s,red-ball.gif,r-ball.gif
142,g\
143  s,yellow-ball.gif,y-ball.gif
144,g\
145  s,constructors.gif,ctors.gif
146,g\
147  s,variables.gif,vars.gif
148,g\
149  s,package-frame.html,package_frame.html
150,g\
151  s,package-tree.html,package_tree.html
152,g\
153  s,gettext-1,gettext.1
154,g\
155  s,gettext-2,gettext.2
156,g\
157  s,msgattrib-1,msgattrib.1
158,g\
159  s,msgattrib-2,msgattrib.2
160,g\
161  s,msgattrib-3,msgattrib.3
162,g\
163  s,msgattrib-4,msgattrib.4
164,g\
165  s,msgattrib-5,msgattrib.5
166,g\
167  s,msgattrib-6,msgattrib.6
168,g\
169  s,msgattrib-7,msgattrib.7
170,g\
171  s,msgattrib-8,msgattrib.8
172,g\
173  s,msgattrib-9,msgattrib.9
174,g\
175  s,msgattrib-10,msgattrib.10
176,g\
177  s,msgattrib-11,msgattrib.11
178,g\
179  s,msgattrib-12,msgattrib.12
180,g\
181  s,msgattrib-13,msgattrib.13
182,g\
183  s,msgattrib-14,msgattrib.14
184,g\
185  s,msgcat-1,msgcat.1
186,g\
187  s,msgcat-2,msgcat.2
188,g\
189  s,msgcat-3,msgcat.3
190,g\
191  s,msgcat-4,msgcat.4
192,g\
193  s,msgcat-5,msgcat.5
194,g\
195  s,msgcat-6,msgcat.6
196,g\
197  s,msgcat-7,msgcat.7
198,g\
199  s,msgcmp-1,msgcmp.1
200,g\
201  s,msgcmp-2,msgcmp.2
202,g\
203  s,msgcomm-1,msgcomm.1
204,g\
205  s,msgcomm-2,msgcomm.2
206,g\
207  s,msgcomm-3,msgcomm.3
208,g\
209  s,msgcomm-4,msgcomm.4
210,g\
211  s,msgcomm-5,msgcomm.5
212,g\
213  s,msgcomm-6,msgcomm.6
214,g\
215  s,msgcomm-7,msgcomm.7
216,g\
217  s,msgcomm-8,msgcomm.8
218,g\
219  s,msgcomm-9,msgcomm.9
220,g\
221  s,msgcomm-10,msgcomm.10
222,g\
223  s,msgcomm-11,msgcomm.11
224,g\
225  s,msgcomm-12,msgcomm.12
226,g\
227  s,msgcomm-13,msgcomm.13
228,g\
229  s,msgcomm-14,msgcomm.14
230,g\
231  s,msgcomm-15,msgcomm.15
232,g\
233  s,msgcomm-16,msgcomm.16
234,g\
235  s,msgcomm-17,msgcomm.17
236,g\
237  s,msgcomm-18,msgcomm.18
238,g\
239  s,msgcomm-19,msgcomm.19
240,g\
241  s,msgcomm-20,msgcomm.20
242,g\
243  s,msgcomm-21,msgcomm.21
244,g\
245  s,msgcomm-22,msgcomm.22
246,g\
247  s,msgcomm-23,msgcomm.23
248,g\
249  s,msgconv-1,msgconv.1
250,g\
251  s,msgconv-2,msgconv.2
252,g\
253  s,msgconv-3,msgconv.3
254,g\
255  s,msgen-1,msgen.1
256,g\
257  s,msgexec-1,msgexec.1
258,g\
259  s,msgexec-2,msgexec.2
260,g\
261  s,msgfilter-1,msgfilter.1
262,g\
263  s,msgfilter-2,msgfilter.2
264,g\
265  s,msgfmt-1,msgfmt.1
266,g\
267  s,msgfmt-2,msgfmt.2
268,g\
269  s,msgfmt-3,msgfmt.3
270,g\
271  s,msgfmt-4,msgfmt.4
272,g\
273  s,msgfmt-5,msgfmt.5
274,g\
275  s,msgfmt-6,msgfmt.6
276,g\
277  s,msgfmt-7,msgfmt.7
278,g\
279  s,msgfmt-8,msgfmt.8
280,g\
281  s,msgfmt-9,msgfmt.9
282,g\
283  s,msgfmt-10,msgfmt.10
284,g\
285  s,msggrep-1,msggrep.1
286,g\
287  s,msggrep-2,msggrep.2
288,g\
289  s,msggrep-3,msggrep.3
290,g\
291  s,msggrep-4,msggrep.4
292,g\
293  s,msgmerge-1,msgmerge.1
294,g\
295  s,msgmerge-2,msgmerge.2
296,g\
297  s,msgmerge-3,msgmerge.3
298,g\
299  s,msgmerge-4,msgmerge.4
300,g\
301  s,msgmerge-5,msgmerge.5
302,g\
303  s,msgmerge-6,msgmerge.6
304,g\
305  s,msgmerge-7,msgmerge.7
306,g\
307  s,msgmerge-8,msgmerge.8
308,g\
309  s,msgmerge-9,msgmerge.9
310,g\
311  s,msgmerge-10,msgmerge.10
312,g\
313  s,msgmerge-11,msgmerge.11
314,g\
315  s,msgmerge-12,msgmerge.12
316,g\
317  s,msgmerge-13,msgmerge.13
318,g\
319  s,msgmerge-14,msgmerge.14
320,g\
321  s,msgmerge-15,msgmerge.15
322,g\
323  s,msgmerge-16,msgmerge.16
324,g\
325  s,msgmerge-17,msgmerge.17
326,g\
327  s,msgmerge-18,msgmerge.18
328,g\
329  s,msgmerge-19,msgmerge.19
330,g\
331  s,msgmerge-20,msgmerge.20
332,g\
333  s,msgunfmt-1,msgunfmt.1
334,g\
335  s,msguniq-1,msguniq.1
336,g\
337  s,msguniq-2,msguniq.2
338,g\
339  s,msguniq-3,msguniq.3
340,g\
341  s,xgettext-1,xgettext.1
342,g\
343  s,xgettext-2,xgettext.2
344,g\
345  s,xgettext-3,xgettext.3
346,g\
347  s,xgettext-4,xgettext.4
348,g\
349  s,xgettext-5,xgettext.5
350,g\
351  s,xgettext-6,xgettext.6
352,g\
353  s,xgettext-7,xgettext.7
354,g\
355  s,xgettext-8,xgettext.8
356,g\
357  s,xgettext-9,xgettext.9
358,g\
359  s,xgettext-10,xgettext.10
360,g\
361  s,xgettext-11,xgettext.11
362,g\
363  s,xgettext-12,xgettext.12
364,g\
365  s,xgettext-13,xgettext.13
366,g\
367  s,xgettext-14,xgettext.14
368,g\
369  s,xgettext-15,xgettext.15
370,g\
371  s,xgettext-16,xgettext.16
372,g\
373  s,xgettext-17,xgettext.17
374,g\
375  s,format-c-1,format/c.1
376,g\
377  s,format-c-2,format/c.2
378,g\
379  s,format-elisp-1,format/elisp.1
380,g\
381  s,format-elisp-2,format/elisp.2
382,g\
383  s,format-java-1,format/java.1
384,g\
385  s,format-java-2,format/java.2
386,g\
387  s,format-librep-1,format/librep.1
388,g\
389  s,format-librep-2,format/librep.2
390,g\
391  s,format-lisp-1,format/lisp.1
392,g\
393  s,format-lisp-2,format/lisp.2
394,g\
395  s,format-python-1,format/python.1
396,g\
397  s,format-python-2,format/python.2
398,g\
399  s,format-pascal-1,format/pascal.1
400,g\
401  s,format-pascal-2,format/pascal.2
402,g\
403  s,format-ycp-1,format/ycp.1
404,g\
405  s,format-ycp-2,format/ycp.2
406,g\
407  s,lang-c++,lang-cxx
408,g\
409  s,rpath-1a,rpath/1a
410,g\
411  s,rpath-1b,rpath/1b
412,g\
413  s,rpath-2aaa,rpath/2aaa
414,g\
415  s,rpath-2aab,rpath/2aab
416,g\
417  s,rpath-2aac,rpath/2aac
418,g\
419  s,rpath-2aad,rpath/2aad
420,g\
421  s,rpath-2aba,rpath/2aba
422,g\
423  s,rpath-2abb,rpath/2abb
424,g\
425  s,rpath-2abc,rpath/2abc
426,g\
427  s,rpath-2abd,rpath/2abd
428,g\
429  s,rpath-2baa,rpath/2baa
430,g\
431  s,rpath-2bab,rpath/2bab
432,g\
433  s,rpath-2bac,rpath/2bac
434,g\
435  s,rpath-2bad,rpath/2bad
436,g\
437  s,rpath-2bba,rpath/2bba
438,g\
439  s,rpath-2bbb,rpath/2bbb
440,g\
441  s,rpath-2bbc,rpath/2bbc
442,g\
443  s,rpath-2bbd,rpath/2bbd
444,g\
445  s,xg-test1.ok.po,xg-test1.ok-po
446,g\
447  s,rpath-1,rpath/1
448,g\
449  s,rpath-2_a,rpath/2_a
450,g\
451  s,rpath-2_b,rpath/2_b
452,g\
453  s,rpath-2.README,rpath/2.README
454,g\
455  s,rpathcfg.sh,rpathcfg.sh
456,g\
457  s,gettext_\\*\\.,gettext.*-,g\
458  s,format-librep,format_librep,g\
459  s,format-pascal,format_pascal,g\
460  /^TESTS[ 	]*=/,/^$/ s,plural-\\([1-9]\\+\\),plural.\\1,g\
461  /^install-info-am:/,/^$/ {\
462    /@list=/ s,\\\$(INFO_DEPS),& gettext.i,\
463    s,file-\\[0-9\\]\\[0-9\\],& \\$\\$file[0-9] \\$\\$file[0-9][0-9],\
464  }\
465  /^iso-639\\.texi[ 	]*:.*$/ {\
466    s,iso-639,\\$(srcdir)/&,g\
467    s,ISO_639,\\$(srcdir)/&,\
468  }\
469  /^iso-3166\\.texi[ 	]*:.*$/ {\
470    s,iso-3166,\\$(srcdir)/&,g\
471    s,ISO_3166,\\$(srcdir)/&,\
472  }\
473  /^# Some rules for yacc handling\\./,$ {\
474    /\\\$(YACC)/ a\\\\\
475	-@test -f y.tab.c && mv -f y.tab.c y_tab.c\\\\\
476	-@test -f y.tab.h && mv -f y.tab.h y_tab.h\
477  }\
478  /^POTFILES:/,/^$/ s,\\\$@-t,t-\\$@,g\
479  s,basename\\.o,,g\
480  s,po-gram-gen2\\.h,po-gram_gen2.h,g\
481  /^Makefile[ 	]*:/,/^$/ {\
482    /CONFIG_FILES=/ s,\\\$(subdir)/\\\$@\\.in,&:\\$(subdir)/\\$@.in-in,\
483  }\
484  /html:/ s,split$,monolithic,g\
485  /^TEXI2HTML[ 	]*=/ s,=[ 	]*,&-,
486}
487
488# javacomp.sh is renamed to javacomp.sh-in,
489# javaexec.sh is renamed to javaexec.sh-in,
490# Makefile.in.in is renamed to Makefile.in-in...
491/^CONFIG_FILES=/,/^EOF/ {
492  s|lib/javacomp\.sh|&:lib/javacomp.sh-in|
493  s|lib/javaexec\.sh|&:lib/javaexec.sh-in|
494  s|po/Makefile\.in|&:po/Makefile.in-in|
495}
496
497# ...and config.h.in into config.h-in
498/^ *CONFIG_HEADERS=/,/^EOF/ {
499  s|config\.h|&:config.h-in|
500}
501
502# The same as above but this time
503# for configure scripts created with Autoconf 2.14a.
504/^config_files="\\\\/,/^$/ {
505  s|po/Makefile\.in|&:po/Makefile.in-in|
506}
507/^config_headers="\\\\/,/^$/ {
508  s|config\.h|&:config.h-in|
509}
510/# Handling of arguments./,/^$/ {
511  s|po/Makefile\.in|&:po/Makefile.in-in|2
512  s|config\.h|&:config.h-in|2
513}
514
515# Replace `(command) > /dev/null` with `command > /dev/null`, since
516# parenthesized commands always return zero status in the ported Bash,
517# even if the named command doesn't exist
518/if [^{].*null/,/ then/ {
519  /test .*null/ {
520    s,(,,
521    s,),,
522  }
523}
524
525# DOS-style absolute file names should be supported as well
526/\*) srcdir=/s,/\*,[\\\\/]* | [A-z]:[\\\\/]*,
527/\$]\*) INSTALL=/s,\[/\$\]\*,[\\\\/$]* | [A-z]:[\\\\/]*,
528/\$]\*) ac_rel_source=/s,\[/\$\]\*,[\\\\/$]* | [A-z]:[\\\\/]*,
529
530# Switch the order of the two Sed commands, since DOS path names
531# could include a colon
532/ac_file_inputs=/s,\( -e "s%\^%\$ac_given_srcdir/%"\)\( -e "s%:% $ac_given_srcdir/%g"\),\2\1,
533
534# Prevent the spliting of conftest.subs.
535# The sed script: conftest.subs is split into 48 or 90 lines long files.
536# This will produce sed scripts called conftest.s1, conftest.s2, etc.
537# that will not work if conftest.subs contains a multi line sed command
538# at line #90. In this case the first part of the sed command will be the
539# last line of conftest.s1 and the rest of the command will be the first lines
540# of conftest.s2. So both script will not work properly.
541# This matches the configure script produced by Autoconf 2.12
542/ac_max_sed_cmds=[0-9]/ s,=.*$,=`sed -n "$=" conftest.subs`,
543# This matches the configure script produced by Autoconf 2.14a
544/ac_max_sed_lines=[0-9]/ s,=.*$,=`sed -n "$=" $ac_cs_root.subs `,
545
546# The following two items are changes needed for configuring
547# and compiling across partitions.
548# 1) The given srcdir value is always translated from the
549#    "x:" syntax into "/dev/x" syntax while we run configure.
550/^[ 	]*-srcdir=\*.*$/ a\
551    ac_optarg=`echo "$ac_optarg" | sed "s,^\\([A-Za-z]\\):,/dev/\\1,"`
552/set X `ls -Lt \$srcdir/ i\
553   if `echo $srcdir | grep "^/dev/" - > /dev/null`; then\
554     srcdir=`echo "$srcdir" | sed -e "s%^/dev/%%" -e "s%/%:/%"`\
555   fi
556
557#  2) We need links across partitions, so we will use "cp -pf" instead of "ln".
558/# Make a symlink if possible; otherwise try a hard link./,/EOF/ {
559  s,;.*then, 2>/dev/null || cp -pf \$srcdir/\$ac_source \$ac_dest&,
560}
561
562# Let libtool use _libs all the time.
563/objdir=/s,\.libs,_libs,
564
565# Stock djdev203 does not provide an unsetenv() function,
566# so we will use djdev204 CVS tree's one.
567/^LTLIBOBJS=/ s,|, unsetenv.c |,
568
569# Stock djdev203 does not provide pw_gecos,
570# so we will use djdev204 CVS tree's one.
571/^LTLIBOBJS=/ s,|, getpwnam.c |,
572