?

Log in

No account? Create an account
LiveJournal Client Discussions [entries|archive|friends|userinfo]
LiveJournal Client Discussions

[ userinfo | livejournal userinfo ]
[ archive | journal archive ]

Crosspost Updated [Nov. 29th, 2005|08:55 pm]
LiveJournal Client Discussions

lj_clients

[trippingbilly]
I should really mention that I upated Crosspost recently... 0.2.1 Alpha!

http://sourceforge.net/projects/crosspost

Changes in this version include complete MySpace blog support as well as a completed update to the Blogger API.

Currently supported blog services are:
  • Livejoural
  • Blogger
  • Myspace
  • Xanga


Give it a whirl. If you have ideas for added features, go here.

Posted by Crosspost! software.
linkReply

Comments:
[User Picture]From: trippingbilly
2006-01-10 08:23 pm (UTC)
Ok. Currently the jar is bundled with the org.eclipse.swt.win32.win32.x86_3.1.0.jar, which expects to find the win32 SWT native library. I've re-packaged the Crosspost jar *without* SWT, so that users can add in SWT support based on their platform. Please test it out and let me know what sort of results you get with it. If it works out for you, I'll put up another jar release today.

Keep in mind that you may have to set your classpath and/or native library path at runtime to make your jre understand that you want to use the SWT libraries. Also, since the jar won't include everything you need (swt, for example) you'll need to add this jar to your classpath and run com.abditory.crosspost.CrosspostMain. YMMV.

I guess I may have to start packaging seperate jars for each platform which I'd really rather not do.

http://crosspost.sourceforge.net/crosspost-2006011001.jar
(Reply) (Parent) (Thread)
From: davidcougle
2006-01-10 10:26 pm (UTC)
ok, i did yum install eclipse-platform and it installed 56 packages:)

i am using jdk 1.5.

I get this, what am I missing?

java -jar crosspost-2006011001.jar
Exception in thread "main" java.lang.NoClassDefFoundError: org/eclipse/swt/widgets/Display
at com.abditory.crosspost.CrosspostMain.main(Unknown Source)


what did i need to do in addition to that?
(Reply) (Parent) (Thread)
[User Picture]From: trippingbilly
2006-01-10 10:36 pm (UTC)
What is your current classpath? Does SWT exist there? Were the SWT native libraries installed in the appropriate place in order for your JRE to locate them?

From the error you're sending, it looks as if your JRE cannot locate the SWT libraries.
(Reply) (Parent) (Thread)
From: davidcougle
2006-01-11 12:44 am (UTC)
what swt libraries do i need to include in classpath?
this may give you an idea of my file location

find / -name libswt*
/usr/share/eclipse/configuration/org.eclipse.osgi/bundles/58/1/.cp/libswt-gnome-gtk-3139.so
/usr/share/eclipse/configuration/org.eclipse.osgi/bundles/58/1/.cp/libswt-atk-gtk-3139.so
/usr/share/eclipse/configuration/org.eclipse.osgi/bundles/58/1/.cp/libswt-awt-gtk-3139.so
/usr/share/eclipse/configuration/org.eclipse.osgi/bundles/58/1/.cp/libswt-mozilla-gtk-3139.so
/usr/share/eclipse/configuration/org.eclipse.osgi/bundles/58/1/.cp/libswt-gtk-3139.so
/usr/share/eclipse/configuration/org.eclipse.osgi/bundles/58/1/.cp/libswt-pi-gtk-3139.so
/usr/lib/eclipse/libswt-gnome-gtk-3139.so
/usr/lib/eclipse/libswt-atk-gtk-3139.so
/usr/lib/eclipse/libswt-awt-gtk-3139.so
/usr/lib/eclipse/libswt-mozilla-gtk-3139.so
/usr/lib/eclipse/libswt-gtk-3139.so
/usr/lib/eclipse/libswt-pi-gtk-3139.so
/usr/lib/libswt-gtk-3139.so
/usr/lib/libswt-atk-gtk-3139.so
/usr/lib/libswt-awt-gtk-3139.so
/usr/lib/libswt-gnome-gtk-3139.so
/usr/lib/libswt-mozilla-gtk-3139.so
/usr/lib/libswt-pi-gtk-3139.so
(Reply) (Parent) (Thread)
From: davidcougle
2006-01-11 12:46 am (UTC)
export CLASSPATH=$classpath:/usr/share/eclipse/configuration/org.eclipse.osgi/bundles/58/1/.cp/
[root@home Desktop]# java -jar crosspost-
crosspost-2006011001.jar crosspost-jar-0.2.1-alpha.jar
[root@home Desktop]# java -jar crosspost-2006011001.jar
Exception in thread "main" java.lang.NoClassDefFoundError: org/eclipse/swt/widgets/Display
at com.abditory.crosspost.CrosspostMain.main(Unknown Source)
(Reply) (Parent) (Thread)
[User Picture]From: trippingbilly
2006-01-11 04:43 am (UTC)
SWT presents two library requirements: classpath, and native.

In the setup described above, you have located the native libraries for SWT, which should *not* be on your classpath. These should be in the default native library path for your JRE. Usually it's something like jre/lib/i386. I'd recommend copying the .so files you located above to this location.

