removed my badly-done attempt at handling compilers that don't handle
authorAndrew Tridgell <tridge@samba.org>
Tue, 20 Oct 1998 03:10:29 +0000 (03:10 +0000)
committerAndrew Tridgell <tridge@samba.org>
Tue, 20 Oct 1998 03:10:29 +0000 (03:10 +0000)
-c and -o at the same time.

my shell script code wasn't portable

source/Makefile.in

index 68738bd6e7bb269d74c265ecc1a04c32eaac541a..43aecf2dc61e56151abb7d494ac3adc6ab81cb76 100644 (file)
@@ -256,9 +256,7 @@ MAKEDIR = || exec false; \
        @if (: >> $@ || : > $@) >/dev/null 2>&1; then rm -f $@; else \
         dir=`echo $@ | sed 's,/[^/]*$$,,;s,^$$,.,'` $(MAKEDIR); fi
        @echo Compiling $*.c
-       @rm -f $@
-       @$(CC) -I. -I$(srcdir) $(FLAGS) -c $<
-       @if ! test -f $@; then mv `basename $@` $@; fi \
+       @$(CC) -I. -I$(srcdir) $(FLAGS) -c $< -o $@ \
        @MAINT@ -Wp,-MD,.deps/`echo $* | sed s,/,_,g`.P && : >.deps/.stamp
 # the line above is for atomatic dependency tracking
 # it will only work with GNU make, gcc and --enable-maintainer-mode
@@ -268,20 +266,16 @@ MAKEDIR = || exec false; \
        @if (: >> $@ || : > $@) >/dev/null 2>&1; then rm -f $@; else \
          dir=`echo $@ | sed 's,/[^/]*$$,,;s,^$$,.,'` $(MAKEDIR); fi
        @echo Compiling $*.c with @PICFLAG@
-       @$(CC) -I. -I$(srcdir) $(FLAGS) @PICFLAG@ -c $<
-       @if ! test -f $@; then mv `basename $@` $@; fi \
+       @$(CC) -I. -I$(srcdir) $(FLAGS) @PICFLAG@ -c $< -o $@ \
        @MAINT@ -Wp,-MD,.deps/`echo $* | sed s,/,_,g`.P && : >.deps/.stamp
-       @mv $@.o $@
 
 # this is for IRIX
 .c.po32: @MAINT@ .deps/.dummy
        @if (: >> $@ || : > $@) >/dev/null 2>&1; then rm -f $@; else \
          dir=`echo $@ | sed 's,/[^/]*$$,,;s,^$$,.,'` $(MAKEDIR); fi
        @echo Compiling $*.c with @PICFLAG@ and -32
-       @$(CC) -32 -I. -I$(srcdir) $(FLAGS) @PICFLAG@ -c $<
-       @if ! test -f $@; then mv `basename $@` $@; fi \
+       @$(CC) -32 -I. -I$(srcdir) $(FLAGS) @PICFLAG@ -c $< -o $@ \
        @MAINT@ -Wp,-MD,.deps/`echo $* | sed s,/,_,g`.P && : >.deps/.stamp
-       @mv $@.o $@
 
 bin/.dummy:
        @if (: >> $@ || : > $@) >/dev/null 2>&1; then :; else \