Re: [Mono-list] build once, run anywhere?

2011-05-03 Thread Jeffrey Stedfast
On 05/03/2011 07:08 PM, pshomov wrote:
 Hi guys,

 I am building mono from source on one machine and then I am zipping the
 binaries and copying them over to other machines and using them (saving on
 the build time here). Is this a good idea? I am getting some exceptions from
 mono on these other machines that are making me suspicious.

The problem with doing this is that different distros (and versions of 
the same distro) bundle different versions of libraries and might put 
them in different locations, etc.

You might also not realize that you are missing libraries (since you 
didn't get a build warning) on some machines.

Also need to make sure all systems are the same architecture.

Jeff

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-dev] undefined reference to `libiconv'

2011-04-27 Thread Jeffrey Stedfast
On 04/26/2011 10:54 PM, Makoto KISHIMOTO wrote:
 Hello,

 In my FreeBSD Box, mono trunk build failed.
 The following is build log.

 $ gmake
 gmake  all-recursive
 gmake[1]: Entering directory `/export/home/ksmakoto/Mono/BUILD'

 (snip)

 gmake[2]: Leaving directory `/export/home/ksmakoto/Mono/BUILD/libgc'
 Making all in eglib
 gmake[2]: Entering directory `/export/home/ksmakoto/Mono/BUILD/eglib'
 gmake  all-recursive
 gmake[3]: Entering directory `/export/home/ksmakoto/Mono/BUILD/eglib'
 Making all in m4
 gmake[4]: Entering directory `/export/home/ksmakoto/Mono/BUILD/eglib/m4'
 gmake[4]: Nothing to be done for `all'.
 gmake[4]: Leaving directory `/export/home/ksmakoto/Mono/BUILD/eglib/m4'
 Making all in src
 gmake[4]: Entering directory `/export/home/ksmakoto/Mono/BUILD/eglib/src'
 gmake[4]: Nothing to be done for `all'.
 gmake[4]: Leaving directory `/export/home/ksmakoto/Mono/BUILD/eglib/src'
 Making all in test
 gmake[4]: Entering directory `/export/home/ksmakoto/Mono/BUILD/eglib/test'
 ./doltlibtool --tag=CC   --mode=link gcc -Wall -D_FORTIFY_SOURCE=2 
 -I../../../mono/eglib/test/../src -I../src -DDRIVER_NAME=\EGlib\ -g -O2 -g 
 -D_GNU_SOURCE  -Wl,-export-dynamic -o test-eglib test_eglib-test.o 
 test_eglib-driver.o test_eglib-hashtable.o test_eglib-string-util.o 
 test_eglib-string.o test_eglib-slist.o test_eglib-sizes.o 
 test_eglib-ptrarray.o test_eglib-list.o test_eglib-array.o test_eglib-fake.o 
 test_eglib-path.o test_eglib-queue.o test_eglib-shell.o test_eglib-spawn.o 
 test_eglib-timer.o test_eglib-file.o test_eglib-pattern.o test_eglib-dir.o 
 test_eglib-markup.o test_eglib-unicode.o test_eglib-utf8.o 
 test_eglib-endian.o test_eglib-module.o test_eglib-memory.o 
 ../src/libeglib.la -lm
 libtool: link: gcc -Wall -D_FORTIFY_SOURCE=2 
 -I../../../mono/eglib/test/../src -I../src -DDRIVER_NAME=\EGlib\ -g -O2 -g 
 -D_GNU_SOURCE -Wl,-export-dynamic -o test-eglib test_eglib-test.o 
 test_eglib-driver.o test_eglib-hashtable.o test_eglib-string-util.o 
 test_eglib-string.o test_eglib-slist.o test_eglib-sizes.o 
 test_eglib-ptrarray.o test_eglib-list.o test_eglib-array.o test_eglib-fake.o 
 test_eglib-path.o test_eglib-queue.o test_eglib-shell.o test_eglib-spawn.o 
 test_eglib-timer.o test_eglib-file.o test_eglib-pattern.o test_eglib-dir.o 
 test_eglib-markup.o test_eglib-unicode.o test_eglib-utf8.o 
 test_eglib-endian.o test_eglib-module.o test_eglib-memory.o  
 ../src/.libs/libeglib.a -lm
 ./src/.libs/libeglib.a(libeglib_la-gunicode.o)(.text+0x5b6): In function 
 `monoeg_g_get_charset':
 ./../../mono/eglib/src/gunicode.c:362: undefined reference to `locale_charset'

Looks like configure detected that your system had localcharset.h which 
should have prototyped a function called locale_charset() which we use 
to get the user's locale charset.

You might be able to fix this by commenting out the #define 
HAVE_LOCALCHARSET_H in config.h

Alternatively, it looks like it might be a part of libiconv (solution 
below).

 ./src/.libs/libeglib.a(libeglib_la-giconv.o)(.text+0x4c): In function 
 `monoeg_g_iconv':
 ./../../mono/eglib/src/giconv.c:177: undefined reference to `libiconv'
 ./src/.libs/libeglib.a(libeglib_la-giconv.o)(.text+0x18f): In function 
 `monoeg_g_iconv_close':
 ./../../mono/eglib/src/giconv.c:158: undefined reference to `libiconv_close'
 ./src/.libs/libeglib.a(libeglib_la-giconv.o)(.text+0x8c6): In function 
 `monoeg_g_iconv_open':
 ./../../mono/eglib/src/giconv.c:132: undefined reference to `libiconv_open'

These errors suggest that configure detected that you had libiconv 
installed, so it tried to use it but apparently thought it was part of 
your libc because I do not see a -liconv in the link line.

I fixed an issue similar to this yesterday, maybe your version of mono 
from git is older than my fix (commit = 
1deef5a760b37cf1e42a60110981d0f752d84d9d ). You can either try updating 
from git or add $(LIBICONV) right after each ($GLIB_LIBS) in the 
Makefile.am files and then rebuild.

Hope that helps,

Jeff

___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-list] gunicode.c:234: error: `ENOTSUP' undeclared (first use in this function)

2011-04-24 Thread Jeffrey Stedfast
On 04/24/2011 02:39 AM, Rod wrote:
 While attempting to make mono from GIT I got this error:

   gunicode.c:234: error: `ENOTSUP' undeclared (first use in this
 function)

 I Google and nothing about gunicode.c and ENOTSUP.

I just fixed this, try pulling from master again.

Jeff

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-dev] [Mono-patches] [mono/moon] caef081d: Implemented an iconv-like API for unicode conversion

2011-04-20 Thread Jeffrey Stedfast

On 04/20/2011 12:00 AM, Rodrigo Kumpera wrote:


Jeff, shouldn't this be part of eglib as a build time option?



I suppose it could be, but I think the plan right now is to simply 
remove g_iconv() from eglib since eglib is supposed to remain a 
minimalist version of glib as per discussion with Miguel.


It's also probably not very useful for most people who want to use 
g_iconv() to *just* have UTF-16/32BE/LE to UTF-8 conversion.


Jeff


On Apr 19, 2011 10:06 PM, Jeffrey Stedfast (f...@gnome.org 
mailto:f...@gnome.org) mono-patc...@lists.ximian.com 
mailto:mono-patc...@lists.ximian.com wrote:


 Branch: refs/heads/master
 Home: https://github.com/mono/moon

 Commit: caef081dc43c17327c37932f65264deec19d8022
 Author: Jeffrey Stedfast f...@gnome.org mailto:f...@gnome.org
 Date: 04/19/2011 21:05:59
 URL: 
https://github.com/mono/moon/commit/caef081dc43c17327c37932f65264deec19d8022


 Implemented an iconv-like API for unicode conversion

 Changed paths:
 M src/Makefile.am
 Added paths:
 A src/miconv.cpp
 A src/miconv.h

 Modified: src/Makefile.am
 ===
 --- a/src/Makefile.am
 +++ b/src/Makefile.am
 @@ -78,6 +78,7 @@ libmoon_include_headers = \
 medialog.h \
 mediaplayer.h \
 messaging.h \
 + miconv.h \
 moon-curves.h \
 moonlightconfiguration.h\
 moon-path.h \
 @@ -234,6 +235,7 @@ dist_libmoon_la_SOURCES = \
 medialog.cpp \
 mediaplayer.cpp \
 messaging.cpp \
 + miconv.cpp \
 moon-curves.c \
 moonlightconfiguration.cpp \
 moon-path.c \

 Added: src/miconv.cpp
 ===
 --- /dev/null
 +++ b/src/miconv.cpp
 @@ -0,0 +1,344 @@
 +/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: t; 
c-basic-offset: 8 -*- */

 +/*
 + * miconv.cpp:
 + *
 + * Contact:
 + * Moonlight List (moonlight-l...@lists.ximian.com 
mailto:moonlight-l...@lists.ximian.com)

 + *
 + * Copyright 2011 Novell, Inc. (http://www.novell.com)
 + *
 + * See the LICENSE file included with the distribution for details.
 + */
 +
 +#include config.h
 +
 +#include glib.h
 +#include string.h
 +#include errno.h
 +
 +#include miconv.h
 +
 +namespace Moonlight {
 +
 +enum Endian {
 + LittleEndian,
 + BigEndian
 +};
 +
 +typedef int (* Decoder) (Endian endian, char **inbytes, size_t 
*inbytesleft, gunichar *outchar);
 +typedef int (* Encoder) (gunichar c, char **outbytes, size_t 
*outbytesleft);

 +
 +static int decode_utf32 (Endian endian, char **inbytes, size_t 
*inbytesleft, gunichar *outchar);
 +//static int encode_utf32 (gunichar c, char **outbytes, size_t 
*outbytesleft);

 +
 +static int decode_utf16 (Endian endian, char **inbytes, size_t 
*inbytesleft, gunichar *outchar);
 +//static int encode_utf16 (gunichar c, char **outbytes, size_t 
*outbytesleft);

 +
 +static int decode_utf8 (Endian endian, char **inbytes, size_t 
*inbytesleft, gunichar *outchar);
 +static int encode_utf8 (gunichar c, char **outbytes, size_t 
*outbytesleft);

 +
 +static struct {
 + const char *name;
 + Decoder decoder;
 + Encoder encoder;
 + Endian endian;
 +} charsets[] = {
 + { UTF-32BE, decode_utf32, NULL, BigEndian },
 + { UTF-32LE, decode_utf32, NULL, LittleEndian },
 + { UTF-16BE, decode_utf16, NULL, BigEndian },
 + { UTF-16LE, decode_utf16, NULL, LittleEndian },
 + { UTF-8, decode_utf8, encode_utf8, LittleEndian },
 +};
 +
 +struct _miconv_t {
 + Decoder decode;
 + Encoder encode;
 + Endian endian;
 + gunichar c;
 +};
 +
 +
 +miconv_t
 +miconv_open (const char *to, const char *from)
 +{
 + Decoder decoder = NULL;
 + Encoder encoder = NULL;
 + Endian endian;
 + miconv_t cd;
 + guint i;
 +
 + if (!to || !from)
 + return (miconv_t) -1;
 +
 + for (i = 0; i  G_N_ELEMENTS (charsets); i++) {
 + if (!strcmp (charsets[i].name, from)) {
 + decoder = charsets[i].decoder;
 + endian = charsets[i].endian;
 + }
 +
 + if (!strcmp (charsets[i].name, to))
 + encoder = charsets[i].encoder;
 + }
 +
 + if (encoder == NULL || decoder == NULL)
 + return (miconv_t) -1;
 +
 + cd = (miconv_t) g_malloc (sizeof (*cd));
 + cd-decode = decoder;
 + cd-encode = encoder;
 + cd-endian = endian;
 + cd-c = -1;
 +
 + return cd;
 +}
 +
 +int
 +miconv_close (miconv_t cd)
 +{
 + g_free (cd);
 + return 0;
 +}
 +
 +int
 +miconv (miconv_t cd, char **inbytes, size_t *inbytesleft,
 + char **outbytes, size_t *outbytesleft)
 +{
 + size_t inleft, outleft;
 + char *inptr, *outptr;
 + gunichar c;
 + int rc = 0;
 +
 + if (outbytes == NULL || outbytesleft == NULL) {
 + /* reset converter */
 + cd-c = -1;
 + return 0;
 + }
 +
 + inleft = inbytesleft ? *inbytesleft : 0;
 + inptr = inbytes ? *inbytes : NULL;
 + outleft = *outbytesleft;
 + outptr = *outbytes;
 + c = cd-c;
 +
 + while (inleft = 0  outleft  0) {
 + if (c == (gunichar) -1  cd-decode (cd-endian, inptr, inleft, 
c) == -1) {

 + rc = -1;
 + break;
 + }
 +
 + if (cd-encode (c, outptr, outleft) == -1) {
 + rc = -1;
 + break;
 + }
 +
 + c = -1;
 + }
 +
 + if (inbytesleft)
 + *inbytesleft = inleft;
 +
 + if (inbytes)
 + *inbytes = inptr

Re: [Mono-dev] Possible QuickSort optimizations for Array.Sort()

2011-04-10 Thread Jeffrey Stedfast

On 04/09/2011 04:39 PM, Jeff Stedfast wrote:

On 04/06/2011 03:18 AM, Marek Safar wrote:

Hello,


public class SortT  {
public delegate int Comparison (T v0, T v1);

You don't need yet another delegate, just use standard Func


static readonly int INSERTIONSORT_THRESHOLD = 7;

Why not to used const int ?

More importantly what is performance of sorting array of 10-20 
elements called 100 times ?




Attached is another test program with 2 newer/faster implementations 
of QuickSort, one of which is Non-Recursive.


You can run this program like so:

mono ./qsort.exe [-random, -sorted, -reversed] [array size] [# loops]

These 2 new implementations manage to reduce the number of comparisons 
done by merging the Median() function from the previous set into the 
main body of the QuickSort function and swapping those 3 elements into 
ascending order as it compares to find the optimal pivot. This has the 
advantage of allowing our loops to start at low+1 and high-1 (thus 
reducing our compares by 2 for each partition).


My previous implementation was able to reduce the compares by 1 by 
starting at low+1 by moving the pivot into low, but this has the 
negative impact of destroying performance on reverse-sorted arrays. My 
new implementation doesn't have this problem (and therefore, we don't 
need to fall back to that insertion-sort if we detect that 
pathological case).


Interestingly, the NonRecursiveQuickSort() implementation does not 
noticeably improve performance over the recursive version and in fact 
is slower than even our current implementation for sorting small 
arrays (made evident when looped millions of times).


How do you feel about replacing corlib's qsort() implementation with 
my FasterQuickSort() implementation?


Jeff


Just to be clear, I meant how do you feel about *me* doing the work to 
replace the current QuickSort impl in corlib with mine? :-)


I just want to make sure before I create a patch that people are interested.

That said, I forgot to include benchmark results:

[fejj@serenity sorting]$ mono ./qsort.exe -random 10 1000
BasicQuickSort comparisons needed: 43000
FasterQuickSort comparisons needed:25000
BasicQuickSort finished in:00:00:18.8535031s
FasterQuickSort finished in:   00:00:16.4478594s

[fejj@serenity sorting]$ mono ./qsort.exe -sorted 10 1000
BasicQuickSort comparisons needed: 33000
FasterQuickSort comparisons needed:18000
BasicQuickSort finished in:00:00:16.9532771s
FasterQuickSort finished in:   00:00:14.1202212s

[fejj@serenity sorting]$ mono ./qsort.exe -reversed 10 1000
BasicQuickSort comparisons needed: 36000
FasterQuickSort comparisons needed:18000
BasicQuickSort finished in:00:00:17.4450895s
FasterQuickSort finished in:   00:00:15.1590930s


Jeff

___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-dev] Possible QuickSort optimizations for Array.Sort()

