Re: [MacRuby-devel] Problems compiling MacRuby

2009-01-30 Thread Dave Baldwin


On 29 Jan 2009, at 17:12, Laurent Sansonetti wrote:


Dave,

The problem here is that you have a custom readline library in your  
system. If you look at the bugs logged in the tracker you will see  
some tips to make it work.


Deleting the extraneous readline.h fixed the problem for me.

Thanks,

Dave.





# I am considering rewriting the extensions build system to avoid  
this kind of problems, but this won't be in 0.4.


Laurent

On Jan 19, 2009, at 2:42 PM, Dave Baldwin wrote:



On 19 Jan 2009, at 21:34, Dave Baldwin wrote:


I get the same error from trunk or testing versions.

I have in the past downloaded readline from macports, but the /opt  
directory isn't in my path.


Any ideas what is wrong with my setup?

PS.  When will we see version 0.4?

Thanks,

Dave.



Jumped the gun - just notices a whole bunch of bugs logged on this  
same issue.


Still interested, though, on when 0.4 is going to be released as I  
don't seem able to build anything myself.


Dave.





gcc -I. -I../../.ext/include/universal-darwin9.0 -I..//.././ 
include -I..//.././ext/readline -DRUBY_EXTCONF_H=\"extconf.h\"  - 
fno-common -fno-common -pipe  -arch i386 -arch x86_64 -o  
readline.o -c readline.c

readline.c: In function ‘filename_completion_proc_call’:
readline.c:684: error: ‘filename_completion_function’ undeclared  
(first use in this function)
readline.c:684: error: (Each undeclared identifier is reported  
only once

readline.c:684: error: for each function it appears in.)
readline.c:684: warning: assignment makes pointer from integer  
without a cast

readline.c: In function ‘username_completion_proc_call’:
readline.c:709: error: ‘username_completion_function’ undeclared  
(first use in this function)
readline.c:709: warning: assignment makes pointer from integer  
without a cast

readline.c: In function ‘filename_completion_proc_call’:
readline.c:684: error: ‘filename_completion_function’ undeclared  
(first use in this function)
readline.c:684: error: (Each undeclared identifier is reported  
only once

readline.c:684: error: for each function it appears in.)
readline.c:684: warning: assignment makes pointer from integer  
without a cast

readline.c: In function ‘username_completion_proc_call’:
readline.c:709: error: ‘username_completion_function’ undeclared  
(first use in this function)
readline.c:709: warning: assignment makes pointer from integer  
without a cast
{standard input}:386:non-relocatable subtraction expression,  
"_mReadline" minus "L009$pb"
{standard input}:386:symbol: "_mReadline" can't be undefined in a  
subtraction expression
{standard input}:384:non-relocatable subtraction expression,  
"_completion_case_fold" minus "L009$pb"
{standard input}:384:symbol: "_completion_case_fold" can't be  
undefined in a subtraction expression
{standard input}:370:non-relocatable subtraction expression,  
"_mReadline" minus "L009$pb"
{standard input}:370:symbol: "_mReadline" can't be undefined in a  
subtraction expression
{standard input}:368:non-relocatable subtraction expression,  
"_completion_proc" minus "L009$pb"
{standard input}:368:symbol: "_completion_proc" can't be undefined  
in a subtraction expression
{standard input}:349:non-relocatable subtraction expression,  
"_mReadline" minus "L008$pb"
{standard input}:349:symbol: "_mReadline" can't be undefined in a  
subtraction expression
{standard input}:347:non-relocatable subtraction expression,  
"_completion_case_fold" minus "L008$pb"
{standard input}:347:symbol: "_completion_case_fold" can't be  
undefined in a subtraction expression
{standard input}:325:non-relocatable subtraction expression,  
"_mReadline" minus "L007$pb"
{standard input}:325:symbol: "_mReadline" can't be undefined in a  
subtraction expression
{standard input}:323:non-relocatable subtraction expression,  
"_completion_case_fold" minus "L007$pb"
{standard input}:323:symbol: "_completion_case_fold" can't be  
undefined in a subtraction expression
{standard input}:303:non-relocatable subtraction expression,  
"_mReadline" minus "L006$pb"
{standard input}:303:symbol: "_mReadline" can't be undefined in a  
subtraction expression
{standard input}:301:non-relocatable subtraction expression,  
"_completion_proc" minus "L006$pb"
{standard input}:301:symbol: "_completion_proc" can't be undefined  
in a subtraction expression
{standard input}:279:non-relocatable subtraction expression,  
"_mReadline" minus "L005$pb"
{standard input}:279:symbol: "_mReadline" can't be undefined in a  
subtraction expression
{standard input}:277:non-relocatable subtraction expression,  
"_completion_proc" minus "L005$pb"
{standard input}:277:symbol: "_completion_proc" can't be undefined  
in a subtraction expression
lipo: can't open input file: /var/folders/h9/h9HZ8oRtFEmwwYfYj60PaU 
+++TI/-Tmp-//ccyxzMdO.out (No such file or directory)

