[Linux Lobby] AFLobby Beta 3.9.7 - Page 21

[Linux Lobby] AFLobby Beta 3.9.7

Discuss everything related to running Spring on your chosen distribution of Linux.

Moderator: Moderators

User avatar
Agon
Posts: 527
Joined: 16 May 2007, 18:33

Post by Agon »

Okay, I instaleld JDK and JRE version 1.6.
And than I enter "scons configure" and java was not found.
Checking for Java... not found
Guessing Java include path... /usr/include/java
Can you tell me that I must include here /usr/include/java ?
I tryed jdk and jre to copy into. But same output!
User avatar
AF
AI Developer
Posts: 20687
Joined: 14 Sep 2004, 11:32

Post by AF »

You'd have to ask tobi, I dont know very much about building spring and its dependencies on linux.
Lippy
Posts: 327
Joined: 16 Jul 2006, 00:24

Post by Lippy »

Agon wrote:Okay, I instaleld JDK and JRE version 1.6.
And than I enter "scons configure" and java was not found.
Checking for Java... not found
Guessing Java include path... /usr/include/java
Can you tell me that I must include here /usr/include/java ?
I tryed jdk and jre to copy into. But same output!
Install free-java-sdk.. worked for me as far as I can remember

EDIT: This guy had the same problem (I think) http://spring.clan-sy.com/phpbb/viewtop ... reejavasdk , I updated the wiki, to include free-java-sdk, but I'm not sure it's the correct way of doing it.
User avatar
Agon
Posts: 527
Joined: 16 May 2007, 18:33

Post by Agon »

Install free-java-sdk.. worked for me as far as I can remember
Thx. I will try it.
Do you mean this: http://openjdk.java.net/ ?

Okay I finish here, sry af. But I have no time for trying to install a open jdk with big requires.
Maybe Lippy can do this. But I don´t want to install 100 of packages to install one package to compile one library.
Lippy
Posts: 327
Joined: 16 Jul 2006, 00:24

Post by Lippy »

Agon wrote:
Install free-java-sdk.. worked for me as far as I can remember
Thx. I will try it.
Do you mean this: http://openjdk.java.net/ ?

