Skype4Java via Scala on Mac OS
Asked Answered
S

1

13

I'm running Mac OS 10.6, Java 1.6_17, Scala 2.8.1 final. I'm attempting to make a simple Skype call using Skype4Java by doing the following:

$>export JAVA_OPTS=-d32

$>scala -classpath .:./skype/release/skype.jar

scala> com.skype.Skype.makeCall("echotest")

I'm getting the error

"invalid attempt to access memory at location 0x0 ... bus error". 

Anybody else experience this and find a solution?

Note: I'm able to use this api perfectly fine by invoking one of the samples when I run it using command line java. Attempting to execute the same sample using command line scala fails with the error above.

Salpingotomy answered 19/5, 2011 at 18:8 Comment(4)
Well, what's the simplest example available? There might just be something in it that you are missing with that example above.Ento
hmm, makeCall() is a pretty simple example. I could look for methods from the api that do less -- maybe just look at the contacts list or something.Salpingotomy
Try object Test { def main(args:Array[String]) { ... } } object syntax, compile and then run with scala -cp ... Test. Also try with java -cp ... Test where scala-library.jar is added to the classpath. The REPL does certain things that may interfere with shared lib loading.Majordomo
Yeah, in my note above I said that I was able to run the sample successfully using command line java (was using -cp). Same applies for the simple example you've listed.Salpingotomy
L
1

Try object Test { def main(args:Array[String]) { ... } }

Lovett answered 24/5, 2012 at 12:33 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.