This is the mail archive of the java-discuss@sources.redhat.com mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: libjava configuration problems


> 
> I'm trying to get libjava working on an arm-netbsd target and have run 
> into the following problem whilst building libjava.
> 
> Autoconf has a test for a variable called timezone, which it tests with 
> 
>    AC_TRY_COMPILE([#include <time.h>], [long z2 = timezone;],
>      [AC_DEFINE(HAVE_TIMEZONE)
>       AC_MSG_RESULT(yes)],
>      [AC_MSG_RESULT(no)])])
> 
> 
> Unfortunately this test passes on NetBSD when it should fail.  timezone 
> exists, but is a function not a variable.  When g++ comes to compile 
> java/lang/natSystem.cc we then get a build failure
> 
> /home/rearnsha/gnusrc/egcs/libjava/java/lang/natSystem.cc: In static 
> member
>    function `static java::lang::String* 
>    java::lang::System::getSystemTimeZone()':
> /home/rearnsha/gnusrc/egcs/libjava/java/lang/natSystem.cc:251: cannot 
> convert
>    `char*()(int, int)' to `long int' in assignment
> 
> 
> Any ideas how to fix the test for this?

Actually, this is wrong,  the test did fail.  So why does natSystem.cc 
still try to use 'timezone'?

R.



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]