Okay I finish here, sry af. But I have no time for trying to install a open jdk with big requires.
Maybe Lippy can do this. But I don´t want to install 100 of packages to install one package to compile one library.
Agon, is it not on yast (you're using suse right?)? I just used "apt-get install free-java-sdk" on ubuntu.

I could try to do "this" but I'm not really sure what "this" is. From what I can figure out AF wants someone to compile the latest SVN and then give him the unitsync.so file? (whats the directory?)
User avatar
Agon
Posts: 527
Joined: 16 May 2007, 18:33

Post by Agon »

I think he needs the javaunitsync.so not the unitsync.so.
cd ~/src/taspring_0.73b1
scons omni
cd omni
cp unitsync.so $HOME/.spring/spring-gui-3.12
For the normal unitsync.so.
User avatar
AF
AI Developer
Posts: 20687
Joined: 14 Sep 2004, 11:32

Post by AF »

If you have a jdk and jre correctly installed and its not taking the hint then I suggest you contact tobi as there must be something wrong with the java check.
Lippy
Posts: 327
Joined: 16 Jul 2006, 00:24

Post by Lippy »

Agon wrote:I think he needs the javaunitsync.so not the unitsync.so.
cd ~/src/taspring_0.73b1
scons omni
cd omni
cp unitsync.so $HOME/.spring/spring-gui-3.12
For the normal unitsync.so.
kk, I'll do it tomorrow morning, as I can't now.
User avatar
Relative
Posts: 1371
Joined: 15 Oct 2006, 13:17

Post by Relative »

Tried to reload the map list after downloading a new map:

Code: Select all

[Loaded com.sun.imageio.plugins.jpeg.JPEGImageWriterSpi from /usr/lib/jvm/java-6-sun-1.6.0.00/jre/lib/rt.jar]
[Loaded com.sun.imageio.spi.FileImageInputStreamSpi from /usr/lib/jvm/java-6-sun-1.6.0.00/jre/lib/rt.jar]
[Loaded com.sun.imageio.spi.FileImageOutputStreamSpi from /usr/lib/jvm/java-6-sun-1.6.0.00/jre/lib/rt.jar]
[Loaded com.sun.imageio.spi.InputStreamImageInputStreamSpi from /usr/lib/jvm/java-6-sun-1.6.0.00/jre/lib/rt.jar]
[Loaded com.sun.imageio.spi.OutputStreamImageOutputStreamSpi from /usr/lib/jvm/java-6-sun-1.6.0.00/jre/lib/rt.jar]
[Loaded com.sun.imageio.spi.RAFImageInputStreamSpi from /usr/lib/jvm/java-6-sun-1.6.0.00/jre/lib/rt.jar]
[Loaded com.sun.imageio.spi.RAFImageOutputStreamSpi from /usr/lib/jvm/java-6-sun-1.6.0.00/jre/lib/rt.jar]
[Loaded javax.imageio.spi.IIORegistry$1 from /usr/lib/jvm/java-6-sun-1.6.0.00/jre/lib/rt.jar]
[Loaded javax.imageio.ImageReader from /usr/lib/jvm/java-6-sun-1.6.0.00/jre/lib/rt.jar]
[Loaded javax.imageio.metadata.IIOMetadataFormat from /usr/lib/jvm/java-6-sun-1.6.0.00/jre/lib/rt.jar]
[Loaded javax.imageio.ImageTranscoder from /usr/lib/jvm/java-6-sun-1.6.0.00/jre/lib/rt.jar]
[Loaded javax.imageio.ImageWriter from /usr/lib/jvm/java-6-sun-1.6.0.00/jre/lib/rt.jar]
[Loaded javax.imageio.IIOException from /usr/lib/jvm/java-6-sun-1.6.0.00/jre/lib/rt.jar]
javax.imageio.IIOException: Can't read input file!
[Loaded aflobby.CBattleWindow$2 from file:/usr/share/games/spring/aflobby.jar]
javax.imageio.IIOException: Can't read input file!
javax.imageio.IIOException: Can't read input file!
[Loaded aflobby.CBattleWindow$57 from file:/usr/share/games/spring/aflobby.jar]
[Loaded javax.swing.BufferStrategyPaintManager$BufferInfo from shared objects file]
[Loaded java.awt.Component$BltBufferStrategy from shared objects file]
[Loaded sun.awt.SubRegionShowable from shared objects file]
[Loaded java.awt.Component$BltSubRegionBufferStrategy from shared objects file]
javax.imageio.IIOException: Can't read input file!
javax.imageio.IIOException: Can't read input file!
[Loaded sun.reflect.GeneratedConstructorAccessor4 from __JVM_DefineClass__]
[Loaded sun.misc.Signal$1 from /usr/lib/jvm/java-6-sun-1.6.0.00/jre/lib/rt.jar]
[Loaded java.io.DeleteOnExitHook from shared objects file]
User avatar
AF
AI Developer
Posts: 20687
Joined: 14 Sep 2004, 11:32

Post by AF »

Itll need tor egenerate that minimap for the new map then.
Lippy
Posts: 327
Joined: 16 Jul 2006, 00:24

Post by Lippy »

Ok, I've compiled the latest SVN (3811), and I've got a unitsync.so in my /usr/local/lib/spring. Is this what you want? (I have no idea if it has the JNI bindings; it is a lot smaller than own3d's too at 0.5mb)
Tobi
Spring Developer
Posts: 4598
Joined: 01 Jun 2005, 11:36

Post by Tobi »

Latest SVN has the Java/JNI bindings.
Lippy
Posts: 327
Joined: 16 Jul 2006, 00:24

Post by Lippy »

User avatar
AF
AI Developer
Posts: 20687
Joined: 14 Sep 2004, 11:32

Post by AF »

Test it with this (after renaming to libjavaunitsync.so)

http://www.darkstars.co.uk/randomfiles/ ... /AFLB1.zip

That build may nto be usable as a lobby but itll tell you if it works or not when you try to login.
User avatar
Relative
Posts: 1371
Joined: 15 Oct 2006, 13:17

Post by Relative »

Sorry, this one doesn't work either

Code: Select all

Exception in thread "Timer-4" java.lang.UnsatisfiedLinkError: aflobby.CUnitSyncJNIBindings.Init(ZI)I
        at aflobby.CUnitSyncJNIBindings.Init(Native Method)
        at aflobby.CSync.Setup(CSync.java:76)
        at aflobby.LoginTask.run(JLoginPanel.java:20)
        at java.util.TimerThread.mainLoop(Timer.java:512)
        at java.util.TimerThread.run(Timer.java:462)
Lippy
Posts: 327
Joined: 16 Jul 2006, 00:24

Post by Lippy »

Bah, I spent absolutely ages trying unitsync to work; but failed; getting the same error as relative every single time; with or without the noexception build.

However I think I may have found the problem; using my trusty ctrl-f skills i found this in SConstruct;

Code: Select all

# Somehow unitsync fails to build with mingw:
#  "build\tools\unitsync\pybind.o(.text+0x129d): In function `initunitsync':
#   pybind.cpp:663: undefined reference to `_imp__Py_InitModule4TraceRefs'"
# Figured this out: this means we're attempting to build unitsync with debugging
# enabled against a python version with debugging disabled.
if env['platform'] != 'windows':
	Default(unitsync)
Now I haven't the slightest idea about python, but I'm assuming that as soon as scons finds it's buidling on an non-ms system, it uses the default unitsync. (which may be one without java bindings). What's even more irritating is that everytime I recompiled I sd5summed the unitsync.so file and every time it was different.

When I commented this out, unitsync did not build at all, so I'm assuming this has not been fixed yet, and was just a quick hack. Could any of the devs shed any light on this?

But then again, I might be completely wrong :P

EDIT: Indeed I was wrong :( ; it means that unitsync is compiled by default on linux
Last edited by Lippy on 09 Jun 2007, 17:59, edited 2 times in total.
User avatar
AF
AI Developer
Posts: 20687
Joined: 14 Sep 2004, 11:32

Post by AF »

Your best asking tobi. As far as I'm aware there isnt an ms system scons actually works on.
User avatar
AF
AI Developer
Posts: 20687
Joined: 14 Sep 2004, 11:32

Post by AF »

Tobi hs just amde a commit that changes th java bindings that might fix things.

Code: Select all

Author: tvo
Date: 2007-06-09 20:43:17 +0200 (Sat, 09 Jun 2007)
New Revision: 3813

Modified:
  trunk/tools/unitsync/javabind.cpp
Log:
* Fix java bindings on Linux (hopefully they still work on Windows)



Modified: trunk/tools/unitsync/javabind.cpp
===================================================================
--- trunk/tools/unitsync/javabind.cpp   2007-06-09 14:33:33 UTC (rev 3812)
+++ trunk/tools/unitsync/javabind.cpp   2007-06-09 18:43:17 UTC (rev 3813)
@@ -22,7 +22,7 @@

 // JNIEXPORT doesn't define default visibility
 #ifdef __GNUC__
-#pragma visibility(default)
+#pragma GCC visibility push(default)
 #endif

 DLL_EXPORT const char* __stdcall GetSpringVersion();
I'll be testing this in windows soon.
Lippy
Posts: 327
Joined: 16 Jul 2006, 00:24

Post by Lippy »

Goddamn i love Tobi; this is only a few hours after I spoke to him!
User avatar
AF
AI Developer
Posts: 20687
Joined: 14 Sep 2004, 11:32

Post by AF »

I've just made a rather big restructuring of the connection code that ment code changes in almost every single class, and first full working build I managed to test, it all worked as good as before if not better. w00t for bugless coding!

The restructuring was in order to support multiple protocols.
Post Reply

Return to “Linux”