For the classpath, you need to locate the required SWT jar files. Try a "find / -name '*swt*.jar" and see what you can come up with. Once you locate them, either copy them to jre/lib/ext (which should be on your classpath by default) or specify them using the environment variable $CLASSPATH.
(Reply) (Parent) (Thread)
From: davidcougle
2006-01-11 05:19 am (UTC)
find / -name '*swt*.jar'
/usr/share/java/swt-gtk-3.1.1.jar
/usr/share/eclipse/plugins/org.eclipse.swt.gtk.linux.x86_3.1.1.jar
/usr/share/eclipse/plugins/org.eclipse.swt_3.1.0.jar

---

java -jar crosspost-2006011001.jar
Exception in thread "main" java.lang.NoClassDefFoundError: org/eclipse/swt/widgets/Display
at com.abditory.crosspost.CrosspostMain.main(Unknown Source)
[david@home Desktop]$ echo $CLASSPATH
/usr/share/java:/usr/share/eclipse/plugins
(Reply) (Parent) (Thread)
[User Picture]From: trippingbilly
2006-01-11 06:38 pm (UTC)
Here's what I did to run the jar I gave you under Linux:

Grab the latest swt build from:
http://www.eclipse.org/downloads/download.php?file=/eclipse/downloads/drops/R-3.1.1-200509290840/swt-3.1.1-gtk-linux-x86.zip

Unzip it into a directory called "swt" in the current path.

Run crosspost:

java -cp swt:crosspost-2006011001.jar -Djava.library.path=swt com.abditory.crosspost.CrosspostMain

You should get an error about it not being able to find the text file for the license because you're not executing the jar directly. It's GPL, so only worry about it if you've never read through the license.

Problems like this are a pain because everybody's Java environment seems to be set up a little differently. I'm working on some docs (behind the scenes) that will go up on http://crosspost.sourceforge.net to help out with issues like this. I also plan on doing some new packages that shoudl solve some of these problems. For example, there will eventually be a linux package that will provide a startup script for running Crosspost (much like Azureus, another SWT-based Java project, does).

Hope this helps. Keep me posted.
(Reply) (Parent) (Thread)
[User Picture]From: trippingbilly
2006-01-11 06:50 pm (UTC)
Also, you should note that I had to commit a new version of the MySpace code to CVS. MySpace made some changes recently to the way they handle the forms for logging in.

I'll have a new release up with the change soon...
(Reply) (Parent) (Thread)
From: davidcougle
2006-01-11 07:23 pm (UTC)
ok, will be waiting for new release.
(Reply) (Parent) (Thread)
[User Picture]From: trippingbilly
2006-01-11 07:36 pm (UTC)
It's up now. :-)
(Reply) (Parent) (Thread)
From: davidcougle
2006-01-11 10:08 pm (UTC)
yeah, it's back to win32:(

java -jar crosspost-jar-0.2.2-alpha.jar
Exception in thread "main" java.lang.UnsatisfiedLinkError: no swt-win32-3138 in java.library.path
at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1682)
at java.lang.Runtime.loadLibrary0(Runtime.java:822)
at java.lang.System.loadLibrary(System.java:992)
at org.eclipse.swt.internal.Library.loadLibrary(Library.java:123)
at org.eclipse.swt.internal.win32.OS.(OS.java:18)
at org.eclipse.swt.widgets.Display.(Display.java:125)
at com.abditory.crosspost.CrosspostMain.main(Unknown Source)
(Reply) (Parent) (Thread)
[User Picture]From: trippingbilly
2006-01-11 10:17 pm (UTC)
Did you see the comment listing out the way I ran it on Linux?

Please don't use "-jar crosspost-jar-0.2.2-alpha.jar" for now... at least until I can bundle all the linux-specific libraries into a linux-specific jar. Try to run it by specifying the classpath and the java.library.path and giving it the fully qualified class name.

I pasted in the exact procedure (that worked for me, by the way) into a previous comment.
(Reply) (Parent) (Thread)
From: davidcougle
2006-01-11 10:25 pm (UTC)
ok, i see it.

extracted swt files to swt/

you broke a line in your post which makes things confusing, so I tried this

java -cp swt:crosspost-jar-0.2.2-alpha.jar -Djava.library.path=swt com.abditory.crosspost.CrosspostMain
Exception in thread "main" java.lang.UnsatisfiedLinkError: no swt-win32-3138 in java.library.path
at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1682)
at java.lang.Runtime.loadLibrary0(Runtime.java:822)
at java.lang.System.loadLibrary(System.java:992)
at org.eclipse.swt.internal.Library.loadLibrary(Library.java:123)
at org.eclipse.swt.internal.win32.OS.(OS.java:18)
at org.eclipse.swt.widgets.Display.(Display.java:125)
at com.abditory.crosspost.CrosspostMain.main(Unknown Source)
(Reply) (Parent) (Thread)
[User Picture]From: trippingbilly
2006-01-12 03:11 pm (UTC)
In your classpath parameter, you're including the swt folder, not the jar. The -cp parameter should read:

"-cp swt.jar:crosspost-jar-0.2.2-alpha.jar"
(Reply) (Parent) (Thread) (Expand)