mirror of
https://git.savannah.gnu.org/git/emacs.git
synced 2024-11-22 07:09:54 +00:00
(making src/Makefile and lib-src/Makefile):
Split off the autoconf substitutions and don't pass them thru cpp. (undefs): Use $canonical as well as $configuration.
This commit is contained in:
parent
eb4252f765
commit
23aaa3427f
@ -1612,7 +1612,7 @@ changequote(,)dnl The horror, the horror.
|
||||
# the C preprocessor to some helpful value like 1, or maybe the empty
|
||||
# string. Needless to say consequent macro substitutions are less
|
||||
# than conducive to the makefile finding the correct directory.
|
||||
undefs="`echo $top_srcdir $configuration |
|
||||
undefs="`echo $top_srcdir $configuration $canonical |
|
||||
sed -e 's/[^a-zA-Z0-9_]/ /g' -e 's/^/ /' -e 's/ *$//' \
|
||||
-e 's/ */ -U/g' -e 's/-U[0-9][^ ]*//g' \
|
||||
`"
|
||||
@ -1620,26 +1620,32 @@ changequote([,])dnl
|
||||
|
||||
echo creating lib-src/Makefile
|
||||
( cd lib-src
|
||||
rm -f junk.c
|
||||
sed -e 's@^# \(Generated.*\)$@/* \1 */@' \
|
||||
rm -f junk.c junk1.c junk2.c
|
||||
sed -e '/start of cpp stuff/q' \
|
||||
< Makefile.in > junk1.c
|
||||
sed -e '1,/start of cpp stuff/d'\
|
||||
-e 's@/\*\*/#\(.*\)$@/* \1 */@' \
|
||||
< Makefile.in > junk.c
|
||||
$CPP $undefs -I. -I$top_srcdir/src $CPPFLAGS junk.c |
|
||||
sed -e 's/^ / /' -e '/^#/d' -e '/^[ ]*$/d' > Makefile.new
|
||||
rm -f junk.c
|
||||
chmod 444 Makefile.new;
|
||||
mv -f Makefile.new Makefile;
|
||||
$CPP $undefs -I. -I$top_srcdir/src $CPPFLAGS junk.c | \
|
||||
sed -e 's/^ / /' -e '/^#/d' -e '/^[ ]*$/d' > junk2.c
|
||||
cat junk1.c junk2.c > Makefile.new
|
||||
rm -f junk.c junk1.c junk2.c
|
||||
chmod 444 Makefile.new
|
||||
mv -f Makefile.new Makefile
|
||||
)
|
||||
|
||||
echo creating src/Makefile
|
||||
( cd src
|
||||
rm -f junk.c
|
||||
sed -e 's@^# \(Generated.*\)$@/* \1 */@' \
|
||||
rm -f junk.c junk1.c junk2.c
|
||||
sed -e '/start of cpp stuff/q' \
|
||||
< Makefile.in > junk1.c
|
||||
sed -e '1,/start of cpp stuff/d'\
|
||||
-e 's@/\*\*/#\(.*\)$@/* \1 */@' \
|
||||
< Makefile.in > junk.c
|
||||
$CPP $undefs -I. -I$top_srcdir/src $CPPFLAGS junk.c |
|
||||
sed -e 's/^ / /' -e '/^#/d' -e '/^[ ]*$/d' > Makefile.new
|
||||
rm -f junk.c
|
||||
chmod 444 Makefile.new;
|
||||
mv -f Makefile.new Makefile;
|
||||
$CPP $undefs -I. -I$top_srcdir/src $CPPFLAGS junk.c | \
|
||||
sed -e 's/^ / /' -e '/^#/d' -e '/^[ ]*$/d' > junk2.c
|
||||
cat junk1.c junk2.c > Makefile.new
|
||||
rm -f junk.c junk1.c junk2.c
|
||||
chmod 444 Makefile.new
|
||||
mv -f Makefile.new Makefile
|
||||
)])
|
||||
|
Loading…
Reference in New Issue
Block a user