Proper support for OpenBSD-i386 shared build, including assember modules!
[openssl.git] / crypto / rc4 / Makefile.ssl
index 3e602662be2b7e2293757490c9747823e74b530d..f63205296abeb275aeec75877b3eb6532f894360 100644 (file)
@@ -26,6 +26,7 @@ RC4_ENC=rc4_enc.o
 
 CFLAGS= $(INCLUDES) $(CFLAG)
 ASFLAGS= $(INCLUDES) $(ASFLAG)
+AFLAGS= $(ASFLAGS)
 
 GENERAL=Makefile
 TEST=rc4test.c
@@ -52,20 +53,17 @@ lib:        $(LIBOBJ)
        $(RANLIB) $(LIB) || echo Never mind.
        @touch lib
 
-# elf
+# ELF
 asm/rx86-elf.s: asm/rc4-586.pl ../perlasm/x86asm.pl
-       (cd asm; $(PERL) rc4-586.pl elf $(CFLAGS) > rx86-elf.s)
-
+       (cd asm; $(PERL) rc4-586.pl elf $(CFLAGS) > ../$@)
+# COFF
+asm/rx86-cof.s: asm/rc4-586.pl ../perlasm/x86asm.pl
+       (cd asm; $(PERL) rc4-586.pl coff $(CFLAGS) > ../$@)
 # a.out
-asm/rx86-out.o: asm/rx86unix.cpp
-       $(CPP) -DOUT asm/rx86unix.cpp | as -o asm/rx86-out.o
-
-# bsdi
-asm/rx86bsdi.o: asm/rx86unix.cpp
-       $(CPP) -DBSDI asm/rx86unix.cpp | sed 's/ :/:/' | as -o asm/rx86bsdi.o
+rx86-out.s: asm/rc4-586.pl ../perlasm/x86asm.pl
+       (cd asm; $(PERL) rc4-586.pl a.out $(CFLAGS) > ../$@)
 
-asm/rx86unix.cpp: asm/rc4-586.pl ../perlasm/x86asm.pl
-       (cd asm; $(PERL) rc4-586.pl cpp >rx86unix.cpp)
+asm/rc4-amd64.s: asm/rc4-amd64.pl;     $(PERL) $< $@
 
 files:
        $(PERL) $(TOP)/util/files.pl Makefile.ssl >> $(TOP)/MINFO
@@ -99,7 +97,7 @@ dclean:
        mv -f Makefile.new $(MAKEFILE)
 
 clean:
-       rm -f asm/rx86unix.cpp asm/*-elf.* *.o *.obj lib tags core .pure .nfs* *.old *.bak fluff asm/*.o
+       rm -f asm/rx86unix.cpp asm/*.s asm/*.o *.s *.o *.obj lib tags core .pure .nfs* *.old *.bak fluff
 
 # DO NOT DELETE THIS LINE -- make depend depends on it.