diff -aruN shujit-0.7.14/ChangeLog shujit/ChangeLog --- shujit-0.7.14/ChangeLog 2003-01-20 10:22:54.000000000 +0900 +++ shujit/ChangeLog 2003-03-20 22:32:20.000000000 +0900 @@ -1,5 +1,12 @@ $Id$ +[20030320] + +Win32 への対応作業を始めた。 +シンボルの生成方法など、基本的な作業を終えた。 +(compiler.h, code.c, code.h, compile.c, linker.c, runtime.c, stack.c, + gentable.rb, configure.in, GNUmakefile.in) + [20030120] gcc 3.2 の dead code elimination が diff -aruN shujit-0.7.14/GNUmakefile shujit/GNUmakefile --- shujit-0.7.14/GNUmakefile 2003-01-20 10:28:43.000000000 +0900 +++ shujit/GNUmakefile 2003-03-20 23:28:58.000000000 +0900 @@ -31,7 +31,7 @@ CO = /usr/bin/co RM = /bin/rm WC = /usr/bin/wc -ETAGS = no +ETAGS = /usr/bin/etags JAVA = /usr/local/java/bin/java JAVAC = /usr/local/java/bin/javac JAVAH = /usr/local/java/bin/javah @@ -55,7 +55,7 @@ COPTFLAGS = -O2 CFLAGS_OPT = CFLAGS_DBG = -g -DDEBUG -DJCOV -NOOPTCFLAGS = -pipe -fPIC ${CFLAGS_${VARIANT}} ${CFLAGS_COMMON} ${INCDIR} +NOOPTCFLAGS = -fPIC -pipe ${CFLAGS_${VARIANT}} ${CFLAGS_COMMON} ${INCDIR} CFLAGS = ${COPTFLAGS} ${NOOPTCFLAGS} LIBS = diff -aruN shujit-0.7.14/GNUmakefile.in shujit/GNUmakefile.in --- shujit-0.7.14/GNUmakefile.in 2002-01-18 23:07:58.000000000 +0900 +++ shujit/GNUmakefile.in 2003-03-20 23:28:31.000000000 +0900 @@ -55,16 +55,16 @@ COPTFLAGS = -O2 CFLAGS_OPT = CFLAGS_DBG = -g -DDEBUG -DJCOV -NOOPTCFLAGS = -pipe -fPIC ${CFLAGS_${VARIANT}} ${CFLAGS_COMMON} ${INCDIR} +NOOPTCFLAGS = @ac_cflags@ -pipe ${CFLAGS_${VARIANT}} ${CFLAGS_COMMON} ${INCDIR} CFLAGS = ${COPTFLAGS} ${NOOPTCFLAGS} LIBS = ifeq (${METAVM}, yes) -TARGET_OPT = libmetavm.so -TARGET_DBG = libmetavm_g.so +TARGET_OPT = @ac_target_metavm@ +TARGET_DBG = @ac_target_metavm_g@ else -TARGET_OPT = libshujit.so -TARGET_DBG = libshujit_g.so +TARGET_OPT = @ac_target_shujit@ +TARGET_DBG = @ac_target_shujit_g@ endif ifeq (${VARIANT}, DBG) OBJDIR = obj_g diff -aruN shujit-0.7.14/README shujit/README --- shujit-0.7.14/README 2003-01-19 23:33:06.000000000 +0900 +++ shujit/README 2003-03-20 17:39:08.000000000 +0900 @@ -13,12 +13,13 @@ Working on the following platforms is confirmed. - FreeBSD - - JDK 1.3.1 patchlevel 7, GCC 2.95.4 and FreeBSD 4.6-STABLE - - JDK 1.1.8 (ELF, V1999-11-9), GCC 2.95.4 and FreeBSD 4.6-STABLE + - JDK 1.3.1 patchlevel 8, GCC 2.95.4 and FreeBSD 4.8-PRERELEASE + - JDK 1.1.8 (ELF, V1999-11-9), GCC 2.95.4 and FreeBSD 4.8-PRERELEASE - Linux - - Blackdown JDK 1.3.1_02b, GCC 3.2 20020903, glibc 2.2.93, Linux 2.4.21-pre3 - - JDK 1.1.8v3, GCC 3.2 20020903, glibc 2.2.93 and Linux 2.4.21-pre3 + - Blackdown JDK 1.3.1_02b, GCC 3.2 20020903, glibc 2.3.2 + and Linux 2.4.21-pre4 + - JDK 1.1.8v3, GCC 3.2 20020903, glibc 2.3.2 and Linux 2.4.21-pre4 - JDK 1.1.7v1a, egcs 1.1.2, libc 5.4.38 and Linux 2.0.35 * Installation diff -aruN shujit-0.7.14/code.c shujit/code.c --- shujit-0.7.14/code.c 2003-01-20 10:20:12.000000000 +0900 +++ shujit/code.c 2003-03-20 21:57:19.000000000 +0900 @@ -130,7 +130,7 @@ DEBUG_IN;\ CB_NAME(CB, %eax); asm("pushl %eax");\ PUSH_CONSTSTR(" clazz: %s\n");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $8,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -146,7 +146,7 @@ CB_NAME(%edi, %edi);\ asm("pushl %edi");\ PUSH_CONSTSTR(" %s#%s\n");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $12,%esp");\ FFLUSH;\ asm(LABEL "_done:");\ @@ -161,7 +161,7 @@ asm("pushl %edi");\ asm("pushl " #OBJ);\ PUSH_CONSTSTR(" obj: 0x%08x mt: 0x%08x\n");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $12,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -176,7 +176,7 @@ "pushl " #REG "\n\t"\ "pushl " #REG);\ PUSH_CONSTSTR(" 0x%08x %d %g\n");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $20,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -189,7 +189,7 @@ "pushl " #HREG "\n\tpushl " #LREG "\n\t"\ "pushl " #HREG "\n\tpushl " #LREG);\ PUSH_CONSTSTR(" 0x%016llx %lld %g\n");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $28,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -215,7 +215,7 @@ "subl $4,%esp\n\tfstpl (%esp)\n\t"\ "pushl " #OPTOP1_REG "\n\tpushl " #OPTOP1_REG);\ PUSH_CONSTSTR(" optop[-1]: 0x%08x %d %g, optop[-2]: 0x%08x %d %g\n");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $36,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -415,7 +415,7 @@ CB_NAME(%eax, %eax); // break %edi asm("pushl %eax"); PUSH_CONSTSTR(" %s#%s\n"); - asm("call " SYMBOL(printf) "@PLT\n\t" + asm("call " FUNCTION(printf) "\n\t" "addl $12,%esp"); FFLUSH; asm("methodhead_name_done:"); @@ -424,7 +424,7 @@ asm("pushl %esi\n\t" "pushl %ebp"); PUSH_CONSTSTR(" ebp: %x\n old var base: %x\n"); - asm("call " SYMBOL(printf) "@PLT\n\t" + asm("call " FUNCTION(printf) "\n\t" "addl $12,%esp"); FFLUSH; @@ -435,7 +435,7 @@ asm("movsbl " EE_EXCEPTIONKIND(%edi) ",%edi\n\t" "pushl %edi"); PUSH_CONSTSTR(" excKind: %d\n remote addr: 0x%x\n"); - asm("call " SYMBOL(printf) "@PLT\n\t" + asm("call " FUNCTION(printf) "\n\t" "addl $12,%esp"); FFLUSH; # endif @@ -450,7 +450,7 @@ DEBUG_IN; asm("pushl %esi"); PUSH_CONSTSTR(" var base: 0x%08x\n"); - asm("call " SYMBOL(printf) "@PLT\n\t" + asm("call " FUNCTION(printf) "\n\t" "addl $8,%esp"); FFLUSH; DEBUG_OUT; @@ -507,7 +507,7 @@ // exception handler // now, eax,edx may be ename,DetailMessage CODE(opc_exc_handler, exc_handler, STANY, STSTA, OPC_NONE) { - asm("call " SYMBOL(exceptionHandler) "@PLT"); + asm("call " FUNCTION(exceptionHandler)); } @@ -524,7 +524,7 @@ asm("movl %0,%%edi\n\t" /* edi = ee */\ "pushl %%edi" : : "m" (ee)); /* push edi */\ \ - asm("call " SYMBOL(METAVM_FUNCNAME) "@PLT\n\t"\ + asm("call " FUNCTION(METAVM_FUNCNAME) "\n\t"\ "popl %edi\n\t" /* edi = ee */\ "addl $4,%esp");\ \ @@ -533,7 +533,7 @@ JUMP_IF_EXC_HASNT_OCCURRED(%edi /* is ee */, LABEL "_done");\ DEBUG_IN;\ PUSH_CONSTSTR("METAVM_MONITOR exc. occurred.\n");\ -asm("call " SYMBOL(printf) "@PLT\n\t"\ +asm("call " FUNCTION(printf) "\n\t"\ "addl $4,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -547,13 +547,17 @@ # define CALL_MONITOR(MON, FUNCNAME) \ asm("pushl " #MON);\ asm("pushl %0" : : "m" (ee)); /* ee */\ - asm("call " SYMBOL(FUNCNAME) "2@PLT\n\t"\ + asm("call " FUNCTION(FUNCNAME) "\n\t"\ "addl $8,%esp") +# define CALL_MONITORENTER(MON) CALL_MONITOR(MON, monitorEnter2) +# define CALL_MONITOREXIT(MON) CALL_MONITOR(MON, monitorExit2) #else # define CALL_MONITOR(MON, FUNCNAME) \ asm("pushl " #MON "\n\t"\ - "call " SYMBOL(FUNCNAME) "@PLT\n\t"\ + "call " FUNCTION(monitorEnter) "\n\t"\ "addl $4,%esp") +# define CALL_MONITORENTER(MON) CALL_MONITOR(MON, monitorEnter) +# define CALL_MONITOREXIT(MON) CALL_MONITOR(MON, monitorExit) #endif // JDK_VER CODE(opc_sync_obj_enter, sync_obj_enter, STANY, STSTA, OPC_THROW) { @@ -564,7 +568,7 @@ DEBUG_IN; asm("pushl %esi\n\tpushl %eax"); PUSH_CONSTSTR(" obj: 0x%x @ 0x%x\n"); - asm("call " SYMBOL(printf) "@PLT\n\t" + asm("call " FUNCTION(printf) "\n\t" "addl $12,%esp"); FFLUSH; DEBUG_OUT; @@ -578,7 +582,7 @@ #endif METAVM_MONITOR(%eax, proxy_monitorenter, "sync_obj_enter", 0); OBJ_MONITOR(%eax); - CALL_MONITOR(%eax, monitorEnter); + CALL_MONITORENTER(%eax); asm("sync_obj_enter_done:"); } @@ -594,7 +598,7 @@ asm("movl %eax," FRAME_MONITOR(%edi)); #endif OBJ_MONITOR(%eax); - CALL_MONITOR(%eax, monitorEnter); + CALL_MONITORENTER(%eax); } @@ -609,7 +613,7 @@ DEBUG_IN; asm("pushl %esi\n\tpushl %eax"); PUSH_CONSTSTR(" obj: 0x%x @ 0x%x\n"); - asm("call " SYMBOL(printf) "@PLT\n\t" + asm("call " FUNCTION(printf) "\n\t" "addl $12,%esp"); FFLUSH; DEBUG_OUT; @@ -617,7 +621,7 @@ #endif METAVM_MONITOR(%eax, proxy_monitorexit, "sync_obj_exit", 0); OBJ_MONITOR(%eax); - CALL_MONITOR(%eax, monitorExit); + CALL_MONITOREXIT(%eax); asm("sync_obj_exit_done:"); FUNCCALL_OUT(2); @@ -631,7 +635,7 @@ // monitorExit(obj_monitor(o)) asm("movl $" STR(CONST) ",%eax"); // eax = clazz OBJ_MONITOR(%eax); - CALL_MONITOR(%eax, monitorExit); + CALL_MONITOREXIT(%eax); FUNCCALL_OUT(2); } @@ -644,7 +648,7 @@ DEBUG_IN; asm("pushl %edi"); PUSH_CONSTSTR(" ee: 0x%x\n"); - asm("call " SYMBOL(printf) "@PLT\n\t" + asm("call " FUNCTION(printf) "\n\t" "addl $8,%esp"); FFLUSH; DEBUG_OUT; @@ -1036,7 +1040,7 @@ "pushl " #VAL "\n\t"\ "pushl $" STR(CONST));\ PUSH_CONSTSTR(" [%d] 0x%08x %d %g\n");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $24,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -1082,7 +1086,7 @@ asm("subl $8,%esp\n\t" "fstl (%esp)"); PUSH_CONSTSTR(" %g\n"); - asm("call " SYMBOL(printf) "@PLT\n\t" + asm("call " FUNCTION(printf) "\n\t" "addl $12,%esp"); FFLUSH; DEBUG_OUT; @@ -1104,7 +1108,7 @@ "movl $" STR(CONST) ",%eax\n\t"\ "pushl %eax");\ PUSH_CONSTSTR(" var[%d]: 0x%016llx, %lld, %g\n");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $32,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -1159,7 +1163,7 @@ asm("subl $8,%esp\n\t" "fstl (%esp)"); PUSH_CONSTSTR(" %g\n"); - asm("call " SYMBOL(printf) "@PLT\n\t" + asm("call " FUNCTION(printf) "\n\t" "addl $12,%esp"); FFLUSH; DEBUG_OUT; @@ -1190,7 +1194,7 @@ DEBUG_IN;\ asm("pushl " #INDEX);\ PUSH_CONSTSTR(" index: %d\n");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $8,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -1200,7 +1204,7 @@ DEBUG_IN;\ asm("pushl " #LEN);\ PUSH_CONSTSTR(" length: %d\n");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $8,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -1277,10 +1281,10 @@ asm("movl $" STR(CONST) ",%edi");\ asm("testl %edi,%edi\n\t"\ "jnz " LABEL "_obj\n\t"\ - "call " SYMBOL(FUNC32) "@PLT\n\t"\ + "call " FUNCTION(FUNC32) "\n\t"\ "jmp " LABEL "_remoteget_done\n\t"\ LABEL "_obj:\n\t"\ - "call " SYMBOL(FUNCOBJ) "@PLT\n\t"\ + "call " FUNCTION(FUNCOBJ) "\n\t"\ LABEL "_remoteget_done:");\ asm("popl %edi\n\t" /* edi = ee */\ "addl $8,%esp");\ @@ -1292,7 +1296,7 @@ JUMP_IF_EXC_HASNT_OCCURRED(%edi /* is ee */, LABEL "_done");\ DEBUG_IN;\ PUSH_CONSTSTR("METAVM_READ exc. occurred.\n");\ -asm("call " SYMBOL(printf) "@PLT\n\t"\ +asm("call " FUNCTION(printf) "\n\t"\ "addl $4,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -1365,7 +1369,7 @@ "pushl " #HANDLE); /* obj (Proxy) */\ asm("pushl %0" : : "m" (ee)); /* ee */\ \ - asm("call " SYMBOL(FUNC) "@PLT\n\t"\ + asm("call " FUNCTION(FUNC) "\n\t"\ "movl %edx," #TGT_HIGH "\n\t"\ "popl %edi\n\t" /* edi = ee */\ "movl %eax," #TGT_LOW "\n\t"\ @@ -1374,7 +1378,7 @@ JUMP_IF_EXC_HASNT_OCCURRED(%edi /* is ee */, LABEL "_done");\ DEBUG_IN;\ PUSH_CONSTSTR("METAVM_READ2 exc. occurred.\n");\ -asm("call " SYMBOL(printf) "@PLT\n\t"\ +asm("call " FUNCTION(printf) "\n\t"\ "addl $4,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -1607,10 +1611,10 @@ asm("movl $" STR(CONST) ",%edi");\ asm("testl %edi,%edi\n\t"\ "jnz " LABEL "_obj\n\t"\ - "call " SYMBOL(FUNC32) "@PLT\n\t"\ + "call " FUNCTION(FUNC32) "\n\t"\ "jmp " LABEL "_return\n\t"\ LABEL "_obj:\n\t"\ - "call " SYMBOL(FUNCOBJ) "@PLT");\ + "call " FUNCTION(FUNCOBJ));\ asm(LABEL "_return:\n\t"\ "popl %edi\n\t" /* edi = ee */\ "addl $12,%esp");\ @@ -1620,7 +1624,7 @@ JUMP_IF_EXC_HASNT_OCCURRED(%edi /* is ee */, LABEL "_done");\ DEBUG_IN;\ PUSH_CONSTSTR("METAVM_WRITE exc. occurred.\n");\ -asm("call " SYMBOL(printf) "@PLT\n\t"\ +asm("call " FUNCTION(printf) "\n\t"\ "addl $4,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -1680,7 +1684,7 @@ DEBUG_IN;\ asm("pushl %edi\n\tpushl %ecx\n\tpushl %edx");\ PUSH_CONSTSTR(" edx: 0x%08x, ecx: 0x%08x, edi: 0x%08x\n");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $16,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -1707,7 +1711,7 @@ /* push array->body[obj_length(..)] */\ "pushl %eax\n\t" /* push value */\ /* call is_instance_of(value, array->body[eax], ee) */\ - "call " SYMBOL(is_instance_of) "@PLT\n\t"\ + "call " FUNCTION(is_instance_of) "\n\t"\ "addl $12,%esp");\ /* if (eax) goto ... */\ asm("testl %eax,%eax");\ @@ -1757,7 +1761,7 @@ "pushl " #HANDLE); /* obj (Proxy) */\ asm("pushl %0" : : "m" (ee)); /* ee */\ \ - asm("call " SYMBOL(FUNC) "@PLT\n\t"\ + asm("call " FUNCTION(FUNC) "\n\t"\ "popl %edi\n\t" /* edi = ee */\ "addl $16,%esp");\ \ @@ -1766,7 +1770,7 @@ JUMP_IF_EXC_HASNT_OCCURRED(%edi /* is ee */, LABEL "_done");\ DEBUG_IN;\ PUSH_CONSTSTR("METAVM_WRITE2 exc. occurred.\n");\ -asm("call " SYMBOL(printf) "@PLT\n\t"\ +asm("call " FUNCTION(printf) "\n\t"\ "addl $4,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -2107,7 +2111,7 @@ asm("pushl " #VAL2 "\n\t"\ "pushl " #VAL1);\ PUSH_CONSTSTR(" %d " SYM " %d\n");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $12,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -2233,7 +2237,7 @@ "pushl " #VAL1_HIGH "\n\tpushl " #VAL1_LOW "\n\t"\ "pushl " #VAL1_HIGH "\n\tpushl " #VAL1_LOW);\ PUSH_CONSTSTR(" %lld(0x%016llx) " SYM " %lld(0x%016llx)\n");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $36,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -2323,7 +2327,7 @@ "pushl " #OPTOP1_REG "\n\t"\ "pushl %edi\n\tpushl %eax");\ PUSH_CONSTSTR(" %lld " SYM " %lld\n");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $20,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -2387,7 +2391,7 @@ "pushl " #OPTOP1_REG "\n\t" /* push v2[0:31] */\ "pushl %edi\n\t" /* push v1[32:63] */\ "pushl %eax\n\t" /* push v1[0:31] */\ - "call " ROP "@PLT\n\t"\ + "call " ROP "\n\t"\ "addl $28,%esp");\ asm(/* movl %edx,%edx */\ "movl %eax,%ecx");\ @@ -2433,8 +2437,8 @@ ARITH_LONG_CALL_ST24(ROP, %edx, %ecx, SYM);\ } - CODE_ARITH_LONG_TEST(div, SYMBOL(__divdi3), "/"); - CODE_ARITH_LONG_TEST(rem, SYMBOL(__moddi3), "mod"); + CODE_ARITH_LONG_TEST(div, FUNCTION(__divdi3), "/"); + CODE_ARITH_LONG_TEST(rem, FUNCTION(__moddi3), "mod"); // fadd, fsub, fmul, fdiv @@ -2451,7 +2455,7 @@ "fstpl 8(%esp)\n\t"\ "fstpl (%esp)");\ PUSH_CONSTSTR(" %g, %g\n");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $20,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -2463,7 +2467,7 @@ asm("subl $8,%esp\n\t"\ "fstpl (%esp)");\ PUSH_CONSTSTR(" %g\n");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $12,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -2624,7 +2628,7 @@ asm("pushl 4(%edi)\n\tpushl (%edi)\n\t"\ "pushl 12(%edi)\n\tpushl 8(%edi)");\ PUSH_CONSTSTR(" %g, %g\n");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $20,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -2636,7 +2640,7 @@ DEBUG_IN;\ asm("pushl %eax\n\tpushl %edi");\ PUSH_CONSTSTR(" %g\n");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $12,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -2793,7 +2797,7 @@ asm("subl $16,%esp"); asm("fstpl (%esp)\n\t" // stack top = optop[-2] (value1) "fstpl 8(%esp)\n\t" // stack top-1 = optop[-1] (value2) - "call " SYMBOL(fmod) "@PLT\n\t" + "call " FUNCTION(fmod) "\n\t" "addl $16,%esp"); FUNCCALL_OUT(0); asm("addl $4,%esp"); @@ -2814,7 +2818,7 @@ "pushl " #OPTOP1_REG "\n\t" /* push v2[0:31] */\ "pushl %edi\n\t" /* push v1[32:63] */\ "pushl %eax\n\t" /* push v1[0:31] */\ - "call " SYMBOL(fmod) "@PLT\n\t"\ + "call " FUNCTION(fmod) "\n\t"\ "addl $16,%esp");\ FUNCCALL_OUT(0);\ asm("subl $8,%esp"); @@ -3032,7 +3036,7 @@ asm("pushl " STR(CONST) "(%esi)\n\t"\ "pushl $" STR(CONST));\ PUSH_CONSTSTR(" var[%d] %d");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $12,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -3044,7 +3048,7 @@ asm("pushl " STR(CONST) "(%esi)\n\t"\ "pushl $" STR(CONST));\ PUSH_CONSTSTR(" + %d = %d\n");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $12,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -3154,7 +3158,7 @@ asm("subl $8,%esp\n\t"\ "fstl (%esp)");\ PUSH_CONSTSTR(" %g\n");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $12,%esp");\ DEBUG_OUT;\ } @@ -3164,7 +3168,7 @@ asm("pushl $0\n"\ "fstcw (%esp)");\ PUSH_CONSTSTR(" FPU cw: 0x%x\n");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $8,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -3385,7 +3389,7 @@ "fstpl 8(%esp)\n\t"\ "fstpl (%esp)");\ PUSH_CONSTSTR(" %g %g\n");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $20,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -3400,7 +3404,7 @@ asm("pushl %eax\n\tpushl %edi\n\t"\ "pushl %edx\n\tpushl %ecx");\ PUSH_CONSTSTR(" %g %g\n");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $20,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -3520,7 +3524,7 @@ asm("pushl " #OPTOP1_REG "\n\t"\ "pushl " #OPTOP2_REG);\ PUSH_CONSTSTR(" %d %d\n");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $12,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -3578,7 +3582,7 @@ DEBUG_IN;\ asm("pushl " #REG);\ PUSH_CONSTSTR(" push 0x%08x\n");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $8,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -3636,7 +3640,7 @@ DEBUG_IN;\ asm("pushl %eax\n\tpushl %edi\n\tpushl " #INDEX);\ PUSH_CONSTSTR(" index: %d [%d:%d]\n");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $16,%esp");\ DEBUG_OUT;\ } @@ -3645,7 +3649,7 @@ DEBUG_IN;\ asm("pushl " #OFF "\n\tpushl " #OFF);\ PUSH_CONSTSTR(" native off: 0x%08x(%d)\n");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $12,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -3711,7 +3715,7 @@ DEBUG_IN;\ asm("pushl %eax\n\tpushl " #KEY);\ PUSH_CONSTSTR(" key: %d, npairs: %d\n");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $12,%esp");\ DEBUG_OUT;\ } @@ -3722,7 +3726,7 @@ "pushl 4(%edi)\n\tpushl 4(%edi)\n\t"\ "pushl (%edi)");\ PUSH_CONSTSTR(" match: %d, target offset: 0x%08x(%d), trampoline code: 0x%08x\n");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $20,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -3948,7 +3952,7 @@ asm("pushl %edx\n\tpushl %ecx"); /* save */\ asm("pushl %edi");\ asm("pushl %0" : : "m" (ee));\ - asm("call " SYMBOL(once_InitClass) "@PLT\n\t"\ + asm("call " FUNCTION(once_InitClass) "\n\t"\ "addl $8,%esp");\ asm("popl %ecx\n\tpopl %edx"); /* restore */\ \ @@ -4155,7 +4159,7 @@ asm("pushl %eax\n\tpushl %ecx"); /* save */\ asm("pushl %edx");\ asm("pushl %0" : : "m" (ee)); /* ee */\ - asm("call " SYMBOL(once_InitClass) "@PLT\n\t"\ + asm("call " FUNCTION(once_InitClass) "\n\t"\ "addl $4,%esp");\ asm("popl %edx\n\tpopl %ecx"); /* restore */\ \ @@ -4193,7 +4197,7 @@ asm("movl -4(%ebp),%eax"); // eax = bytepcoff asm("pushl %eax\n\tpushl %eax"); PUSH_CONSTSTR(" pc: %d(0x%x)\n"); - asm("call " SYMBOL(printf) "@PLT\n\t" + asm("call " FUNCTION(printf) "\n\t" "addl $12,%esp"); FFLUSH; DEBUG_OUT; @@ -4235,7 +4239,7 @@ asm("jmp inv_core_invoke_done");\ \ asm("inv_core_invoke_normal:");\ - asm("call " SYMBOL(invocationHelper) "@PLT");\ + asm("call " FUNCTION(invocationHelper));\ asm("inv_core_invoke_done:") #else // DIRECT_INVOCATION # define INVCORE_INVOKE \ @@ -4245,7 +4249,7 @@ asm("addl -4(%ebp),%ecx"); /* ecx = bytepcoff */\ asm("movl %ecx," FRAME_LASTPC(%edi));\ \ - asm("call " SYMBOL(invocationHelper) "@PLT") + asm("call " FUNCTION(invocationHelper)) #endif // DIRECT_INVOCATION @@ -4255,7 +4259,7 @@ DEBUG_IN;\ asm("pushl %eax");\ PUSH_CONSTSTR(" invocationHelper() returns: %d\n");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $8,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -4420,7 +4424,7 @@ "pushl %eax\n\t" // methodblock "pushl %edx"); // obj (Proxy) asm("pushl %0" : : "m" (ee)); // ee - asm("call " SYMBOL(proxy_invoke) "@PLT\n\t" + asm("call " FUNCTION(proxy_invoke) "\n\t" "addl $16,%esp"); asm(".byte 0xe9\n\t.long " STR(CONST)); // jump to invoke_core_done @@ -4527,7 +4531,7 @@ "pushl $" STR(CONST) "\n\t" // imethod "pushl %0\n\t" // ee "pushl %%edx" : : "m" (ee)); // obj, save - asm("call " SYMBOL(getInterfaceMethod) "@PLT\n\t" + asm("call " FUNCTION(getInterfaceMethod) "\n\t" // here code is patched with `INT 3' if PATCH_WITH_SIGTRAP is defined "popl %edx\n\t" // restore #ifdef INVINTF_INLINE_CACHE @@ -4620,7 +4624,7 @@ DEBUG_IN; asm("pushl %esi"); PUSH_CONSTSTR(" saved var base: %x\n"); - asm("call " SYMBOL(printf) "@PLT\n\t" + asm("call " FUNCTION(printf) "\n\t" "addl $8,%esp"); DEBUG_OUT; } @@ -4640,7 +4644,7 @@ DEBUG_IN; asm("pushl %esi"); PUSH_CONSTSTR(" restored var base: %x\n"); - asm("call " SYMBOL(printf) "@PLT\n\t" + asm("call " FUNCTION(printf) "\n\t" "addl $8,%esp"); DEBUG_OUT; } @@ -4677,7 +4681,7 @@ FUNCCALL_IN(STATE);\ asm("pushl " #CB_REG "\n\t"\ "pushl %edi\n\t"\ - "call " SYMBOL(isByValue) "@PLT");\ + "call " FUNCTION(isByValue));\ asm("popl %edi\n\t"\ "popl " #CB_REG);\ FUNCCALL_OUT(STATE);\ @@ -4694,7 +4698,7 @@ "pushl %eax\n\t"\ /* ee->current_frame->current_method->fb.clazz */\ "pushl %edi\n\t" /* ee */\ - "call " SYMBOL(proxy_new) "@PLT\n\t"\ + "call " FUNCTION(proxy_new) "\n\t"\ "popl %edi\n\t" /* edi = ee */\ "addl $12,%esp");\ FUNCCALL_OUT(STATE);\ @@ -4702,7 +4706,7 @@ JUMP_IF_EXC_HASNT_OCCURRED(%edi /* is ee */, LABEL "_done");\ DEBUG_IN;\ PUSH_CONSTSTR("METAVM_NEW exc. occurred.\n");\ -asm("call " SYMBOL(printf) "@PLT\n\t"\ +asm("call " FUNCTION(printf) "\n\t"\ "addl $4,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -4730,7 +4734,7 @@ "pushl %%edi" : : "m" (mb)); /* mb->fb.clazz */\ asm("pushl " #CB_REG);\ asm("pushl %0" : : "m" (ee));\ - asm("call " SYMBOL(once_InitClass) "@PLT\n\t"\ + asm("call " FUNCTION(once_InitClass) "\n\t"\ "addl $12,%esp");\ \ asm("popl %ecx\n\tpopl %edx"); /* restore CB_REG */\ @@ -4766,7 +4770,7 @@ asm("pushl %0" : : "m" (ee)); /* ee */\ asm("pushl $0\n\t" /* pc */\ "pushl " #CB_REG "\n\t"\ - "call " SYMBOL(newobject) "@PLT\n\t"\ + "call " FUNCTION(newobject) "\n\t"\ "addl $12,%esp");\ FUNCCALL_OUT(STATE);\ OBJ_DEBUG(%eax);\ @@ -4811,7 +4815,7 @@ DEBUG_IN;\ asm("pushl " #COUNT "\n\tpushl " #TYPE);\ PUSH_CONSTSTR(" type: 0x%x, count: %d\n");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $12,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -4841,7 +4845,7 @@ "pushl %eax\n\t"\ /* ee->current_frame->current_method->fb.clazz */\ "pushl %edi\n\t" /* ee */\ - "call " SYMBOL(proxy_newarray) "@PLT\n\t"\ + "call " FUNCTION(proxy_newarray) "\n\t"\ "popl %edi\n\t" /* edi = ee */\ "addl $16,%esp");\ FUNCCALL_OUT(STATE);\ @@ -4849,7 +4853,7 @@ JUMP_IF_EXC_HASNT_OCCURRED(%edi /* is ee */, LABEL "_done");\ DEBUG_IN;\ PUSH_CONSTSTR("METAVM_NEWARRAY exc. occurred.\n");\ -asm("call " SYMBOL(printf) "@PLT\n\t"\ +asm("call " FUNCTION(printf) "\n\t"\ "addl $4,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -4923,7 +4927,7 @@ "pushl %eax\n\t"\ /* ee->current_frame->current_method->fb.clazz */\ "pushl %edi\n\t" /* ee */\ - "call " SYMBOL(proxy_anewarray) "@PLT\n\t"\ + "call " FUNCTION(proxy_anewarray) "\n\t"\ "popl %edi\n\t" /* edi = ee */\ "addl $16,%esp");\ FUNCCALL_OUT(STATE);\ @@ -4931,7 +4935,7 @@ JUMP_IF_EXC_HASNT_OCCURRED(%edi /* is ee */, LABEL "_done");\ DEBUG_IN;\ PUSH_CONSTSTR("METAVM_ANEWARRAY exc. occurred.\n");\ -asm("call " SYMBOL(printf) "@PLT\n\t"\ +asm("call " FUNCTION(printf) "\n\t"\ "addl $4,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -4988,7 +4992,7 @@ FUNCCALL_IN(STATE);\ asm("pushl " #HANDLE);\ asm("pushl %0" : : "m" (ee)); /* ee */\ - asm("call " SYMBOL(proxy_arraylength) "@PLT\n\t"\ + asm("call " FUNCTION(proxy_arraylength) "\n\t"\ "movl %eax," #DST "\n\t"\ "addl $8,%esp");\ FUNCCALL_OUT(STATE);\ @@ -5078,7 +5082,7 @@ # define METAVM_CHECKCAST(OPTOP1_REG, LABEL, STATE) \ FUNCCALL_IN(STATE);\ asm("pushl %eax\n\t" /* cb */\ - "call " SYMBOL(isCheckPassType) "@PLT\n\t"\ + "call " FUNCTION(isCheckPassType) "\n\t"\ "testl %eax,%eax\n\t"\ "popl %eax");\ FUNCCALL_OUT(STATE);\ @@ -5098,7 +5102,7 @@ asm("pushl %0" : : "m" (ee)); /* ee */\ asm("pushl %eax\n\t" /* cb */\ "pushl %edi\n\t"\ - "call " SYMBOL(is_subclass_of) "@PLT\n\t"\ + "call " FUNCTION(is_subclass_of) "\n\t"\ "addl $12,%esp");\ FUNCCALL_OUT(STATE);\ \ @@ -5121,7 +5125,7 @@ asm("testl %eax,%eax\n\t"\ "jnz " LABEL "_cc_debug_not_null");\ PUSH_CONSTSTR(" methodtable is null\n");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $8,%esp\n\t"\ "jmp " LABEL "_cc_debug_done");\ \ @@ -5130,7 +5134,7 @@ CB_NAME(%eax, %eax);\ asm("pushl %eax");\ PUSH_CONSTSTR(" %s instanceof %s\n");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $12,%esp");\ \ asm(LABEL "_cc_debug_done:");\ @@ -5163,7 +5167,7 @@ asm("pushl %0" : : "m" (ee)); /* ee */\ asm("pushl %eax\n\t" /* cb */\ "pushl " #HANDLE "\n\t"\ - "call " SYMBOL(is_instance_of) "@PLT\n\t"\ + "call " FUNCTION(is_instance_of) "\n\t"\ "popl " #HANDLE "\n\t"\ "addl $8,%esp");\ FUNCCALL_OUT(STATE);\ @@ -5186,7 +5190,7 @@ asm("pushl %0" : : "m" (ee)); /* ee */\ asm("pushl %eax\n\t" /* cb */\ "pushl " #HANDLE "\n\t"\ - "call " SYMBOL(is_instance_of) "@PLT\n\t"\ + "call " FUNCTION(is_instance_of) "\n\t"\ "popl " #HANDLE "\n\t"\ "addl $8,%esp");\ FUNCCALL_OUT(STATE);\ @@ -5222,7 +5226,7 @@ # define METAVM_INSTANCEOF(OPTOP1_REG, LABEL, STATE) \ FUNCCALL_IN(STATE);\ asm("pushl %eax\n\t" /* cb */\ - "call " SYMBOL(isCheckPassType) "@PLT\n\t"\ + "call " FUNCTION(isCheckPassType) "\n\t"\ "testl %eax,%eax\n\t"\ "popl %eax");\ FUNCCALL_OUT(STATE);\ @@ -5242,7 +5246,7 @@ asm("pushl %0" : : "m" (ee)); /* ee */\ asm("pushl %eax\n\t" /* cb */\ "pushl %edi\n\t"\ - "call " SYMBOL(is_subclass_of) "@PLT\n\t"\ + "call " FUNCTION(is_subclass_of) "\n\t"\ "addl $12,%esp");\ FUNCCALL_OUT(STATE);\ \ @@ -5270,7 +5274,7 @@ asm("pushl %0" : : "m" (ee)); /* ee */\ asm("pushl %eax\n\t" /* cb */\ "pushl " #OPTOP1_REG "\n\t"\ - "call " SYMBOL(is_instance_of) "@PLT\n\t"\ + "call " FUNCTION(is_instance_of) "\n\t"\ "addl $12,%esp");\ asm("movl %eax," #OPTOP1_REG);\ FUNCCALL_OUT(STATE);\ @@ -5300,7 +5304,7 @@ if (runtime_debug) {\ DEBUG_IN;\ PUSH_CONSTSTR(" monitor*() done.\n");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $4,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -5344,8 +5348,8 @@ } #if JDK_VER >= 12 - CODE_MONITOR(monitorenter, monitorEnter, proxy_monitorenter); - CODE_MONITOR(monitorexit, monitorExit, proxy_monitorexit); + CODE_MONITOR(monitorenter, monitorEnter2, proxy_monitorenter); + CODE_MONITOR(monitorexit, monitorExit2, proxy_monitorexit); #else CODE_MONITOR(monitorenter, monitorEnter, proxy_monitorenter); CODE_MONITOR(monitorexit, monitorExit, proxy_monitorexit); @@ -5367,11 +5371,11 @@ #ifdef RUNTIME_DEBUG # define MULTIANEWARRAY_FUNC \ asm("pushl %0" : : "m" (runtime_debug));\ - asm("call " SYMBOL(multianewarray) "@PLT\n\t"\ + asm("call " FUNCTION(multianewarray) "\n\t"\ "addl $20,%esp") #else # define MULTIANEWARRAY_FUNC \ - asm("call " SYMBOL(multianewarray) "@PLT\n\t"\ + asm("call " FUNCTION(multianewarray) "\n\t"\ "addl $16,%esp") #endif @@ -5399,7 +5403,7 @@ "pushl %eax\n\t"\ /* ee->current_frame->current_method->fb.clazz */\ "pushl %edi\n\t" /* ee */\ - "call " SYMBOL(proxy_multianewarray) "@PLT\n\t"\ + "call " FUNCTION(proxy_multianewarray) "\n\t"\ "popl %edi\n\t" /* edi = ee */\ "addl $20,%esp");\ \ @@ -5409,7 +5413,7 @@ JUMP_IF_EXC_HASNT_OCCURRED(%edi /* is ee */, LABEL "_done");\ DEBUG_IN;\ PUSH_CONSTSTR("METAVM_MULTIANEWARRAY exc. occurred.\n");\ -asm("call " SYMBOL(printf) "@PLT\n\t"\ +asm("call " FUNCTION(printf) "\n\t"\ "addl $4,%esp");\ FFLUSH;\ DEBUG_OUT;\ @@ -5521,7 +5525,7 @@ asm("pushl %0" : : "m" (ee)); /* ee */\ asm("pushl $0\n\t" /* pc */\ "pushl $" STR(CONST) "\n\t"\ - "call " SYMBOL(newobject) "@PLT\n\t"\ + "call " FUNCTION(newobject) "\n\t"\ "addl $12,%esp");\ FUNCCALL_OUT(STATE);\ asm("movl %eax," #DST_REG) @@ -5569,7 +5573,7 @@ #define JMATH_DIRECT_ST0(ROP) \ asm("fldl (%esp)\n\t" ROP "\n\tfstpl (%esp)") #define JMATH_FUNCCALL_ST0(FUNC) \ - asm("call " SYMBOL(FUNC) "@PLT\n\t"\ + asm("call " FUNCTION(FUNC) "\n\t"\ "fstpl (%esp)") #ifdef USE_SSE2 @@ -5842,7 +5846,7 @@ if (runtime_debug) { DEBUG_IN; PUSH_CONSTSTR("exceptionHandler called.\n"); - asm("call " SYMBOL(printf) "@PLT\n\t" + asm("call " FUNCTION(printf) "\n\t" "addl $4,%esp"); FFLUSH; DEBUG_OUT; @@ -5866,7 +5870,7 @@ DEBUG_IN; asm("pushl %eax"); PUSH_CONSTSTR("exc ID: %d\n"); - asm("call " SYMBOL(printf) "@PLT\n\t" + asm("call " FUNCTION(printf) "\n\t" "addl $8,%esp"); FFLUSH; DEBUG_OUT; @@ -5876,7 +5880,7 @@ // eax = signal_name[eax] asm("pushl %%eax\n\t" // eax should be (char *) ename "pushl %0\n\t" - "call " SYMBOL(SignalError) "@PLT\n\t" + "call " FUNCTION(SignalError) "\n\t" "addl $12,%%esp" : : "m" (ee)); asm("exc_new_done:"); @@ -5897,7 +5901,7 @@ "pushl %0\n\t" "pushl %1" : : "m" (mb), "m" (ee)); - asm("call " SYMBOL(searchCatchFrame) "@PLT"); + asm("call " FUNCTION(searchCatchFrame)); #ifdef RUNTIME_DEBUG asm("addl $16,%esp"); #else @@ -5936,7 +5940,7 @@ DEBUG_IN; asm("pushl %ecx"); PUSH_CONSTSTR(" exc handler state: %d\n"); - asm("call " SYMBOL(printf) "@PLT\n\t" + asm("call " FUNCTION(printf) "\n\t" "addl $8,%esp"); FFLUSH; DEBUG_OUT; @@ -5955,7 +5959,7 @@ DEBUG_IN; asm("pushl %edx"); PUSH_CONSTSTR(" st1 edx: %x\n"); - asm("call " SYMBOL(printf) "@PLT\n\t" + asm("call " FUNCTION(printf) "\n\t" "addl $8,%esp"); DEBUG_OUT; } @@ -5970,7 +5974,7 @@ DEBUG_IN; asm("pushl %ecx"); PUSH_CONSTSTR(" st3 ecx: %x\n"); - asm("call " SYMBOL(printf) "@PLT\n\t" + asm("call " FUNCTION(printf) "\n\t" "addl $8,%esp"); FFLUSH; DEBUG_OUT; @@ -5987,7 +5991,7 @@ DEBUG_IN; asm("pushl %ecx"); PUSH_CONSTSTR(" st2 ecx: %x\n"); - asm("call " SYMBOL(printf) "@PLT\n\t" + asm("call " FUNCTION(printf) "\n\t" "addl $8,%esp"); FFLUSH; DEBUG_OUT; @@ -6004,7 +6008,7 @@ DEBUG_IN; asm("pushl %edx"); PUSH_CONSTSTR(" st4 edx: %x\n"); - asm("call " SYMBOL(printf) "@PLT\n\t" + asm("call " FUNCTION(printf) "\n\t" "addl $8,%esp"); FFLUSH; DEBUG_OUT; diff -aruN shujit-0.7.14/code.h shujit/code.h --- shujit-0.7.14/code.h 2003-01-20 09:58:38.000000000 +0900 +++ shujit/code.h 2003-03-20 21:48:11.000000000 +0900 @@ -2,7 +2,7 @@ This file is part of shuJIT, Just In Time compiler for Sun Java Virtual Machine. - Copyright (C) 1998,1999,2000,2001,2002 Kazuyuki Shudo + Copyright (C) 1998,1999,2000,2001,2002,2003 Kazuyuki Shudo This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public @@ -82,6 +82,9 @@ // // constant +#ifdef WIN32 +# undef CONST +#endif #define CONST 0x606060 // for exception handler #define BYTEPCOFF 0x626262 @@ -127,7 +130,7 @@ #define FFLUSH \ PUSH_STDOUT;\ - asm("call " SYMBOL(fflush) "@PLT\n\t"\ + asm("call " FUNCTION(fflush) "\n\t"\ "addl $4,%esp") #if 0 @@ -217,7 +220,7 @@ if (runtime_debug) {\ asm("pushl %eax");\ PUSH_CONSTSTR(">" LABEL " %x\n");\ - asm("call " SYMBOL(printf) "@PLT\n\t"\ + asm("call " FUNCTION(printf) "\n\t"\ "addl $8,%esp");\ FFLUSH;\ }\ @@ -347,13 +350,13 @@ asm("pushl " #LEN "\n\t"\ "pushl " TYPE);\ asm("pushl %0" : : "m" (ee));\ - asm("call " SYMBOL(allocArray) "@PLT\n\t"\ + asm("call " FUNCTION(allocArray) "\n\t"\ "addl $12,%esp"); #else # define ALLOC_ARRAY(TYPE, LEN) \ asm("pushl " #LEN "\n\t"\ "pushl " TYPE "\n\t"\ - "call " SYMBOL(ArrayAlloc) "@PLT\n\t"\ + "call " FUNCTION(ArrayAlloc) "\n\t"\ "addl $8,%esp"); #endif diff -aruN shujit-0.7.14/compile.c shujit/compile.c --- shujit-0.7.14/compile.c 2003-01-06 20:15:21.000000000 +0900 +++ shujit/compile.c 2003-03-20 20:18:48.000000000 +0900 @@ -26,7 +26,10 @@ #if defined(__FreeBSD__) || defined(__NetBSD__) # include // for a type u_long #endif -#include // for ntohl(), htonl() +#include // for INT_MAX +#ifndef WIN32 +# include // for ntohl() +#endif #include "compiler.h" #include "constants.h" @@ -1860,8 +1863,8 @@ case opc_tableswitch: { int32_t *argp = (int32_t *)ALIGNUP32(bytepc + 1); - int32_t l = (int32_t)ntohl((unsigned long)argp[1]); - int32_t h = (int32_t)ntohl((unsigned long)argp[2]); + int32_t l = (int32_t)ntohl((uint32_t)argp[1]); + int32_t h = (int32_t)ntohl((uint32_t)argp[2]); argp += 3 + (h - l + 1); byteinc = ((unsigned char *)argp) - bytepc; @@ -1870,7 +1873,7 @@ case opc_lookupswitch: { int32_t *argp = (int32_t *)ALIGNUP32(bytepc + 1); - int32_t npairs = (int32_t)ntohl((unsigned long)argp[1]); + int32_t npairs = (int32_t)ntohl((uint32_t)argp[1]); argp += 2 + (npairs * 2); byteinc = ((unsigned char *)argp) - bytepc; @@ -1981,9 +1984,9 @@ } else if (opcode == opc_tableswitch) { // tableswitch int32_t *argp = (int32_t *)ALIGNUP32(bytepc + 1); - int32_t defoff = (int32_t)ntohl((unsigned long)argp[0]); - int32_t l = (int32_t)ntohl((unsigned long)argp[1]); - int32_t h = (int32_t)ntohl((unsigned long)argp[2]); + int32_t defoff = (int32_t)ntohl((uint32_t)argp[0]); + int32_t l = (int32_t)ntohl((uint32_t)argp[1]); + int32_t h = (int32_t)ntohl((uint32_t)argp[2]); #ifdef COMPILE_DEBUG if (compile_debug) { printf(" tableswitch at 0x%x(%d):\n", entry->byteoff, entry->byteoff); @@ -2004,7 +2007,7 @@ argp += 3; // skip default, low, and high for (j = 0; j < (h - l + 1); j++) { - int32_t off = (int32_t)ntohl((unsigned long)argp[j]); + int32_t off = (int32_t)ntohl((uint32_t)argp[j]); loopp = (off < 0) ? TRUE : FALSE; off += entry->byteoff; #ifdef COMPILE_DEBUG @@ -2024,8 +2027,8 @@ } else if (opcode == opc_lookupswitch) { // lookupswitch int32_t *argp = (int32_t *)ALIGNUP32(bytepc + 1); - int32_t defoff = (int32_t)ntohl((unsigned long)argp[0]); - int32_t npairs = (int32_t)ntohl((unsigned long)argp[1]); + int32_t defoff = (int32_t)ntohl((uint32_t)argp[0]); + int32_t npairs = (int32_t)ntohl((uint32_t)argp[1]); #ifdef COMPILE_DEBUG if (compile_debug) { printf(" lookupswitch at 0x%x(%d):\n", entry->byteoff, entry->byteoff); @@ -2046,7 +2049,7 @@ argp += 2; // skip default and npairs for (j = 0; j < npairs; j++) { - int32_t off = ntohl((unsigned long)argp[1]); + int32_t off = (int32_t)ntohl((uint32_t)argp[1]); loopp = (off < 0) ? TRUE : FALSE; off += entry->byteoff; #ifdef COMPILE_DEBUG @@ -2810,8 +2813,8 @@ case opc_tableswitch: { int32_t *argp = (int32_t *)ALIGNUP32(bytepc + 1); - int32_t l = (int32_t)ntohl((unsigned long)argp[1]); - int32_t h = (int32_t)ntohl((unsigned long)argp[2]); + int32_t l = (int32_t)ntohl((uint32_t)argp[1]); + int32_t h = (int32_t)ntohl((uint32_t)argp[2]); #ifdef COMPILE_DEBUG if (compile_debug) { printf(" low: %d, high: %d\n", l, h); fflush(stdout); @@ -2825,7 +2828,7 @@ case opc_lookupswitch: { int32_t *argp = (int32_t *)ALIGNUP32(bytepc + 1); - int32_t npairs = (int32_t)ntohl((unsigned long)argp[1]); + int32_t npairs = (int32_t)ntohl((uint32_t)argp[1]); #ifdef COMPILE_DEBUG if (compile_debug) { printf(" npairs: %d\n", npairs); fflush(stdout); @@ -3451,9 +3454,9 @@ CodeTable *codep; int32_t *argp = (int32_t *)ALIGNUP32(cc->mb->code + byteoff + 1); - int32_t defoff = (int32_t)ntohl((unsigned long)argp[0]); - int32_t l = (int32_t)ntohl((unsigned long)argp[1]); - int32_t h = (int32_t)ntohl((unsigned long)argp[2]); + int32_t defoff = (int32_t)ntohl((uint32_t)argp[0]); + int32_t l = (int32_t)ntohl((uint32_t)argp[1]); + int32_t h = (int32_t)ntohl((uint32_t)argp[2]); int32_t *tblp; int last_state = code_table[opcode][state].last_state; int i; @@ -3497,7 +3500,7 @@ argp += 3; // skit default, low, and high for (i = 0; i < (h - l + 1); i++) { - int32_t off = (int32_t)ntohl((unsigned long)argp[i]); + int32_t off = (int32_t)ntohl((uint32_t)argp[i]); tgttable = pctableGetByPC(cc, byteoff + off); sysAssert(tgttable != NULL); tblp[0] = tgttable->nativeoff; @@ -3526,8 +3529,8 @@ CodeTable *codep; int32_t *argp = (int32_t *)ALIGNUP32(cc->mb->code + byteoff + 1); - int32_t defoff = (int32_t)ntohl((unsigned long)argp[0]); - int32_t npairs = (int32_t)ntohl((unsigned long)argp[1]); + int32_t defoff = (int32_t)ntohl((uint32_t)argp[0]); + int32_t npairs = (int32_t)ntohl((uint32_t)argp[1]); int32_t *tblp; int last_state = code_table[opcode][state].last_state; @@ -3557,8 +3560,8 @@ // (int32_t)match and (int32_t)jump offset while (npairs-- > 0) { - int32_t match = (int32_t)ntohl((unsigned long)argp[0]); - int32_t off = (int32_t)ntohl((unsigned long)argp[1]); + int32_t match = (int32_t)ntohl((uint32_t)argp[0]); + int32_t off = (int32_t)ntohl((uint32_t)argp[1]); tblp[0] = match; tgttable = pctableGetByPC(cc, byteoff + off); @@ -3695,8 +3698,8 @@ case opc_tableswitch: { int32_t *argp = (int32_t *)ALIGNUP32(bytepc + 1); - int32_t l = (int32_t)ntohl((unsigned long)argp[1]); - int32_t h = (int32_t)ntohl((unsigned long)argp[2]); + int32_t l = (int32_t)ntohl((uint32_t)argp[1]); + int32_t h = (int32_t)ntohl((uint32_t)argp[2]); int32_t *tblp = (int32_t *)(mb->CompiledCode + entry->operand); @@ -3712,7 +3715,7 @@ case opc_lookupswitch: { int32_t *argp = (int32_t *)ALIGNUP32(bytepc + 1); - int32_t npairs = (int32_t)ntohl((unsigned long)argp[1]); + int32_t npairs = (int32_t)ntohl((uint32_t)argp[1]); int32_t *tblp = (int32_t *)(mb->CompiledCode + entry->operand); diff -aruN shujit-0.7.14/compiler.h shujit/compiler.h --- shujit-0.7.14/compiler.h 2003-01-06 19:15:11.000000000 +0900 +++ shujit/compiler.h 2003-03-20 21:42:08.000000000 +0900 @@ -2,7 +2,7 @@ This file is part of shuJIT, Just In Time compiler for Sun Java Virtual Machine. - Copyright (C) 1996,1997,1998,1999,2000,2001,2002 Kazuyuki Shudo + Copyright (C) 1996,1997,1998,1999,2000,2001,2002,2003 Kazuyuki Shudo This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public @@ -25,7 +25,7 @@ #define _COMPILER_H_ -#define VERSION "0.7.14" +#define VERSION "0.8" #include "config.h" @@ -60,7 +60,7 @@ // Additional type definition -#if !(defined(_ILP32) || defined(_LP64) || defined(_SYS_INTTYPES_H_) /* for FreeBSD */) +#if !(defined(_ILP32) || defined(_LP64) || defined(_STDINT_H) || defined(_SYS_INTTYPES_H_) /* for FreeBSD */) # ifndef _UINT16_T # define _UINT16_T typedef unsigned short uint16_t; @@ -125,6 +125,16 @@ #undef COUNT_TSC +#ifdef WIN32 +# undef PATCH_WITH_SIGTRAP +# define PATCH_ON_JUMP +# undef INITCLASS_IN_COMPILATION +# undef GET_SIGCONTEXT +# undef NULLEXC_BY_SIGNAL +# undef ARITHEXC_BY_SIGNAL +#endif + + #define LAZY_COMPILATION_THRESHOLD_FOR_SYS 10 #define LAZY_COMPILATION_THRESHOLD_FOR_USER 1 @@ -253,6 +263,10 @@ # ifndef HAVE_GREENTHR_HEADER # define NATIVE // for Linux/JDK 1.1.8v1 # endif +# ifdef WIN32 +# define _JAVASOFT_WIN32_TIMEVAL_H_ // avoid redefinition of timercmp() +# define _JAVASOFT_WIN32_IO_MD_H_ // avoid redefinition of S_IS*() +# endif # include "sys_api.h" # undef NATIVE #else @@ -338,8 +352,13 @@ #if (defined(__FreeBSD__) || defined(__NetBSD__)) && !defined(__ELF__) # define SYMBOL(SYM) "_" STR(SYM) +# define FUNCTION(SYM) SYMBOL(SYM) "@PLT" +#elif defined(WIN32) +# define SYMBOL(SYM) "_" STR(SYM) +# define FUNCTION(SYM) SYMBOL(SYM) #else # define SYMBOL(SYM) STR(SYM) +# define FUNCTION(SYM) SYMBOL(SYM) "@PLT" #endif diff -aruN shujit-0.7.14/configure shujit/configure --- shujit-0.7.14/configure 2002-07-17 17:51:24.000000000 +0900 +++ shujit/configure 2003-03-20 23:28:53.000000000 +0900 @@ -1,43 +1,310 @@ #! /bin/sh - # Guess values for system-dependent variables and create Makefiles. -# Generated automatically using autoconf version 2.13 -# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc. +# Generated by GNU Autoconf 2.53. # +# Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002 +# Free Software Foundation, Inc. # This configure script is free software; the Free Software Foundation # gives unlimited permission to copy, distribute and modify it. -# Defaults: -ac_help= +if expr a : '\(a\)' >/dev/null 2>&1; then + as_expr=expr +else + as_expr=false +fi + + +## --------------------- ## +## M4sh Initialization. ## +## --------------------- ## + +# Be Bourne compatible +if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then + emulate sh + NULLCMD=: +elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then + set -o posix +fi + +# NLS nuisances. +# Support unset when possible. +if (FOO=FOO; unset FOO) >/dev/null 2>&1; then + as_unset=unset +else + as_unset=false +fi + +(set +x; test -n "`(LANG=C; export LANG) 2>&1`") && + { $as_unset LANG || test "${LANG+set}" != set; } || + { LANG=C; export LANG; } +(set +x; test -n "`(LC_ALL=C; export LC_ALL) 2>&1`") && + { $as_unset LC_ALL || test "${LC_ALL+set}" != set; } || + { LC_ALL=C; export LC_ALL; } +(set +x; test -n "`(LC_TIME=C; export LC_TIME) 2>&1`") && + { $as_unset LC_TIME || test "${LC_TIME+set}" != set; } || + { LC_TIME=C; export LC_TIME; } +(set +x; test -n "`(LC_CTYPE=C; export LC_CTYPE) 2>&1`") && + { $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set; } || + { LC_CTYPE=C; export LC_CTYPE; } +(set +x; test -n "`(LANGUAGE=C; export LANGUAGE) 2>&1`") && + { $as_unset LANGUAGE || test "${LANGUAGE+set}" != set; } || + { LANGUAGE=C; export LANGUAGE; } +(set +x; test -n "`(LC_COLLATE=C; export LC_COLLATE) 2>&1`") && + { $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set; } || + { LC_COLLATE=C; export LC_COLLATE; } +(set +x; test -n "`(LC_NUMERIC=C; export LC_NUMERIC) 2>&1`") && + { $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set; } || + { LC_NUMERIC=C; export LC_NUMERIC; } +(set +x; test -n "`(LC_MESSAGES=C; export LC_MESSAGES) 2>&1`") && + { $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set; } || + { LC_MESSAGES=C; export LC_MESSAGES; } + + +# Name of the executable. +as_me=`(basename "$0") 2>/dev/null || +$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ + X"$0" : 'X\(//\)$' \| \ + X"$0" : 'X\(/\)$' \| \ + . : '\(.\)' 2>/dev/null || +echo X/"$0" | + sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; } + /^X\/\(\/\/\)$/{ s//\1/; q; } + /^X\/\(\/\).*/{ s//\1/; q; } + s/.*/./; q'` + +# PATH needs CR, and LINENO needs CR and PATH. +# Avoid depending upon Character Ranges. +as_cr_letters='abcdefghijklmnopqrstuvwxyz' +as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' +as_cr_Letters=$as_cr_letters$as_cr_LETTERS +as_cr_digits='0123456789' +as_cr_alnum=$as_cr_Letters$as_cr_digits + +# The user is always right. +if test "${PATH_SEPARATOR+set}" != set; then + echo "#! /bin/sh" >conftest.sh + echo "exit 0" >>conftest.sh + chmod +x conftest.sh + if (PATH=".;."; conftest.sh) >/dev/null 2>&1; then + PATH_SEPARATOR=';' + else + PATH_SEPARATOR=: + fi + rm -f conftest.sh +fi + + + as_lineno_1=$LINENO + as_lineno_2=$LINENO + as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null` + test "x$as_lineno_1" != "x$as_lineno_2" && + test "x$as_lineno_3" = "x$as_lineno_2" || { + # Find who we are. Look in the path if we contain no path at all + # relative or not. + case $0 in + *[\\/]* ) as_myself=$0 ;; + *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break +done + + ;; + esac + # We did not find ourselves, most probably we were run as `sh COMMAND' + # in which case we are not to be found in the path. + if test "x$as_myself" = x; then + as_myself=$0 + fi + if test ! -f "$as_myself"; then + { echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2 + { (exit 1); exit 1; }; } + fi + case $CONFIG_SHELL in + '') + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for as_base in sh bash ksh sh5; do + case $as_dir in + /*) + if ("$as_dir/$as_base" -c ' + as_lineno_1=$LINENO + as_lineno_2=$LINENO + as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null` + test "x$as_lineno_1" != "x$as_lineno_2" && + test "x$as_lineno_3" = "x$as_lineno_2" ') 2>/dev/null; then + CONFIG_SHELL=$as_dir/$as_base + export CONFIG_SHELL + exec "$CONFIG_SHELL" "$0" ${1+"$@"} + fi;; + esac + done +done +;; + esac + + # Create $as_me.lineno as a copy of $as_myself, but with $LINENO + # uniformly replaced by the line number. The first 'sed' inserts a + # line-number line before each line; the second 'sed' does the real + # work. The second script uses 'N' to pair each line-number line + # with the numbered line, and appends trailing '-' during + # substitution so that $LINENO is not a special case at line end. + # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the + # second 'sed' script. Blame Lee E. McMahon for sed's syntax. :-) + sed '=' <$as_myself | + sed ' + N + s,$,-, + : loop + s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3, + t loop + s,-$,, + s,^['$as_cr_digits']*\n,, + ' >$as_me.lineno && + chmod +x $as_me.lineno || + { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2 + { (exit 1); exit 1; }; } + + # Don't try to exec as it changes $[0], causing all sort of problems + # (the dirname of $[0] is not the place where we might find the + # original and so on. Autoconf is especially sensible to this). + . ./$as_me.lineno + # Exit status is that of the last command. + exit +} + + +case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in + *c*,-n*) ECHO_N= ECHO_C=' +' ECHO_T=' ' ;; + *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;; + *) ECHO_N= ECHO_C='\c' ECHO_T= ;; +esac + +if expr a : '\(a\)' >/dev/null 2>&1; then + as_expr=expr +else + as_expr=false +fi + +rm -f conf$$ conf$$.exe conf$$.file +echo >conf$$.file +if ln -s conf$$.file conf$$ 2>/dev/null; then + # We could just check for DJGPP; but this test a) works b) is more generic + # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04). + if test -f conf$$.exe; then + # Don't use ln at all; we don't have any links + as_ln_s='cp -p' + else + as_ln_s='ln -s' + fi +elif ln conf$$.file conf$$ 2>/dev/null; then + as_ln_s=ln +else + as_ln_s='cp -p' +fi +rm -f conf$$ conf$$.exe conf$$.file + +as_executable_p="test -f" + +# Sed expression to map a string onto a valid CPP name. +as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g" + +# Sed expression to map a string onto a valid variable name. +as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g" + + +# IFS +# We need space, tab and new line, in precisely that order. +as_nl=' +' +IFS=" $as_nl" + +# CDPATH. +$as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=$PATH_SEPARATOR; export CDPATH; } + + +# Name of the host. +# hostname on some systems (SVR3.2, Linux) returns a bogus exit status, +# so uname gets run too. +ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` + +exec 6>&1 + +# +# Initializations. +# ac_default_prefix=/usr/local -# Any additions from configure.in: -ac_help="$ac_help - --disable-codedb disable code DB " -ac_help="$ac_help - --enable-sse2 - use SSE2 instructions instead of x87 " -ac_help="$ac_help - --enable-moba - support thread migration " -ac_help="$ac_help - --enable-metavm-no-array - enable MetaVM and arrays are passed by value " -ac_help="$ac_help - --enable-metavm enable MetaVM " -ac_help="$ac_help - --with-jdk path where JDK installed to " -ac_help="$ac_help - --enable-c-interpreter the JDK uses C version of interpreter " +cross_compiling=no +subdirs= +MFLAGS= +MAKEFLAGS= +SHELL=${CONFIG_SHELL-/bin/sh} + +# Maximum number of lines to put in a shell here document. +# This variable seems obsolete. It should probably be removed, and +# only ac_max_sed_lines should be used. +: ${ac_max_here_lines=38} + +# Identity of this package. +PACKAGE_NAME= +PACKAGE_TARNAME= +PACKAGE_VERSION= +PACKAGE_STRING= +PACKAGE_BUGREPORT= + +ac_unique_file="compiler.c" +# Factoring default headers for most tests. +ac_includes_default="\ +#include +#if HAVE_SYS_TYPES_H +# include +#endif +#if HAVE_SYS_STAT_H +# include +#endif +#if STDC_HEADERS +# include +# include +#else +# if HAVE_STDLIB_H +# include +# endif +#endif +#if HAVE_STRING_H +# if !STDC_HEADERS && HAVE_MEMORY_H +# include +# endif +# include +#endif +#if HAVE_STRINGS_H +# include +#endif +#if HAVE_INTTYPES_H +# include +#else +# if HAVE_STDINT_H +# include +# endif +#endif +#if HAVE_UNISTD_H +# include +#endif" + # Initialize some variables set by options. +ac_init_help= +ac_init_version=false # The variables have the same names as the options, with # dashes changed to underlines. -build=NONE -cache_file=./config.cache +cache_file=/dev/null exec_prefix=NONE -host=NONE no_create= -nonopt=NONE no_recursion= prefix=NONE program_prefix=NONE @@ -46,10 +313,15 @@ silent= site= srcdir= -target=NONE verbose= x_includes=NONE x_libraries=NONE + +# Installation directory options. +# These are left unexpanded so users can "make install exec_prefix=/foo" +# and all the variables that are supposed to be based on exec_prefix +# by default will actually change. +# Use braces instead of parens because sh, perl, etc. also accept them. bindir='${exec_prefix}/bin' sbindir='${exec_prefix}/sbin' libexecdir='${exec_prefix}/libexec' @@ -63,17 +335,9 @@ infodir='${prefix}/info' mandir='${prefix}/man' -# Initialize some other variables. -subdirs= -MFLAGS= MAKEFLAGS= -SHELL=${CONFIG_SHELL-/bin/sh} -# Maximum number of lines to put in a shell here document. -ac_max_here_lines=12 - ac_prev= for ac_option do - # If the previous option needs an argument, assign it. if test -n "$ac_prev"; then eval "$ac_prev=\$ac_option" @@ -81,59 +345,59 @@ continue fi - case "$ac_option" in - -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;; - *) ac_optarg= ;; - esac + ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'` # Accept the important Cygnus configure options, so we can diagnose typos. - case "$ac_option" in + case $ac_option in -bindir | --bindir | --bindi | --bind | --bin | --bi) ac_prev=bindir ;; -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) - bindir="$ac_optarg" ;; + bindir=$ac_optarg ;; -build | --build | --buil | --bui | --bu) - ac_prev=build ;; + ac_prev=build_alias ;; -build=* | --build=* | --buil=* | --bui=* | --bu=*) - build="$ac_optarg" ;; + build_alias=$ac_optarg ;; -cache-file | --cache-file | --cache-fil | --cache-fi \ | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) ac_prev=cache_file ;; -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) - cache_file="$ac_optarg" ;; + cache_file=$ac_optarg ;; + + --config-cache | -C) + cache_file=config.cache ;; -datadir | --datadir | --datadi | --datad | --data | --dat | --da) ac_prev=datadir ;; -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \ | --da=*) - datadir="$ac_optarg" ;; + datadir=$ac_optarg ;; -disable-* | --disable-*) - ac_feature=`echo $ac_option|sed -e 's/-*disable-//'` + ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'` # Reject names that are not valid shell variable names. - if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then - { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; } - fi - ac_feature=`echo $ac_feature| sed 's/-/_/g'` - eval "enable_${ac_feature}=no" ;; + expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null && + { echo "$as_me: error: invalid feature name: $ac_feature" >&2 + { (exit 1); exit 1; }; } + ac_feature=`echo $ac_feature | sed 's/-/_/g'` + eval "enable_$ac_feature=no" ;; -enable-* | --enable-*) - ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'` + ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` # Reject names that are not valid shell variable names. - if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then - { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; } - fi - ac_feature=`echo $ac_feature| sed 's/-/_/g'` - case "$ac_option" in - *=*) ;; + expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null && + { echo "$as_me: error: invalid feature name: $ac_feature" >&2 + { (exit 1); exit 1; }; } + ac_feature=`echo $ac_feature | sed 's/-/_/g'` + case $ac_option in + *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;; *) ac_optarg=yes ;; esac - eval "enable_${ac_feature}='$ac_optarg'" ;; + eval "enable_$ac_feature='$ac_optarg'" ;; -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ @@ -142,95 +406,47 @@ -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ | --exec=* | --exe=* | --ex=*) - exec_prefix="$ac_optarg" ;; + exec_prefix=$ac_optarg ;; -gas | --gas | --ga | --g) # Obsolete; use --with-gas. with_gas=yes ;; - -help | --help | --hel | --he) - # Omit some internal or obsolete options to make the list less imposing. - # This message is too long to be a string in the A/UX 3.1 sh. - cat << EOF -Usage: configure [options] [host] -Options: [defaults in brackets after descriptions] -Configuration: - --cache-file=FILE cache test results in FILE - --help print this message - --no-create do not create output files - --quiet, --silent do not print \`checking...' messages - --version print the version of autoconf that created configure -Directory and file names: - --prefix=PREFIX install architecture-independent files in PREFIX - [$ac_default_prefix] - --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX - [same as prefix] - --bindir=DIR user executables in DIR [EPREFIX/bin] - --sbindir=DIR system admin executables in DIR [EPREFIX/sbin] - --libexecdir=DIR program executables in DIR [EPREFIX/libexec] - --datadir=DIR read-only architecture-independent data in DIR - [PREFIX/share] - --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc] - --sharedstatedir=DIR modifiable architecture-independent data in DIR - [PREFIX/com] - --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var] - --libdir=DIR object code libraries in DIR [EPREFIX/lib] - --includedir=DIR C header files in DIR [PREFIX/include] - --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include] - --infodir=DIR info documentation in DIR [PREFIX/info] - --mandir=DIR man documentation in DIR [PREFIX/man] - --srcdir=DIR find the sources in DIR [configure dir or ..] - --program-prefix=PREFIX prepend PREFIX to installed program names - --program-suffix=SUFFIX append SUFFIX to installed program names - --program-transform-name=PROGRAM - run sed PROGRAM on installed program names -EOF - cat << EOF -Host type: - --build=BUILD configure for building on BUILD [BUILD=HOST] - --host=HOST configure for HOST [guessed] - --target=TARGET configure for TARGET [TARGET=HOST] -Features and packages: - --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) - --enable-FEATURE[=ARG] include FEATURE [ARG=yes] - --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] - --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) - --x-includes=DIR X include files are in DIR - --x-libraries=DIR X library files are in DIR -EOF - if test -n "$ac_help"; then - echo "--enable and --with options recognized:$ac_help" - fi - exit 0 ;; + -help | --help | --hel | --he | -h) + ac_init_help=long ;; + -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) + ac_init_help=recursive ;; + -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) + ac_init_help=short ;; -host | --host | --hos | --ho) - ac_prev=host ;; + ac_prev=host_alias ;; -host=* | --host=* | --hos=* | --ho=*) - host="$ac_optarg" ;; + host_alias=$ac_optarg ;; -includedir | --includedir | --includedi | --included | --include \ | --includ | --inclu | --incl | --inc) ac_prev=includedir ;; -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ | --includ=* | --inclu=* | --incl=* | --inc=*) - includedir="$ac_optarg" ;; + includedir=$ac_optarg ;; -infodir | --infodir | --infodi | --infod | --info | --inf) ac_prev=infodir ;; -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) - infodir="$ac_optarg" ;; + infodir=$ac_optarg ;; -libdir | --libdir | --libdi | --libd) ac_prev=libdir ;; -libdir=* | --libdir=* | --libdi=* | --libd=*) - libdir="$ac_optarg" ;; + libdir=$ac_optarg ;; -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ | --libexe | --libex | --libe) ac_prev=libexecdir ;; -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ | --libexe=* | --libex=* | --libe=*) - libexecdir="$ac_optarg" ;; + libexecdir=$ac_optarg ;; -localstatedir | --localstatedir | --localstatedi | --localstated \ | --localstate | --localstat | --localsta | --localst \ @@ -239,19 +455,19 @@ -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ | --localstate=* | --localstat=* | --localsta=* | --localst=* \ | --locals=* | --local=* | --loca=* | --loc=* | --lo=*) - localstatedir="$ac_optarg" ;; + localstatedir=$ac_optarg ;; -mandir | --mandir | --mandi | --mand | --man | --ma | --m) ac_prev=mandir ;; -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) - mandir="$ac_optarg" ;; + mandir=$ac_optarg ;; -nfp | --nfp | --nf) # Obsolete; use --without-fp. with_fp=no ;; -no-create | --no-create | --no-creat | --no-crea | --no-cre \ - | --no-cr | --no-c) + | --no-cr | --no-c | -n) no_create=yes ;; -no-recursion | --no-recursion | --no-recursio | --no-recursi \ @@ -265,26 +481,26 @@ -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) - oldincludedir="$ac_optarg" ;; + oldincludedir=$ac_optarg ;; -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) ac_prev=prefix ;; -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) - prefix="$ac_optarg" ;; + prefix=$ac_optarg ;; -program-prefix | --program-prefix | --program-prefi | --program-pref \ | --program-pre | --program-pr | --program-p) ac_prev=program_prefix ;; -program-prefix=* | --program-prefix=* | --program-prefi=* \ | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) - program_prefix="$ac_optarg" ;; + program_prefix=$ac_optarg ;; -program-suffix | --program-suffix | --program-suffi | --program-suff \ | --program-suf | --program-su | --program-s) ac_prev=program_suffix ;; -program-suffix=* | --program-suffix=* | --program-suffi=* \ | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) - program_suffix="$ac_optarg" ;; + program_suffix=$ac_optarg ;; -program-transform-name | --program-transform-name \ | --program-transform-nam | --program-transform-na \ @@ -301,7 +517,7 @@ | --program-transfo=* | --program-transf=* \ | --program-trans=* | --program-tran=* \ | --progr-tra=* | --program-tr=* | --program-t=*) - program_transform_name="$ac_optarg" ;; + program_transform_name=$ac_optarg ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil) @@ -311,7 +527,7 @@ ac_prev=sbindir ;; -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ | --sbi=* | --sb=*) - sbindir="$ac_optarg" ;; + sbindir=$ac_optarg ;; -sharedstatedir | --sharedstatedir | --sharedstatedi \ | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ @@ -322,58 +538,57 @@ | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ | --sha=* | --sh=*) - sharedstatedir="$ac_optarg" ;; + sharedstatedir=$ac_optarg ;; -site | --site | --sit) ac_prev=site ;; -site=* | --site=* | --sit=*) - site="$ac_optarg" ;; + site=$ac_optarg ;; -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) ac_prev=srcdir ;; -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) - srcdir="$ac_optarg" ;; + srcdir=$ac_optarg ;; -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ | --syscon | --sysco | --sysc | --sys | --sy) ac_prev=sysconfdir ;; -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) - sysconfdir="$ac_optarg" ;; + sysconfdir=$ac_optarg ;; -target | --target | --targe | --targ | --tar | --ta | --t) - ac_prev=target ;; + ac_prev=target_alias ;; -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) - target="$ac_optarg" ;; + target_alias=$ac_optarg ;; -v | -verbose | --verbose | --verbos | --verbo | --verb) verbose=yes ;; - -version | --version | --versio | --versi | --vers) - echo "configure generated by autoconf version 2.13" - exit 0 ;; + -version | --version | --versio | --versi | --vers | -V) + ac_init_version=: ;; -with-* | --with-*) - ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'` + ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` # Reject names that are not valid shell variable names. - if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then - { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; } - fi + expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null && + { echo "$as_me: error: invalid package name: $ac_package" >&2 + { (exit 1); exit 1; }; } ac_package=`echo $ac_package| sed 's/-/_/g'` - case "$ac_option" in - *=*) ;; + case $ac_option in + *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;; *) ac_optarg=yes ;; esac - eval "with_${ac_package}='$ac_optarg'" ;; + eval "with_$ac_package='$ac_optarg'" ;; -without-* | --without-*) - ac_package=`echo $ac_option|sed -e 's/-*without-//'` + ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'` # Reject names that are not valid shell variable names. - if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then - { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; } - fi - ac_package=`echo $ac_package| sed 's/-/_/g'` - eval "with_${ac_package}=no" ;; + expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null && + { echo "$as_me: error: invalid package name: $ac_package" >&2 + { (exit 1); exit 1; }; } + ac_package=`echo $ac_package | sed 's/-/_/g'` + eval "with_$ac_package=no" ;; --x) # Obsolete; use --with-x. @@ -384,99 +599,110 @@ ac_prev=x_includes ;; -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) - x_includes="$ac_optarg" ;; + x_includes=$ac_optarg ;; -x-libraries | --x-libraries | --x-librarie | --x-librari \ | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) ac_prev=x_libraries ;; -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) - x_libraries="$ac_optarg" ;; + x_libraries=$ac_optarg ;; - -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; } + -*) { echo "$as_me: error: unrecognized option: $ac_option +Try \`$0 --help' for more information." >&2 + { (exit 1); exit 1; }; } ;; + *=*) + ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` + # Reject names that are not valid shell variable names. + expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null && + { echo "$as_me: error: invalid variable name: $ac_envvar" >&2 + { (exit 1); exit 1; }; } + ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` + eval "$ac_envvar='$ac_optarg'" + export $ac_envvar ;; + *) - if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then - echo "configure: warning: $ac_option: invalid host type" 1>&2 - fi - if test "x$nonopt" != xNONE; then - { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } - fi - nonopt="$ac_option" + # FIXME: should be removed in autoconf 3.0. + echo "$as_me: WARNING: you should use --build, --host, --target" >&2 + expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && + echo "$as_me: WARNING: invalid host type: $ac_option" >&2 + : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option} ;; esac done if test -n "$ac_prev"; then - { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; } -fi - -trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15 - -# File descriptor usage: -# 0 standard input -# 1 file creation -# 2 errors and warnings -# 3 some systems may open it to /dev/tty -# 4 used on the Kubota Titan -# 6 checking for... messages and results -# 5 compiler messages saved in config.log -if test "$silent" = yes; then - exec 6>/dev/null -else - exec 6>&1 + ac_option=--`echo $ac_prev | sed 's/_/-/g'` + { echo "$as_me: error: missing argument to $ac_option" >&2 + { (exit 1); exit 1; }; } fi -exec 5>./config.log -echo "\ -This file contains any messages produced by compilers while -running configure, to aid debugging if configure makes a mistake. -" 1>&5 +# Be sure to have absolute paths. +for ac_var in exec_prefix prefix +do + eval ac_val=$`echo $ac_var` + case $ac_val in + [\\/$]* | ?:[\\/]* | NONE | '' ) ;; + *) { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2 + { (exit 1); exit 1; }; };; + esac +done -# Strip out --no-create and --no-recursion so they do not pile up. -# Also quote any args containing shell metacharacters. -ac_configure_args= -for ac_arg +# Be sure to have absolute paths. +for ac_var in bindir sbindir libexecdir datadir sysconfdir sharedstatedir \ + localstatedir libdir includedir oldincludedir infodir mandir do - case "$ac_arg" in - -no-create | --no-create | --no-creat | --no-crea | --no-cre \ - | --no-cr | --no-c) ;; - -no-recursion | --no-recursion | --no-recursio | --no-recursi \ - | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;; - *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*) - ac_configure_args="$ac_configure_args '$ac_arg'" ;; - *) ac_configure_args="$ac_configure_args $ac_arg" ;; + eval ac_val=$`echo $ac_var` + case $ac_val in + [\\/$]* | ?:[\\/]* ) ;; + *) { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2 + { (exit 1); exit 1; }; };; esac done -# NLS nuisances. -# Only set these to C if already set. These must not be set unconditionally -# because not all systems understand e.g. LANG=C (notably SCO). -# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'! -# Non-C LC_CTYPE values break the ctype check. -if test "${LANG+set}" = set; then LANG=C; export LANG; fi -if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi -if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi -if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi +# There might be people who depend on the old broken behavior: `$host' +# used to hold the argument of --host etc. +# FIXME: To remove some day. +build=$build_alias +host=$host_alias +target=$target_alias + +# FIXME: To remove some day. +if test "x$host_alias" != x; then + if test "x$build_alias" = x; then + cross_compiling=maybe + echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host. + If a cross compiler is detected then cross compile mode will be used." >&2 + elif test "x$build_alias" != "x$host_alias"; then + cross_compiling=yes + fi +fi -# confdefs.h avoids OS command line length limits that DEFS can exceed. -rm -rf conftest* confdefs.h -# AIX cpp loses on an empty file, so make sure it contains at least a newline. -echo > confdefs.h +ac_tool_prefix= +test -n "$host_alias" && ac_tool_prefix=$host_alias- + +test "$silent" = yes && exec 6>/dev/null -# A filename unique to this package, relative to the directory that -# configure is in, which we can look for to find out if srcdir is correct. -ac_unique_file=compiler.c # Find the source files, if location was not specified. if test -z "$srcdir"; then ac_srcdir_defaulted=yes # Try the directory containing this script, then its parent. - ac_prog=$0 - ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'` - test "x$ac_confdir" = "x$ac_prog" && ac_confdir=. + ac_confdir=`(dirname "$0") 2>/dev/null || +$as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$0" : 'X\(//\)[^/]' \| \ + X"$0" : 'X\(//\)$' \| \ + X"$0" : 'X\(/\)' \| \ + . : '\(.\)' 2>/dev/null || +echo X"$0" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; } + /^X\(\/\/\)[^/].*/{ s//\1/; q; } + /^X\(\/\/\)$/{ s//\1/; q; } + /^X\(\/\).*/{ s//\1/; q; } + s/.*/./; q'` srcdir=$ac_confdir if test ! -r $srcdir/$ac_unique_file; then srcdir=.. @@ -486,13 +712,385 @@ fi if test ! -r $srcdir/$ac_unique_file; then if test "$ac_srcdir_defaulted" = yes; then - { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; } + { echo "$as_me: error: cannot find sources ($ac_unique_file) in $ac_confdir or .." >&2 + { (exit 1); exit 1; }; } else - { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; } + { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2 + { (exit 1); exit 1; }; } fi fi -srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'` +srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'` +ac_env_build_alias_set=${build_alias+set} +ac_env_build_alias_value=$build_alias +ac_cv_env_build_alias_set=${build_alias+set} +ac_cv_env_build_alias_value=$build_alias +ac_env_host_alias_set=${host_alias+set} +ac_env_host_alias_value=$host_alias +ac_cv_env_host_alias_set=${host_alias+set} +ac_cv_env_host_alias_value=$host_alias +ac_env_target_alias_set=${target_alias+set} +ac_env_target_alias_value=$target_alias +ac_cv_env_target_alias_set=${target_alias+set} +ac_cv_env_target_alias_value=$target_alias +ac_env_CC_set=${CC+set} +ac_env_CC_value=$CC +ac_cv_env_CC_set=${CC+set} +ac_cv_env_CC_value=$CC +ac_env_CFLAGS_set=${CFLAGS+set} +ac_env_CFLAGS_value=$CFLAGS +ac_cv_env_CFLAGS_set=${CFLAGS+set} +ac_cv_env_CFLAGS_value=$CFLAGS +ac_env_LDFLAGS_set=${LDFLAGS+set} +ac_env_LDFLAGS_value=$LDFLAGS +ac_cv_env_LDFLAGS_set=${LDFLAGS+set} +ac_cv_env_LDFLAGS_value=$LDFLAGS +ac_env_CPPFLAGS_set=${CPPFLAGS+set} +ac_env_CPPFLAGS_value=$CPPFLAGS +ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set} +ac_cv_env_CPPFLAGS_value=$CPPFLAGS +ac_env_CPP_set=${CPP+set} +ac_env_CPP_value=$CPP +ac_cv_env_CPP_set=${CPP+set} +ac_cv_env_CPP_value=$CPP + +# +# Report the --help message. +# +if test "$ac_init_help" = "long"; then + # Omit some internal or obsolete options to make the list less imposing. + # This message is too long to be a string in the A/UX 3.1 sh. + cat <<_ACEOF +\`configure' configures this package to adapt to many kinds of systems. + +Usage: $0 [OPTION]... [VAR=VALUE]... + +To assign environment variables (e.g., CC, CFLAGS...), specify them as +VAR=VALUE. See below for descriptions of some of the useful variables. + +Defaults for the options are specified in brackets. + +Configuration: + -h, --help display this help and exit + --help=short display options specific to this package + --help=recursive display the short help of all the included packages + -V, --version display version information and exit + -q, --quiet, --silent do not print \`checking...' messages + --cache-file=FILE cache test results in FILE [disabled] + -C, --config-cache alias for \`--cache-file=config.cache' + -n, --no-create do not create output files + --srcdir=DIR find the sources in DIR [configure dir or \`..'] + +_ACEOF + + cat <<_ACEOF +Installation directories: + --prefix=PREFIX install architecture-independent files in PREFIX + [$ac_default_prefix] + --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX + [PREFIX] + +By default, \`make install' will install all the files in +\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify +an installation prefix other than \`$ac_default_prefix' using \`--prefix', +for instance \`--prefix=\$HOME'. + +For better control, use the options below. + +Fine tuning of the installation directories: + --bindir=DIR user executables [EPREFIX/bin] + --sbindir=DIR system admin executables [EPREFIX/sbin] + --libexecdir=DIR program executables [EPREFIX/libexec] + --datadir=DIR read-only architecture-independent data [PREFIX/share] + --sysconfdir=DIR read-only single-machine data [PREFIX/etc] + --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] + --localstatedir=DIR modifiable single-machine data [PREFIX/var] + --libdir=DIR object code libraries [EPREFIX/lib] + --includedir=DIR C header files [PREFIX/include] + --oldincludedir=DIR C header files for non-gcc [/usr/include] + --infodir=DIR info documentation [PREFIX/info] + --mandir=DIR man documentation [PREFIX/man] +_ACEOF + + cat <<\_ACEOF + +System types: + --build=BUILD configure for building on BUILD [guessed] + --host=HOST cross-compile to build programs to run on HOST [BUILD] + --target=TARGET configure for building compilers for TARGET [HOST] +_ACEOF +fi + +if test -n "$ac_init_help"; then + + cat <<\_ACEOF + +Optional Features: + --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) + --enable-FEATURE[=ARG] include FEATURE [ARG=yes] + --disable-codedb disable code DB + --enable-sse2 + use SSE2 instructions instead of x87 + --enable-moba + support thread migration + --enable-metavm-no-array + enable MetaVM and arrays are passed by value + --enable-metavm enable MetaVM + --enable-c-interpreter the JDK uses C version of interpreter + +Optional Packages: + --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] + --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) + --with-jdk path where JDK installed to + +Some influential environment variables: + CC C compiler command + CFLAGS C compiler flags + LDFLAGS linker flags, e.g. -L if you have libraries in a + nonstandard directory + CPPFLAGS C/C++ preprocessor flags, e.g. -I if you have + headers in a nonstandard directory + CPP C preprocessor + +Use these variables to override the choices made by `configure' or to help +it to find libraries and programs with nonstandard names/locations. + +_ACEOF +fi + +if test "$ac_init_help" = "recursive"; then + # If there are subdirs, report their specific --help. + ac_popdir=`pwd` + for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue + test -d $ac_dir || continue + ac_builddir=. + +if test "$ac_dir" != .; then + ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'` + # A "../" for each directory in $ac_dir_suffix. + ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'` +else + ac_dir_suffix= ac_top_builddir= +fi + +case $srcdir in + .) # No --srcdir option. We are building in place. + ac_srcdir=. + if test -z "$ac_top_builddir"; then + ac_top_srcdir=. + else + ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'` + fi ;; + [\\/]* | ?:[\\/]* ) # Absolute path. + ac_srcdir=$srcdir$ac_dir_suffix; + ac_top_srcdir=$srcdir ;; + *) # Relative path. + ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix + ac_top_srcdir=$ac_top_builddir$srcdir ;; +esac +# Don't blindly perform a `cd "$ac_dir"/$ac_foo && pwd` since $ac_foo can be +# absolute. +ac_abs_builddir=`cd "$ac_dir" && cd $ac_builddir && pwd` +ac_abs_top_builddir=`cd "$ac_dir" && cd $ac_top_builddir && pwd` +ac_abs_srcdir=`cd "$ac_dir" && cd $ac_srcdir && pwd` +ac_abs_top_srcdir=`cd "$ac_dir" && cd $ac_top_srcdir && pwd` + + cd $ac_dir + # Check for guested configure; otherwise get Cygnus style configure. + if test -f $ac_srcdir/configure.gnu; then + echo + $SHELL $ac_srcdir/configure.gnu --help=recursive + elif test -f $ac_srcdir/configure; then + echo + $SHELL $ac_srcdir/configure --help=recursive + elif test -f $ac_srcdir/configure.ac || + test -f $ac_srcdir/configure.in; then + echo + $ac_configure --help + else + echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 + fi + cd $ac_popdir + done +fi + +test -n "$ac_init_help" && exit 0 +if $ac_init_version; then + cat <<\_ACEOF + +Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002 +Free Software Foundation, Inc. +This configure script is free software; the Free Software Foundation +gives unlimited permission to copy, distribute and modify it. +_ACEOF + exit 0 +fi +exec 5>config.log +cat >&5 <<_ACEOF +This file contains any messages produced by compilers while +running configure, to aid debugging if configure makes a mistake. + +It was created by $as_me, which was +generated by GNU Autoconf 2.53. Invocation command line was + + $ $0 $@ + +_ACEOF +{ +cat <<_ASUNAME +## --------- ## +## Platform. ## +## --------- ## + +hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` +uname -m = `(uname -m) 2>/dev/null || echo unknown` +uname -r = `(uname -r) 2>/dev/null || echo unknown` +uname -s = `(uname -s) 2>/dev/null || echo unknown` +uname -v = `(uname -v) 2>/dev/null || echo unknown` + +/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` +/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` + +/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` +/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` +/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` +hostinfo = `(hostinfo) 2>/dev/null || echo unknown` +/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` +/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` +/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` + +_ASUNAME + +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + echo "PATH: $as_dir" +done + +} >&5 + +cat >&5 <<_ACEOF + + +## ----------- ## +## Core tests. ## +## ----------- ## + +_ACEOF + +# Keep a trace of the command line. +# Strip out --no-create and --no-recursion so they do not pile up. +# Also quote any args containing shell meta-characters. +ac_configure_args= +ac_sep= +for ac_arg +do + case $ac_arg in + -no-create | --no-create | --no-creat | --no-crea | --no-cre \ + | --no-cr | --no-c | -n ) continue ;; + -no-recursion | --no-recursion | --no-recursio | --no-recursi \ + | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) + continue ;; + *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*) + ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; + esac + case " $ac_configure_args " in + *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. + *) ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'" + ac_sep=" " ;; + esac + # Get rid of the leading space. +done + +# When interrupted or exit'd, cleanup temporary files, and complete +# config.log. We remove comments because anyway the quotes in there +# would cause problems or look ugly. +# WARNING: Be sure not to use single quotes in there, as some shells, +# such as our DU 5.0 friend, will then `close' the trap. +trap 'exit_status=$? + # Save into config.log some information that might help in debugging. + { + echo + cat <<\_ASBOX +## ---------------- ## +## Cache variables. ## +## ---------------- ## +_ASBOX + echo + # The following way of writing the cache mishandles newlines in values, +{ + (set) 2>&1 | + case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in + *ac_space=\ *) + sed -n \ + "s/'"'"'/'"'"'\\\\'"'"''"'"'/g; + s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p" + ;; + *) + sed -n \ + "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p" + ;; + esac; +} + echo + if test -s confdefs.h; then + cat <<\_ASBOX +## ----------- ## +## confdefs.h. ## +## ----------- ## +_ASBOX + echo + sed "/^$/d" confdefs.h + echo + fi + test "$ac_signal" != 0 && + echo "$as_me: caught signal $ac_signal" + echo "$as_me: exit $exit_status" + } >&5 + rm -f core core.* *.core && + rm -rf conftest* confdefs* conf$$* $ac_clean_files && + exit $exit_status + ' 0 +for ac_signal in 1 2 13 15; do + trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal +done +ac_signal=0 + +# confdefs.h avoids OS command line length limits that DEFS can exceed. +rm -rf conftest* confdefs.h +# AIX cpp loses on an empty file, so make sure it contains at least a newline. +echo >confdefs.h + +# Predefined preprocessor variables. + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_NAME "$PACKAGE_NAME" +_ACEOF + + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_TARNAME "$PACKAGE_TARNAME" +_ACEOF + + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_VERSION "$PACKAGE_VERSION" +_ACEOF + + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_STRING "$PACKAGE_STRING" +_ACEOF + + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" +_ACEOF + + +# Let the site file select an alternate cache file if it wants to. # Prefer explicitly selected file to automatically selected ones. if test -z "$CONFIG_SITE"; then if test "x$prefix" != xNONE; then @@ -503,44 +1101,108 @@ fi for ac_site_file in $CONFIG_SITE; do if test -r "$ac_site_file"; then - echo "loading site script $ac_site_file" + { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5 +echo "$as_me: loading site script $ac_site_file" >&6;} + sed 's/^/| /' "$ac_site_file" >&5 . "$ac_site_file" fi done if test -r "$cache_file"; then - echo "loading cache $cache_file" - . $cache_file + # Some versions of bash will fail to source /dev/null (special + # files actually), so we avoid doing that. + if test -f "$cache_file"; then + { echo "$as_me:$LINENO: loading cache $cache_file" >&5 +echo "$as_me: loading cache $cache_file" >&6;} + case $cache_file in + [\\/]* | ?:[\\/]* ) . $cache_file;; + *) . ./$cache_file;; + esac + fi else - echo "creating cache $cache_file" - > $cache_file + { echo "$as_me:$LINENO: creating cache $cache_file" >&5 +echo "$as_me: creating cache $cache_file" >&6;} + >$cache_file +fi + +# Check that the precious variables saved in the cache have kept the same +# value. +ac_cache_corrupted=false +for ac_var in `(set) 2>&1 | + sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do + eval ac_old_set=\$ac_cv_env_${ac_var}_set + eval ac_new_set=\$ac_env_${ac_var}_set + eval ac_old_val="\$ac_cv_env_${ac_var}_value" + eval ac_new_val="\$ac_env_${ac_var}_value" + case $ac_old_set,$ac_new_set in + set,) + { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 +echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} + ac_cache_corrupted=: ;; + ,set) + { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5 +echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} + ac_cache_corrupted=: ;; + ,);; + *) + if test "x$ac_old_val" != "x$ac_new_val"; then + { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5 +echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} + { echo "$as_me:$LINENO: former value: $ac_old_val" >&5 +echo "$as_me: former value: $ac_old_val" >&2;} + { echo "$as_me:$LINENO: current value: $ac_new_val" >&5 +echo "$as_me: current value: $ac_new_val" >&2;} + ac_cache_corrupted=: + fi;; + esac + # Pass precious variables to config.status. + if test "$ac_new_set" = set; then + case $ac_new_val in + *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*) + ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; + *) ac_arg=$ac_var=$ac_new_val ;; + esac + case " $ac_configure_args " in + *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. + *) ac_configure_args="$ac_configure_args '$ac_arg'" ;; + esac + fi +done +if $ac_cache_corrupted; then + { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5 +echo "$as_me: error: changes in the environment can compromise the build" >&2;} + { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5 +echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;} + { (exit 1); exit 1; }; } fi ac_ext=c -# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. ac_cpp='$CPP $CPPFLAGS' -ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' -ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' -cross_compiling=$ac_cv_prog_cc_cross - -ac_exeext= -ac_objext=o -if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then - # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu. - if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then - ac_n= ac_c=' -' ac_t=' ' - else - ac_n=-n ac_c= ac_t= - fi -else - ac_n= ac_c='\c' ac_t= -fi +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + + + + + + + + + + + + + +ac_config_headers="$ac_config_headers config.h" + + ac_aux_dir= for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do if test -f $ac_dir/install-sh; then @@ -551,220 +1213,1023 @@ ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/install.sh -c" break + elif test -f $ac_dir/shtool; then + ac_aux_dir=$ac_dir + ac_install_sh="$ac_aux_dir/shtool install -c" + break fi done if test -z "$ac_aux_dir"; then - { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; } -fi -ac_config_guess=$ac_aux_dir/config.guess -ac_config_sub=$ac_aux_dir/config.sub -ac_configure=$ac_aux_dir/configure # This should be Cygnus configure. + { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5 +echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;} + { (exit 1); exit 1; }; } +fi +ac_config_guess="$SHELL $ac_aux_dir/config.guess" +ac_config_sub="$SHELL $ac_aux_dir/config.sub" +ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure. +# Make sure we can run config.sub. +$ac_config_sub sun4 >/dev/null 2>&1 || + { { echo "$as_me:$LINENO: error: cannot run $ac_config_sub" >&5 +echo "$as_me: error: cannot run $ac_config_sub" >&2;} + { (exit 1); exit 1; }; } + +echo "$as_me:$LINENO: checking build system type" >&5 +echo $ECHO_N "checking build system type... $ECHO_C" >&6 +if test "${ac_cv_build+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + ac_cv_build_alias=$build_alias +test -z "$ac_cv_build_alias" && + ac_cv_build_alias=`$ac_config_guess` +test -z "$ac_cv_build_alias" && + { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5 +echo "$as_me: error: cannot guess build type; you must specify one" >&2;} + { (exit 1); exit 1; }; } +ac_cv_build=`$ac_config_sub $ac_cv_build_alias` || + { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_build_alias failed" >&5 +echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed" >&2;} + { (exit 1); exit 1; }; } + +fi +echo "$as_me:$LINENO: result: $ac_cv_build" >&5 +echo "${ECHO_T}$ac_cv_build" >&6 +build=$ac_cv_build +build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` +build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` +build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` + + +echo "$as_me:$LINENO: checking host system type" >&5 +echo $ECHO_N "checking host system type... $ECHO_C" >&6 +if test "${ac_cv_host+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + ac_cv_host_alias=$host_alias +test -z "$ac_cv_host_alias" && + ac_cv_host_alias=$ac_cv_build_alias +ac_cv_host=`$ac_config_sub $ac_cv_host_alias` || + { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_host_alias failed" >&5 +echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;} + { (exit 1); exit 1; }; } + +fi +echo "$as_me:$LINENO: result: $ac_cv_host" >&5 +echo "${ECHO_T}$ac_cv_host" >&6 +host=$ac_cv_host +host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` +host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` +host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` + + +echo "$as_me:$LINENO: checking target system type" >&5 +echo $ECHO_N "checking target system type... $ECHO_C" >&6 +if test "${ac_cv_target+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + ac_cv_target_alias=$target_alias +test "x$ac_cv_target_alias" = "x" && + ac_cv_target_alias=$ac_cv_host_alias +ac_cv_target=`$ac_config_sub $ac_cv_target_alias` || + { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_target_alias failed" >&5 +echo "$as_me: error: $ac_config_sub $ac_cv_target_alias failed" >&2;} + { (exit 1); exit 1; }; } + +fi +echo "$as_me:$LINENO: result: $ac_cv_target" >&5 +echo "${ECHO_T}$ac_cv_target" >&6 +target=$ac_cv_target +target_cpu=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` +target_vendor=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` +target_os=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` -# Do some error checking and defaulting for the host and target type. -# The inputs are: -# configure --host=HOST --target=TARGET --build=BUILD NONOPT -# -# The rules are: -# 1. You are not allowed to specify --host, --target, and nonopt at the -# same time. -# 2. Host defaults to nonopt. -# 3. If nonopt is not specified, then host defaults to the current host, -# as determined by config.guess. -# 4. Target and build default to nonopt. -# 5. If nonopt is not specified, then target and build default to host. # The aliases save the names the user supplied, while $host etc. # will get canonicalized. -case $host---$target---$nonopt in -NONE---*---* | *---NONE---* | *---*---NONE) ;; -*) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;; -esac - - -# Make sure we can run config.sub. -if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then : -else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; } -fi - -echo $ac_n "checking host system type""... $ac_c" 1>&6 -echo "configure:592: checking host system type" >&5 - -host_alias=$host -case "$host_alias" in -NONE) - case $nonopt in - NONE) - if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then : - else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; } - fi ;; - *) host_alias=$nonopt ;; - esac ;; -esac - -host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias` -host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` -host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` -host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` -echo "$ac_t""$host" 1>&6 - -echo $ac_n "checking target system type""... $ac_c" 1>&6 -echo "configure:613: checking target system type" >&5 - -target_alias=$target -case "$target_alias" in -NONE) - case $nonopt in - NONE) target_alias=$host_alias ;; - *) target_alias=$nonopt ;; - esac ;; -esac - -target=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $target_alias` -target_cpu=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` -target_vendor=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` -target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` -echo "$ac_t""$target" 1>&6 - -echo $ac_n "checking build system type""... $ac_c" 1>&6 -echo "configure:631: checking build system type" >&5 - -build_alias=$build -case "$build_alias" in -NONE) - case $nonopt in - NONE) build_alias=$host_alias ;; - *) build_alias=$nonopt ;; - esac ;; -esac - -build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias` -build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` -build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` -build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` -echo "$ac_t""$build" 1>&6 - -test "$host_alias" != "$target_alias" && +test -n "$target_alias" && test "$program_prefix$program_suffix$program_transform_name" = \ NONENONEs,x,x, && program_prefix=${target_alias}- - -# Check whether --enable-codedb or --disable-codedb was given. -if test "${enable_codedb+set}" = set; then - enableval="$enable_codedb" - : +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. +set dummy ${ac_tool_prefix}gcc; ac_word=$2 +echo "$as_me:$LINENO: checking for $ac_word" >&5 +echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +if test "${ac_cv_prog_CC+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 else - - LIBS="$LIBS -L/usr/local/lib" - echo $ac_n "checking for gdbm_open in -lgdbm""... $ac_c" 1>&6 -echo "configure:663: checking for gdbm_open in -lgdbm" >&5 -ac_lib_var=`echo gdbm'_'gdbm_open | sed 'y%./+-%__p_%'` -if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 + if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. else - ac_save_LIBS="$LIBS" -LIBS="-lgdbm $LIBS" -cat > conftest.$ac_ext <&5 + break 2 + fi +done +done -int main() { -gdbm_open() -; return 0; } -EOF -if { (eval echo configure:682: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then - rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=yes" +fi +fi +CC=$ac_cv_prog_CC +if test -n "$CC"; then + echo "$as_me:$LINENO: result: $CC" >&5 +echo "${ECHO_T}$CC" >&6 else - echo "configure: failed program was:" >&5 - cat conftest.$ac_ext >&5 - rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=no" + echo "$as_me:$LINENO: result: no" >&5 +echo "${ECHO_T}no" >&6 fi -rm -f conftest* -LIBS="$ac_save_LIBS" fi -if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then - echo "$ac_t""yes" 1>&6 - - ac_libgdbm=yes - cat >> confdefs.h <<\EOF -#define GDBM 1 -EOF - - +if test -z "$ac_cv_prog_CC"; then + ac_ct_CC=$CC + # Extract the first word of "gcc", so it can be a program name with args. +set dummy gcc; ac_word=$2 +echo "$as_me:$LINENO: checking for $ac_word" >&5 +echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +if test "${ac_cv_prog_ac_ct_CC+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 else - echo "$ac_t""no" 1>&6 - - ac_libgdbm= - echo $ac_n "checking for dbm_open in -lndbm""... $ac_c" 1>&6 -echo "configure:709: checking for dbm_open in -lndbm" >&5 -ac_lib_var=`echo ndbm'_'dbm_open | sed 'y%./+-%__p_%'` -if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 + if test -n "$ac_ct_CC"; then + ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. else - ac_save_LIBS="$LIBS" -LIBS="-lndbm $LIBS" -cat > conftest.$ac_ext <&5 + break 2 + fi +done +done + +fi +fi +ac_ct_CC=$ac_cv_prog_ac_ct_CC +if test -n "$ac_ct_CC"; then + echo "$as_me:$LINENO: result: $ac_ct_CC" >&5 +echo "${ECHO_T}$ac_ct_CC" >&6 +else + echo "$as_me:$LINENO: result: no" >&5 +echo "${ECHO_T}no" >&6 +fi + + CC=$ac_ct_CC +else + CC="$ac_cv_prog_CC" +fi + +if test -z "$CC"; then + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. +set dummy ${ac_tool_prefix}cc; ac_word=$2 +echo "$as_me:$LINENO: checking for $ac_word" >&5 +echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +if test "${ac_cv_prog_CC+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_CC="${ac_tool_prefix}cc" + echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done +done + +fi +fi +CC=$ac_cv_prog_CC +if test -n "$CC"; then + echo "$as_me:$LINENO: result: $CC" >&5 +echo "${ECHO_T}$CC" >&6 +else + echo "$as_me:$LINENO: result: no" >&5 +echo "${ECHO_T}no" >&6 +fi + +fi +if test -z "$ac_cv_prog_CC"; then + ac_ct_CC=$CC + # Extract the first word of "cc", so it can be a program name with args. +set dummy cc; ac_word=$2 +echo "$as_me:$LINENO: checking for $ac_word" >&5 +echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +if test "${ac_cv_prog_ac_ct_CC+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + if test -n "$ac_ct_CC"; then + ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_CC="cc" + echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done +done + +fi +fi +ac_ct_CC=$ac_cv_prog_ac_ct_CC +if test -n "$ac_ct_CC"; then + echo "$as_me:$LINENO: result: $ac_ct_CC" >&5 +echo "${ECHO_T}$ac_ct_CC" >&6 +else + echo "$as_me:$LINENO: result: no" >&5 +echo "${ECHO_T}no" >&6 +fi + + CC=$ac_ct_CC +else + CC="$ac_cv_prog_CC" +fi + +fi +if test -z "$CC"; then + # Extract the first word of "cc", so it can be a program name with args. +set dummy cc; ac_word=$2 +echo "$as_me:$LINENO: checking for $ac_word" >&5 +echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +if test "${ac_cv_prog_CC+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else + ac_prog_rejected=no +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then + ac_prog_rejected=yes + continue + fi + ac_cv_prog_CC="cc" + echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done +done + +if test $ac_prog_rejected = yes; then + # We found a bogon in the path, so make sure we never use it. + set dummy $ac_cv_prog_CC + shift + if test $# != 0; then + # We chose a different compiler from the bogus one. + # However, it has the same basename, so the bogon will be chosen + # first if we set CC to just the basename; use the full file name. + shift + set dummy "$as_dir/$ac_word" ${1+"$@"} + shift + ac_cv_prog_CC="$@" + fi +fi +fi +fi +CC=$ac_cv_prog_CC +if test -n "$CC"; then + echo "$as_me:$LINENO: result: $CC" >&5 +echo "${ECHO_T}$CC" >&6 +else + echo "$as_me:$LINENO: result: no" >&5 +echo "${ECHO_T}no" >&6 +fi + +fi +if test -z "$CC"; then + if test -n "$ac_tool_prefix"; then + for ac_prog in cl + do + # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. +set dummy $ac_tool_prefix$ac_prog; ac_word=$2 +echo "$as_me:$LINENO: checking for $ac_word" >&5 +echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +if test "${ac_cv_prog_CC+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_CC="$ac_tool_prefix$ac_prog" + echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done +done + +fi +fi +CC=$ac_cv_prog_CC +if test -n "$CC"; then + echo "$as_me:$LINENO: result: $CC" >&5 +echo "${ECHO_T}$CC" >&6 +else + echo "$as_me:$LINENO: result: no" >&5 +echo "${ECHO_T}no" >&6 +fi + + test -n "$CC" && break + done +fi +if test -z "$CC"; then + ac_ct_CC=$CC + for ac_prog in cl +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +echo "$as_me:$LINENO: checking for $ac_word" >&5 +echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +if test "${ac_cv_prog_ac_ct_CC+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + if test -n "$ac_ct_CC"; then + ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_CC="$ac_prog" + echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done +done + +fi +fi +ac_ct_CC=$ac_cv_prog_ac_ct_CC +if test -n "$ac_ct_CC"; then + echo "$as_me:$LINENO: result: $ac_ct_CC" >&5 +echo "${ECHO_T}$ac_ct_CC" >&6 +else + echo "$as_me:$LINENO: result: no" >&5 +echo "${ECHO_T}no" >&6 +fi + + test -n "$ac_ct_CC" && break +done + + CC=$ac_ct_CC +fi + +fi + + +test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH" >&5 +echo "$as_me: error: no acceptable C compiler found in \$PATH" >&2;} + { (exit 1); exit 1; }; } + +# Provide some information about the compiler. +echo "$as_me:$LINENO:" \ + "checking for C compiler version" >&5 +ac_compiler=`set X $ac_compile; echo $2` +{ (eval echo "$as_me:$LINENO: \"$ac_compiler --version &5\"") >&5 + (eval $ac_compiler --version &5) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } +{ (eval echo "$as_me:$LINENO: \"$ac_compiler -v &5\"") >&5 + (eval $ac_compiler -v &5) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } +{ (eval echo "$as_me:$LINENO: \"$ac_compiler -V &5\"") >&5 + (eval $ac_compiler -V &5) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } + +cat >conftest.$ac_ext <<_ACEOF +#line $LINENO "configure" #include "confdefs.h" -/* Override any gcc2 internal prototype to avoid an error. */ -/* We use char because int might match the return type of a gcc2 - builtin and then its argument prototype would still apply. */ -char dbm_open(); -int main() { -dbm_open() -; return 0; } -EOF -if { (eval echo configure:728: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then - rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=yes" +#ifdef F77_DUMMY_MAIN +# ifdef __cplusplus + extern "C" +# endif + int F77_DUMMY_MAIN() { return 1; } +#endif +int +main () +{ + + ; + return 0; +} +_ACEOF +ac_clean_files_save=$ac_clean_files +ac_clean_files="$ac_clean_files a.out a.exe" +# Try to create an executable without -o first, disregard a.out. +# It will help us diagnose broken compilers, and finding out an intuition +# of exeext. +echo "$as_me:$LINENO: checking for C compiler default output" >&5 +echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6 +ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` +if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5 + (eval $ac_link_default) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; then + # Find the output, starting from the most likely. This scheme is +# not robust to junk in `.', hence go to wildcards (a.*) only as a last +# resort. + +# Be careful to initialize this variable, since it used to be cached. +# Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile. +ac_cv_exeext= +for ac_file in `ls a_out.exe a.exe conftest.exe 2>/dev/null; + ls a.out conftest 2>/dev/null; + ls a.* conftest.* 2>/dev/null`; do + case $ac_file in + *.$ac_ext | *.o | *.obj | *.xcoff | *.tds | *.d | *.pdb | *.xSYM ) ;; + a.out ) # We found the default executable, but exeext='' is most + # certainly right. + break;; + *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` + # FIXME: I believe we export ac_cv_exeext for Libtool --akim. + export ac_cv_exeext + break;; + * ) break;; + esac +done else - echo "configure: failed program was:" >&5 - cat conftest.$ac_ext >&5 - rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=no" + echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 +{ { echo "$as_me:$LINENO: error: C compiler cannot create executables" >&5 +echo "$as_me: error: C compiler cannot create executables" >&2;} + { (exit 77); exit 77; }; } +fi + +ac_exeext=$ac_cv_exeext +echo "$as_me:$LINENO: result: $ac_file" >&5 +echo "${ECHO_T}$ac_file" >&6 + +# Check the compiler produces executables we can run. If not, either +# the compiler is broken, or we cross compile. +echo "$as_me:$LINENO: checking whether the C compiler works" >&5 +echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6 +# FIXME: These cross compiler hacks should be removed for Autoconf 3.0 +# If not cross compiling, check that we can run a simple program. +if test "$cross_compiling" != yes; then + if { ac_try='./$ac_file' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + cross_compiling=no + else + if test "$cross_compiling" = maybe; then + cross_compiling=yes + else + { { echo "$as_me:$LINENO: error: cannot run C compiled programs. +If you meant to cross compile, use \`--host'." >&5 +echo "$as_me: error: cannot run C compiled programs. +If you meant to cross compile, use \`--host'." >&2;} + { (exit 1); exit 1; }; } + fi + fi +fi +echo "$as_me:$LINENO: result: yes" >&5 +echo "${ECHO_T}yes" >&6 + +rm -f a.out a.exe conftest$ac_cv_exeext +ac_clean_files=$ac_clean_files_save +# Check the compiler produces executables we can run. If not, either +# the compiler is broken, or we cross compile. +echo "$as_me:$LINENO: checking whether we are cross compiling" >&5 +echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6 +echo "$as_me:$LINENO: result: $cross_compiling" >&5 +echo "${ECHO_T}$cross_compiling" >&6 + +echo "$as_me:$LINENO: checking for suffix of executables" >&5 +echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6 +if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 + (eval $ac_link) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; then + # If both `conftest.exe' and `conftest' are `present' (well, observable) +# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will +# work properly (i.e., refer to `conftest.exe'), while it won't with +# `rm'. +for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do + case $ac_file in + *.$ac_ext | *.o | *.obj | *.xcoff | *.tds | *.d | *.pdb ) ;; + *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` + export ac_cv_exeext + break;; + * ) break;; + esac +done +else + { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link" >&5 +echo "$as_me: error: cannot compute suffix of executables: cannot compile and link" >&2;} + { (exit 1); exit 1; }; } +fi + +rm -f conftest$ac_cv_exeext +echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5 +echo "${ECHO_T}$ac_cv_exeext" >&6 + +rm -f conftest.$ac_ext +EXEEXT=$ac_cv_exeext +ac_exeext=$EXEEXT +echo "$as_me:$LINENO: checking for suffix of object files" >&5 +echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6 +if test "${ac_cv_objext+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + cat >conftest.$ac_ext <<_ACEOF +#line $LINENO "configure" +#include "confdefs.h" + +#ifdef F77_DUMMY_MAIN +# ifdef __cplusplus + extern "C" +# endif + int F77_DUMMY_MAIN() { return 1; } +#endif +int +main () +{ + + ; + return 0; +} +_ACEOF +rm -f conftest.o conftest.obj +if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; then + for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do + case $ac_file in + *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb ) ;; + *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` + break;; + esac +done +else + echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 +{ { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile" >&5 +echo "$as_me: error: cannot compute suffix of object files: cannot compile" >&2;} + { (exit 1); exit 1; }; } +fi + +rm -f conftest.$ac_cv_objext conftest.$ac_ext +fi +echo "$as_me:$LINENO: result: $ac_cv_objext" >&5 +echo "${ECHO_T}$ac_cv_objext" >&6 +OBJEXT=$ac_cv_objext +ac_objext=$OBJEXT +echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5 +echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6 +if test "${ac_cv_c_compiler_gnu+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + cat >conftest.$ac_ext <<_ACEOF +#line $LINENO "configure" +#include "confdefs.h" + +#ifdef F77_DUMMY_MAIN +# ifdef __cplusplus + extern "C" +# endif + int F77_DUMMY_MAIN() { return 1; } +#endif +int +main () +{ +#ifndef __GNUC__ + choke me +#endif + + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + ac_compiler_gnu=yes +else + echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 +ac_compiler_gnu=no +fi +rm -f conftest.$ac_objext conftest.$ac_ext +ac_cv_c_compiler_gnu=$ac_compiler_gnu + +fi +echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5 +echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6 +GCC=`test $ac_compiler_gnu = yes && echo yes` +ac_test_CFLAGS=${CFLAGS+set} +ac_save_CFLAGS=$CFLAGS +CFLAGS="-g" +echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5 +echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6 +if test "${ac_cv_prog_cc_g+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + cat >conftest.$ac_ext <<_ACEOF +#line $LINENO "configure" +#include "confdefs.h" + +#ifdef F77_DUMMY_MAIN +# ifdef __cplusplus + extern "C" +# endif + int F77_DUMMY_MAIN() { return 1; } +#endif +int +main () +{ + + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + ac_cv_prog_cc_g=yes +else + echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 +ac_cv_prog_cc_g=no +fi +rm -f conftest.$ac_objext conftest.$ac_ext +fi +echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5 +echo "${ECHO_T}$ac_cv_prog_cc_g" >&6 +if test "$ac_test_CFLAGS" = set; then + CFLAGS=$ac_save_CFLAGS +elif test $ac_cv_prog_cc_g = yes; then + if test "$GCC" = yes; then + CFLAGS="-g -O2" + else + CFLAGS="-g" + fi +else + if test "$GCC" = yes; then + CFLAGS="-O2" + else + CFLAGS= + fi +fi +# Some people use a C++ compiler to compile C. Since we use `exit', +# in C++ we need to declare it. In case someone uses the same compiler +# for both compiling C and C++ we need to have the C++ compiler decide +# the declaration of exit, since it's the most demanding environment. +cat >conftest.$ac_ext <<_ACEOF +#ifndef __cplusplus + choke me +#endif +_ACEOF +rm -f conftest.$ac_objext +if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + for ac_declaration in \ + ''\ + '#include ' \ + 'extern "C" void std::exit (int) throw (); using std::exit;' \ + 'extern "C" void std::exit (int); using std::exit;' \ + 'extern "C" void exit (int) throw ();' \ + 'extern "C" void exit (int);' \ + 'void exit (int);' +do + cat >conftest.$ac_ext <<_ACEOF +#line $LINENO "configure" +#include "confdefs.h" +#include +$ac_declaration +#ifdef F77_DUMMY_MAIN +# ifdef __cplusplus + extern "C" +# endif + int F77_DUMMY_MAIN() { return 1; } +#endif +int +main () +{ +exit (42); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + : +else + echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 +continue +fi +rm -f conftest.$ac_objext conftest.$ac_ext + cat >conftest.$ac_ext <<_ACEOF +#line $LINENO "configure" +#include "confdefs.h" +$ac_declaration +#ifdef F77_DUMMY_MAIN +# ifdef __cplusplus + extern "C" +# endif + int F77_DUMMY_MAIN() { return 1; } +#endif +int +main () +{ +exit (42); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + break +else + echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 fi +rm -f conftest.$ac_objext conftest.$ac_ext +done rm -f conftest* -LIBS="$ac_save_LIBS" +if test -n "$ac_declaration"; then + echo '#ifdef __cplusplus' >>confdefs.h + echo $ac_declaration >>confdefs.h + echo '#endif' >>confdefs.h +fi +else + echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 fi -if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then - echo "$ac_t""yes" 1>&6 - - ac_libndbm=yes - cat >> confdefs.h <<\EOF +rm -f conftest.$ac_objext conftest.$ac_ext +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + +# Check whether --enable-codedb or --disable-codedb was given. +if test "${enable_codedb+set}" = set; then + enableval="$enable_codedb" + +else + + case "$host_os" in + cygwin) + ;; + *) + LIBS="$LIBS -L/usr/local/lib" + echo "$as_me:$LINENO: checking for gdbm_open in -lgdbm" >&5 +echo $ECHO_N "checking for gdbm_open in -lgdbm... $ECHO_C" >&6 +if test "${ac_cv_lib_gdbm_gdbm_open+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lgdbm $LIBS" +cat >conftest.$ac_ext <<_ACEOF +#line $LINENO "configure" +#include "confdefs.h" + +/* Override any gcc2 internal prototype to avoid an error. */ +#ifdef __cplusplus +extern "C" +#endif +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char gdbm_open (); +#ifdef F77_DUMMY_MAIN +# ifdef __cplusplus + extern "C" +# endif + int F77_DUMMY_MAIN() { return 1; } +#endif +int +main () +{ +gdbm_open (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext conftest$ac_exeext +if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 + (eval $ac_link) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + ac_cv_lib_gdbm_gdbm_open=yes +else + echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 +ac_cv_lib_gdbm_gdbm_open=no +fi +rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +echo "$as_me:$LINENO: result: $ac_cv_lib_gdbm_gdbm_open" >&5 +echo "${ECHO_T}$ac_cv_lib_gdbm_gdbm_open" >&6 +if test $ac_cv_lib_gdbm_gdbm_open = yes; then + + ac_libgdbm=yes + cat >>confdefs.h <<\_ACEOF +#define GDBM 1 +_ACEOF + + +else + + ac_libgdbm= + echo "$as_me:$LINENO: checking for dbm_open in -lndbm" >&5 +echo $ECHO_N "checking for dbm_open in -lndbm... $ECHO_C" >&6 +if test "${ac_cv_lib_ndbm_dbm_open+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lndbm $LIBS" +cat >conftest.$ac_ext <<_ACEOF +#line $LINENO "configure" +#include "confdefs.h" + +/* Override any gcc2 internal prototype to avoid an error. */ +#ifdef __cplusplus +extern "C" +#endif +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char dbm_open (); +#ifdef F77_DUMMY_MAIN +# ifdef __cplusplus + extern "C" +# endif + int F77_DUMMY_MAIN() { return 1; } +#endif +int +main () +{ +dbm_open (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext conftest$ac_exeext +if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 + (eval $ac_link) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + ac_cv_lib_ndbm_dbm_open=yes +else + echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 +ac_cv_lib_ndbm_dbm_open=no +fi +rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +echo "$as_me:$LINENO: result: $ac_cv_lib_ndbm_dbm_open" >&5 +echo "${ECHO_T}$ac_cv_lib_ndbm_dbm_open" >&6 +if test $ac_cv_lib_ndbm_dbm_open = yes; then + + ac_libndbm=yes + cat >>confdefs.h <<\_ACEOF #define NDBM 1 -EOF +_ACEOF + - else - echo "$ac_t""no" 1>&6 - ac_libndbm= - ac_libndbm=yes - + ac_libndbm= + ac_libndbm=yes + fi - + fi - ac_codedb=yes - cat >> confdefs.h <<\EOF + ac_codedb=yes + cat >>confdefs.h <<\_ACEOF #define CODE_DB 1 -EOF +_ACEOF - -fi + ;; + esac +fi; @@ -772,97 +2237,95 @@ # Check whether --enable-sse2 or --disable-sse2 was given. if test "${enable_sse2+set}" = set; then enableval="$enable_sse2" - + ac_sse2=yes - cat >> confdefs.h <<\EOF + cat >>confdefs.h <<\_ACEOF #define USE_SSE2 1 -EOF +_ACEOF - -fi +fi; # Check whether --enable-moba or --disable-moba was given. if test "${enable_moba+set}" = set; then enableval="$enable_moba" - + ac_moba=yes - cat >> confdefs.h <<\EOF + cat >>confdefs.h <<\_ACEOF #define MOBA 1 -EOF +_ACEOF - -fi +fi; # Check whether --enable-metavm_no_array or --disable-metavm_no_array was given. if test "${enable_metavm_no_array+set}" = set; then enableval="$enable_metavm_no_array" - + ac_metavm=yes ac_metavm_no_array=yes - cat >> confdefs.h <<\EOF + cat >>confdefs.h <<\_ACEOF #define METAVM 1 -EOF +_ACEOF - cat >> confdefs.h <<\EOF + cat >>confdefs.h <<\_ACEOF #define METAVM_NO_ARRAY 1 -EOF +_ACEOF - -else - ac_metavm_no_array= -fi +else + ac_metavm_no_array= +fi; # Check whether --enable-metavm or --disable-metavm was given. if test "${enable_metavm+set}" = set; then enableval="$enable_metavm" - + ac_metavm=yes - cat >> confdefs.h <<\EOF + cat >>confdefs.h <<\_ACEOF #define METAVM 1 -EOF +_ACEOF - -fi +fi; -echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6 -echo "configure:839: checking whether ${MAKE-make} sets \${MAKE}" >&5 -set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'` -if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 +echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \${MAKE}" >&5 +echo $ECHO_N "checking whether ${MAKE-make} sets \${MAKE}... $ECHO_C" >&6 +set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,./+-,__p_,'` +if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then + echo $ECHO_N "(cached) $ECHO_C" >&6 else - cat > conftestmake <<\EOF + cat >conftest.make <<\_ACEOF all: @echo 'ac_maketemp="${MAKE}"' -EOF +_ACEOF # GNU make sometimes prints "make[1]: Entering...", which would confuse us. -eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=` +eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=` if test -n "$ac_maketemp"; then eval ac_cv_prog_make_${ac_make}_set=yes else eval ac_cv_prog_make_${ac_make}_set=no fi -rm -f conftestmake +rm -f conftest.make fi if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then - echo "$ac_t""yes" 1>&6 + echo "$as_me:$LINENO: result: yes" >&5 +echo "${ECHO_T}yes" >&6 SET_MAKE= else - echo "$ac_t""no" 1>&6 + echo "$as_me:$LINENO: result: no" >&5 +echo "${ECHO_T}no" >&6 SET_MAKE="MAKE=${MAKE-make}" fi -echo $ac_n "checking C compiler""... $ac_c" 1>&6 -echo "configure:866: checking C compiler" >&5 +echo "$as_me:$LINENO: checking C compiler" >&5 +echo $ECHO_N "checking C compiler... $ECHO_C" >&6 ac_cc=no if test -n "$CC"; then if test -f "$CC"; then @@ -870,38 +2333,42 @@ else # Extract the first word of "$CC", so it can be a program name with args. set dummy $CC; ac_word=$2 -echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:875: checking for $ac_word" >&5 -if eval "test \"`echo '$''{'ac_cv_path_ac_cc'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 +echo "$as_me:$LINENO: checking for $ac_word" >&5 +echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +if test "${ac_cv_path_ac_cc+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 else - case "$ac_cc" in - /*) + case $ac_cc in + [\\/]* | ?:[\\/]*) ac_cv_path_ac_cc="$ac_cc" # Let the user override the test with a path. ;; - ?:/*) - ac_cv_path_ac_cc="$ac_cc" # Let the user override the test with a dos path. - ;; *) - IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" - ac_dummy="$PATH" - for ac_dir in $ac_dummy; do - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/$ac_word; then - ac_cv_path_ac_cc="$ac_dir/$ac_word" - break - fi - done - IFS="$ac_save_ifs" + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_path_ac_cc="$as_dir/$a