make: *** [readline.o] Error 1
rake aborted!
Command failed with status

[MacRuby-devel] hotcocoa - can't find executable...how to find it

2009-01-30 Thread Tim Rand
>> $:.each{|path| puts path + "/" + "hotcocoa.rb" if File.exists?(path + "/"
+ "hotcocoa.rb")}
/Library/Frameworks/MacRuby.framework/Versions/0.4/usr/lib/ruby/1.9.0/hotcocoa.rb

$: is a ruby environmental variable for an array of all the paths that ruby
looks at to require a file.
Another useful one to know is $", which holds the names of all currently
loaded external files.

I would imagine that somehow the path setting has been altered or you
accidentally moved hotcocoa to a location not included in the $: set.

I am frustrated that macgem is not functioning too. There are a lot of
possible reasons for it, but the most likely seems to be that many of the
gems for older versions of ruby need to be updated to work with 1.9, the
version that macruby is based on. Alternatively, failure of any given gem to
load could be due to macruby being under development and yet incomplete.

For me getting certain gems like sqlite3 to funciton with macruby is a
necessity.

Perhaps wonderful Laraunt or someone else could share some of his/her wisdom
on this issue of why many gems don't work, and if there is a plan for how to
fix it. Otherwise, I am going to keep plugging away at it in my spare
time--maybe around 2050 or so I will solve it. But I will solve it
eventually, because I love the idea of macruby and I love my old gem library
and I can't live without either.
Tim
___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


Re: [MacRuby-devel] hotcocoa - can't find executable...how to find it

2009-01-30 Thread Dr Nic Williams
Try: $LOAD_PATH.unshift
File.join(OSX::NSBundle.mainBundle.privateFrameworksPath,
'MacRuby.framework/Versions/Current/usr/lib/ruby/1.9.0')

(from Eloy a few days ago)

On Fri, Jan 30, 2009 at 6:27 PM, Tim Rand  wrote:
>>> $:.each{|path| puts path + "/" + "hotcocoa.rb" if File.exists?(path + "/"
>>> + "hotcocoa.rb")}
> /Library/Frameworks/MacRuby.framework/Versions/0.4/usr/lib/ruby/1.9.0/hotcocoa.rb
>
> $: is a ruby environmental variable for an array of all the paths that ruby
> looks at to require a file.
> Another useful one to know is $", which holds the names of all currently
> loaded external files.
>
> I would imagine that somehow the path setting has been altered or you
> accidentally moved hotcocoa to a location not included in the $: set.
>
> I am frustrated that macgem is not functioning too. There are a lot of
> possible reasons for it, but the most likely seems to be that many of the
> gems for older versions of ruby need to be updated to work with 1.9, the
> version that macruby is based on. Alternatively, failure of any given gem to
> load could be due to macruby being under development and yet incomplete.
>
> For me getting certain gems like sqlite3 to funciton with macruby is a
> necessity.
>
> Perhaps wonderful Laraunt or someone else could share some of his/her wisdom
> on this issue of why many gems don't work, and if there is a plan for how to
> fix it. Otherwise, I am going to keep plugging away at it in my spare
> time--maybe around 2050 or so I will solve it. But I will solve it
> eventually, because I love the idea of macruby and I love my old gem library
> and I can't live without either.
> Tim
>
> ___
> MacRuby-devel mailing list
> [email protected]
> http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel
>
>



-- 
Dr Nic Williams
iPhone and Rails consultants - http://mocra.com
Fun with iPhone/Ruby/Rails/Javascript - http://drnicwilliams.com
* Surf Report for iPhone - http://mocra.com/projects/surfreport/ *
___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


