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