2011-04-09 Thread Jeffrey Stedfast

On 04/06/2011 03:18 AM, Marek Safar wrote:

Hello,


public class SortT  {
public delegate int Comparison (T v0, T v1);

You don't need yet another delegate, just use standard Func


static readonly int INSERTIONSORT_THRESHOLD = 7;

Why not to used const int ?

More importantly what is performance of sorting array of 10-20 
elements called 100 times ?




Attached is another test program with 2 newer/faster implementations of 
QuickSort, one of which is Non-Recursive.


You can run this program like so:

mono ./qsort.exe [-random, -sorted, -reversed] [array size] [# loops]

These 2 new implementations manage to reduce the number of comparisons 
done by merging the Median() function from the previous set into the 
main body of the QuickSort function and swapping those 3 elements into 
ascending order as it compares to find the optimal pivot. This has the 
advantage of allowing our loops to start at low+1 and high-1 (thus 
reducing our compares by 2 for each partition).


My previous implementation was able to reduce the compares by 1 by 
starting at low+1 by moving the pivot into low, but this has the 
negative impact of destroying performance on reverse-sorted arrays. My 
new implementation doesn't have this problem (and therefore, we don't 
need to fall back to that insertion-sort if we detect that pathological 
case).


Interestingly, the NonRecursiveQuickSort() implementation does not 
noticeably improve performance over the recursive version and in fact is 
slower than even our current implementation for sorting small arrays 
(made evident when looped millions of times).


How do you feel about replacing corlib's qsort() implementation with my 
FasterQuickSort() implementation?


Jeff

using System;
using System.Diagnostics;

namespace SortingTest {
	public class SortT {
		public delegate int Comparison (T v0, T v1);
		
		static void swap (T [] array, int i, int j)
		{
			T tmp = array[i];
			array[i] = array[j];
			array[j] = tmp;
		}
		
		static void QuickSortBasicR (T [] array, int low0, int high0, Comparison comparison)
		{
			int low = low0;
			int high = high0;
			
			// Be careful with overflows
			int mid = low + ((high - low) / 2);
			T keyPivot = array [mid];
			
			while (true) {
if (keyPivot == null) {
	while (low  high0  array [low] == null)
		++low;
	while (high  low0  array [high] != null)
		--high;
} else {
	// Move the walls in
	while (low  high0  comparison (array [low], keyPivot)  0)
		++low;
	while (high  low0  comparison (keyPivot, array [high])  0)
		--high;
}

if (low = high) {
	swap (array, low, high);
	++low;
	--high;
} else
	break;
			}
			
			if (low0  high)
QuickSortBasicR (array, low0, high, comparison);
			if (low  high0)
QuickSortBasicR (array, low, high0, comparison);
		}
		
		public static void QuickSortBasic (T [] array, int index, int length, Comparison comparison)
		{
			QuickSortBasicR (array, index, index + length - 1, comparison);
		}
		
		const int INSERTIONSORT_THRESHOLD = 7;
		