Re: [MacRuby-devel] [MacRuby] #215: OpenSSL's SSLSocket appears not to be initialised correctly

2009-01-30 Thread MacRuby
#215: OpenSSL's SSLSocket appears not to be initialised correctly
---+
 Reporter:  cel...@…   |   Owner:  lsansone...@…
 Type:  defect |  Status:  new  
 Priority:  major  |   Milestone:   
Component:  MacRuby|Keywords:  openssl  
---+

Comment(by cel...@…):

 Alright, here's a fix - I was testing the tests (!) from the cases/
 directory, rather than from where runner.rb was located, hence the
 CCompiler couldn't find ruby.h where it was looking ...

 I've inlined IOWaitReadable like you mentioned, ... and, I'm going to go
 hunt down why the C initialize is never called in the first place now! :-)

-- 
Ticket URL: 
MacRuby 

___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


Re: [MacRuby-devel] [MacRuby] #215: OpenSSL's SSLSocket appears not to be initialised correctly

2009-01-30 Thread MacRuby
#215: OpenSSL's SSLSocket appears not to be initialised correctly
---+
 Reporter:  cel...@…   |   Owner:  lsansone...@…
 Type:  defect |  Status:  new  
 Priority:  major  |   Milestone:   
Component:  MacRuby|Keywords:  openssl  
---+

Comment(by eloy.de.en...@…):

 Ah I see. Well actually the tests should run from anywhere IMO, so we
 shouldn't use relative paths.
 But I can probably look at that as well now that I understand what the
 problem was.

 Looking forward to the results of your research on why it's never called.
 Hint: try `git bisect' if you aren't already using that :)

-- 
Ticket URL: 
MacRuby 

___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


[MacRuby-devel] hotcocoa - can't find executable...how to find it

2009-01-30 Thread Robert Schaaf
Thanks Tim, this is helpful, but the problem is that once hotcocoa.rb  
is found, is fails on line 1, framework 'cocoa', thus:


RuntimeError: framework at path `cocoa' cannot be loaded: Error  
Domain=NSCocoaErrorDomain Code=4 UserInfo=0x136c620 "The bundle  
“cocoa” could not be loaded because its executable could not be  
located."
	from /Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ 
