TimeZoneInfo in 2.3.0.1 on Mono in Ubuntu 9.04 Desktop

mojoPortal is no longer supported on mono. This forum is here for archival purposes.

This thread is closed to new posts. You must sign in to post in the forums.
4/29/2009 3:41:16 PM
Gravatar
Total Posts 1

TimeZoneInfo in 2.3.0.1 on Mono in Ubuntu 9.04 Desktop

I have just installed a new Linux box (Ubuntu Desktop 9.04) (corporatate mandate to use Linux for our external websites) and installed Mono, MonoDevelop (2.0).

I then proceeded to download mojoPortal 2.3.0.1 sqlite and decompressed it and dropped it into /var/www and I was welcomed with various issues - I found what I needed to comment out of Web.config to get it past the internal issues but was ultimately halted at a point: Could not load type 'mojoPortal.Web.MonoCompilationSection, mojoPortal.Web'.

So I figured I needed to compile it from source.

I downloaded the source edition and loaded the .mds and hit F7 - it crunched away for a bit but then I was greeted with (in the middle of the compile):

/home/christian/Desktop/sourcecode/mojoportal/mojoPortal.Web.Framework/DateTimeHelper.cs(142,28): error CS0246: The type or namespace name `TimeZoneInfo' could not be found. Are you missing a using directive or an assembly reference?
/home/christian/Desktop/sourcecode/mojoportal/mojoPortal.Web.Framework/DateTimeHelper.cs(245,23): error CS0246: The type or namespace name `TimeZoneInfo' could not be found. Are you missing a using directive or an assembly reference?
/home/christian/Desktop/sourcecode/mojoportal/mojoPortal.Web.Framework/DateTimeHelper.cs(255,72): error CS0246: The type or namespace name `TimeZoneInfo' could not be found. Are you missing a using directive or an assembly reference?


Build complete -- 3 errors, 2 warnings

I looked at the first instance of the error and there is a comment indicating that this is known.

/// <summary>

/// The plan is to use this for setting the site default time zone and user time zones.

/// As of 2009-04-06 its throwing NotImplementedException on Mono if you invoke this method.

/// So we are holding off on using it for now to keep from breaking compatibility with Mono.

/// TimeZoneInfo is a new class in 3.5 .NET

/// https://bugzilla.novell.com/show_bug.cgi?id=492924

/// </summary>

 

The question is: How do I get around this - more specifically - what is the appropriate workaround. I am confident that I could hack a new TimeZoneInfo object, but is that the right thing to do?)

 

Is there a specific Binary available for Mono, one that has all the Web.config stuff already done for me?

 

I will donate $15 if I can have this before Friday the 1st of May!

 

Thanks!

 

/// <returns></returns>

4/29/2009 3:47:14 PM
Gravatar
Total Posts 18439

Re: TimeZoneInfo in 2.3.0.1 on Mono in Ubuntu 9.04 Desktop

Hi,

You should get the mojoportal-2-3-0-1-pgsqlreleasefiles-for-mono.zip, then replace the /bin/*Data.dll files with the ones from the SQLite package.

Thats should get you goinf using xsp2 at least. I think there may be still some bugs in Mono 2.4 for mod_mono and also an issue with the password recovery as indicated in other psots in this forum. 

Hope it helps,

Joe

4/29/2009 3:50:00 PM
Gravatar
Total Posts 18439

Re: TimeZoneInfo in 2.3.0.1 on Mono in Ubuntu 9.04 Desktop

Alternately, you can comment out the code for the methods that use the new TimeZoneInfo classes, they are not actually used yet in mojoportal because I know they throw not implemented exceptions, but on my suse machine it does compile and doesn't throw any runtime errors under xsp at least, because that code is not used yet.

Hope it helps,

Joe 

You must sign in to post in the forums. This thread is closed to new posts.