		static void FasterQuickSortR (T [] array, int low, int high, Comparison comparison)
		{
			int mid, i, k;
			T pval;
			
			if ((low + INSERTIONSORT_THRESHOLD)  high) {
// switch to insertion sort
for (i = low + 1; i = high; i++)
	for (k = i; k  low  comparison (array[k], array[k-1])  0; k--)
		swap (array, k - 1, k);

return;
			}
			
			// calculate the middle element
			mid = low + ((high - low) / 2);
			
			// once we re-order the lo, mid, and hi elements to be in
			// ascending order, we'll use mid as our pivot.
			if (comparison (array[mid], array[low])  0)
swap (array, mid, low);
			
			if (comparison (array[high], array[mid])  0) {
swap (array, mid, high);
if (comparison (array[mid], array[low])  0)
	swap (array, mid, low);
			}
			
			/* since we've already guaranteed that lo = mid and mid = hi,
			 * we can skip comparing them again */
			pval = array[mid];
			k = high - 1;
			i = low + 1;
			
			do {
if (pval == null) {
	while (i  k  array[i] == null)
		i++;
	
	while (k = i  array[k] != null)
		k--;
} else {
	// find the first element with a value  pivot value
	while (i  k  comparison (array[i], pval) = 0)
		i++;
	
	// find the last element with a value = pivot value
	while (k = i  comparison (pval, array[k])  0)
		k--;
}

if (k = i)
	break;

swap (array, i, k);

// make sure we keep track of our pivot element
if (mid == i)
	mid = k;
else if (mid == k)
	mid = i;

i++;
k--;
			} while (true);
			
			if (k != mid) {
// swap the pivot with the last element in the first partition
swap (array, mid, k);
			}
			
			/* recursively sort each partition */
			if ((k + 1)  high) FasterQuickSortR (array, k + 1, high, comparison);
			if ((k - 1)  low) FasterQuickSortR (array, low, k - 1, 

Re: [Mono-dev] Possible QuickSort optimizations for Array.Sort()

2011-04-06 Thread Jeffrey Stedfast

On 04/06/2011 03:18 AM, Marek Safar wrote:

Hello,


public class SortT  {
public delegate int Comparison (T v0, T v1);

You don't need yet another delegate, just use standard Func


It was just a quick hack to get things going, if we decide it's worth 
having corlib move to my QuickSort implementation, it would use the same 
standard func corlib is using now.




static readonly int INSERTIONSORT_THRESHOLD = 7;

Why not to used const int ?


I never learned when to use const vs static/readonly in C# :-(

I assume you suggest const because it is more appropriate, so I will :-)



More importantly what is performance of sorting array of 10-20 
elements called 100 times ?



I've attached a sample program to test this in case you'd like to play 
with it some more, but here are the results on my system for 20 elements 
@ 1 million iterations:


[fejj@serenity sorting]$ mono ./qsort-small.exe -random 100
Timings for sorting 20 random items 100 times.
Basic QuickSort finished in: 00:00:03.0227324s
QuickSort+Insertion finished in: 00:00:02.5357660s

[fejj@serenity sorting]$ mono ./qsort-small.exe -sorted 100
Timings for sorting 20 sorted items 100 times.
Basic QuickSort finished in: 00:00:02.3003898s
QuickSort+Insertion finished in: 00:00:01.9493073s

[fejj@serenity sorting]$ mono ./qsort-small.exe -reversed 100
Timings for sorting 20 reversed items 100 times.
Basic QuickSort finished in: 00:00:02.4001482s
QuickSort+Insertion finished in: 00:00:02.3277809s


And here are the results for 10 elements @ 1 million iterations:

[fejj@serenity sorting]$ mono ./qsort-small.exe -random 100
Timings for sorting 10 random items 100 times.
Basic QuickSort finished in: 00:00:01.8165901s
QuickSort+Insertion finished in: 00:00:01.7363410s

[fejj@serenity sorting]$ mono ./qsort-small.exe -sorted 100
Timings for sorting 10 sorted items 100 times.
Basic QuickSort finished in: 00:00:01.7398261s
QuickSort+Insertion finished in: 00:00:01.5270049s

[fejj@serenity sorting]$ mono ./qsort-small.exe -reversed 100
Timings for sorting 10 reversed items 100 times.
Basic QuickSort finished in: 00:00:01.7166351s
QuickSort+Insertion finished in: 00:00:01.6798535s


Hope that helps,

Jeff
using System;
using System.Diagnostics;

namespace SortingTest {
	public class SortT {
		public delegate int Comparison (T v0, T v1);
		
		static void swap (T [] array, int i, int j)
		{
			T tmp = array[i];
			array[i] = array[j];
			array[j] = tmp;
		}
		
		static void QuickSortBasicR (T [] array, int low0, int high0, Comparison comparison)
		{
			int low = low0;
			int high = high0;
			
			// Be careful with overflows
			int mid = low + ((high - low) / 2);
			T keyPivot = array [mid];
			
			while (true) {
if (keyPivot == null) {
	while (low  high0  array [low] == null)
		++low;
	while (high  low0  array [high] != null)
		--high;
} else {
	// Move the walls in
	while (low  high0  comparison (array [low], keyPivot)  0)
		++low;
	while (high  low0  comparison (keyPivot, array [high])  0)
		--high;
}

if (low = high) {
	swap (array, low, high);
	++low;
	--high;
} else
	break;
			}
			
			if (low0  high)
QuickSortBasicR (array, low0, high, comparison);
			if (low  high0)
QuickSortBasicR (array, low, high0, comparison);
		}
		
		public static void QuickSortBasic (T [] array, int index, int length, Comparison comparison)
		{
			QuickSortBasicR (array, index, index + length - 1, comparison);
		}
		
		static int Median (T [] array, int a, int b, int c, Comparison comparison)
		{
			T keyA = array[a];
			T keyB = array[b];
			T keyC = array[c];
			
			if (comparison (keyA, keyB)  0) {
/* a  b  c */
if (comparison (keyB, keyC)  0)
	return b;

/* a  c  b */
if (comparison (keyA, keyC)  0)
	return c;

/* c  a  b */
return a;
			} else {
/* b  a  c */
if (comparison (keyA, keyC)  0)
	return a;

/* b  c  a */
if (comparison (keyB, keyC)  0)
	return c;

/* c  b  a */
return b;
			}
		}
		
		static void QuickSortMedianR (T [] array, int low, int high, Comparison comparison)
		{
			int pivot, mid, i, k;
			T pval;
			
			// determine which element contains the median value
			mid = low + ((high - low) / 2);
			pivot = Median (array, low, mid, high, comparison);
			
			if (pivot != low) {
// swap pivot value into first element (so the location stays constant)
swap (array, low, pivot);
pivot = low;
			}
			
			pval = array[pivot];
			i = low + 1;
			k = high;
			
			do {
if (pval == null) {
	while (i  k  array[i] == null)
		i++;
	
	while (k = i  array[k] != null)
		k--;
} else {
	// find the first element with a value  pivot value
	while (i  k  comparison (array[i], pval) = 0)
		i++;
	
	// find the last element with a value = pivot value
			

Re: [Mono-dev] Possible QuickSort optimizations for Array.Sort()

2011-04-06 Thread Jeffrey Stedfast
On 04/06/2011 10:40 AM, Robert Jordan wrote:
 Hi,

 On 06.04.2011 15:48, Jeffrey Stedfast wrote:
 static readonly int INSERTIONSORT_THRESHOLD = 7;

 Why not to used const int ?
 I never learned when to use const vs static/readonly in C# :-(
 Consts will be expanded inline by the compiler.

 pros: fast
 cons: versioning trouble when the const is public and it is
 consumed by another assembly.

Aha, thanks. So yea, in this case it makes sense to use const.

Jeff

___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


[Mono-dev] Possible QuickSort optimizations for Array.Sort()

2011-04-05 Thread Jeffrey Stedfast

Attached you'll find qsort.cs which includes 3 QuickSort implementations:

1. QuickSortBasic[R]: This is a basic QuickSort implementation and the 
one currently in use as the sorting function in Array.Sort(). This 
implementation always uses the middle element as the pivot.


2. QuickSortMedian[R]: This implementation is also a basic QuickSort 
implementation which attempts choose a better pivot based on the first, 
last, and middle elements. For sorted inputs and random inputs, this 
seems to help performance somewhat as the array gets larger and larger. 
However, for reverse-sorted inputs, it seems to kill performance. 
Perhaps if I choose 3 random points to feed into Median() it will do better.


3. QuickSortInsertion[R]: This implementation includes the above perf 
trick and also includes an Insertion Sort fallback when partitions are 
broken down smaller than some threshold # of elements (7 in the attached 
code). It also falls back to Insertion Sort when it encounters a 
worst-case scenario. As always, the performance improvement with this is 
greater as the number of elements increases and/or as the comparison 
function becomes more complex.



You'll notice that the attached test program will print out the number 
of comparisons that each sort routine uses in order to complete its job. 
It's important to keep in mind that the more complex the comparison 
function is, the more important it is that the number of comparisons is 
kept to a minimum.


Here are some example runs:


[fejj@warpig sorting]$ mono ./qsort.exe -random 1
Basic QuickSort comparisons needed: 3807986012
QuickSort+Median comparisons needed:3077915654
QuickSort+Insertion comparisons needed: 3021355043
Basic QuickSort finished in: 00:00:43.8178721s
QuickSort+Median finished in:00:00:37.3047443s
QuickSort+Insertion finished in: 00:00:36.6122681s


[fejj@warpig sorting]$ mono ./qsort.exe -sorted 1
Basic QuickSort comparisons needed: 2632227866
QuickSort+Median comparisons needed:2632227867
QuickSort+Insertion comparisons needed: 2483222808
Basic QuickSort finished in: 00:00:21.8213618s
QuickSort+Median finished in:00:00:21.2622527s
QuickSort+Insertion finished in: 00:00:19.0837352s


(Note: I reduced the array size here due to wanting to head home for dinner)
[fejj@warpig sorting]$ mono ./qsort.exe -reversed 1
Basic QuickSort comparisons needed: 129546
QuickSort+Median comparisons needed:12522499
QuickSort+Insertion comparisons needed: 39993
Basic QuickSort finished in: 00:00:00.0016905s
QuickSort+Median finished in:00:00:00.0911385s
QuickSort+Insertion finished in: 00:00:00.0008721s


Jeff
using System;
using System.Diagnostics;

namespace SortingTest {
	public class SortT {
		public delegate int Comparison (T v0, T v1);
		
		static void swap (T [] array, int i, int j)
		{
			T tmp = array[i];
			array[i] = array[j];
			array[j] = tmp;
		}
		
		static void QuickSortBasicR (T [] array, int low0, int high0, Comparison comparison)
		{
			int low = low0;
			int high = high0;
			
			// Be careful with overflows
			int mid = low + ((high - low) / 2);
			T keyPivot = array [mid];
			
			while (true) {
if (keyPivot == null) {
	while (low  high0  array [low] == null)
		++low;
	while (high  low0  array [high] != null)
		--high;
} else {
	// Move the walls in
	while (low  high0  comparison (array [low], keyPivot)  0)
		++low;
	while (high  low0  comparison (keyPivot, array [high])  0)
		--high;
}

if (low = high) {
	swap (array, low, high);
	++low;
	--high;
} else
	break;
			}
			
			if (low0  high)
QuickSortBasicR (array, low0, high, comparison);
			if (low  high0)
QuickSortBasicR (array, low, high0, comparison);
		}
		
		public static void QuickSortBasic (T [] array, int index, int length, Comparison comparison)
		{
			QuickSortBasicR (array, index, index + length - 1, comparison);
		}
		
		static int Median (T [] array, int a, int b, int c, Comparison comparison)
		{
			T keyA = array[a];
			T keyB = array[b];
			T keyC = array[c];
			
			if (comparison (keyA, keyB)  0) {
/* a  b  c */
if (comparison (keyB, keyC)  0)
	return b;

/* a  c  b */
if (comparison (keyA, keyC)  0)
	return c;

/* c  a  b */
return a;
			} else {
/* b  a  c */
if (comparison (keyA, keyC)  0)
	return a;

/* b  c  a */
if (comparison (keyB, keyC)  0)
	return c;

/* c  b  a */
return b;
			}
		}
		
		static void QuickSortMedianR (T [] array, int low, int high, Comparison comparison)
		{
			int pivot, mid, i, k;
			T pval;
			
			// determine which element contains the median value
			mid = low + ((high - low) / 2);
			pivot = Median (array, low, mid, high, comparison);
			
			if (pivot != low) {
// swap pivot value into first element (so the location stays constant)
swap (array, low, pivot);
pivot = low;
			}
			
			pval = 

Re: [Mono-dev] Sale of Novell

2010-11-23 Thread Jeffrey Stedfast
On 11/23/2010 08:50 AM, Paul F. Johnson wrote:
 Hi,

 Now that Novell has been sold and along with it 882 patents either
 directly or indirectly to MS, can anyone give a definitive statement on
 what will happen with Mono and if the licences will remain the same?

 I don't want to see the sale mean the death of Mono, but with the future
 of SUSE unclear now, we could do with some sort of re-assurance.

 TTFN

 Paul
   

As Miguel stated yesterday, the only thing that will change wrt Mono is
where we, the developers, will be getting our paychecks. They'll be
coming from Attachmate instead of Novell in the near future (assuming
the deal goes through). There are also no plans to change the licensing
of Mono.

The same holds true for SUSE.

Hope that helps,

Jeff

___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-list] Ubuntu

2010-08-11 Thread Jeffrey Stedfast
On 08/11/2010 09:24 PM, Daniel Hughes wrote:
 Ubuntu does not believe it is its responsibility to update mono
 between OS releases.
   

It's their responsibility to update *all* of their packages between OS
releases. If they don't, then they presumably had a reason not to. It's
kinda hard for them not to take responsibility for the packages they
ship ;-)

 Mono does not believe it is its responsibility to provide ubuntu
 packages for new mono releases.

 Users fall into a gap between the two. And must compile from source or
 use unsupported third party PPA's if and when they are available.
   

Jo (aka Directhex) is the guy that packages Mono for Ubuntu proper, so
his PPA isn't really third party.

Hope that helps,

Jeff

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] mono performance, 20x differential with Java (what am i doing wrong)

2010-02-01 Thread Jeffrey Stedfast
On 02/01/2010 08:16 PM, Diego Frata wrote:
 Jon,

 Not going to happen? Heck, few years back I wouldn't say Mono would
 happen. Implementing the CLR, porting lots of .NET libraries without
 even looking at implementation details? No f*ing way. :) 

 It just requires work and time (= money) and passion, as everything
 else on earth.

Agreed ;-)

FWIW, the JIT guys are looking into this and have some ideas. I'm
confidant that it'll happen.

  

 Hope that sometime between this year and the next one I can start
 contributing instead of just using it. And maybe you too!

I think this is certainly possible!

Jeff

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Mono 2.6 for Ubuntu

2010-01-19 Thread Jeffrey Stedfast
On 01/11/2010 03:42 PM, James Mansion wrote:
 B.R. wrote:
   
 It's not really up to Novell here, it's up to the Debian/Ubuntu 
 maintainers to decide when new versions get supported. Part of the 
 reason for this is that Debian, and by extension Ubuntu, have very 
 specific policies on how things should be packaged (the Debian Free 
 Software Guidelines are very strict, and the Mono project does violate 
 them in a few places), and Novell simply haven't the resources to 
 invest in hiring someone specifically to do Debian (and by extension 
 Ubuntu) packaging, so it's left up to the maintainers who do a pretty 
 good job with the time and resources they have. The reason binaries 
 are shipped for Windows with every release is because there's no 
 package specification to follow, so the binary packages are easy to 
 build (build the libs, put them in the right places, package them up 
 in an installer and you're good to go).
 
 I think that's a bit lame - it makes a big assumption about the mono 
 team shipping a package for a start. Binary compatibility for apps (if 
 not drivers) is at least passable with current Linux systems.  Why 
 should it be hard to ship a universal binary when Adobe and Sun (in 
 particular) have managed it for a long time?
   

We used to make binary packages but they aren't upgradeable via the
distribution's package system. You really really want it to be
upgradeable via the package system and have the package system be aware
of the Mono installation, otherwise the system quickly becomes a mess. I
doubt you have the binary install of Java or OpenOffice on your machine.
I'm sure you've gotten them via the package manager from your distro.

There are people working on making Ubuntu packages (that also make the
official ubuntu/debian packages).

 I can see that Novell need SLES to be the best platform for Mono for 
 commercial, but I think it needs to be ubiquitous first and then given 
 value add on the Novell product - and that means better support for 
 other Linuxen, and OpenSolaris, and FreeBSD.
   

We are always accepting patches to make it work better on other
platforms - there's no plot to make Mono work best on SLE (it's the same
Mono as on every other platform).

Jeff

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Sites Using Mono

2009-11-20 Thread Jeffrey Stedfast
On 11/20/2009 07:01 AM, sirmak wrote:
 Hi,

 I sent a similar message before and couldn't get an answer. Web Projects
 Using Mono section in  http://www.mono-project.com/Companies_Using_Mono
 Companies_Using_Mono  page is old, I checked every site there with alexa and
 there is no commerical high load site in the list. Wikipedia only uses it
 for search with lucene.net and Mozilla is only using deki.
  
 Isn't there ANY high load site reference in mono community that constructed
 with mono ?

 Cheers,

   

Wouldn't you consider SecondLife to be high-load?

Jeff

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Embeding Mono. Memory management

2009-11-20 Thread Jeffrey Stedfast
On 11/20/2009 08:25 AM, Alexander Smirnov wrote:
 But how GC knows when to free such objects? When it frees such objects?
 Could GC free the object when I still need it? 
 for example

 void func() {
   MonoString* str=mono_string_new (domain, some text);
   /*
could GC free str before using str, if no, why?
   */
   // using str
 }

 thanks
   

You might find this article informative:
http://en.wikipedia.org/wiki/Garbage_collection_%28computer_science%29

The gist of it is that Mono's GC (which is just Boehm's GC) scans for
references to memory that it has allocated, so as long as your program
has pointers to these objects, the GC will not collect them.

Hope that helps,

Jeff

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-dev] Should we replace MemoryStream?

2009-11-09 Thread Jeffrey Stedfast
Miguel de Icaza wrote:
 Hello folks,

 I just blogged about a memory fragmentation issue here:

   http://tirania.org/blog/archive/2009/Nov-09.html

 And I am wondering: since MemoryStream is one of these sources of
 problems, we could replace this implementation with MindTouch's
 ChunkedStream.
   

I'm really liking the idea of a chunked stream like this. Even once sgen
is complete and deployed, a chunked stream will still be more efficient
- not just in avoiding fragmentation, but also because reallocating a
new, larger buffer, has overhead associated with copying the content
whereas allocating a new chunk is a cheaper operation.

Jeff


___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-list] Will there be an easy way to install MonoDevelop 2.2 on Ubuntu

2009-11-04 Thread Jeffrey Stedfast
Jo Shields (Mono* maintainer for Ubuntu) will likely build MonoDevelop
2.2 packages when it comes out. I'm not sure what his repository url is,
however.

Jeff

Mike Christensen wrote:
 Hi - When MonoDevelop 2.2 is released, will there be an easy way to
 install this on Ubuntu, or will the only way be to download the
 sources and build?

 I tried building from the trunk, however I ran into an endless maze of
 dependencies and gave up after about 2 hours.

 Thanks!

 Mike
 

 ___
 Mono-list maillist  -  Mono-list@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/mono-list
   

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Trying to muster up some community interest

2009-10-10 Thread Jeffrey Stedfast
Have you considered using GMimeSharp as your message parser/decoder
system? I notice it looks like you were planning on targeting Gtk so it
might be a good fit.

In any event, good luck with your project.

Jeff

Timothy Roberts wrote:
 Hey Mono-list, I've been working on a C#/Mono project lately, a NNTP
 protocol suite with library, CLI, and GUI applications.

 I've made some significant headway with a full NNTP specification
 library, which supports all common NNTP commands and yEnc encoding and
 decoding, with CRC32 support. However, I need members of the community
 to review the code, find bugs, send in patches, etc.

 That's where you come in. :-) If you have the time, please head over
 to http://nntpsharp.codeplex.com and download the latest source and
 binaries release of NNTPSharpLib. Test it out in your own projects.
 It's almost feature-complete, with yEnc header and trailer parsing
 still needing to be implemented.

 --Timothy Roberts(tr.parac...@gmail.com mailto:tr.parac...@gmail.com)
 

 ___
 Mono-list maillist  -  Mono-list@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/mono-list
   

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


[Mono-dev] IOMAP fix for CreateFile()

2009-09-10 Thread Jeffrey Stedfast
In mono/io-layer/io.c's CreateFile() function, if the first call to
_wapi_open() fails due to the path being a directory, it is retried w/o
WRITE permissions. As far as I can tell, the fallback open() call should
really be a _wapi_open() so that IOMAP magic is applied just as it was
in the first attempt.

Attached is a patch to fix that (assuming I'm correct in what it should
be doing).

Jeff

Index: ChangeLog
===
--- ChangeLog	(revision 140963)
+++ ChangeLog	(working copy)
@@ -1,3 +1,8 @@
+2009-09-10  Jeffrey Stedfast  f...@novell.com
+
+	* io.c (CreateFile): In the directory fallback case, use
+	_wapi_open() again so that IOMAP magic happens.
+
 2009-08-18  Christian Hergert  ch...@dronelabs.com
 
 	* wthreads.c: Roll back change for thread-id as it embraces
Index: io.c
===
--- io.c	(revision 140963)
+++ io.c	(working copy)
@@ -1547,7 +1547,7 @@
 	if (fd == -1  errno == EISDIR)
 	{
 		/* Try again but don't try to make it writable */
-		fd = open(filename, flags   ~(O_RDWR|O_WRONLY), perms);
+		fd = _wapi_open (filename, flags  ~(O_RDWR|O_WRONLY), perms);
 	}
 	
 	if (fd == -1) {
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-dev] Mono 2.4 - glib requirement issues

2009-04-22 Thread Jeffrey Stedfast
John M wrote:
 Thanks for the answer Miguel.

 We installed a private copy of glib 2.3.4 and are using that.
   

FWIW, glib 2.3.4 is a development version (i.e. unstable), you might
want to use glib = 2.4.0 (where the middle number is even rather than odd).

Jeff

___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-list] BinaryFormatter serialization accross .NET and Mono

2009-02-23 Thread Jeffrey Stedfast
Chris Howie wrote:
 On Fri, Feb 6, 2009 at 5:19 PM, schmmd mich...@schmitztech.com wrote:
   