ruby/1.9.0/hotcocoa.rb:1:in `framework'




Is this because the cocoa framework can't be found, or that it might  
be corrupted, or what?


Here are the paths that your suggestion returns, with added newlines  
for clarity (and a several non-working gems!)


["/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/gems/ 
1.9.0/gems/rb-appscript-0.5.1/lib",
 "/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/ 
gems/1.9.0/gems/yahoofinance-1.2.2/lib",
 "/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/ 
site_ruby/1.9.0",
 "/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/ 
site_ruby/1.9.0/universal-darwin9.0",
 "/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/ 
site_ruby",
 "/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/ 
vendor_ruby/1.9.0",
 "/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/ 
vendor_ruby/1.9.0/universal-darwin9.0",
 "/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/ 
vendor_ruby",
 "/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/ 
1.9.0",
 "/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/ 
1.9.0/universal-darwin9.0",

 "."]

Could it have been a macgem install gone bad that clobbered  
something?  What does a normal macruby installation look like?


Continued thanks,

Bob Schaaf

Tim Rand wrote:

$:.each{|path| puts path + "/" + "hotcocoa.rb" if File.exists? 
(path + "/"

+ "hotcocoa.rb")}
/Library/Frameworks/MacRuby.framework/Versions/0.4/usr/lib/ruby/ 
1.9.0/hotcocoa.rb


$: is a ruby environmental variable for an array of all the paths  
that ruby

looks at to require a file.
Another useful one to know is $", which holds the names of all  
currently

loaded external files.

___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


Re: [MacRuby-devel] hotcocoa not loading cocoa framework

2009-01-30 Thread Robert Schaaf

Hello all (again),

I may have found the root of the problem.  If so, I need a fix.

Laurent's hint, 'NSBundle.bundleWithPath('/System/Library/Frameworks/  
Cocoa.framework').load' succeeds,. Tim Rand's pointing out the $:  
variable was a big help, and here's the result:


>> $:.each {|sp| puts sp + "\n"}
/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/gems/ 
1.9.0/gems/rb-appscript-0.5.1/lib
/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/gems/ 
1.9.0/gems/yahoofinance-1.2.2/lib
/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/ 
site_ruby/1.9.0
/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/ 
site_ruby/1.9.0/universal-darwin9.0
/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/ 
site_ruby
/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/ 
vendor_ruby/1.9.0
/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/ 
vendor_ruby/1.9.0/universal-darwin9.0
/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/ 
vendor_ruby

/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/1.9.0
/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/1.9.0/ 
universal-darwin9.0


It looks like /System/Library/Frameworks/  is not in my search path.   
The questions are why not? how do I remedy this? and will doing so  
make it work?


Even more thanks,

Bob Schaaf

___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


Re: [MacRuby-devel] hotcocoa not loading cocoa framework

2009-01-30 Thread Robert Schaaf

Hmmm,

I spoke too soon.  I just loaded MacRuby into a clean environment on  
another machine, and /System/Library/Frameworks/  is not in $: and  
require 'hotcocoa' works just fine.


Back to the drawing board.

Bob Schaaf


On Jan 30, 2009, at 6:27 PM, Robert Schaaf wrote:


Hello all (again),

I may have found the root of the problem.  If so, I need a fix.

Laurent's hint, 'NSBundle.bundleWithPath('/System/Library/ 
Frameworks/ Cocoa.framework').load' succeeds,. Tim Rand's pointing  
out the $: variable was a big help, and here's the result:


>> $:.each {|sp| puts sp + "\n"}
/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/gems/ 
1.9.0/gems/rb-appscript-0.5.1/lib
/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/gems/ 
1.9.0/gems/yahoofinance-1.2.2/lib
/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/ 
site_ruby/1.9.0
/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/ 
site_ruby/1.9.0/universal-darwin9.0
/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/ 
site_ruby
/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/ 
vendor_ruby/1.9.0
/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/ 
vendor_ruby/1.9.0/universal-darwin9.0
/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/ 
vendor_ruby

/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/1.9.0
/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/ 
1.9.0/universal-darwin9.0


It looks like /System/Library/Frameworks/  is not in my search  
path.  The questions are why not? how do I remedy this? and will  
doing so make it work?


Even more thanks,

Bob Schaaf

___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


Re: [MacRuby-devel] hotcocoa not loading cocoa framework

2009-01-30 Thread Joshua Ballanco

Bob,

Out of curiosity, does the machine that's giving you trouble have a  
case-sensitive HFS+ filesystem? Just a shot in the dark, but I've had  
case-sensitivity related issues with Ruby 'require's in the past...


- Josh



On Jan 30, 2009, at 7:36 PM, Robert Schaaf  wrote:


Hmmm,

I spoke too soon.  I just loaded MacRuby into a clean environment on  
another machine, and /System/Library/Frameworks/  is not in $: and  
require 'hotcocoa' works just fine.


Back to the drawing board.

Bob Schaaf


On Jan 30, 2009, at 6:27 PM, Robert Schaaf wrote:


Hello all (again),

I may have found the root of the problem.  If so, I need a fix.

Laurent's hint, 'NSBundle.bundleWithPath('/System/Library/ 
Frameworks/ Cocoa.framework').load' succeeds,. Tim Rand's pointing  
out the $: variable was a big help, and here's the result:


>> $:.each {|sp| puts sp + "\n"}
/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/ 
gems/1.9.0/gems/rb-appscript-0.5.1/lib
/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/ 
gems/1.9.0/gems/yahoofinance-1.2.2/lib
/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/ 
site_ruby/1.9.0
/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/ 
site_ruby/1.9.0/universal-darwin9.0
/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/ 
site_ruby
/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/ 
vendor_ruby/1.9.0
/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/ 
vendor_ruby/1.9.0/universal-darwin9.0
/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/ 
vendor_ruby

/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/1.9.0
/Library/Frameworks/MacRuby.framework/Versions/0.3/usr/lib/ruby/ 
1.9.0/universal-darwin9.0


It looks like /System/Library/Frameworks/  is not in my search  
path.  The questions are why not? how do I remedy this? and will  
doing so make it work?


Even more thanks,

Bob Schaaf

___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel

___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel