Home | History | Annotate | Line # | Download | only in libm
Makefile revision 1.5
      1  1.3  mycroft #	from: @(#)Makefile	5.11 (Berkeley) 12/2/92
      2  1.5      cgd #	$Id: Makefile,v 1.5 1993/10/01 23:56:08 cgd Exp $
      3  1.1      cgd #
      4  1.1      cgd # ieee		- for most IEEE machines, we hope.
      5  1.1      cgd # mc68881	- the, ahem, mc68881.
      6  1.1      cgd # national	- for those ieee machines whose floating point implementation
      7  1.1      cgd #		  has similar byte ordering as the NATIONAL 32016 with 32081.
      8  1.1      cgd # i386		- i387 NPX, currently the same as "national"
      9  1.3  mycroft # mips		- for MIPS achitecture machines
     10  1.1      cgd # tahoe		- for the tahoe double format.
     11  1.1      cgd # vax		- for the vax D_floating format
     12  1.1      cgd 
     13  1.1      cgd LIB=	m
     14  1.1      cgd CFLAGS+=-I${.CURDIR}/common_source
     15  1.1      cgd 
     16  1.3  mycroft .if (${MACHINE} == "ieee")
     17  1.3  mycroft 
     18  1.3  mycroft HARDWARE=${MACHINE}
     19  1.3  mycroft .PATH:	${.CURDIR}/common_source ${.CURDIR}/common ${.CURDIR}/ieee
     20  1.3  mycroft # common_source
     21  1.4  mycroft SRCS+=	acosh.c asincos.c asinh.c atan.c atanh.c cosh.c erf.c exp.c exp__D.c \
     22  1.4  mycroft 	exp__E.c expm1.c floor.c fmod.c gamma.c lgamma.c j0.c j1.c jn.c log.c \
     23  1.4  mycroft 	log10.c log1p.c log__D.c log__L.c logtab.c pow.c sinh.c tanh.c
     24  1.3  mycroft # common
     25  1.3  mycroft SRCS+=	atan2.c sincos.c tan.c
     26  1.3  mycroft # ieee
     27  1.3  mycroft SRCS+=	cabs.c cbrt.c support.c
     28  1.3  mycroft 
     29  1.3  mycroft .elif (${MACHINE} == "hp300" || ${MACHINE} == "luna68k")
     30  1.3  mycroft 
     31  1.3  mycroft HARDWARE=mc68881
     32  1.3  mycroft .PATH:	${.CURDIR}/mc68881 ${.CURDIR}/common_source ${.CURDIR}/ieee
     33  1.3  mycroft # common_source
     34  1.5      cgd SRCS+=	acosh.c asinh.c erf.c exp__D.c exp__E.c fmod.c gamma.c lgamma.c j0.c \
     35  1.5      cgd 	j1.c log__D.c log__L.c logtab.c pow.c
     36  1.3  mycroft # mc68881
     37  1.3  mycroft SRCS+=	asincos.s atan.s atan2.c atanh.s cosh.s exp.s expm1.s floor.s \
     38  1.3  mycroft 	log.s log10.s log1p.s sincos.s sinh.s sqrt.s support.s tan.s tanh.s
     39  1.3  mycroft # ieee
     40  1.3  mycroft SRCS+=	cabs.c cbrt.c
     41  1.3  mycroft 
     42  1.3  mycroft .elif (${MACHINE} == "i386")
     43  1.3  mycroft 
     44  1.1      cgd HARDWARE=i387
     45  1.3  mycroft .PATH:	${.CURDIR}/common_source ${.CURDIR}/common ${.CURDIR}/ieee
     46  1.3  mycroft CFLAGS+= -Dnational
     47  1.3  mycroft # common_source
     48  1.4  mycroft SRCS+=	acosh.c asincos.c asinh.c atan.c atanh.c cosh.c erf.c exp.c exp__D.c \
     49  1.5      cgd 	exp__E.c expm1.c floor.c fmod.c gamma.c lgamma.c j0.c j1.c jn.c log.c \
     50  1.5      cgd 	log10.c log1p.c log__D.c log__L.c logtab.c pow.c sinh.c tanh.c
     51  1.3  mycroft # common
     52  1.3  mycroft SRCS+=	atan2.c sincos.c tan.c
     53  1.3  mycroft # ieee
     54  1.3  mycroft SRCS+=	cabs.c cbrt.c support.c
     55  1.3  mycroft 
     56  1.3  mycroft .elif (${MACHINE} == "mips")
     57  1.3  mycroft 
     58  1.3  mycroft HARDWARE=${MACHINE}
     59  1.3  mycroft .PATH:	${.CURDIR}/common_source ${.CURDIR}/common ${.CURDIR}/ieee
     60  1.3  mycroft CFLAGS+= -Dnational
     61  1.3  mycroft # common_source
     62  1.4  mycroft SRCS+=	acosh.c asincos.c asinh.c atan.c atanh.c cosh.c erf.c exp.c exp__D.c \
     63  1.5      cgd 	exp__E.c expm1.c floor.c fmod.c gamma.c lgamma.c j0.c j1.c jn.c log.c \
     64  1.5      cgd 	log10.c log1p.c log__D.c log__L.c logtab.c pow.c sinh.c tanh.c
     65  1.3  mycroft # common
     66  1.3  mycroft SRCS+=	atan2.c sincos.c tan.c
     67  1.3  mycroft # ieee
     68  1.3  mycroft SRCS+=	cabs.c cbrt.c support.c
     69  1.3  mycroft 
     70  1.3  mycroft .elif (${MACHINE} == "national")
     71  1.3  mycroft 
     72  1.3  mycroft HARDWARE=${MACHINE}
     73  1.3  mycroft .PATH:	${.CURDIR}/common_source ${.CURDIR}/common ${.CURDIR}/national \
     74  1.3  mycroft .elif (${MACHINE} == "national")
     75  1.3  mycroft 
     76  1.3  mycroft HARDWARE=${MACHINE}
     77  1.3  mycroft .PATH:	${.CURDIR}/common_source ${.CURDIR}/common ${.CURDIR}/national \
     78  1.1      cgd 	${.CURDIR}/ieee
     79  1.3  mycroft # common_source
     80  1.4  mycroft SRCS+=	acosh.c asincos.c asinh.c atan.c atanh.c cosh.c erf.c exp.c exp__D.c \
     81  1.5      cgd 	exp__E.c expm1.c floor.c fmod.c gamma.c lgamma.c j0.c j1.c jn.c log.c \
     82  1.5      cgd 	log10.c log1p.c log__D.c log__L.c logtab.c pow.c sinh.c tanh.c
     83  1.3  mycroft # common
     84  1.3  mycroft SRCS+=	atan2.c sincos.c tan.c
     85  1.3  mycroft # national
     86  1.3  mycroft SRCS+=	sqrt.s support.s
     87  1.3  mycroft # ieee
     88  1.3  mycroft SRCS+=	cabs.c cbrt.c
     89  1.3  mycroft 
     90  1.3  mycroft .elif (${MACHINE} == "sparc")
     91  1.3  mycroft 
     92  1.3  mycroft HARDWARE=${MACHINE}
     93  1.3  mycroft .PATH:  ${.CURDIR}/common_source ${.CURDIR}/common ${.CURDIR}/ieee
     94  1.1      cgd # common_source
     95  1.4  mycroft SRCS+=	acosh.c asincos.c asinh.c atan.c atanh.c cosh.c erf.c exp.c exp__D.c \
     96  1.5      cgd 	exp__E.c expm1.c floor.c fmod.c gamma.c lgamma.c j0.c j1.c jn.c log.c \
     97  1.5      cgd 	log10.c log1p.c log__D.c log__L.c logtab.c pow.c sinh.c tanh.c
     98  1.3  mycroft # XXX should do sqrt & support functions in assembly
     99  1.1      cgd # common
    100  1.1      cgd SRCS+=	atan2.c sincos.c tan.c
    101  1.1      cgd # ieee
    102  1.1      cgd SRCS+=	cabs.c cbrt.c support.c
    103  1.3  mycroft 
    104  1.3  mycroft .elif (${MACHINE} == "tahoe")
    105  1.3  mycroft 
    106  1.3  mycroft HARDWARE=${MACHINE}
    107  1.3  mycroft .PATH:	${.CURDIR}/common_source ${.CURDIR}/common ${.CURDIR}/tahoe \
    108  1.3  mycroft # common_source
    109  1.4  mycroft SRCS+=	acosh.c asincos.c asinh.c atan.c atanh.c cosh.c erf.c exp.c exp__D.c \
    110  1.5      cgd 	exp__E.c expm1.c floor.c fmod.c gamma.c lgamma.c j0.c j1.c jn.c log.c \
    111  1.5      cgd 	log10.c log1p.c log__D.c log__L.c logtab.c pow.c sinh.c tanh.c
    112  1.3  mycroft # common
    113  1.3  mycroft SRCS+=	atan2.c sincos.c tan.c
    114  1.3  mycroft # tahoe
    115  1.3  mycroft SRCS+=	cabs.s cbrt.s sqrt.s support.s infnan.s
    116  1.3  mycroft 
    117  1.3  mycroft .elif (${MACHINE} == "vax")
    118  1.3  mycroft 
    119  1.3  mycroft HARDWARE=${MACHINE}
    120  1.3  mycroft .PATH:	${.CURDIR}/common_source ${.CURDIR}/vax
    121  1.3  mycroft # common_source
    122  1.4  mycroft SRCS+=	acosh.c asincos.c asinh.c atan.c atanh.c cosh.c erf.c exp.c exp__D.c \
    123  1.5      cgd 	exp__E.c expm1.c floor.c fmod.c gamma.c lgamma.c j0.c j1.c jn.c log.c \
    124  1.5      cgd 	log10.c log1p.c log__D.c log__L.c logtab.c pow.c sinh.c tanh.c
    125  1.3  mycroft # vax
    126  1.3  mycroft SRCS+=	atan2.s cabs.s cbrt.s sqrt.s sincos.s tan.s argred.s support.s \
    127  1.3  mycroft 	infnan.s
    128  1.3  mycroft 
    129  1.3  mycroft .endif
    130  1.1      cgd 
    131  1.1      cgd MAN3+=	acos.0 acosh.0 asin.0 asinh.0 atan.0 atan2.0 atanh.0 ceil.0 \
    132  1.1      cgd 	cos.0 cosh.0 erf.0 exp.0 fabs.0 floor.0 fmod.0 hypot.0 ieee.0 \
    133  1.1      cgd 	infnan.0 j0.0 lgamma.0 math.0 rint.0 sin.0 sinh.0 sqrt.0 \
    134  1.1      cgd 	tan.0 tanh.0
    135  1.1      cgd 
    136  1.1      cgd MLINKS+=erf.3 erfc.3
    137  1.1      cgd MLINKS+=exp.3 expm1.3 exp.3 log.3 exp.3 log10.3 exp.3 log1p.3 exp.3 pow.3
    138  1.1      cgd MLINKS+=hypot.3 cabs.3
    139  1.1      cgd MLINKS+=ieee.3 copysign.3 ieee.3 drem.3 ieee.3 finite.3 ieee.3 logb.3 \
    140  1.1      cgd 	ieee.3 scalb.3
    141  1.1      cgd MLINKS+=j0.3 j1.3 j0.3 jn.3 j0.3 y0.3 j0.3 y1.3 j0.3 yn.3
    142  1.1      cgd MLINKS+=lgamma.3 gamma.3
    143  1.1      cgd 
    144  1.1      cgd # can't use the standard mkdep, because there are some .s files that
    145  1.1      cgd # are using '#' as a comment indicator and cpp thinks it's an undefined
    146  1.1      cgd # control.
    147  1.1      cgd 
    148  1.1      cgd depend: .depend
    149  1.1      cgd .depend: ${SRCS}
    150  1.1      cgd 	mkdep ${CFLAGS:M-[ID]*} ${.ALLSRC:M*.c}
    151  1.1      cgd 
    152  1.1      cgd .include <bsd.lib.mk>
    153  1.1      cgd 
    154  1.1      cgd .s.o:
    155  1.1      cgd 	${AS} -o ${.TARGET} ${.IMPSRC}
    156  1.1      cgd 	@${LD} -x -r ${.TARGET}
    157  1.1      cgd 	@mv a.out ${.TARGET}
    158  1.1      cgd 
    159  1.1      cgd .s.po:
    160  1.1      cgd 	sed -f ${.CURDIR}/${HARDWARE}/mcount.sed ${.IMPSRC} | \
    161  1.1      cgd 	    ${AS} -o ${.TARGET}
    162  1.1      cgd 	@${LD} -X -r ${.TARGET}
    163  1.1      cgd 	@mv a.out ${.TARGET}
    164