 Hi, I am asking to learn if it is a goal of the Mono project to have
 consistent serialization across Mono and .Net with respect to the
 BinaryFormatter.  Serialization is the same in some cases.  For example,
 serialization of a byte array is the same in .NET and Mono.  However,
 serialization of a struct containing a byte array is not.

 [snip]

 Is this a bug or is consistency between .NET and Mono not a goal?
 

 I do not believe it is a very high-priority goal.  You might try the
 SoapFormatter class.  It at least produces more readable output so if
 there is an issue it's easier to spot, and hence easier for the
 developers to fix.

   
Things might be able to be serialized slightly differently and yet
achieve the same results. However, I would suggest that, if things are
not working using the binary formatter between .NET and Mono, then you
should submit a bug. It's important that Mono and .NET are able to
communicate properly.


Jeff

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Learning Mono just like .NET?

2009-02-08 Thread Jeffrey Stedfast
stevemcc wrote:
 So I am a college student interested in programming. I've done some
 programming, just a little bit in java, python, VB, and php. I noticed
 theres a lot of demand for .NET developers and I use linux most of the time.
 Is mono close enough .net that learning mono would prepare me for an
 eventually job that might require me to develop using .NET and windows. Or
 are they close, but still different beasts?
   
As Michael Hutchinson has already said, they should be close enough to
not matter.

As a possible added bonus to learning Mono, more and more .NET
development houses may begin to favor new recruits with Linux/Mono
experience because Linux is becoming an important platform to support
(not to mention Mac). We've already seen evidence of companies porting
their .NET software over to Linux to run on Mono to either save
themselves a lot of money (e.g. custom web apps), or to reach a wider
market (selling their .NET apps for Mac/Linux).

Jeff

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Isn't silverlight already crossbrowser ?

2008-12-09 Thread Jeffrey Stedfast
On Sat, 2008-12-06 at 19:04 -0800, joelafrite wrote:
 Hi.
 
 I don't much about Silverlight but I understand it's advertised as cross
 browser/platform by Microsoft.
 Is that by using Moonlight or does Silverlight come in several version
 itselfs ?

Microsoft's Silverlight works on Windows and Mac only.

Moonlight is the Linux port (that we'd like to make work on other
platforms as well. Currently I think there's work being done on a
Solaris port, for example).

Jeff


___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Is Mono fully compatible with .net framework?

2008-11-19 Thread Jeffrey Stedfast
On Mon, 2008-11-17 at 18:22 -0800, Katmai wrote:
 Is Mono fully compatible with .net framework now?If not,when will it be?(or
 will it be?)

The runtime and compiler are, afaik, fully compat with Microsoft's. The
implemented class libraries are compatible in so far as we know, however
the .NET class libraries are extensive and always growing - if you want
to know if your application will run using Mono's class libraries, you
can run a tool called MoMA and it will provide you with any problematic
areas.

That should answer your question, although you were pretty vague so
maybe not.

Jeff


___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Parsing email

2008-11-10 Thread Jeffrey Stedfast
You could try GMime-Sharp (make sure it is version 2.4.x), it's a
binding to the GMime C library which can parse MIME messages.

I don't have any monodoc docs written for it, but it's pretty close to
the C API which is documented at
http://library.gnome.org/devel/gmime/stable/

You can download the source from
http://ftp.gnome.org/pub/GNOME/sources/gmime/2.4/

Jeff

On Mon, 2008-11-10 at 23:01 +, Jorge Bastos wrote:
 I'm sure they all work.
 In fact I've seen them already, but they are all commercial and that's not an 
 option for me now.
 I have no problem to buy software, in fact I have a lot of it that I buyed, 
 but right now it's not a good time to invest.
 
 
 
  -Original Message-
  From: Stéphane Zanoni [mailto:[EMAIL PROTECTED]
  Sent: segunda-feira, 10 de Novembro de 2008 17:58
  To: Jorge Bastos; 'mono-list'
  Subject: Re: [Mono-list] Parsing email
  
  I believe the .msg files use the OLE 2 Compound Document format
  (proprietary format for MAPI?).
  
  A quick google for parse msg files or .net .msg format returned a
  couple results, nothing jumps out in the open/shared source realm.
  
  100% managed (mono support) + purchasable source:
  http://www.independentsoft.de/msg/index.html
  
  http://www.aspose.com/categories/utility-components/aspose.network-for-
  .net/default.aspx
  
  
  java options (may be portable?) --
  http://www.rgagnon.com/javadetails/java-0613.html
  
  
  If you do find something that works, let me know.
  
  
  Stphane
  
  
   Jorge Bastos [EMAIL PROTECTED] 11/10/2008 9:43 AM 
  And about the .msg one's?
  
  
   -Original Message-
   From: Stphane Zanoni [mailto:[EMAIL PROTECTED]
   Sent: segunda-feira, 10 de Novembro de 2008 16:23
   To: Jorge Bastos; 'mono-list'
   Subject: Re: [Mono-list] Parsing email
  
   eml are just MIME.822 formatted, the Lumisoft library has well
   developed Mime parsing capabilities.
  
  
Jorge Bastos [EMAIL PROTECTED] 11/10/2008 7:29 AM 
   Sorry not .eml, but .msg msoutlook 2003/2007
  
  
-Original Message-
From: [EMAIL PROTECTED] [mailto:mono-list-
[EMAIL PROTECTED] On Behalf Of Jorge Bastos
Sent: segunda-feira, 10 de Novembro de 2008 14:26
To: 'mono-list'
Subject: Re: [Mono-list] Parsing email
   
Can this library parse the .eml messages from MSOutlook 2003/2007?
   
   
   
 -Original Message-
 From: [EMAIL PROTECTED] [mailto:mono-list-
 [EMAIL PROTECTED] On Behalf Of Damien
 Sent: segunda-feira, 10 de Novembro de 2008 14:22
 To: Peter Hagen; mono-list@lists.ximian.com
 Subject: Re: [Mono-list] Parsing email

 Hi,

 The Lumisoft Net library :
 http://www.lumisoft.ee/lsWWW/Download/Downloads/Net/

 Cheers,

 Damien

 2008/11/10 Peter Hagen [EMAIL PROTECTED]:
  Hi all
 
  does anyone know if there is a existing library or function
  for
 parsing
  email messages? For example to easily get the attachments?
 
  cheers
 
  Peter Hagen
 
 
  ___
  Mono-list maillist  -  Mono-list@lists.ximian.com
  http://lists.ximian.com/mailman/listinfo/mono-list
 
 ___
 Mono-list maillist  -  Mono-list@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/mono-list
   
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list
  
   ___
   Mono-list maillist  -  Mono-list@lists.ximian.com
   http://lists.ximian.com/mailman/listinfo/mono-list
  
  
  ___
  Mono-list maillist  -  Mono-list@lists.ximian.com
  http://lists.ximian.com/mailman/listinfo/mono-list
 
 ___
 Mono-list maillist  -  Mono-list@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/mono-list

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Linux Equivalent to Visual Studio?

2008-10-28 Thread Jeffrey Stedfast
On Tue, 2008-10-28 at 18:46 -0700, Jerry Houston wrote:
 Please be assured that I'm not poking fun at mono, or Linux.  I use
 Windows because I have to, and I use Linux because I want to.
 
 I'm a full-time .NET developer at work, and I really want mono to be to
 Linux what .NET is to Windows.  However, I'm finding it really slow
 getting started with mono, because I haven't yet found anything I can
 use to create winform applications visually.  Does such a thing exist
 for mono?
 
 I can build an application using Visual Studio, and then port it to mono
 without a lot of trouble, but every time I've tried to *start* an
 application using mono, I end up frustrated and quit.  I just downloaded
 the latest version, thinking that I'd be pleasantly surprised this time,
 but monodevelop still seems like little more than a fairly smart code
 editor.
 
 Surely, there must be a mono equivalent to Visual Studio somewhere, but
 I haven't found it yet.  Something with a visual designer, and
 Intellisense-type help, and so on.  Can someone point me in the right
 direction?

MonoDevelop has all of these things, including a visual designer, the
only catch is that the designer is for Gtk# rather than Windows.Forms.

There was some work a while back to implement a Windows.Forms designer
for MonoDevelop as a Google Summer of Code project, but I don't remember
what ever came of it.

Jeff


___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Does Mono Support Partial Methods?

2008-10-21 Thread Jeffrey Stedfast
On Mon, 2008-10-20 at 20:08 -0700, used2could wrote:
 I am trying to use some classes that contain partial methods (not to be
 confused with partial classes) and i am getting a compilation Error: Feature
 'partial methods' cannot be used because it is not part of the C# 2.0
 language spec...

Sounds like you might be using mcs instead of gmcs?

Make sure you are using the gmcs compiler, mcs is for .NET 1.1

Jeff


___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Packages for armv4t (OpenMoko)

2008-09-26 Thread Jeffrey Stedfast
On Fri, 2008-09-26 at 12:43 +0200, [EMAIL PROTECTED] wrote:
 Hi all,
 i tryed to make the NDesk.DBus package with the existing mono 1.2.5.
 i get the following error. are there newer packages as 1.2.5 avail or 
 existing NDesk.Dbus for armv4t?
 I dont know how to(and dont want to) build mono from source. 

There's a 1.2.6 if you really want to stick to a 1.2.x release or you
can try the latest 2.0 release candidate.

Ideally you'll probably want 2.0 once it's released.

Jeff


___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Name of the CSharp Shell

2008-09-21 Thread Jeffrey Stedfast
On Sun, 2008-09-21 at 17:39 -0400, Miguel de Icaza wrote:
 Hey folks,
 
 The name of the C# shell today is `csharp', but this is awkward to
 type, we have been considering renaming it, the options are:
 
 * csi - stands for C# interactive
 
   Pros: short, cute, easy to remember.
   Cons: popular TV show.

I really like the name csi :)

 
 * imcs - interactive Mono C# compiler
 
   Pros: similar to `gmcs' and `mcs'
 
   Cons: hard to figure out it exists.

eh :\

Jeff


___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-dev] Mono invoke the C++ method

2008-09-19 Thread Jeffrey Stedfast
The easiest solution is to wrap each of the c++ methods you need to call
in a c-library (since Mono can P/Invoke C functions).

Jeff

On Fri, 2008-09-19 at 10:15 +0800, Taoye wrote:
   Hi , i am a C# programmer  .Now we develop a project in
 Window , .NET Framework 2.0. We need to run it on mono.I know it can
 run well . But the project use a C++ DLL which
  
   develop in Window VC++6.0 . So the problems comes. When we run the
 project on mono , it cannt invoke the method in C++. Can you  give me
 some ideas. Thanks for your help.
  
  
  Ye Tao
  
   2008-09-19
 ___
 Mono-devel-list mailing list
 Mono-devel-list@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/mono-devel-list

___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-list] Congrats!

2008-08-23 Thread Jeffrey Stedfast
Thanks! Your gratitude is appreciated by all of us ;-)

Jeff

On Thu, 2008-08-21 at 16:16 -0400, Abe Gillespie wrote:
 Hi Mono Monkeys,
 
 Just wanted to extend a huge congrats on the accomplishment with  
 Linden Labs / Second Life.  I know it's been a long time coming.
 
 Congratulations!
 -Abe
 ___
 Mono-list maillist  -  Mono-list@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/mono-list

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-dev] Moonlight 0.8 - Where are they Release Notes

2008-08-18 Thread Jeffrey Stedfast

On Mon, 2008-08-18 at 10:14 -0700, Daniel Morgan wrote:
 As Eno pointed out, where are the release notes for Moonlight 0.8?
 
 Is Moonlight good enough to watch video from http://www.nbcolympics.com/ on 
 Linux now?
 

Yea, we slipped up on updating the release notes file.

Moonlight 0.8 only reliably works for Silverlight 1.0 sites so far.
Silverlight 2.0 is still in Beta and so the API's are not yet frozen.

Unfortunately, nbcolympics.com targets Silverlight 2.0 Beta and so
Moonlight 0.8 will not work with it.

Jeff


___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-dev] moonlight source in mono-2.0

2008-08-18 Thread Jeffrey Stedfast
The 2.1 assemblies are just stripped-down 2.0 assemblies and smcs is
just gmcs built to target 2.1

None of the Silverlight classes are included inside Mono, so there
shouldn't need to be any source-code removal at all.

Also... why would the source code need to be removed at all in the
source packages anyway? I'm totally lost.

Jeff

On Mon, 2008-08-18 at 20:15 +0100, Paul wrote:
 Hi,
 
