m68k)
cpu="m68k"
;;
+ microblaze)
+ cpu="microblaze"
+ ;;
mips)
cpu="mips"
;;
arm-softmmu \
cris-softmmu \
m68k-softmmu \
+microblaze-softmmu \
mips-softmmu \
mipsel-softmmu \
mips64-softmmu \
armeb-linux-user \
cris-linux-user \
m68k-linux-user \
+microblaze-linux-user \
mips-linux-user \
mipsel-linux-user \
ppc-linux-user \
##########################################
# pthread probe
+PTHREADLIBS_LIST="-lpthread -lpthreadGC2"
PTHREADLIBS=""
if test "$pthread" = yes; then
pthread=no
cat > $TMPC << EOF
#include <pthread.h>
-int main(void) { pthread_mutex_t lock; return 0; }
+int main(void) { pthread_create(0,0,0,0); return 0; }
EOF
- if $cc $ARCH_CFLAGS -o $TMPE $PTHREADLIBS $TMPC 2> /dev/null > /dev/null ; then
- pthread=yes
- PTHREADLIBS="-lpthread"
- fi
+ for pthread_lib in $PTHREADLIBS_LIST; do
+ if $cc $ARCH_CFLAGS -o $TMPE $TMPC $pthread_lib 2> /dev/null > /dev/null ; then
+ pthread=yes
+ PTHREADLIBS="$pthread_lib"
+ break
+ fi
+ done
fi
if test "$pthread" = no; then
echo "ARCH=m68k" >> $config_mak
echo "#define HOST_M68K 1" >> $config_h
;;
+ microblaze)
+ echo "ARCH=microblaze" >> $config_mak
+ echo "#define HOST_MICROBLAZE 1" >> $config_h
+ ;;
mips)
echo "ARCH=mips" >> $config_mak
echo "#define HOST_MIPS 1" >> $config_h
fi
echo "TOOLS=$tools" >> $config_mak
-test -f ${config_h}~ && cmp -s $config_h ${config_h}~ && mv ${config_h}~ $config_h
+if test -f ${config_h}~ ; then
+ if cmp -s $config_h ${config_h}~ ; then
+ mv ${config_h}~ $config_h
+ else
+ rm ${config_h}~
+ fi
+fi
+
config_host_mak=${config_mak}
for target in $target_list; do
target_bigendian="no"
[ "$target_cpu" = "armeb" ] && target_bigendian=yes
[ "$target_cpu" = "m68k" ] && target_bigendian=yes
+[ "$target_cpu" = "microblaze" ] && target_bigendian=yes
[ "$target_cpu" = "mips" ] && target_bigendian=yes
[ "$target_cpu" = "mipsn32" ] && target_bigendian=yes
[ "$target_cpu" = "mips64" ] && target_bigendian=yes
gdb_xml_files="cf-core.xml cf-fp.xml"
target_phys_bits=32
;;
- mips|mipsel)
+ microblaze)
+ echo "TARGET_ARCH=microblaze" >> $config_mak
+ echo "#define TARGET_ARCH \"microblaze\"" >> $config_h
+ echo "#define TARGET_MICROBLAZE 1" >> $config_h
+ bflt="yes"
+ target_nptl="yes"
+ target_phys_bits=32
+ ;;
+ mips|mipsel)
echo "TARGET_ARCH=mips" >> $config_mak
echo "#define TARGET_ARCH \"mips\"" >> $config_h
echo "#define TARGET_MIPS 1" >> $config_h
if test "$target_cpu" = "arm" \
-o "$target_cpu" = "armeb" \
-o "$target_cpu" = "m68k" \
+ -o "$target_cpu" = "microblaze" \
-o "$target_cpu" = "mips" \
-o "$target_cpu" = "mipsel" \
-o "$target_cpu" = "mipsn32" \