mirror of
https://git.FreeBSD.org/src.git
synced 2024-12-22 11:17:19 +00:00
aa9bc17601
BMakefiles and other bits will follow. Requested by: Andrey Chernov Made world by: Chuck Robey
179 lines
5.9 KiB
Plaintext
179 lines
5.9 KiB
Plaintext
# This file is a shell script fragment that supplies the information
|
|
# necessary for a configure script to process the program in
|
|
# this directory. For more information, look at ../configure.
|
|
|
|
configdirs=
|
|
srctrigger=powerpc32
|
|
srcname="GNU Multi-Precision library/mpn"
|
|
|
|
# per-host:
|
|
|
|
# per-target:
|
|
|
|
case "${target}" in
|
|
sparc9*-*-* | sparc64*-*-* | ultrasparc*-*-*)
|
|
#path="sparc64" ;; Don't use this until compilers are ready
|
|
path="sparc32/v8 sparc" ;;
|
|
sparc8*-*-* | microsparc*-*-*)
|
|
path="sparc32/v8 sparc" ;;
|
|
supersparc*-*-*)
|
|
path="sparc32/v8/supersparc sparc32/v8 sparc"
|
|
extra_functions="udiv" ;;
|
|
sparc*-*-*) path="sparc32"
|
|
if [ x$floating_point = xno ]
|
|
then extra_functions="udiv_nfp"
|
|
else extra_functions="udiv_fp"
|
|
fi
|
|
;;
|
|
hppa7000*-*-*) path="hppa/hppa1_1 hppa"; extra_functions="udiv_qrnnd" ;;
|
|
hppa1.0*-*-*) path="hppa"; extra_functions="udiv_qrnnd" ;;
|
|
hppa*-*-*) # assume pa7100
|
|
path="hppa/hppa1_1/pa7100 hppa/hppa1_1 hppa"
|
|
extra_functions="udiv_qrnnd" ;;
|
|
cray2-cray-unicos* | [xy]mp-cray-unicos* | [ctj]90-cray-unicos*)
|
|
path="cray" ;;
|
|
alphaev5-*-*) path="alpha/ev5 alpha"; extra_functions="udiv_qrnnd" ;;
|
|
alpha*-*-*) path="alpha"; extra_functions="udiv_qrnnd" ;;
|
|
am29000*-*-*) path="am29000" ;;
|
|
a29k*-*-*) path="am29000" ;;
|
|
|
|
# Intel x86 configurations
|
|
i[34]86*-*-linuxaout* | i[34]86*-*-linuxoldld* | \
|
|
i[34]86*-*-*bsd*) # x86 running BSD or Linux with a.out
|
|
echo '#define BSD_SYNTAX' >asm-syntax.h
|
|
echo '#include "'$srcdir'/x86/syntax.h"' >>asm-syntax.h
|
|
path="x86" ;;
|
|
i[56]86*-*-linuxaout* | pentium-*-linuxaout* | pentiumpro-*-linuxaout* | \
|
|
i[56]86*-*-linuxoldld* | pentium-*-linuxoldld* | pentiumpro-*-linuxoldld* | \
|
|
i[56]86*-*-*bsd* | pentium-*-*bsd* | pentiumpro-*-*bsd*)
|
|
echo '#define BSD_SYNTAX' >asm-syntax.h
|
|
echo '#include "'$srcdir'/x86/syntax.h"' >>asm-syntax.h
|
|
path="x86/pentium x86" ;;
|
|
i[34]86*-*-*) # x86 with ELF/SysV format
|
|
echo '#define ELF_SYNTAX' >asm-syntax.h
|
|
echo '#include "'$srcdir'/x86/syntax.h"' >>asm-syntax.h
|
|
path="x86" ;;
|
|
i[56]86*-*-* | pentium-*-* | pentiumpro-*-*) # x86 with ELF/SysV format
|
|
echo '#define ELF_SYNTAX' >asm-syntax.h
|
|
echo '#include "'$srcdir'/x86/syntax.h"' >>asm-syntax.h
|
|
path="x86/pentium x86" ;;
|
|
|
|
# Motorola 68k configurations. Let m68k mean 68020-68040.
|
|
# mc68000 or mc68060 configurations need to be specified explicitly
|
|
m680[234]0*-*-linuxaout* | m68k*-*-linuxaout*)
|
|
echo '#define MIT_SYNTAX' >asm-syntax.h
|
|
echo '#include "'$srcdir'/m68k/syntax.h"' >>asm-syntax.h
|
|
path="m68k/mc68020 m68k" ;;
|
|
m68060*-*-linuxaout*)
|
|
echo '#define MIT_SYNTAX' >asm-syntax.h
|
|
echo '#include "'$srcdir'/m68k/syntax.h"' >>asm-syntax.h
|
|
path="m68k" ;;
|
|
m680[234]0*-*-linux* | m68k*-*-linux*)
|
|
echo '#define ELF_SYNTAX' >asm-syntax.h
|
|
echo '#include "'$srcdir'/m68k/syntax.h"' >>asm-syntax.h
|
|
path="m68k/mc68020 m68k" ;;
|
|
m68060*-*-linux*)
|
|
echo '#define ELF_SYNTAX' >asm-syntax.h
|
|
echo '#include "'$srcdir'/m68k/syntax.h"' >>asm-syntax.h
|
|
path="m68k" ;;
|
|
m68000*-*-* | m68060*-*-*)
|
|
echo '#define MIT_SYNTAX' >asm-syntax.h
|
|
echo '#include "'$srcdir'/m68k/syntax.h"' >>asm-syntax.h
|
|
path="m68k/mc68000" ;;
|
|
m680[234]0*-*-* | m68k*-*-*)
|
|
echo '#define MIT_SYNTAX' >asm-syntax.h
|
|
echo '#include "'$srcdir'/m68k/syntax.h"' >>asm-syntax.h
|
|
path="m68k/mc68020 m68k" ;;
|
|
|
|
i960*-*-*) path="i960" ;;
|
|
m88k*-*-* | m88k*-*-*) path="m88k" ;;
|
|
m88110*-*-*) path="m88k/mc88110 m88k" ;;
|
|
ns32k*-*-*) path="n32k" ;;
|
|
ppc601-*-*) path="power powerpc32" ;;
|
|
ppc620-*-* | powerpc64*-*-*) path="powerpc64" ;;
|
|
ppc60[234]*-*-* | powerpc*-*-*) path="powerpc32" ;;
|
|
pyramid-*-*) path="pyr" ;;
|
|
rs6000-*-* | power-*-* | power2-*-*)
|
|
path="power"; extra_functions="udiv_w_sdiv" ;;
|
|
sh-*-*) path="sh" ;;
|
|
sh2-*-*) path="sh/sh2 sh" ;;
|
|
mips[34]*-*-*) path="mips3" ;;
|
|
mips*-*-irix6*) path="mips3" ;;
|
|
mips*-*-*) path="mips2" ;;
|
|
vax*-*-*) path="vax"; extra_functions="udiv_w_sdiv" ;;
|
|
z8000x*-*-*) path="z8000x"; extra_functions="udiv_w_sdiv" ;;
|
|
z8000*-*-*) path="z8000"; extra_functions="udiv_w_sdiv" ;;
|
|
clipper*-*-*) path="clipper" ;;
|
|
*-*-*) ;;
|
|
esac
|
|
|
|
case "${target}" in
|
|
*-*-linuxaout* | *-*-linuxoldld*) config=bsd.h ;;
|
|
*-sysv* | *-solaris* | *-*-linux*) config="sysv.h" ;;
|
|
*) config="bsd.h" ;;
|
|
esac
|
|
|
|
case "${target}" in
|
|
i[3456]86*-*-*bsd* | i[3456]86*-*-linuxaout* | i[3456]86*-*-linuxoldld* | \
|
|
pentium-*-*bsd* | pentium-*-linuxaout* | pentium-*-linuxoldld* | \
|
|
pentiumpro-*-*bsd* | pentiumpro-*-linuxaout* | pentiumpro-*-linuxoldld*)
|
|
target_makefile_frag=config/t-oldgas ;;
|
|
rs6000-*-aix[456789]* | rs6000-*-aix3.2.[456789])
|
|
target_makefile_frag=config/t-pwr-aix ;;
|
|
ppc601-*-aix[456789]* | ppc601-*-aix3.2.[456789] | \
|
|
ppc60[234]*-*-aix[456789]* | ppc60[234]*-*-aix3.2.[456789] | \
|
|
powerpc*-*-aix[456789]* | powerpc*-*-aix3.2.[456789])
|
|
target_makefile_frag=config/t-ppc-aix ;;
|
|
esac
|
|
|
|
|
|
functions="${extra_functions} inlines add_n addmul_1 cmp divmod_1 \
|
|
divrem divrem_1 dump lshift mod_1 mul mul_1 mul_n random2 rshift sqrtrem \
|
|
sub_n submul_1 get_str set_str scan0 scan1 popcount hamdist gcd_1 \
|
|
pre_mod_1 perfsqr bdivmod gcd gcdext"
|
|
|
|
path="$path generic"
|
|
mpn_objects=
|
|
|
|
for fn in $functions ; do
|
|
mpn_objects="$mpn_objects $fn.o"
|
|
for dir in $path ; do
|
|
rm -f $fn.[Ssc]
|
|
if test -f $srcdir/$dir/$fn.S ; then
|
|
files="$files $dir/$fn.S"
|
|
links="$links $fn.S"
|
|
break
|
|
elif test -f $srcdir/$dir/$fn.s ; then
|
|
files="$files $dir/$fn.s"
|
|
links="$links $fn.s"
|
|
break
|
|
elif test -f $srcdir/$dir/$fn.c ; then
|
|
files="$files $dir/$fn.c"
|
|
links="$links $fn.c"
|
|
break
|
|
fi
|
|
done
|
|
done
|
|
|
|
for dir in $path ; do
|
|
rm -f gmp-mparam.h
|
|
if test -f $srcdir/$dir/gmp-mparam.h ; then
|
|
files="$files $dir/gmp-mparam.h"
|
|
links="$links gmp-mparam.h"
|
|
break
|
|
fi
|
|
done
|
|
|
|
links="sysdep.h $links"
|
|
files="$config $files"
|
|
|
|
mpn_links=$links
|
|
|
|
# post-target:
|
|
|
|
sed <Makefile >Makefile.tmp \
|
|
-e "s/MPN_LINKS = .*/MPN_LINKS =${mpn_links}/" \
|
|
-e "s/MPN_OBJECTS = .*/MPN_OBJECTS =${mpn_objects}/"
|
|
|
|
mv Makefile.tmp Makefile
|