* configure.in: match i[3-6]86-*-win32, not just i386-*-win32.
[deliverable/binutils-gdb.git] / binutils / configure.in
1 # This file is a shell script that supplies the information necessary
2 # to tailor a template configure script into the configure script
3 # appropriate for this directory. For more information, check any
4 # existing configure script.
5
6 srctrigger=ar.c
7 srcname="Binutils"
8
9 # per-host:
10
11 . ${srcdir}/../bfd/configure.host
12
13 host_makefile_frag=
14 if [ -f ${srcdir}/../bfd/config/${my_host}.mh ] ; then
15 host_makefile_frag=../bfd/config/${my_host}.mh
16 fi
17
18 # per-target:
19
20 # Canonicalize the secondary target names.
21 if [ -n "$enable_targets" ]; then
22 for targ in `echo $enable_targets | sed 's/,/ /g'`
23 do
24 result=`$configsub $targ 2>/dev/null`
25 if [ -n "$result" ]; then
26 canon_targets="$canon_targets $result"
27 else
28 # Allow targets that config.sub doesn't recognize, like "all".
29 canon_targets="$canon_targets $targ"
30 fi
31 done
32 else
33 # If our target is rs6000 _and nothing else_ then we build only nm!
34 case $target in
35 rs6000-*-lynx*) target_makefile_frag=config/rslynx ;;
36 esac
37 fi
38
39 all_targets=false
40 build_nlmconv=false
41 nlmconv_defs=
42 build_srconv=false
43 build_dlltool=false
44 dlltool_defs=
45
46 for targ in $target $canon_targets
47 do
48 bfd_target=`${config_shell} $srcdir/../bfd/config.bfd $targ`
49
50 if [ "x$bfd_target" = "xall" ]; then
51 all_targets=true
52 build_nlmconv=true
53 build_srconv=true
54 nlmconv_defs="-DNLMCONV_I386 -DNLMCONV_ALPHA -DNLMCONV_POWERPC -DNLMCONV_SPARC"
55 else
56 case $targ in
57 i[345]86*-*-netware*)
58 build_nlmconv=true
59 nlmconv_defs="$nlmconv_defs -DNLMCONV_I386"
60 ;;
61 alpha*-*-netware*)
62 build_nlmconv=true
63 nlmconv_defs="$nlmconv_defs -DNLMCONV_ALPHA"
64 ;;
65 powerpc*-*-netware*)
66 build_nlmconv=true
67 nlmconv_defs="$nlmconv_defs -DNLMCONV_POWERPC"
68 ;;
69 sparc*-*-netware*)
70 build_nlmconv=true
71 nlmconv_defs="$nlmconv_defs -DNLMCONV_SPARC"
72 ;;
73 esac
74 case $targ in
75 *-*-hms*) build_srconv=true ;;
76 esac
77 case $targ in
78 arm-*pe*)
79 build_dlltool=true;
80 dlltool_defs="$dlltool_defs -DDLLTOOL_ARM"
81 ;;
82 i[3-6]86-*pe* | i[3-6]86-*-win32)
83 build_dlltool=true;
84 dlltool_defs="$dlltool_defs -DDLLTOOL_I386"
85 ;;
86 esac
87 fi
88 done
89
90 # We don't do any links based on the target system, just makefile config.
91
92 # post-target:
93
94 rm -f Makefile.tmp Makefile.2
95 mv Makefile Makefile.tmp
96
97 if [ "x${build_nlmconv}" = "xtrue" ]; then
98 echo 'BUILD_NLMCONV = $(NLMCONV_PROG)' >> Makefile.2
99 echo "NLMCONV_DEFS = ${nlmconv_defs}" >> Makefile.2
100 fi
101
102 if [ "x${build_srconv}" = "xtrue" ]; then
103 echo 'BUILD_SRCONV = $(SRCONV_PROG)' >> Makefile.2
104 fi
105
106 if [ "x${build_dlltool}" = "xtrue" ]; then
107 echo 'BUILD_DLLTOOL = $(DLLTOOL_PROG)' >> Makefile.2
108 echo "DLLTOOL_DEFS = ${dlltool_defs}" >> Makefile.2
109 fi
110
111 if [ "x`${config_shell} $srcdir/../bfd/config.bfd $target _`" = "xyes" ]; then
112 underscore=1
113 else
114 underscore=0
115 fi
116 echo "UNDERSCORE = ${underscore}" >> Makefile.2
117
118 cat Makefile.tmp >> Makefile.2
119 rm -f Makefile.tmp
120 mv Makefile.2 Makefile
This page took 0.034515 seconds and 5 git commands to generate.