]>
Commit | Line | Data |
---|---|---|
3768a1ae JMG |
1 | # Additional editing of Makefiles |
2 | /(echo[ ]*':t/ a\ | |
3 | # DJGPP specific Makefile changes.\ | |
4 | /^aliaspath * *=/s,:,";",g;t t\ | |
5 | /TEXINPUTS=/s,:,";",g;t t\ | |
6 | /PATH=/s,:,";",g;t t\ | |
7 | s,\\.deps,_deps,g;t t\ | |
8 | s,\\.new\\.,_new.,g;t t\ | |
9 | s,\\.old\\.,_old.,g;t t\ | |
10 | s,c++\\.at,cxx.at,g;t t\ | |
11 | s,c++\\.m4,cxx.m4,g;t t\ | |
12 | s,calc++,calcxx,g;t t\ | |
13 | s,Makefile\\.in\\.in,Makefile.in-in,g;t t\ | |
14 | s,Makefile\\.am\\.in,Makefile.am-in,g;t t\ | |
15 | s,(MAKEINFOFLAGS),& --no-split,\ | |
16 | /^install-info-am:/,/^$/ {\ | |
17 | /@list=/ s,\\\$(INFO_DEPS),& bison.i,\ | |
18 | /@for *file/ s,\\\$(INFO_DEPS),& bison.i,\ | |
19 | s,file-\\[0-9\\]\\[0-9\\],& \\$\\$file[0-9] \\$\\$file[0-9][0-9],\ | |
20 | }\ | |
21 | /^\\.y\\.c:/,/^$/ {\ | |
22 | /\\\$(YACCCOMPILE)/ {\ | |
23 | a\\\ | |
24 | -@test -f y.tab.c && mv -f y.tab.c y_tab.c\\\ | |
25 | -@test -f y.tab.h && mv -f y.tab.h y_tab.h\ | |
26 | }\ | |
27 | }\ | |
28 | /^libbison.a:/ i\\\ | |
29 | \\$(top_srcdir)/djgpp/subpipe.c: \\$(top_srcdir)/djgpp/subpipe.h\\\ | |
30 | subpipe.o: \\$(top_srcdir)/djgpp/subpipe.c \\$(top_srcdir)/djgpp/subpipe.h\\\ | |
31 | \\$(COMPILE) -c \\$<\ | |
32 | /^yacc:/ i\\\ | |
33 | yacc.bat:\\\ | |
34 | echo "bison\\$(EXEEXT) -y %1 %2 %3 %4 %5 %6 %7 %8 %9" >\\$@\ | |
35 | /^bin_SCRIPTS =/s/$/ yacc.bat/\ | |
36 | /^MOSTLYCLEANFILES = yacc/s/$/ yacc.bat/ | |
37 | ||
38 | ||
39 | # Makefile.in.in is renamed to Makefile.in-in. | |
40 | /ac_config_files=/,/_ACEOF/ { | |
41 | s|po/Makefile\.in|&:po/Makefile.in-in| | |
42 | } | |
43 | /CONFIG_FILES=/ s|po/Makefile\.in|&:po/Makefile.in-in|2 | |
44 | ||
45 | # We always use _deps and _libs instead of .deps and .libs, because | |
46 | # the latter is an invalid name on 8+3 MS-DOS filesystem. This makes | |
47 | # the generated Makefiles good for every DJGPP installation, not only | |
48 | # the one where the package was configured (which could happen to be | |
49 | # a Windows box, where leading dots in file names are allowed). | |
50 | s,\.deps,_deps,g | |
51 | s,\.libs,_libs,g | |
52 | /^rmdir[ ]*\.tst/ i\ | |
53 | am__leading_dot=_ | |
54 | ||
55 | # Replace (command) > /dev/null with `command > /dev/null`, since | |
56 | # parenthesized commands always return zero status in the ported Bash, | |
57 | # even if the named command doesn't exist | |
58 | /if ([^|;`]*null/{ | |
59 | s,(,`, | |
60 | s,),, | |
61 | /null[ ]*2>&1/ s,2>&1,&`, | |
62 | /null.*null/ s,null.*null,&`, | |
63 | /null.*null/ !{ | |
64 | /null[ ]*2>&1/ !s,null,&`, | |
65 | } | |
66 | } | |
67 | ||
68 | # DOS-style absolute file names should be supported as well | |
69 | /\*) top_srcdir=/s,/\*,[\\\\/]* | ?:[\\\\/]*, | |
70 | ||
71 | # Prevent the spliting of subs.sed. | |
72 | # The sed script: subs.sed is split into 48 lines long files. | |
73 | # This will produce sed scripts called subs-$ac_sed_frag.sed, where | |
74 | # $ac_sed_frag is some unique number. This will not work if the splited | |
75 | # sed script contains a multiple line sed command at line #48. In this | |
76 | # case the first part of the multiple line sed command will be written | |
77 | # at the end of one particular subs-$ac_sed_frag.sed and the rest of the | |
78 | # sed command will be written at the begining of the next subs-$ac_sed_frag.sed | |
79 | # making both sed script useless. | |
80 | # This matches the configure script produced by Autoconf 2.57 | |
81 | /ac_max_sed_lines=[0-9]/ s,=.*$,=`sed -n "$=" $tmp/subs.sed`, | |
82 | ||
83 | # The following two items are changes needed for configuring | |
84 | # and compiling across partitions. | |
85 | # 1) The given srcdir value is always translated from the | |
86 | # "x:" syntax into "/dev/x" syntax while we run configure. | |
87 | /^[ ]*-srcdir=\*.*$/ a\ | |
88 | ac_optarg=`echo "$ac_optarg" | sed "s,^\\([A-Za-z]\\):,/dev/\\1,"` | |
89 | /set X `ls -Lt \$srcdir/ i\ | |
90 | if `echo $srcdir | grep "^/dev/" - > /dev/null`; then\ | |
91 | srcdir=`echo "$srcdir" | sed -e "s%^/dev/%%" -e "s%/%:/%"`\ | |
92 | fi | |
93 | ||
94 | # Autoconf 2.52e generated configure scripts | |
95 | # write absolute paths into Makefiles and bison.in | |
96 | # making them useless for DJGPP installations for | |
97 | # which the package has not been configured for. | |
98 | /MISSING=/,/^$/ { | |
99 | /^fi$/ a\ | |
100 | am_missing_run=`echo "$am_missing_run" | sed 's%/dev.*/bison-[0-9]\\{1,1\\}[-.0-9A-z]*%${top_srcdir}%;s%.:.*/bison-[0-9]\\{1,1\\}[-.0-9A-z]*%${top_srcdir}%'` | |
101 | } | |
102 | /^install_sh=/a\ | |
103 | install_sh=`echo "$install_sh" | sed 's%/dev.*/bison-[0-9]\\{1,1\\}[-.0-9A-z]*%${top_srcdir}%;s%.:.*/bison-[0-9]\\{1,1\\}[-.0-9A-z]*%${top_srcdir}%'` | |
104 | ||
105 | # This will only work if the assumption that the | |
106 | # testsuite is ran from the following path: | |
107 | # ${top_srcdir}/tests/testsuite.dir | |
108 | # holds. The explicit names are of no importance. | |
109 | # ../../. == ${top_srcdir} | |
110 | /\.)[ ]*ac_abs_builddir=/,/^esac$/ { | |
111 | /^esac$/ a\ | |
112 | ac_abs_builddir=`echo "$ac_abs_builddir" | sed "s%/dev.*/bison-[0-9]\\{1,1\\}[-.0-9A-z]*/[^/]*%../../.%;s%.:.*/bison-[0-9]\\{1,1\\}[-.0-9A-z]*/[^/]*%../../.%"` | |
113 | } | |
114 | /\.)[ ]*ac_abs_top_builddir=/,/^esac$/ { | |
115 | /^esac$/ a\ | |
116 | ac_abs_top_builddir=`echo "$ac_abs_top_builddir" | sed "s%/dev.*/bison-[0-9]\\{1,1\\}[-.0-9A-z]*/[^/]*%../../../%;s%.:.*/bison-[0-9]\\{1,1\\}[-.0-9A-z]*/[^/]*%../../../%"` | |
117 | } | |
118 | /\.)[ ]*ac_abs_srcdir=/,/^esac$/ { | |
119 | /^esac$/ a\ | |
120 | ac_abs_srcdir=`echo "$ac_abs_srcdir" | sed "s%/dev.*/bison-[0-9]\\{1,1\\}[-.0-9A-z]*/[^/]*%../../.%;s%.:.*/bison-[0-9]\\{1,1\\}[-.0-9A-z]*/[^/]*%../../.%"` | |
121 | } | |
122 | /\.)[ ]*ac_abs_top_srcdir=/,/^esac$/ { | |
123 | /^esac$/ a\ | |
124 | ac_abs_top_srcdir=`echo "$ac_abs_top_srcdir" | sed "s%/dev.*/bison-[0-9]\\{1,1\\}[-.0-9A-z]*/[^/]*%../../../%;s%.:.*/bison-[0-9]\\{1,1\\}[-.0-9A-z]*/[^/]*%../../../%"` | |
125 | } | |
126 | ||
127 | # Add DJGPP version information. | |
128 | /^#define VERSION/ s/\$VERSION/& (DJGPP port (r1))/ | |
129 | ||
130 | # We need makeinfo to make the html formated docs. | |
131 | /\$am_missing_run[ ]*makeinfo/ s,\$am_missing_run,, | |
132 | ||
133 | # The path to the FORTRAN compiler and libraries | |
134 | # shall contain no absolute path reference so it | |
135 | # will be good for all djgpp installations. | |
136 | /^FLIBS="\$ac_cv_flibs"/ i\ | |
137 | ac_djgpp_path=`echo "$DJDIR" | sed 's%\\\\\\%/%g' | tr $as_cr_LETTERS $as_cr_letters`\ | |
138 | ac_cv_flibs=`echo "$ac_cv_flibs" | sed "s%-L$ac_djgpp_path%-L/dev/env/DJDIR%g"` | |
139 | ||
140 | # The following is not a valid DOS file name | |
141 | s/calc++/calcxx/g |