 As part of the regular review of updated packages within fedora, we've
 found that the current 2.0 preview has the ability to build the
 moonlight assemblies (or not depending on the configure option).
 
 Moonlight is a forbidden item in Fedora, so I've built it with the
 configure script saying no thanks to moonlight. However, if the code is
 in the mono tarballs, it has to be removed when it's packaged up.
 
 Looking at the source, I can't see anything glaringly obvious, but from
 memory, its smcs, System.Net and anything 2.1 in gac. Can someone
 confirm this?
 
 Thanks
 
 TTFN
 
 Paul
 ___
 Mono-devel-list mailing list
 Mono-devel-list@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/mono-devel-list

___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-dev] moonlight source in mono-2.0

2008-08-18 Thread Jeffrey Stedfast

On Mon, 2008-08-18 at 23:02 +0100, Paul wrote:
 Hi,
 
  Also... why would the source code need to be removed at all in the
  source packages anyway? I'm totally lost.
 
 Moonlight is a forbidden package by fedora (it is considered too dodgy
 due to the unholy pact between Novell and the borg - or something like
 that). This means that they will neither ship the source or the built
 binaries.
 
 Other examples : MP3, mpeg2 and anything else, which under US law, can
 land them in hot water.
 
 For that reason, anything to do with moonlight has to be removed from
 the sourceball, therefore the code to build smcs has to go.

but the source to smcs is exactly the same as that of gmcs!?!?

As Yoda might say: No sense does this logic make.

 
 TTFN
 
 Paul
 ___
 Mono-devel-list mailing list
 Mono-devel-list@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/mono-devel-list

___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-dev] moonlight source in mono-2.0

2008-08-18 Thread Jeffrey Stedfast
Forgot to add that IMHO, ideally you should package (even if you don't
ship by default) the 2.1 assemblies (and smcs?) so that it is easier for
Fedora's end-users to get a working Moonlight should they choose to
install it.

W/o the 2.1 assemblies packaged, they would have to build their own
Mono.

Since Fedora deems Mono legally safe, there's no reason for Fedora not
to at least package the 2.1 assemblies as there is absolutely nothing
new in the code.

Jeff

On Mon, 2008-08-18 at 23:37 +0100, Paul wrote:
 Hi,
 
   For that reason, anything to do with moonlight has to be removed from
   the sourceball, therefore the code to build smcs has to go.
  
  but the source to smcs is exactly the same as that of gmcs!?!?
  
  As Yoda might say: No sense does this logic make.
 
 In that case, what does smcs really do that gmcs doesn't other than
 target the moonlight bits and pieces? Fedora are really picky over
 things, so I play it safe.
 
 Now, onto more pressing matters. How the hell do I get XIM to play
 nicely...
 
 TTFN
 
 Paul
 ___
 Mono-devel-list mailing list
 Mono-devel-list@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/mono-devel-list

___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-dev] moonlight source in mono-2.0

2008-08-18 Thread Jeffrey Stedfast
On Mon, 2008-08-18 at 23:37 +0100, Paul wrote:
 Hi,
 
   For that reason, anything to do with moonlight has to be removed from
   the sourceball, therefore the code to build smcs has to go.
  
  but the source to smcs is exactly the same as that of gmcs!?!?
  
  As Yoda might say: No sense does this logic make.
 
 In that case, what does smcs really do that gmcs doesn't other than
 target the moonlight bits and pieces?

Nothing. That's the entire difference.

The difference between the 2.0 and the 2.1 assemblies is that the 2.1
assemblies are only a small subset of the 2.0 assemblies (wouldn't want
Silverlight apps accessing the filesystem, or accessing many of the
other System classes due to security concerns, so the 2.1 assemblies
simply strip all of that out).

  Fedora are really picky over
 things, so I play it safe.
 
 Now, onto more pressing matters. How the hell do I get XIM to play
 nicely...
 
 TTFN
 
 Paul
 ___
 Mono-devel-list mailing list
 Mono-devel-list@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/mono-devel-list

___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-dev] moonlight source in mono-2.0

2008-08-18 Thread Jeffrey Stedfast
On Mon, 2008-08-18 at 20:10 -0400, Geoff Norton wrote:
 Jeff,
 
 On Mon, 2008-08-18 at 19:58 -0400, Jeffrey Stedfast wrote:
  Forgot to add that IMHO, ideally you should package (even if you don't
  ship by default) the 2.1 assemblies (and smcs?) so that it is easier for
  Fedora's end-users to get a working Moonlight should they choose to
  install it.
 
  W/o the 2.1 assemblies packaged, they would have to build their own
  Mono.
  
 
 I'm fairly certain the plan here is for us to provide a .xpi that would
 run on a mono-less machine for SL2.  In other words we're going to
 bundle the runtime bits we need in the .xpi.

Aha, then disregard my previous mail ;-)

Jeff


___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-list] [Mono-dev] Moonlight 0.8 - Where are they Release Notes

2008-08-18 Thread Jeffrey Stedfast

On Mon, 2008-08-18 at 10:14 -0700, Daniel Morgan wrote:
 As Eno pointed out, where are the release notes for Moonlight 0.8?
 
 Is Moonlight good enough to watch video from http://www.nbcolympics.com/ on 
 Linux now?
 

Yea, we slipped up on updating the release notes file.

Moonlight 0.8 only reliably works for Silverlight 1.0 sites so far.
Silverlight 2.0 is still in Beta and so the API's are not yet frozen.

Unfortunately, nbcolympics.com targets Silverlight 2.0 Beta and so
Moonlight 0.8 will not work with it.

Jeff


___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Moonlight 0.8 installation

2008-08-16 Thread Jeffrey Stedfast
It's fairly common for the following X.Org config option (in the Device
section) to speed up Moonlight considerably:

Option  XaaNoOffscreenPixmaps true

Jeff


On Sat, 2008-08-16 at 21:15 -0400, Geoff Norton wrote:
 Filipe,
 
  From this message, figured libxcb-xlib was missing :)  and went ahead
  and installed it. It's now working!
 
 Great
 
  However, i'm finding it extremely slow with the above example (haven't
  compared with running it with silverlight, though).
  
 
 
 If you're having performance problems please file a bug, and make sure
 to include the following information:
 
 Distro
 Architecture
 Video Card
 Video Card Driver Version
 XOrg version
 Xorg.conf
 The site / test in question
 
 thanks
 
 -g
 
 
 ___
 Mono-list maillist  -  Mono-list@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/mono-list

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-dev] Streaming with Moonlight/Silverlight vs Flash

2008-07-04 Thread Jeffrey Stedfast
On Fri, 2008-07-04 at 12:31 +0200, Federico Di Gregorio wrote:
 Hi everybody,
 
 I am about to choose the technology that will be used during the next
 two years to build the ESOF2010 web site (if you're curious about ESOF
 just check this year website, http://www.esof2008.org/). The project for
 2010 includes a lot of streaming using preferably open protocols and
 open source software (mandatory on the servers, the client code should
 work at least on Windows and Linux and may use proprietary plugins). The
 tools to create the streams should be free software.
 
 We choosed to use feng as the streaming server because it supports
 RTP/RTSP and RTMP (now mostly free) with fallback on HTTP encapsulation
 and a lot of different non-proprietary codecs. 
 
 Looking at MS website for Silverlight specifications it seems to me that
 streaming using the standard protocols cited above is not supported and
 that only MS codecs (that we don't like to use) can be used. We also
 investigated the possibility of writing a a managed RTP implementation
 but it seems that UDP is not supported in Silverlight. And even if we
 manage to have a working implementation of RTP it is not clear how you
 can decode the data and send it to the multimedia part of the framework.
 
 So it seems that while we would much better like to work with
 Mono/Moonlight and keep compatibility with Silverlight in the end will
 be forced to use Adobe Flash (RTMP + one of the non-free codecs: at
 least there are open source tools to do the authoring and the encoding
 conversions).
 
 I am writing to this list because I _hope_ we missed something and that
 Silverlight/Moonlight can be used to play streams using open protocols
 and codecs.

I /believe/ that Silverlight/Moonlight can do RTSP and RSTPT (and
obviously MMS), but I'm not 100% sure. I don't know too much about the
protocols but at one point I was helping out with the media streaming
code and noticed code to handle those 2 protocol schemes (although it's
possible that the code just did immediate fallback to http or something,
I can't remember).

Hopefully one of the moonlight media people can answer this more
accurately.

However, in the end, if you aren't happy with the codecs that
Silverlight supports, then even if we add support for your preferred
codec into Moonlight, it wouldn't solve your codec problem.

Out of curiosity, which codec do you plan on using?

Jeff


___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-list] Mono Licensing for Dedicated/Embedded Devices

2008-06-20 Thread Jeffrey Stedfast
There's probably a special email address for this but I don't know what
it is off the top of my head. Emailing [EMAIL PROTECTED] and/or
[EMAIL PROTECTED] would probably be enough.

Jeff

On Wed, 2008-06-18 at 12:43 -0700, Praerit wrote:
 hi,
 We are building a client/server solution using Mono and C#.  Clients are
 going to be traditional applications installed on PC/Mac systems and
 eventually mobile devices also.  Servers however may be installed on
 dedicated servers or embedded server devices.  Both client  servers are
 expected to be distributed widely.  
 We do not expect or want our customers to be updating Mono bits independent
 of our solution - particularly for the servers.  We will manage this update
 process for our customers to make sure the end-to-end solution doesn't
 break.
 
 From reading the FAQ, it seems like there are restrictions with using Mono
 when trying to build such a solution.
 Can someone please clarify or point me to the right person to talk to?
 
 thx!
 --pg

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Simple Console ReadLine problem

2008-03-28 Thread Jeffrey Stedfast

On Wed, 2008-03-26 at 12:13 -0700, radzfoto wrote:
 I am a moderately experienced programmer especially in C and C++. I am just
 learning C#.
 
 I compiled the following under MS Visual Studio and it worked fine. However,
 exact same code fails to read the string using ReadLine. Any ideas that
 could help me out?
 
 Here is the code:
 using System;
 
 namespace TestReadLine
 {
   class MainClass
   {
   public static void Main(string[] args)
   {
   string str;
   
   Console.Write(Enter some text and press enter: );
   str = Console.ReadLine();
   Console.WriteLine(This is the text you entered:  + 
 str);
   Console.ReadLine

this line ^^^ needs to be changed to:

  Console.ReadLine();

   }
   }
 }
 
 Thanks!
 Radzfoto
 

before making the change, I was not able to compile your test program,
so I assume you must have had the (); in your original source.

That said, I wasn't able to reproduce your problem:

[EMAIL PROTECTED] src]$ gmcs readln.cs 
[EMAIL PROTECTED] src]$ mono ./readln.exe 
Enter some text and press enter: sdffasfasfasfasf
This is the text you entered: sdffasfasfasfasf

In case you were maybe using mcs instead of gmcs, I tried again:

[EMAIL PROTECTED] src]$ mcs readln.cs 
[EMAIL PROTECTED] src]$ mono ./readln.exe 
Enter some text and press enter: asfasdasdasdas
This is the text you entered: asfasdasdasdas


Can you explain your problem a bit more?

Jeff


___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Hosting Silverlight applications on Apache2

2008-01-30 Thread Jeffrey Stedfast
The only problem I've come across hosting Silverlight apps over lighttpd
(did feel like configuring Apache for local testing) was filename case
sensitivity.

IIS seems to be case insensitive while lighttpd (and likely Apache) are
not.

Also, fwiw, I didn't have to add any mime types.

Jeff

On Wed, 2008-01-30 at 18:16 +0100, Timothy Parez wrote:
 Hi,
 
 While this is not purely mono related, I think some of you might be  
 able to help.
 I had a sample application which worked fine when hosted with IIS, but  
 doesn't work when hosted on Apache2.
 
 http://www.itcrowd.be/silverlight/netrissilver.html
 
 The exception I get it this:
 
 The Page at http://www.itcrowd.be says:
 
 Silverlight error message
 ErrorCode: 1001
 ErrorType: ParserError
 Message: AG_E_UNKNOWN_ERROR
 XamlFile: netris.xaml
 Line: 11
 Position: 9
 
 If you check out a sample by someone else, also hosted on Apache:
 http://www.zendurl.com/t/timheuer/v1_1/Default.html
 
 You get this
 The page at http://www.zendurl.com says:
 Silverlight error message
 Errorcode: 1001
 ErrorType: ParserError
 Message: AG_E_UNKNOWN_ERROR
 XamleFile: Page.xaml
 Line: 9
 Position: 2
 
 Quite similar, so I'm guessing it's not my code.
 
 I've added the following Mime types to the Apache configuration, but  
 it still doesn't work:
 
 AddType application/xaml+xml xaml
 AddType application/x-ms-application application
 AddType application/x-ms-xbap xbap
 AddType application/manifest manifest
 AddType application/octet-stream deploy
 AddType application/vnd.ms-xpsdocument xps
 AddType application/x-msdownload dll
 
 
 Since the Mono team is working on Moonlight,
 I assume they also know how to host these applications on Linux?
 
 It's all client side isn't it? So it shouldn't require Mono/ASP.NET  
 right?
 (Even though it's an ASP.NET site, so even then it should still work)
 (Mono is installed on my server. It's version 1.2.6 --with-preview=yes  
 --with-moonlight=yes)
 
 Thank you for any suggestions.
 
 Timothy.
 ___
 Mono-list maillist  -  Mono-list@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/mono-list

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-dev] [Mono-list] trying to compil moon

