GNU make needs VPATH with the for-all-make(1)s thing (at least if
the sources are in different directories, despite being listed in ${SRCS_FP} with full paths) - XXX can this work with nmake or so?
This commit is contained in:
parent
990c9eaf0c
commit
9f4376d2ad
24
Build.sh
24
Build.sh
@ -1,5 +1,5 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
srcversion='$MirOS: src/bin/mksh/Build.sh,v 1.428 2009/10/16 18:45:31 tg Exp $'
|
srcversion='$MirOS: src/bin/mksh/Build.sh,v 1.429 2009/10/16 18:51:30 tg Exp $'
|
||||||
#-
|
#-
|
||||||
# Copyright (c) 2003, 2004, 2005, 2006, 2007, 2008, 2009
|
# Copyright (c) 2003, 2004, 2005, 2006, 2007, 2008, 2009
|
||||||
# Thorsten Glaser <tg@mirbsd.org>
|
# Thorsten Glaser <tg@mirbsd.org>
|
||||||
@ -1441,10 +1441,9 @@ echo tcfn=$mkshexe >>Rebuild.sh
|
|||||||
echo "$CC $CFLAGS $LDFLAGS -o \$tcfn $lobjs $LIBS $ccpr" >>Rebuild.sh
|
echo "$CC $CFLAGS $LDFLAGS -o \$tcfn $lobjs $LIBS $ccpr" >>Rebuild.sh
|
||||||
echo 'test -f $tcfn || exit 1; size $tcfn' >>Rebuild.sh
|
echo 'test -f $tcfn || exit 1; size $tcfn' >>Rebuild.sh
|
||||||
if test $cm = makefile; then
|
if test $cm = makefile; then
|
||||||
of=Makefrag.inc
|
|
||||||
extras='emacsfn.h sh.h sh_flags.h var_spec.h'
|
extras='emacsfn.h sh.h sh_flags.h var_spec.h'
|
||||||
test 0 = $HAVE_SYS_SIGNAME && extras="$extras signames.inc"
|
test 0 = $HAVE_SYS_SIGNAME && extras="$extras signames.inc"
|
||||||
cat >$of <<EOF
|
cat >Makefrag.inc <<EOF
|
||||||
# Makefile fragment for building mksh $dstversion
|
# Makefile fragment for building mksh $dstversion
|
||||||
|
|
||||||
PROG= $mkshexe
|
PROG= $mkshexe
|
||||||
@ -1461,29 +1460,26 @@ CPPFLAGS= $CPPFLAGS
|
|||||||
LDFLAGS= $LDFLAGS
|
LDFLAGS= $LDFLAGS
|
||||||
LIBS= $LIBS
|
LIBS= $LIBS
|
||||||
|
|
||||||
EOF
|
|
||||||
cat >>$of <<'EOF'
|
|
||||||
# not BSD make only:
|
# not BSD make only:
|
||||||
#all: $(PROG)
|
#VPATH= $srcdir
|
||||||
#$(PROG): $(OBJS_BP)
|
#all: \$(PROG)
|
||||||
# $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $(OBJS_BP) $(LIBS)
|
#\$(PROG): \$(OBJS_BP)
|
||||||
#$(OBJS_BP): $(SRCS_FP) $(NONSRCS)
|
# \$(CC) \$(CFLAGS) \$(LDFLAGS) -o \$@ \$(OBJS_BP) \$(LIBS)
|
||||||
|
#\$(OBJS_BP): \$(SRCS_FP) \$(NONSRCS)
|
||||||
#.c.o:
|
#.c.o:
|
||||||
# $(CC) $(CFLAGS) $(CPPFLAGS) -c $<
|
# \$(CC) \$(CFLAGS) \$(CPPFLAGS) -c \$<
|
||||||
|
|
||||||
# for all make variants:
|
# for all make variants:
|
||||||
#REGRESS_FLAGS= -v
|
#REGRESS_FLAGS= -v
|
||||||
#regress:
|
#regress:
|
||||||
# ./test.sh $(REGRESS_FLAGS)
|
# ./test.sh \$(REGRESS_FLAGS)
|
||||||
|
|
||||||
EOF
|
|
||||||
cat >>$of <<EOF
|
|
||||||
# for BSD make only:
|
# for BSD make only:
|
||||||
#.PATH: $srcdir
|
#.PATH: $srcdir
|
||||||
#.include <bsd.prog.mk>
|
#.include <bsd.prog.mk>
|
||||||
EOF
|
EOF
|
||||||
$e
|
$e
|
||||||
$e Generated $of successfully.
|
$e Generated Makefrag.inc successfully.
|
||||||
exit 0
|
exit 0
|
||||||
fi
|
fi
|
||||||
if test $cm = combine; then
|
if test $cm = combine; then
|
||||||
|
Loading…
x
Reference in New Issue
Block a user