Hajimu UMEMOTO wrote:
> Hi,
> 
> >>>>> On Sun, 17 Mar 2002 15:38:48 -0800
> >>>>> Maxime Henrion <[EMAIL PROTECTED]> said:
> 
> mux> Actually, this patch is wrong because it won't ever compile des_enc.S.
> mux> Whatever I do, des_enc.c gets compiled and I can't figure out how to
> mux> compile a .S file with bsd.kmod.mk.  If someone with more make(1) clue
> mux> than me could help out, that would be appreciated.
> 
> Did you make sure to do make depend after changing your Makefile?
> I tried it and I could reproduce your problem with `make buildkernel
> NOCLEAN=YES NO_KERNELDEPEND=YES'.  Then, I tried with `make
> buildkernel NOCLEAN=YES', and the problem was gone.

Oops.  You are entirely right :-)  Do you agree with the attached patch ?
I just changed ${.CURDIR}/../../crypto/des/arch/i386 to
${.CURDIR}/../../crypto/des/arch/${MACHINE_ARCH} in the .PATH directive
since make(1) is not whining about non-existing directories, and this
will allow to only modify the Makefile in one place when adding new
assembly des_enc.S files.  I'll commit it if it's fine with you.

Maxime
Index: Makefile
===================================================================
RCS file: /home/ncvs/src/sys/modules/smbfs/Makefile,v
retrieving revision 1.4
diff -u -r1.4 Makefile
--- Makefile    11 Jan 2002 15:48:57 -0000      1.4
+++ Makefile    18 Mar 2002 11:11:59 -0000
@@ -1,6 +1,7 @@
 # $FreeBSD: src/sys/modules/smbfs/Makefile,v 1.4 2002/01/11 15:48:57 ru Exp $
 
 .PATH: ${.CURDIR}/../../crypto/des \
+       ${.CURDIR}/../../crypto/des/arch/${MACHINE_ARCH} \
        ${.CURDIR}/../../kern \
        ${.CURDIR}/../../libkern \
        ${.CURDIR}/../../netsmb \
@@ -22,6 +23,11 @@
 
 .if defined(NETSMBCRYPTO)
 SRCS+= des_ecb.c des_setkey.c
+.if ${MACHINE_ARCH} == "i386"
+SRCS+= des_enc.S
+.else
+SRCS+= des_enc.c
+.endif
 .endif
 
 # Build with IPX support (1|0)

Reply via email to