2007-12-31 Thread Jeffrey Stedfast
Do you have (the right version?) of (lib)expat-devel on your system?

Jeff


On Sun, 2007-12-30 at 13:20 +0100, Petit Eric wrote:
 hey folk
 somebody have the same error and know how to fix it ?
 make[2]: entrant dans le répertoire « /root/mono/moon/src »
 /bin/sh ../libtool --tag=CXX   --mode=link g++  -g -O2   -o demo
 demo.o -lmoon -pthread -L/usr/lib/pkgconfig/../../lib -lgtk-x11-2.0
 -lgdk-x11-2.0 -latk-1.0 -lgdk_pixbuf-2.0 -lpangocairo-1.0 -lcairo
 -lpango-1.0 -lgobject-2.0 -lgmodule-2.0 -lasound -lfreetype
 -lfontconfig -lXrandr -lmono -lpthread -lgthread-2.0 -lrt -lglib-2.0
 -lavformat -lavcodec -lz -la52 -lamrnb -lamrwb -lfaac -lfaad -lmp3lame
 -lm -lnut -lx264 -lxvidcore -ldl -lX11 -lXext -ldirac_encoder
 -ldirac_decoder -lavutil
 g++ -g -O2 -o .libs/demo demo.o -pthread
 /root/mono/moon/src/.libs/libmoon.so /usr/lib/libdirectfb.so
 /usr/lib/libfusion.so /usr/lib/libdirect.so /usr/lib/libglitz.so
 -L/usr/lib/pkgconfig/../../lib /usr/lib/libgtk-x11-2.0.so
 /usr/lib/libgdk-x11-2.0.so /usr/lib/libatk-1.0.so
 /usr/lib/libgdk_pixbuf-2.0.so /usr/lib/libpangocairo-1.0.so
 /usr/lib/libpangoft2-1.0.so /usr/lib/libcairo.so -lpng12
 /usr/lib/libpixman-1.so /usr/lib/libpango-1.0.so
 /usr/lib/libgobject-2.0.so /usr/lib/libgmodule-2.0.so
 /usr/lib/libasound.so /usr/lib/libfontconfig.so
 /usr/lib/libfreetype.so /usr/lib/libxml2.so /usr/lib/libXrandr.so
 /usr/lib/libXrender.so /usr/lib/libmono.so /usr/lib/libgthread-2.0.so
 -lpthread -lrt /usr/lib/libglib-2.0.so -lavformat -lavcodec -lz
 /usr/lib/liba52.so -lamrnb -lamrwb /usr/lib/libfaac.so
 /usr/lib/libfaad.so /usr/lib/libmp3lame.so -lm -lnut -lx264 -lxvidcore
 /usr/lib/libXext.so /usr/lib/libX11.so /usr/lib/libXdmcp.so -ldl
 /usr/lib/libXau.so /usr/lib/libdirac_encoder.so
 /usr/lib/libdirac_decoder.so -lavutil
 /root/mono/moon/src/.libs/libmoon.so: undefined reference to `XML_ErrorString'
 /root/mono/moon/src/.libs/libmoon.so: undefined reference to `XML_SetUserData'
 /root/mono/moon/src/.libs/libmoon.so: undefined reference to
 `XML_GetCurrentLineNumber'
 /root/mono/moon/src/.libs/libmoon.so: undefined reference to
 `XML_SetNamespaceDeclHandler'
 /root/mono/moon/src/.libs/libmoon.so: undefined reference to `XML_ParserFree'
 /root/mono/moon/src/.libs/libmoon.so: undefined reference to
 `XML_SetElementHandler'
 /root/mono/moon/src/.libs/libmoon.so: undefined reference to
 `XML_GetCurrentColumnNumber'
 /root/mono/moon/src/.libs/libmoon.so: undefined reference to
 `XML_SetDoctypeDeclHandler'
 /root/mono/moon/src/.libs/libmoon.so: undefined reference to
 `XML_SetCharacterDataHandler'
 /root/mono/moon/src/.libs/libmoon.so: undefined reference to
 `XML_ParserCreateNS'
 /root/mono/moon/src/.libs/libmoon.so: undefined reference to 
 `XML_GetErrorCode'
 /root/mono/moon/src/.libs/libmoon.so: undefined reference to `XML_StopParser'
 /root/mono/moon/src/.libs/libmoon.so: undefined reference to 
 `XML_ParserCreate'
 /root/mono/moon/src/.libs/libmoon.so: undefined reference to `XML_Parse'
 collect2: ld returned 1 exit status
 make[2]: *** [demo] Erreur 1
 make[2]: quittant le répertoire « /root/mono/moon/src »
 make[1]: *** [all-recursive] Erreur 1
 make[1]: quittant le répertoire « /root/mono/moon »
 make: *** [all] Erreur 2
 [EMAIL PROTECTED] moon]#
 ___
 Mono-list maillist  -  [EMAIL PROTECTED]
 http://lists.ximian.com/mailman/listinfo/mono-list

___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-list] trying to compil moon

2007-12-31 Thread Jeffrey Stedfast
Do you have (the right version?) of (lib)expat-devel on your system?

Jeff


On Sun, 2007-12-30 at 13:20 +0100, Petit Eric wrote:
 hey folk
 somebody have the same error and know how to fix it ?
 make[2]: entrant dans le répertoire « /root/mono/moon/src »
 /bin/sh ../libtool --tag=CXX   --mode=link g++  -g -O2   -o demo
 demo.o -lmoon -pthread -L/usr/lib/pkgconfig/../../lib -lgtk-x11-2.0
 -lgdk-x11-2.0 -latk-1.0 -lgdk_pixbuf-2.0 -lpangocairo-1.0 -lcairo
 -lpango-1.0 -lgobject-2.0 -lgmodule-2.0 -lasound -lfreetype
 -lfontconfig -lXrandr -lmono -lpthread -lgthread-2.0 -lrt -lglib-2.0
 -lavformat -lavcodec -lz -la52 -lamrnb -lamrwb -lfaac -lfaad -lmp3lame
 -lm -lnut -lx264 -lxvidcore -ldl -lX11 -lXext -ldirac_encoder
 -ldirac_decoder -lavutil
 g++ -g -O2 -o .libs/demo demo.o -pthread
 /root/mono/moon/src/.libs/libmoon.so /usr/lib/libdirectfb.so
 /usr/lib/libfusion.so /usr/lib/libdirect.so /usr/lib/libglitz.so
 -L/usr/lib/pkgconfig/../../lib /usr/lib/libgtk-x11-2.0.so
 /usr/lib/libgdk-x11-2.0.so /usr/lib/libatk-1.0.so
 /usr/lib/libgdk_pixbuf-2.0.so /usr/lib/libpangocairo-1.0.so
 /usr/lib/libpangoft2-1.0.so /usr/lib/libcairo.so -lpng12
 /usr/lib/libpixman-1.so /usr/lib/libpango-1.0.so
 /usr/lib/libgobject-2.0.so /usr/lib/libgmodule-2.0.so
 /usr/lib/libasound.so /usr/lib/libfontconfig.so
 /usr/lib/libfreetype.so /usr/lib/libxml2.so /usr/lib/libXrandr.so
 /usr/lib/libXrender.so /usr/lib/libmono.so /usr/lib/libgthread-2.0.so
 -lpthread -lrt /usr/lib/libglib-2.0.so -lavformat -lavcodec -lz
 /usr/lib/liba52.so -lamrnb -lamrwb /usr/lib/libfaac.so
 /usr/lib/libfaad.so /usr/lib/libmp3lame.so -lm -lnut -lx264 -lxvidcore
 /usr/lib/libXext.so /usr/lib/libX11.so /usr/lib/libXdmcp.so -ldl
 /usr/lib/libXau.so /usr/lib/libdirac_encoder.so
 /usr/lib/libdirac_decoder.so -lavutil
 /root/mono/moon/src/.libs/libmoon.so: undefined reference to `XML_ErrorString'
 /root/mono/moon/src/.libs/libmoon.so: undefined reference to `XML_SetUserData'
 /root/mono/moon/src/.libs/libmoon.so: undefined reference to
 `XML_GetCurrentLineNumber'
 /root/mono/moon/src/.libs/libmoon.so: undefined reference to
 `XML_SetNamespaceDeclHandler'
 /root/mono/moon/src/.libs/libmoon.so: undefined reference to `XML_ParserFree'
 /root/mono/moon/src/.libs/libmoon.so: undefined reference to
 `XML_SetElementHandler'
 /root/mono/moon/src/.libs/libmoon.so: undefined reference to
 `XML_GetCurrentColumnNumber'
 /root/mono/moon/src/.libs/libmoon.so: undefined reference to
 `XML_SetDoctypeDeclHandler'
 /root/mono/moon/src/.libs/libmoon.so: undefined reference to
 `XML_SetCharacterDataHandler'
 /root/mono/moon/src/.libs/libmoon.so: undefined reference to
 `XML_ParserCreateNS'
 /root/mono/moon/src/.libs/libmoon.so: undefined reference to 
 `XML_GetErrorCode'
 /root/mono/moon/src/.libs/libmoon.so: undefined reference to `XML_StopParser'
 /root/mono/moon/src/.libs/libmoon.so: undefined reference to 
 `XML_ParserCreate'
 /root/mono/moon/src/.libs/libmoon.so: undefined reference to `XML_Parse'
 collect2: ld returned 1 exit status
 make[2]: *** [demo] Erreur 1
 make[2]: quittant le répertoire « /root/mono/moon/src »
 make[1]: *** [all-recursive] Erreur 1
 make[1]: quittant le répertoire « /root/mono/moon »
 make: *** [all] Erreur 2
 [EMAIL PROTECTED] moon]#
 ___
 Mono-list maillist  -  Mono-list@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/mono-list

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Process.Exitcode is always less than 255

2007-12-16 Thread Jeffrey Stedfast
Programs under Linux always return a value between 0 and 255
(inclusively), they cannot return anything outside of that range.

Jeff

On Tue, 2007-12-11 at 22:35 -0800, sumesh0710 wrote:
 Hello 
  I have a dotnet program which is compiled in .net 2003 in windows. I run
 this program in linux. It calls a c program in process.start() method from
 .net. Upon some error conditions the c program returns the error code to
 .net program. The problem is here. Suppose i return an error code 2053, and
 when i read this code from process.exitcode in .net, what i get is 5. on
 experiment i found that, what ever i return from c program, .net resets it
 after 255. In above case its like 256*8=2048. 
 2048+5=2053. and i get 5 in .net. In windows it works correctly.How to solve
 this problem?any idea? 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Mono C# versus Java 6 -server performance

2007-12-02 Thread Jeffrey Stedfast
I could be completely wrong, but my thinking is that the slowness is is
the Mono implementations of various things (VM, classes, etc).

There has been significant performance improvements done since 1.2.3, so
you might try that and see how things have changed (Mono still may be
slower than java6).

Jeff

On Thu, 2007-11-29 at 10:34 +, Robert Hulme wrote:
 Hi,
 
 I have recently been part of a discussion with colleagues about the 
 merits of C# versus Java. I am of the opinion that C# is a superior 
 language, but my colleagues questioned whether the performance is 
 comparable on Linux (which is what we use here at EBI).
 
 I had a look on the Language Shootout, comparing Mono 1.2.5 with Java 6 
 -server. 
 http://shootout.alioth.debian.org/gp4/benchmark.php?test=alllang=csharp
 
 In almost all the benchmarks Mono C# was significantly slower than Java 6.
 
 I downloaded some of the benchmarks to see if I could reproduce the 
 results on my machine (Mono JIT compiler version 1.2.3.1 / Java 6). The 
 results were the same. Twiddling with mono / mcs flags didn't seem to 
 make a difference.
 
 I was wondering if anyone had any insights in to why this is, whether it 
 is a CIL/C# issue or is specific to the Mono implementation, and whether 
 there are any plans to bring Mono performance in line with Java performance.
 
 Many thanks,
 Robert Hulme
 

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] OpenGL/TAO

2007-10-30 Thread Jeffrey Stedfast
LibGL is the OpenGL API implementation, it does all the low-level
rendering.

Glut is the GL Utility Toolkit which is very simple and sits on top of
LibGL as far as a programming API goes. Does basic window creation,
keyboard/mouse events, etc. It's also a portable API.

GLX is an X11-specific windowing/keyboard/mouse/ library similar to Glut
but more powerful and lets you hook into other X11 API.

Not sure how exactly to explain Xgl and AIGLX, they are basically OpenGL
accelerated X11 variants. Maybe someone else can explain it better.

Indirect rendering means that rendering is done in software.

Direct rendering means that rendering is done by the hardware, and is
usually faster than Indirect (assuming the drivers don't suck).


Anyways, this is all basic (other than Xgl and AIGLX) knowledge you can
find in just about any books on OpenGL. The Red Book goes into LibGL,
Glut, GLX and the win32/mac versions.

Jeff

On Tue, 2007-10-30 at 08:00 -0500, Adrien Dessemond wrote:
 Hello all!
 
 Little Question : how is considered Tao (usable/incomplete/...) ? 
 (its last update is 2 years old).
 
 I am also (desesperately) looking looking for a clear 
 schema/paper/reference about how 
 words  GLX/LibGL/Glut/AIGLX/Xgl/(Indirect) Direct Rendering are glued 
 together. I have a fuzzy image in head but too far to catch a precise 
 (high-level) idea of what is going on behind the scenes when an 
 OpenGL application like glxgears is running.
 
 Regards,
 
 Adrien
 
 ___
 Mono-list maillist  -  Mono-list@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/mono-list

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-dev] Silverlight/Moonlight questions

