ben
May 6, 2008, 11:32am
1
Hi
I try to write a little blog article about installing mono and
ironruby on Mac Leopard from the ground up. It’s a bit a bumpy road
(especially to get mono build from sources), but I’m almost there.
I’m following these instructions
http://sparcs.kaist.ac.kr/~tinuviel/download/IronRuby/HOWTO
and work with the latest patch:
$ patch -p0 < patch-mono-r94
from here:
http://sparcs.kaist.ac.kr/~tinuviel/download/IronRuby/patch-mono-r94
but it doesn’t work:
$ rake compile mono=1
rake aborted!
cannot resolve path System.dll
~/mono/compiling/ironruby/rakefile:137
(See full trace by running task with --trace)
(* with --trace see below)
What’s needed that the System.dll can be resolved?
Thanks for your help.
Ben
(*)
$ sudo rake compile mono=1 --trace
(~/mono/compiling/ironruby)
** Invoke compile (first_time)
** Invoke happy (first_time)
** Execute happy
** Invoke clean_build (first_time)
** Invoke happy
** Execute clean_build
** Invoke compile_dlr (first_time)
** Invoke clean_build
** Execute compile_dlr
rake aborted!
cannot resolve path System.dll
./context.rb:90:in resolve_framework_path' ./context.rb:89:in
each’
./context.rb:89:in resolve_framework_path' ./context.rb:130:in
resolve_framework_path’
./context.rb:405:in resolve_framework_path' ./context.rb:420:in
references’
./context.rb:418:in each' ./context.rb:418:in
references’
./context.rb:434:in compile' ./context.rb:432:in
chdir’
./context.rb:432:in compile' /mono/compiling/ironruby/rakefile:137 ./context.rb:578:in
instance_eval’
./context.rb:578:in source_context' /mono/compiling/ironruby/rakefile:135 /opt/local/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:546:in
call’
/opt/local/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:546:in
execute' /opt/local/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:541:in
each’
/opt/local/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:541:in
execute' /opt/local/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:508:in
invoke_with_call_chain’
/opt/local/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:501:in
synchronize' /opt/local/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:501:in
invoke_with_call_chain’
/opt/local/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:518:in
invoke_prerequisites' /opt/local/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:1183:in
each’
/opt/local/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:1183:in send' /opt/local/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:1183:in
each’
/opt/local/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:515:in
invoke_prerequisites' /opt/local/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:507:in
invoke_with_call_chain’
/opt/local/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:501:in
synchronize' /opt/local/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:501:in
invoke_with_call_chain’
/opt/local/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:494:in invoke' /opt/local/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:1931:in
invoke_task’
/opt/local/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:1909:in
top_level' /opt/local/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:1909:in
each’
/opt/local/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:1909:in
top_level' /opt/local/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:1948:in
standard_exception_handling’
/opt/local/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:1903:in
top_level' /opt/local/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:1881:in
run’
/opt/local/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:1948:in
standard_exception_handling' /opt/local/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:1878:in
run’
/opt/local/lib/ruby/gems/1.8/gems/rake-0.8.1/bin/rake:31
/opt/local/bin/rake:16:in `load’
/opt/local/bin/rake:16
ben
May 6, 2008, 12:16pm
2
2008/5/6 Ben A. [email protected] :
What’s needed that the System.dll can be resolved?
You need to have pkg-config correctly configured.
$ pkg-config --variable=libdir mono
/usr/lib
If you don’t get any output, try setting PKG_CONFIG_PATH so that
pkg-config can find mono.pc.
ben
May 6, 2008, 12:42pm
3
that’s my line in ~/.bash_profile:
…
export PKG_CONFIG_PATH="/opt/mono/lib/pkgconfig/"
,…
and this is what I get with
$ pkg-config --variable=libdir mono
/opt/mono/lib/pkgconfig/…/…/lib
should this be correct - no? What’s wrong here?
ben
May 6, 2008, 12:54pm
4
I forgot to mention:
after restarting the shell, I tried it once again:
$ rake compile mono=1
(in /mono/compiling/ironruby)
Read in 33 resources from
‘…/ironruby/src/microsoft.scripting.core/Microsoft.Scripting.txt’
Writing resource file… Done.
–and than this error (?):
./actions/comdispatch/DispCallable.cs(134,9): error CS0452: The type
T' must be a reference type in order to use it as type parameter
T’
in the generic type or method
Microsoft.Scripting.Actions.RuleBuilder<T>'. ./actions/comdispatch/comtypelibdesc.cs(141,9): error CS0452: The type
T’ must be a reference type in order to use it as type parameter T' in the generic type or method
Microsoft.Scripting.Actions.RuleBuilder’.
–
Compilation failed: 2 error(s), 0 warnings
rake aborted!
Command failed with status (1): [gmcs
/out:"/users/shared/xfiles/root/nowit…]
/mono/compiling/ironruby/rakefile:137
When I now try to run it again I simply get:
$ sudo rake compile mono=1
rake aborted!
cannot resolve path System.dll
ben
May 6, 2008, 1:29pm
5
2008/5/6 Ben A. [email protected] :
–and than this error (?):
./actions/comdispatch/DispCallable.cs(134,9): error CS0452: The type
T' must be a reference type in order to use it as type parameter
T’
in the generic type or method
Microsoft.Scripting.Actions.RuleBuilder<T>'. ./actions/comdispatch/comtypelibdesc.cs(141,9): error CS0452: The type
T’ must be a reference type in order to use it as type parameter T' in the generic type or method
Microsoft.Scripting.Actions.RuleBuilder'.
This is a recent unrelated error. This problem is reported as Mono bug
#387040 .
https://bugzilla.novell.com/show_bug.cgi?id=387040
The last working revision is r98. If all you want is to try IronRuby,
you could update to old revisions.
When I now try to run it again I simply get:
$ sudo rake compile mono=1
rake aborted!
cannot resolve path System.dll
Of course, you are using sudo, which resets the shell environment.
Therefore, don’t.
ben
May 6, 2008, 2:25pm
6
ok, I’m a little confused now. What excactly do I have to do now in
order to compile it?
I’m stuck with compiling ironruby.
$ rake compile mono=1
rake aborted!
cannot resolve path System.dll
What to do??
ben
May 6, 2008, 1:53pm
7
oh I have a script that should do all that.
i can email it to you if you want.
I also have that blogpost up that explains everything
ben
May 6, 2008, 2:27pm
8
Ivan, your article was one of the references for my attempt to install
ironruby on leopard. It would be very nice if you could send me your
script to [email protected]
thanks
ben
May 6, 2008, 2:49pm
9
Seo,
As I’ve writte in my 2nd response PKG_CONFIG_PATH is set. The question
is: Is it set correctly and what is the criteria for the correct
setting?
ben
May 6, 2008, 2:32pm
10
2008/5/6 Ben A. [email protected] :
ok, I’m a little confused now. What excactly do I have to do now in
order to compile it?
I believe I already answered all your questions. If you have some
more, please state it.
Cannot resolve path System.dll
Configure pkg-config correctly. Make sure PKG_CONFIG_PATH is set. Make
sure you don’t use sudo, which reset the shell environment.
Bizarre CS0452 error from Mono C# compiler
Mono bug #387040 . No solution yet. Downgrade to SVN r98.
ben
May 6, 2008, 3:01pm
11
ok I have the reason why it didn’t worked.
on the post of Ivan
(Compiling Mono and IronRuby on OSX Leopard - Ivan Porto Carrero )
I copied the line:
export
PKG_CONFIG_PATH=“/usr/local/lib/pkgconfig:/opt/local/lib/pkgconfig”
now the path (/usr/local/…) has other exclamation marks than there
are on my mac.
" (blog)
" (my mac)
I don’t know if you can see the difference. But fact is that it
doesn’t work with the “blog marks”.
Does somebody has an explanation for this?
thanks
Ben
ben
May 6, 2008, 3:16pm
12
thanks,
does that mean, that my terminal don’t know the character set used on
the website?
On Tue, May 6, 2008 at 3:10 PM, Thibaut Barrère
ben
May 6, 2008, 3:12pm
13
Does somebody has an explanation for this?
The double quote is transformed into mister ”, a nicer yet
incompatible-with-your-command-line version of itself.
cheers
Thibaut
http://blog.logeek.fr - learning content for developers
http://evolvingworker.com - tools for a better day
ben
May 6, 2008, 3:24pm
14
if I understand Seo correctly, I have to downgrade in order to
compile ironruby for mac. There is no other option.
Could somebody tell me the (best) way for downgrading the sources. Can
I downgrade with SVN the existing sources? If yes - how?
Or is it better to remove the checked out sources and make a checkout
again with the specific revision number? Again - how?
thanks for your help
Benh
ben
May 6, 2008, 3:25pm
15
does that mean, that my terminal don’t know the character set used on the
website?
If you use the html version on the OS X command line, the variable will
keep
the quotes inside the value instead of acting like a string delimiter:
Macintosh:temp thbar$ export
SOMEVAR="/usr/local/lib/pkgconfig:/opt/local/lib/pkgconfig"
Macintosh:temp thbar$ echo $SOMEVAR
“/usr/local/lib/pkgconfig:/opt/local/lib/pkgconfig”
On the other hand, if you use the regular double-quote, you’ll get the
expected behaviour:
Macintosh:temp thbar$ export
SOMEVAR="/usr/local/lib/pkgconfig:/opt/local/lib/pkgconfig"
Macintosh:temp thbar$ echo $SOMEVAR
*/usr/local/lib/pkgconfig:/opt/local/lib/pkgconfig
*
hope this helps
– Thibaut
ben
May 6, 2008, 3:29pm
16
2008/5/6 Ben A. [email protected] :
Could somebody tell me the (best) way for downgrading the sources. Can
I downgrade with SVN the existing sources? If yes - how?
Yes. svn update -r 98.
ben
May 6, 2008, 4:30pm
17
thanks,
I always got the error:
svn: Failed to add file ‘web/makefile’: object of the same name already
exists
I removed web/Makefile, and than it worked …