]> git.ipfire.org Git - thirdparty/nettle.git/commitdiff
Simplify .asm-related make rules.
authorNiels Möller <nisse@lysator.liu.se>
Wed, 3 Sep 2014 21:16:20 +0000 (23:16 +0200)
committerNiels Möller <nisse@lysator.liu.se>
Wed, 3 Sep 2014 21:16:20 +0000 (23:16 +0200)
ChangeLog
Makefile.in
config.make.in
configure.ac

index 5a20c89f21145091fca1253c363ae37f1d3ba56e..20c7d2b5ebe549be511674a8d769bcac3af1222f 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,12 @@
 2014-09-03  Niels Möller  <nisse@lysator.liu.se>
 
+       * Makefile.in: Revert 2013-02-06 Makefile changes: use a single
+       rule for transforming .asm to .o, and drop include of asm.d.
+       Possible now since we generate a single object file from each asm
+       file. This change also helps Solaris' make recognize .asm files.
+       * config.make.in (.SUFFIXES): Drop .s from list.
+       * configure.ac: Delete code to generate asm.d.
+
        * Makefile.in: Delete all uses of *.po files, use the same object
        files for both shared and static libraries.
        * configure.ac (dummy-dep-files): Don't create any .po.d files.
index 43aac2de82dd6274e130df0331afee54c38a8500..a35f8ad13357a02246c7954377b1eb16464ae80f 100644 (file)
@@ -360,13 +360,10 @@ ecc-384.$(OBJEXT): ecc-384.h
 ecc-521.$(OBJEXT): ecc-521.h
 ecc-25519.$(OBJEXT): ecc-25519.h
 
-.asm.s: $(srcdir)/asm.m4 machine.m4 config.m4
-       $(M4) $(srcdir)/asm.m4 machine.m4 config.m4 $< >$@T \
-       && test -s $@T && mv -f $@T $@
-
-.s.$(OBJEXT):
-       $(COMPILE) -c $<
-       @echo > $@.d
+.asm.$(OBJEXT): $(srcdir)/asm.m4 machine.m4 config.m4
+       $(M4) $(srcdir)/asm.m4 machine.m4 config.m4 $< >$*.s
+       $(COMPILE) -c $*.s
+       @echo "$@ : $< $(srcdir)/asm.m4 machine.m4 config.m4" >$@.d 
 
 # Texinfo rules
 .texinfo.info:
@@ -628,5 +625,5 @@ maintainer-clean-here:
 tags-here:     
        etags -o $(srcdir)/TAGS $(srcdir)/*.c $(srcdir)/*.h
 
-DEP_FILES = $(SOURCES:.c=.$(OBJEXT).d) asm.d
+DEP_FILES = $(SOURCES:.c=.$(OBJEXT).d)
 @DEP_INCLUDE@ $(DEP_FILES)
index a8ab49faa714ca3cd74cf4962c3ba7e1c518827f..8d5f4b3f7fc8f16237e5d966a03cba49bc6841d2 100644 (file)
@@ -83,7 +83,7 @@ default: all
 # compile was broken when .SUFFIXES was moved here from Makefile.in.
 
 .SUFFIXES:
-.SUFFIXES: .asm .s .c .$(OBJEXT) .p$(OBJEXT) .html .dvi .info .exe .pdf .ps .texinfo
+.SUFFIXES: .asm .c .$(OBJEXT) .p$(OBJEXT) .html .dvi .info .exe .pdf .ps .texinfo
 
 # Disable builtin rule
 %$(EXEEXT) : %.c
index 07fc994456f28ebf5950de05dee4a4dc4e2168d0..3e464e71071966f5edc16858aded1a40d3735f4f 100644 (file)
@@ -373,22 +373,6 @@ AH_VERBATIM([HAVE_NATIVE],
 #undef HAVE_NATIVE_ecc_521_redc
 #undef HAVE_NATIVE_gcm_hash8])
 
-# Besides getting correct dependencies, the explicit rules also tell
-# make that the .s files "ought to exist", so they are preferred over
-# .c files.
-AC_CONFIG_COMMANDS([asm.d],
-    [ for f in $asm_file_list
-      do
-        case $f in
-         *.asm)
-           echo "`basename $f .asm`.s : $f "'$(srcdir)/asm.m4 machine.m4 config.m4'
-           ;;
-       esac
-      done > asm.d
-    ],
-    [ asm_file_list="$asm_file_list" ]
-)
-
 if test "x$enable_pic" = xyes; then
     LSH_CCPIC
 else