2007-10-23 Thread Jeffrey Stedfast

On Mon, 2007-10-22 at 17:12 +0200, Andrés G. Aragoneses [ knocte ]
wrote:
 Miguel de Icaza escribió:
  Is MS Silverlight also a native library like Moonlight? Doesn't it have 
  a managed API to be consumed by managed programs in order to use it 
  outside of a browser?
  
  It is a COM component, and Microsoft has stated that they do not plan on
  supporting that API and reserve the right to break it as needed.
 
 Ok! All is clear now. I confess that I couldn't have thought of using 
 COM nowadays...
 
 Then, if one wants to make a cross-platform gadget, the only way is 
 depending on the browser component, right?

correct

  Or creating a compatibility 
 layer library which would call to COM in Windows and deal with Moonlight 
 API library in Linux.. But that seems too complex for me. Would it be 
 feasible to create it?

I'm personally not sure about this...

 
 But now I am thinking of another solution: Silverlight is a subset of 
 WPF right?

yes and no. The API is a stripped down and slightly modified version of
WPF, it's not actually compatible w/ WPF.

  Then, in order to make moonlight work, this small subset of 
 libraries must be already developed on olive, right?

They are in Olive, but not as part of the WPF implementation.

  Then, I suppose 
 that if one creates a .NET application that uses WPF3.0 libraries 
 without accessing non-Silverlight parts, this application should be 
 crossplatform I guess?

I don't think so, no.


Jeff


___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-list] Monodevelop doesn't start :(

2007-07-26 Thread Jeffrey Stedfast
rm -rf $prefix/lib/monodevelop and then do another make install

afaik, this means that you have old data still in that directory and md
gets confused.

Jeff

On Wed, 2007-07-25 at 14:22 +0300, =?UTF-8?Q?Szentp=E1li_J=E1nos?=
wrote:
 When I try to start monodevelop I get the following error (of course the 
 app quits instantly):
 
 --- START ---
 
 Unhandled Exception: Mono.Addins.Setup.InstallException: Application not 
 found: IDE
   at MonoDevelop.Core.ApplicationService.StartApplication (System.String 
 appId, System.String[] parameters) [0x0]
   at MonoDevelop.Startup.SharpDevelopMain.Main (System.String[] args) 
 [0x0]
 
 --- END ---
 
 
 My questions:
 - does anyone know what is going on?
 - how can I make it not complain about MOZILLA_FIVE_HOME... for I have 
 no Mozilla installed and I don't intend to. I currently set it to '/'
 
 János
 
 ___
 Mono-list maillist  -  Mono-list@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/mono-list

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Bug in Environment.TickCount

2007-07-19 Thread Jeffrey Stedfast
from what I can tell reading the man page... you want to do this:

guint32 GetTickCount (void)
{
struct tms tms;
clock_t ticks;

if ((ticks = times (tms)) == -1)
return 0;

#ifdef LINUX_KERNEL_2_6_0_OR_LATER
ticks -= (UINT_MAX - 300) * CLOCKS_PER_SEC;
#endif

#define MSEC_PER_SEC 1000
#define CLOCKS_PER_MSEC (CLOCKS_PER_SEC / MSEC_PER_SEC)

return (guint32) (ticks / CLOCKS_PER_MSEC);
} 

On Thu, 2007-07-19 at 22:38 -0300, Thiago M. Sayão wrote:
 Hello!
 
 Enrironment.TickCount is supposed to return the miliseconds since the
 boot. For my surprise it was returning a negative number which should
 only happen on the 47th day of uptime.
 
 I did i fix (attached) but it doesn't seem 100% correct and i am not
 sure if it would work after some days.
 
 Since i'm coding a msn library and msn p2p protocol uses GetTickCount(),
 it's messing things for me!
 
 Can anyone take a look?
 
 Thanks!
 
 ___
 Mono-list maillist  -  Mono-list@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/mono-list

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Bug in Environment.TickCount

2007-07-19 Thread Jeffrey Stedfast
n/m, that's not quite right... CLOCKS_PER_SEC is incorrect...

try this:

#include sys/times.h
#include inttypes.h
#include limits.h
#include unistd.h

static uint32_t initial_ticks;
static uint32_t ticks_per_msec;
static uint32_t ticks_per_sec;

static void
TickCountInit (void)
{
ticks_per_sec = sysconf (_SC_CLK_TCK);
ticks_per_msec = ticks_per_sec  1000 ? ticks_per_sec / 1000 : 1;
#if defined (__linux__) /* FIXME:  kernel  2.6.0 */
initial_ticks = (UINT_MAX - 300) * ticks_per_sec;
#else
initial_ticks = 0;
#endif
}

static uint32_t
GetTickCount (void)
{
struct tms tms;
clock_t ticks;

if ((ticks = times (tms)) == (clock_t) -1)
return 0;

ticks -= initial_ticks;

return (uint32_t) ticks / ticks_per_msec;
}


this gives 1/100th of a second accuracy +/-, so not quite millisecond
accuracy but... eh.

Jeff


On Fri, 2007-07-20 at 00:23 -0400, Jeffrey Stedfast wrote:
 from what I can tell reading the man page... you want to do this:
 
 guint32 GetTickCount (void)
 {
   struct tms tms;
   clock_t ticks;
   
   if ((ticks = times (tms)) == -1)
   return 0;
   
 #ifdef LINUX_KERNEL_2_6_0_OR_LATER
   ticks -= (UINT_MAX - 300) * CLOCKS_PER_SEC;
 #endif
 
 #define MSEC_PER_SEC 1000
 #define CLOCKS_PER_MSEC (CLOCKS_PER_SEC / MSEC_PER_SEC)
   
   return (guint32) (ticks / CLOCKS_PER_MSEC);
 } 
 
 On Thu, 2007-07-19 at 22:38 -0300, Thiago M. Sayão wrote:
  Hello!
  
  Enrironment.TickCount is supposed to return the miliseconds since the
  boot. For my surprise it was returning a negative number which should
  only happen on the 47th day of uptime.
  
  I did i fix (attached) but it doesn't seem 100% correct and i am not
  sure if it would work after some days.
  
  Since i'm coding a msn library and msn p2p protocol uses GetTickCount(),
  it's messing things for me!
  
  Can anyone take a look?
  
  Thanks!
  
  ___
  Mono-list maillist  -  Mono-list@lists.ximian.com
  http://lists.ximian.com/mailman/listinfo/mono-list
 
 ___
 Mono-list maillist  -  Mono-list@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/mono-list

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-dev] SmtpClient only supports ESMTP?

2007-05-30 Thread Jeffrey Stedfast
On Wed, 2007-05-30 at 12:12 +0200, Mads Bondo Dydensborg wrote:
 Hi there
 
 Regrettable I crashed into a smtp server today, that does not support 
 ESMTP, 
 but only SMTP (some old kind of exchange server, I think).
 
 It seems that System.Net.Mail.SmtpClient only supports ESMTP - is this true? 
 Any plans for supporting SMTP also?

I've just committed a fix to make it work for non-ESMTP servers (as well
as a few fixes for other low-hanging fruit that I spotted while browsing
thru the code).

Jeff


___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


[Mono-dev] test message

2007-05-22 Thread Jeffrey Stedfast
test to see if servers are back up

___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-dev] Character encoding issues on Linux

2007-05-17 Thread Jeffrey Stedfast
As far as I know, Mono depends on libiconv (as either a standalone
package or built into glibc - which is the case on Linux systems afaik)
for charset conversion.

The charset names used by libiconv however, may be named differently -
so I'm sure Mono has a table to try and do the proper mapping (I've had
to write tables like this in the past working on other projects).

I think CodePage 1256 probably maps to Windows-CP1256, which on my
particular Linux system w/ whatever libiconv I have could be mapped to
either CP1256 or WINDOWS-1256

(iconv --list will give you a listing of all supported charset names)

Perhaps I'll take a look later and see if I can't see something obvious
(I haven't ever worked on the runtime so I dunno for sure how it does
charset conversion, I could be way off)

Jeff

On Thu, 2007-05-17 at 11:08 +0100, Martin Brown wrote:
 Hi,
 
 We've got an application running on Mono on Linux. For the most part it
 runs very well; however every so often we get an exception: 
 CodePage 1256 not supported
 The code page number varies depending on the encoding present in the
 file.
 
 From the MS page here
 http://msdn.microsoft.com/library/shared/deeptree/asp/rightframe.asp?dtcfg=/library/deeptreeconfig.xmlurl=/library/en-us/cpref/html/frlrfsystemtextencodingclassgetencodingtopic1.asp?frame=truehidetoc=false
  
 it looks like the MS .Net implementation relies on the OS for character 
 encoding services. Is this the case for Mono too? If so, what needs to be 
 available on Linux to perform this encoding?
 
 Thanks
 
 Martin
 Filtered by 3BClean from http://www.3bview.com
 ___
 Mono-devel-list mailing list
 Mono-devel-list@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/mono-devel-list

___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-list] Benchmark Results - Mono vs .Net

2007-04-23 Thread Jeffrey Stedfast
I've been playing around with this benchmark and have discovered that
some of the reasons mono performs slower than MS is that (g)mcs doesn't
optimize things like:

r += i++;

very well. If you instead write the code as:

r += i; i++;

the performance of the arithmetic loops under mono matches that of the
MS .Net vm.

As far as the other tests... I dunno yet :)

Jeff

On Fri, 2007-04-13 at 09:46 +0200, Henk Tiggelaar wrote:
 Below are the results of benchmarks under Mono 1.2.3.1 and
 Microsoft.NET 2.0. Benchmark code used can be found at
 http://www.tommti-systems.de/main-Dateien/reviews/languages/benchmarks.html
 
 Mono 1.2.3.1 results
 
 Int arithmetic elapsed time: 8094 ms
 Double arithmetic elapsed time: 12141 ms
 long arithmetic elapsed time: 26406 ms
 Trig elapsed time: 2749 ms
 IO elapsed time: 3204 ms
 Array elapsed time: 406 ms
 Exception elapsed time: 3719 ms
 HashMap elapsed time: 234 ms
 HashMaps elapsed time: 5265 ms
 HeapSort elapsed time: 609 ms
 Vector elapsed time: 9953 ms
 Matrix Multiply elapsed time: 71562 ms
 Nested Loop elapsed time: 10359 ms
 String Concat. (fixed) elapsed time: 578 ms
 Total C# benchmark time: 155279 ms
 
 .NET 2.0 results
  
  Int arithmetic elapsed time: 5812 ms
 Double arithmetic elapsed time: 7249 ms
 long arithmetic elapsed time: 16265 ms
 Trig elapsed time: 2281 ms
 IO elapsed time: 2499 ms
 Array elapsed time: 203 ms
 Exception elapsed time: 26687 ms
 HashMap elapsed time: 124 ms
 HashMaps elapsed time: 3999 ms
 HeapSort elapsed time: 531 ms
 Vector elapsed time: 9890 ms
 Matrix Multiply elapsed time: 33687 ms
 Nested Loop elapsed time: 22265 ms
 String Concat. (fixed) elapsed time: 359 ms
 Total C# benchmark time: 131851 ms
 ___
 Mono-list maillist  -  Mono-list@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/mono-list

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] [mono-list]DLL Import errors

