1 # -sed1v2.inp-----------------------------------------------------------
2 # Configuration script for src/Makefile under DJGPP v2.x
3 # ----------------------------------------------------------------------
5 # Copyright (C) 1996-1997, 1999-2012 Free Software Foundation, Inc.
7 # This file is part of GNU Emacs.
9 # This file is free software; as a special exception, the author gives
10 # unlimited permission to copy and/or distribute it, with or without
11 # modifications, as long as this notice is preserved.
13 # This program is distributed in the hope that it will be useful,
14 # but WITHOUT ANY WARRANTY; without even the implied warranty of
15 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
17 # ----------------------------------------------------------------------
24 /^srcdir *=/s/@[^@\n]*@/./
25 /^abs_builddir *=/s|@abs_builddir@|../src|
26 /^VPATH *=/s/@[^@\n]*@/./
27 /^CC *=/s/@[^@\n]*@/gcc/
28 /^CPP *=/s/@[^@\n]*@/gcc -e/
29 /^CFLAGS *=/s/@[^@\n]*@/-O2 -gcoff/
30 /^ALL_CFLAGS *=/s/@[^@\n]*@//g
31 /^ALL_CFLAGS *=/s/ -I\.//g
32 /^CPPFLAGS *=/s|@[^@\n]*@|-I../msdos|
33 /^LDFLAGS *=/s/@[^@\n]*@//
34 /^LD_FIRSTFLAG *=/s/@[^@\n]*@//
35 /^LIBS *=/s/@[^@\n]*@//
39 /^LIBOBJS *=/s/@[^@\n]*@//
40 /^C_SWITCH_MACHINE *=/s/@C_SWITCH_MACHINE@//
41 /^C_SWITCH_SYSTEM *=/s/@C_SWITCH_SYSTEM@//
42 /^GNUSTEP_CFLAGS *=/s/@GNUSTEP_CFLAGS@//
43 /^C_SWITCH_X_SITE *=/s/@C_SWITCH_X_SITE@//
44 /^WARN_CFLAGS *=/s/@WARN_CFLAGS@//
45 /^WERROR_CFLAGS *=/s/@WERROR_CFLAGS@//
46 /^PROFILING_CFLAGS *=/s/@PROFILING_CFLAGS@//
47 #/^LD_SWITCH_X_SITE *=/s/@LD_SWITCH_X_SITE@//
48 /^LD_SWITCH_SYSTEM_TEMACS *=/s/@LD_SWITCH_SYSTEM_TEMACS@//
49 /^LD_SWITCH_X_SITE_AUX *=/s/@LD_SWITCH_X_SITE_AUX@//
50 /^LD_SWITCH_X_SITE_AUX_RPATH *=/s/@LD_SWITCH_X_SITE_AUX_RPATH@//
51 /^LD_SWITCH_SYSTEM *=/s/@LD_SWITCH_SYSTEM@//
52 /^TEMACS_LDFLAGS2 *=/s/@TEMACS_LDFLAGS2@/$(LDFLAGS)/
53 /^LIBS_SYSTEM *=/s/@LIBS_SYSTEM@//
54 /^LIB_GCC *=/s/@LIB_GCC@//
55 /^LIB_STANDARD *=/s/@LIB_STANDARD@//
56 /^LIB_MATH *=/s/@LIB_MATH@/-lm/
57 /^LIB_PTHREAD *=/s/@LIB_PTHREAD@//
58 /^LIBTIFF *=/s/@LIBTIFF@//
59 /^LIBJPEG *=/s/@LIBJPEG@//
60 /^LIBPNG *=/s/@LIBPNG@//
61 /^LIBGIF *=/s/@LIBGIF@//
62 /^LIBXPM *=/s/@LIBXPM@//
63 /^XFT_LIBS *=/s/@XFT_LIBS@//
64 /^FONTCONFIG_CFLAGS *=/s/@FONTCONFIG_CFLAGS@//
65 /^FONTCONFIG_LIBS *=/s/@FONTCONFIG_LIBS@//
66 /^FREETYPE_CFLAGS *=/s/@FREETYPE_CFLAGS@//
67 /^FREETYPE_LIBS *=/s/@FREETYPE_LIBS@//
68 /^LIBOTF_CFLAGS *=/s/@LIBOTF_CFLAGS@//
69 /^LIBOTF_LIBS *=/s/@LIBOTF_LIBS@//
70 /^M17N_FLT_CFLAGS *=/s/@M17N_FLT_CFLAGS@//
71 /^M17N_FLT_LIBS *=/s/@M17N_FLT_LIBS@//
72 /^DBUS_CFLAGS *=/s/@DBUS_CFLAGS@//
73 /^DBUS_LIBS *=/s/@DBUS_LIBS@//
74 /^DBUS_OBJ *=/s/@DBUS_OBJ@//
75 /^SETTINGS_CFLAGS *=/s/@SETTINGS_CFLAGS@//
76 /^SETTINGS_LIBS *=/s/@SETTINGS_LIBS@//
77 /^GTK_OBJ *=/s/@GTK_OBJ@//
78 /^LIBS_TERMCAP *=/s/@LIBS_TERMCAP@//
79 /^TERMCAP_OBJ *=/s/@TERMCAP_OBJ@/termcap.o tparam.o/
80 /^LIBXMU *=/s/@LIBXMU@//
81 /^LIBXSM *=/s/@LIBXSM@//
82 /^LIBXTR6 *=/s/@LIBXTR6@//
83 /^LIBXT_OTHER *=/s/@LIBXT_OTHER@//
84 /^OLDXMENU_TARGET *=/s/@OLDXMENU_TARGET@//
85 /^OLDXMENU_DEPS *=/s/@OLDXMENU_DEPS@//
87 /^TOOLKIT_LIBW *=/s/@TOOLKIT_LIBW@//
88 /^LIBSOUND *=/s/@LIBSOUND@//
89 /^CFLAGS_SOUND *=/s/@CFLAGS_SOUND@//
90 /^RSVG_LIBS *=/s/@RSVG_LIBS@//
91 /^RSVG_CFLAGS *=/s/@RSVG_CFLAGS@//
92 /^IMAGEMAGICK_LIBS *=/s/@IMAGEMAGICK_LIBS@//
93 /^IMAGEMAGICK_CFLAGS *=/s/@IMAGEMAGICK_CFLAGS@//
94 /^LIBXML2_LIBS *=/s/@LIBXML2_LIBS@//
95 /^LIBXML2_CFLAGS *=/s/@LIBXML2_CFLAGS@//
96 /^WIDGET_OBJ *=/s/@WIDGET_OBJ@//
97 /^CYGWIN_OBJ *=/s/@CYGWIN_OBJ@//
98 /^MSDOS_OBJ *=/s/= */= dosfns.o msdos.o w16select.o/
99 /^ns_appdir *=/s/@ns_appdir@//
100 /^ns_appbindir *=/s/@ns_appbindir@//
101 /^ns_appsrc *=/s/@ns_appsrc@//
102 /^NS_OBJ *=/s/@NS_OBJ@//
103 /^NS_OBJC_OBJ *=/s/@NS_OBJC_OBJ@//
104 /^GNU_OBJC_CFLAGS*=/s/@GNU_OBJC_CFLAGS@//
105 /^LIBRESOLV *=/s/@LIBRESOLV@//
106 /^LIBSELINUX_LIBS *=/s/@LIBSELINUX_LIBS@//
107 /^LIB_PTHREAD_SIGMASK *=/s/@[^@\n]*@//
108 /^LIB_CLOCK_GETTIME *=/s/@[^@\n]*@//g
109 /^LIB_TIMER_TIME *=/s/@[^@\n]*@//g
110 /^LIBGNUTLS_LIBS *=/s/@[^@\n]*@//
111 /^LIBGNUTLS_CFLAGS *=/s/@[^@\n]*@//
112 /^GETLOADAVG_LIBS *=/s/@[^@\n]*@//
113 /^START_FILES *=/s/@START_FILES@//
114 /^OTHER_FILES *=/s/@OTHER_FILES@//
115 /^XMENU_OBJ *=/s/@XMENU_OBJ@/xmenu.o/
116 /^FONT_OBJ *=/s/@FONT_OBJ@//
117 /^LIBGPM *=/s/@LIBGPM@//
118 /^EXEEXT *=/s/@EXEEXT@/.exe/
119 /^OLDXMENU *=/s/@OLDXMENU@/nothing/
120 /^LIBXMENU *=/s/@LIBXMENU@//
121 /^LIBX_OTHER *=/s/@LIBX_OTHER@//
122 /^GMALLOC_OBJ *=/s/@GMALLOC_OBJ@/gmalloc.o/
123 /^VMLIMIT_OBJ *=/s/@VMLIMIT_OBJ@/vm-limit.o/
124 /^RALLOC_OBJ *=/s/@RALLOC_OBJ@/ralloc.o/
125 /^PRE_ALLOC_OBJ *=/s/@PRE_ALLOC_OBJ@/lastfile.o/
126 /^POST_ALLOC_OBJ *=/s/@POST_ALLOC_OBJ@/$(vmlimitobj)/
127 /^UNEXEC_OBJ *=/s/@UNEXEC_OBJ@/unexcoff.o/
128 /^CANNOT_DUMP *=/s/@CANNOT_DUMP@/no/
129 /^DEPFLAGS *=/s/@DEPFLAGS@//
130 /^MKDEPDIR *=/s/@MKDEPDIR@//
131 /^version *=/s/@[^@\n]*@//
132 /^@SET_MAKE@$/s/@SET_MAKE@//
133 /^ [ ]*\$(libsrc)\/make-docfile.*>.*\/DOC/s!make-docfile!make-docfile -o $(etc)/DOC!
134 /^ [ ]*\$(libsrc)\/make-docfile.*>.*gl-tmp/s!make-docfile!make-docfile -o gl-tmp!
135 /^.\$(libsrc)\/make-doc/s!>.*$!!
136 /^ [ ]*\$(libsrc)\/make-docfile /s!`[^`]*`!$(lisp); cd ../src!
138 /^\$(leimdir)\/leim-list.el: /s/bootstrap-emacs\$(EXEEXT)/temacs$(EXEEXT) $(BOOTSTRAPEMACS)/
139 /^ if test -f/,/^ fi$/c\
140 command.com /c if exist .gdbinit rm -f _gdbinit
141 /^ *test "X\$(PAXCTL)" = X/d
142 /^ *test "\$(CANNOT_DUMP)" = "yes"/d
143 /^ if test "\$(CANNOT_DUMP)" =/,/^ else /d
144 /^ -\{0,1\} *ln -/s/bootstrap-emacs\$(EXEEXT).*$/bootstrap-emacs$(EXEEXT)/
146 /^ *LC_ALL=C \$(RUN_TEMACS)/i\
147 stubedit temacs.exe minstack=1024k
148 /^ *LC_ALL=C.*\$(RUN_TEMACS)/s/LC_ALL=C/set &;/
151 stubedit emacs.exe minstack=2048k
155 s/^ [^ ]*move-if-change / update /
156 /^ echo[ ][ ]*timestamp/s/echo /djecho /
157 /^ .*djecho timestamp/a\
159 /^ cd \$(leimdir) && \$(MAKE)/c\
160 $(MAKE) $(MFLAGS) -C $(leimdir) leim-list.el EMACS=$(bootstrap_exe)
161 /^ cd \$(lib) && \$(MAKE)/c\
162 $(MAKE) $(MFLAGS) -C $(lib) libgnu.a
163 /^RUN_TEMACS *=/s|`/bin/pwd`|.|
164 /^ *@\$(MKDEPDIR) *$/d
165 /^ mv \.\/\.gdbinit/d
166 /^ if test -f/,/^ fi$/c\
167 command.com /c if exist .gdbinit rm -f _gdbinit
169 /^ cd.*make-docfile/s!$!; cd ../src!
171 /^ -\{0,1\} *ln -/s/ln -f/cp -pf/
172 /^[ ]touch /s/touch/djecho $@ >/
173 s/@YMF_PASS_LDFLAGS@/flags/
177 s/@PRE_EDIT_LDFLAGS@//
178 s/@POST_EDIT_LDFLAGS@//
179 s/bootstrap-emacs/b-emacs/
180 s/bootstrap-temacs/b-temacs/
181 s/bootstrap-doc/b-doc/
182 /rm -f bootstrap-emacs/s/b-emacs/b-emacs b-emacs.exe/
183 s/echo.*buildobj.lst/dj&/
184 / --load loadup bootstrap/i\
185 stubedit temacs.exe minstack=1024k
186 / --load loadup bootstrap/a\
189 stubedit b-emacs.exe minstack=3072k\
190 djecho bootlisp > bootlisp
191 /^ -\{0,1\}rm -f/s/\\#/#/
192 /^ @\{0,1\}cd ..\/lisp;.*[^\]$/s|$|\; cd ../src|
193 /^ *THEFILE=/s|$|\; cd ../src|
194 /^ echo.* buildobj.h/s|echo |djecho |
195 # Make the GCC command line fit one screen line
196 /^[ ][ ]*\$(GNUSTEP_CFLAGS)/d
197 /^[ ][ ]*\$(GCONF_CFLAGS)/d
198 /^[ ][ ]*\$(LIBGNUTLS_CFLAGS)/d
199 s/\$(LIBOTF_CFLAGS) \$(M17N_FLT_CFLAGS) \$(DEPFLAGS) //
200 s/ \$(C_SWITCH_X_SITE)//
202 s| -I\$(srcdir)/../lib||
203 # Add our local inttypes.h to prerequisites where needed
204 /^lread\.o:/s|lread\.c|& ../msdos/inttypes.h|