2007-04-20 Thread Jeffrey Stedfast
On Wed, 2007-04-18 at 10:28 -0600, Eric Morgan wrote:
 
 
 Frequently the problem is that the library is improperly linked; mono
 (effectively) loads libraries using dlopen(3) with RTLD_NOW set, so
 if
 your library depends on a symbol from another library but wasn't
 linked 
 against that library, you will get errors loading it.
 
 You can also use http://www.jprl.com/dltest.c to test this scenario
 (see
 the comments for compile commands). 
 
 If that still fails, you can reply to the mailing list with the Mono
 output attached.
 
  - Jon
 
 
 Still fails, and the output is generally the same from when I was
 using MONO_LOG_LEVEL=debug.  Here's the output from dltest: 
 
 [EMAIL PROTECTED] dltest]$
 ll /home/rengeo/RenegadeGeophysics/SeismicStudioLinux64/lib/
 total 992
 -r-xr-xr-x  1 rengeo rengeo 339956 Apr 17 10:14 libSentinelKeys32.a
 -r-xr-xr-x  1 rengeo rengeo 315468 Feb  8 14:42 libSentinelKeys32.so
 -r-xr-xr-x  1 rengeo rengeo 328388 Apr 17 12:26 libSentinelKeysJDK.so
 [EMAIL PROTECTED]
 dltest]$ ./dltest 
 /home/rengeo/RenegadeGeophysics/SeismicStudioLinux64/lib/libSentinelKeys32.so
 error loading library
 `/home/rengeo/RenegadeGeophysics/SeismicStudioLinux64/lib/libSentinelKeys32.so':
  
 /home/rengeo/RenegadeGeophysics/SeismicStudioLinux64/lib/libSentinelKeys32.so:
  cannot open shared object file: No such file or directory 
 [EMAIL PROTECTED] dltest]$
 
 
 The library is clearly there, but both mono and this dltest is saying
 that it doesn't exist.  I've tried copying the library directly into
 the folder with dltest, and it still can't find it, even though is
 literally right there. 

Don't assume that it means that the file you gave it doesn't exist (I
know, it is the most reasonable assumption to make). I suspect that
Jonathan is correct, the problem is that your library depends on symbols
not found in either the application nor in the library you are trying to
load, and so dlopen() is failing - of course, this is just a guess :)

The only way to know for sure is to read the source code for dlopen()
and try to figure out what the problem is that way.

Jeff


___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Benchmark Results - Mono vs .Net

2007-04-17 Thread Jeffrey Stedfast
For the Mono test, was that run on Windows? Or Linux?

I'm getting slower results (typically not by much except for the Double
Arith benchmark) on Linux with an AMD Athlon XP 2600
(altho /proc/cpuinfo says I have a 3200?). Either way my processor is
rated at 2200 GHz +/-.

Maybe if I get some spare cycles I'll dig into the performance problems
a bit (assuming someone else doesn't get there first).

Jeff

On Fri, 2007-04-13 at 09:46 +0200, Henk Tiggelaar wrote:
 Below are the results of benchmarks under Mono 1.2.3.1 and
 Microsoft.NET 2.0. Benchmark code used can be found at
 http://www.tommti-systems.de/main-Dateien/reviews/languages/benchmarks.html
 
 Mono 1.2.3.1 results
 
 Int arithmetic elapsed time: 8094 ms
 Double arithmetic elapsed time: 12141 ms
 long arithmetic elapsed time: 26406 ms
 Trig elapsed time: 2749 ms
 IO elapsed time: 3204 ms
 Array elapsed time: 406 ms
 Exception elapsed time: 3719 ms
 HashMap elapsed time: 234 ms
 HashMaps elapsed time: 5265 ms
 HeapSort elapsed time: 609 ms
 Vector elapsed time: 9953 ms
 Matrix Multiply elapsed time: 71562 ms
 Nested Loop elapsed time: 10359 ms
 String Concat. (fixed) elapsed time: 578 ms
 Total C# benchmark time: 155279 ms
 
 .NET 2.0 results
  
  Int arithmetic elapsed time: 5812 ms
 Double arithmetic elapsed time: 7249 ms
 long arithmetic elapsed time: 16265 ms
 Trig elapsed time: 2281 ms
 IO elapsed time: 2499 ms
 Array elapsed time: 203 ms
 Exception elapsed time: 26687 ms
 HashMap elapsed time: 124 ms
 HashMaps elapsed time: 3999 ms
 HeapSort elapsed time: 531 ms
 Vector elapsed time: 9890 ms
 Matrix Multiply elapsed time: 33687 ms
 Nested Loop elapsed time: 22265 ms
 String Concat. (fixed) elapsed time: 359 ms
 Total C# benchmark time: 131851 ms
 ___
 Mono-list maillist  -  Mono-list@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/mono-list

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-dev] Suggestions abt layout designer

2007-03-21 Thread Jeffrey Stedfast
Looks like QLayout is similar to Gtk's layout widgets, no?

Jeff

On Wed, 2007-03-21 at 16:37 +0530, Sharique uddin Ahmed Farooqui wrote:
 
 
 On 3/21/07, Jensen Somers [EMAIL PROTECTED] wrote:
 Hi,
 
 On 3/20/07, Sharique uddin Ahmed Farooqui
 [EMAIL PROTECTED] wrote:
  Hi,
   Qt's layout designer is really good. I think we should
 include it in 
  mono.
 
 
 MonoDevelop has a built in stetic designer, and there is still
 a tool
 called Glade (http://glade.gnome.org/). I also recall a tool
 named
 Gazpacho ( http://gazpacho.sicem.biz/).
 Both tools are GTK designers, so the created XML file can be
 used in
 C, C++ and C#.
 
 I think my questions is not clear. I'm talking abt Qt's layout
 controls not whole  designer.  These controls ease laying controls or
 grp of controls. 
 
 This  article  will  give  more  idea  what  exactly  I'm saying.
 http://www.codeproject.com/csharp/QtLikeLayout.asp
 
 
 I think these tools are good enough. The only thing that might
 be
 useful is a tool like Linguist.
 
 Regards,
 Jensen
 ___
 Mono-devel-list mailing list
 Mono-devel-list@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/mono-devel-list
 
 
 
 -- 
 Sharique uddin Ahmed Farooqui
 (C++/C# Developer, IT Consultant)
 http://www.manageweb.info/sharique
 A revolution is about to begin.
 A world is about to change.
 And you and me are the initiator. 
 ___
 Mono-devel-list mailing list
 Mono-devel-list@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/mono-devel-list

___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-dev] building mono, monodevelop, etc. from SVN on Ubuntu Edgy

2007-03-14 Thread Jeffrey Stedfast
On Wed, 2007-03-14 at 16:31 -0400, joel reed wrote:
 Eric Miller wrote:
  I've been Googling for some advice on building mono and monodevelop from 
  SVN on Ubuntu Edgy and haven't come up with much.

 
 http://www.mono-project.com/Compiling_Mono
 
 anything else you need to know?

after installing [libgdiplus,] mono/mcs, you'll need to build gtk-sharp,
gnome-sharp, gtkmozembed-sharp and gtksourceview-sharp from SVN in order
to build monodevelop

you'll probably find you'll need to install various gtk/gnome/etc -dev
packages as you go, most of the time the configure script will help with
that (or at worst check the config.log to see what is missing)

for gtk-sharp, you'll want to use ./bootstrap-2.10  (I think Edgy has
gtk+-2.10) and pass any --prefix, etc configure flags you want.

Jeff

___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-list] RE: Is it Mono safe?

2004-05-20 Thread Jeffrey Stedfast
On Thu, 2004-05-20 at 13:50 -0700, Rick Kitts wrote:
 On May 20, 2004, at 12:52 PM, Christopher McGinnis wrote:
 
  [...snip...]
  I would have to whole heartedly agree.  Good technology is good 
  technology
  no mater where it comes from.
 
 Would you have accepted a technology that, say, reduced processor heat 
 by 2 orders of magnitude (whatever) from, say, Stalin's soviet union 
 knowing what you know now about that mass murdering government?
 
 I think the question at hand is not, or at least should not be, about 
 what is practical. The CLR (or .NET if you'd prefer) is pretty sweet no 
 doubt about it. There is an ethical question regards adopting a MS 
 technology that will help MS. MS is not friendly to my ability to 
 choose. Enhancing their position in any way offers them increasing 
 potential to diminish my ability to choose.

you are confusing the issue. it's not the idea that can limit your
freedom, it's the implementation that can.

that said, your concerns becomes moot.

Jeff

-- 
Jeffrey Stedfast
Evolution Hacker - Novell, Inc.
[EMAIL PROTECTED]  - www.novell.com

___
Mono-list maillist  -  [EMAIL PROTECTED]
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] I give up

2004-04-08 Thread Jeffrey Stedfast
It falls under the LGPL

Jeff

On Thu, 2004-04-08 at 07:33, Timothy Parez wrote:
 What license does GTK fall under?
 
 ___
 Mono-list maillist  -  [EMAIL PROTECTED]
 http://lists.ximian.com/mailman/listinfo/mono-list
 

___
Mono-list maillist  -  [EMAIL PROTECTED]
http://lists.ximian.com/mailman/listinfo/mono-list


RE: [Mono-list] I give up

2004-04-08 Thread Jeffrey Stedfast
On Thu, 2004-04-08 at 09:33, Dan Winship wrote:
  If someone would actually take the time, Qt# can be used to write good 
  applications.
 
 Then take the time. If you find any bugs in mono that keep Qt# from working,
 we'll gladly accept your patches.

...and bug reports

Jeff

 
 -- Dan
 ___
 Mono-list maillist  -  [EMAIL PROTECTED]
 http://lists.ximian.com/mailman/listinfo/mono-list
 

___
Mono-list maillist  -  [EMAIL PROTECTED]
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Use of mcs sources

2003-11-10 Thread Jeffrey Stedfast
you should just be able to get away with using the lex/yacc (or, I think
mono uses jay) files.

Jeff

On Mon, 2003-11-10 at 08:09, [EMAIL PROTECTED] wrote:
 I want to write a C# editor tool as Visual Studio or SharpDevelop, but specialized
 on Mono and GTk# enviroment. I would need a C# parser and some .cs files
 of the mcs sources (/mcs directory) that are exactly that I'm looking for
 (using it, I could implement code analysis or autocompletion). I don't know
 if I could include some files of the sources on my own project (making clear
 where I find it), if I have to notify to the user to download the mcs sources
 to compile my project or if I cannot use it anyway r:-/ Do I have to change
 my project to GPL license?
 
 thanks!
 Manuel Castrillo
 
 -- Mensaje Original --
 Subject: Re: [Mono-list] Use of mcs sources
 From: Jonathan Pryor [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Cc: [EMAIL PROTECTED]
 Date: Mon, 10 Nov 2003 07:19:29 -0500
 
 
 You didn't specify which parts of mcs source code you wanted to use;
 this could refer to either the mcs.exe (the C# compiler) sources, or to
 the class library sources (which are in the mcs CVS repository). 
 Thus, I will clarify things.
 
 Licens
 s are a per-assembly construct, not a per-repository construct.
 
 So, in the mcs CVS repository, the mcs.exe assembly (sources in /mcs)
 is GPL.  Many (but not all, IIRC) of the tools (sources in /tools) are
 also GPL, but some are MIT X11 (again, I
 RC).
 
 The class libraries (sources in /class) are MIT X11.
 
 In general, .exe's are GPL, and .dll's are MIT X11.  The only exceptions
 to this rule are some .exe's (which are X11); all .dll's should be X11.
 
 Of course, this doesn't affect fair us
  of the source code.  You
 should be able to use GPL source code to determine how it works, and use
 that knowledge in new code; literal copying generally isn't permitted. 
 Fair use might allow some literal copying, though; this gets into a lot
 of g
 ay areas of copyright law, so it's probably best to just avoid it.
 
 Or, write GPL code and use the existing mcs.exe code as much as you
 want.
 
  - Jon
 
 On Mon, 2003-11-10 at 02:50, [EMAIL PROTECTED] wrote:
  Hi list!
  
  I'm a bit confused 
 bout licenses... Can I use parts of the mcs source code
  (GPL License) in a BSD proyect? Can I simply use parts of mcs sources?
  
  Thanks!
  
  
  PRUEBA TISCALI ADSL HASTA 6 MESES
  SIN CUOTAS FIJAS, SIN COMPROMISO
  
  PONNOS A PRUEBA
  
 
  http://acceso.tiscali.es/pag-acceso-adsl-Prueba.jsp?did=adp-7530007
  
  
  
  
  
  
  
  ___
  Mono-list maillist  -  [EMAIL PROTECTED]
  http://lists.ximian.com/mailman/listinfo/mono-
 ist
 
 
 
 
 PRUEBA TISCALI ADSL HASTA 6 MESES
 SIN CUOTAS FIJAS, SIN COMPROMISO
 
 PONNOS A PRUEBA
 
 http://acceso.tiscali.es/pag-acceso-adsl-Prueba.jsp?did=adp-7530007
 
 
 
 
 
 
 
 ___
 Mono-list maillist  -  [EMAIL PROTECTED]
 http://lists.ximian.com/mailman/listinfo/mono-list
-- 
Jeffrey Stedfast
Evolution Hacker - Ximian, Inc.
[EMAIL PROTECTED]  - www.ximian.com

___
Mono-list maillist  -  [EMAIL PROTECTED]
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] ThreadPool, why?

2003-08-27 Thread Jeffrey Stedfast
the overhead of launching a new thread can be quite substantial for some
operating systems, others might not be quite so bad, but even so -
re-using threads is always a lot less overhead than spawning news ones.

Jeff

On Wed, 2003-08-27 at 21:31 +0200, Sergio Blanco Cuaresma wrote:
 Hello!
 
 I don't understand the benefits of using a ThreadPool instead of
 launching simple Threads, I have read in several articles that its just
 more efficient, but I don't know why? What are the advantages of using
 ThreadPools ?
 
 Thanks!
-- 
Jeffrey Stedfast
Evolution Hacker - Ximian, Inc.
[EMAIL PROTECTED]  - www.ximian.com

___
Mono-list maillist  -  [EMAIL PROTECTED]
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Build fails on OS X

2003-03-12 Thread Jeffrey Stedfast
you probably need to install libiconv from
ftp://ftp.gnu.org/pub/gnu/libiconv/

(I think I got the url path right, if not - it's somewhere on
ftp.gnu.org)

Jeff

On Wed, 2003-03-12 at 16:39, James Fitzsimons wrote:
 Hi all,
 I am trying to build mono on my OS X (10.2) machine at home.
 Unfortunately I ran into problems before I even got to Mono!
 
 I got the following error trying to build glibc:
 
 snip
 checking for indent... indent
 checking for perl... /usr/bin/perl
 checking for iconv_open... no
 checking for libiconv_open in -liconv... no
 checking for iconv_open in -liconv... no
 configure: error: *** No iconv() implementation found in C library or
 libiconv 
 bash-2.05a$ 
 /snip
 
 I was wondering if anyone else had struck this problem on OS X and could
 suggest a work around?
 
 Thanks very much,
 James Fitzsimons
 ___
 Mono-list maillist  -  [EMAIL PROTECTED]
 http://lists.ximian.com/mailman/listinfo/mono-list
-- 
Jeffrey Stedfast
Evolution Hacker - Ximian, Inc.
[EMAIL PROTECTED]  - www.ximian.com

___
Mono-list maillist  -  [EMAIL PROTECTED]
http://lists.ximian.com/mailman/listinfo/mono-list