• Willkommen im Linux Club - dem deutschsprachigen Supportforum für GNU/Linux. Registriere dich kostenlos, um alle Inhalte zu sehen und Fragen zu stellen.

Probleme mit JbidWatcher bzw. BidWatcher

andreas034

Newbie
Hi Leute,
erstmal frohe Ostern und schöne dicke Eier ;-)

Ich bin über JbidWatcher durch PCWelt Linux gestolpert und wollte mir diesen mal anschauen!
So wie ich dass verstanden habe, muss ich nur dass .jar file von http://sourceforge.net/project/showfiles.php?group_id=3914&release_id=363147 runterladen und mittels Konsole und dem Befehl java -jar Programmname starten. Da bekomme ich dann folgende Fehlermeldung:

Invalid or corrupt jarfile ./Desktop/JBidWatcher-1.0pre6.jar

Ich habe dass .jar file öfters runtergeladen, aber immer dass selbe :-( also denke ich liegt da ein anderes Problem vor, kann mir da jemand Helfen? Die Java-version von Fedora 4 habe ich schon getauscht.
java -version
java version "1.5.0_06"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_06-b05)
Java HotSpot(TM) Client VM (build 1.5.0_06-b05, mixed mode, sharing)

Dann habe ich mir dass ganze als tar.gz runtergeladen und entpackt! In der Konsole dann make eingegeben, da bekomme ich dann diese Fehlermeldung:

Compiling all classes.
----------
1. WARNING in JBidWatch.java
(at line 8)
private AudioPlayer m_ap = null;
^^^^
The field JBidWatch.m_ap is never read locally
----------
----------
2. WARNING in JBidWatch.java
(at line 938)
class JFriendlyFrame
^^^^^^^^^^^^^^
The serializable class JFriendlyFrame does not declare a static final serialVersionUID field of type long
----------
----------
3. WARNING in /home/andreas/Desktop/jbidwatcher-1.0pre6/./JBidMenuBar.java
(at line 26)
import java.util.Hashtable;
^^^^^^^^^^^^^^^^^^^
The import java.util.Hashtable is never used
----------
----------
4. WARNING in /home/andreas/Desktop/jbidwatcher-1.0pre6/./JBidMenuBar.java
(at line 34)
public class JBidMenuBar extends JMenuBar {
^^^^^^^^^^^
The serializable class JBidMenuBar does not declare a static final serialVersionUID field of type long
----------
----------
5. WARNING in /home/andreas/Desktop/jbidwatcher-1.0pre6/./JBidMouse.java
(at line 108)
AuctionServer as = AuctionServerManager.getInstance().getDefaultServer();
^^
The local variable as is never read
----------
----------
6. ERROR in /home/andreas/Desktop/jbidwatcher-1.0pre6/./JMouseAdapter.java
(at line 131)
Window window = SwingUtilities.getWindowAncestor(localPopup);
^^^^^^^^^^^^^^^^^
The method getWindowAncestor(JPopupMenu) is undefined for the type SwingUtilities
----------
6 problems (1 error, 5 warnings)make: *** [compile] Fehler 255

Damit kann ich leider gar nichts mit anfangen :-( vielleicht findet ja jemand meinen Fehler und kann mir helfen!

Nachdem dies nicht klappte habe ich probiert den BidWatcher zu Installieren, dies geht auch nicht,
nach der Eingabe von ./configure kommt folgendes:
./configure
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking whether make sets $(MAKE)... yes
checking for working aclocal... found
checking for working autoconf... found
checking for working automake... found
checking for working autoheader... found
checking for working makeinfo... found
checking for gcc... gcc
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables...
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ANSI C... none needed
checking how to run the C preprocessor... gcc -E
checking for g++... g++
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking for a BSD-compatible install... /usr/bin/install -c
checking for glib-config... no
checking for GLIB - version >= 1.2.0... no
*** The glib-config script installed by GLIB could not be found
*** If GLIB was installed in PREFIX, make sure PREFIX/bin is in
*** your path, or set the GLIB_CONFIG environment variable to the
*** full path to glib-config.
checking for gtk-config... no
checking for GTK - version >= 1.2.0... no
*** The gtk-config script installed by GTK could not be found
*** If GTK was installed in PREFIX, make sure PREFIX/bin is in
*** your path, or set the GTK_CONFIG environment variable to the
*** full path to gtk-config.
configure: error: Cannot find Gtk+

angeblich fehlt Gtk+, allerdings nach Eingabe von rpm -qa | grep gtk+
findet er dieses:
gtk+extra-2.1.1-1.fc4
gtk+extra-devel-2.1.1-1.fc4
gtk+-1.2.10-39

Mein Englisch ist miserabel und mit Linux kenne ich mich nicht so gut aus, damit ich verstehe, was dieser Bitwatcher von mir möchte! Kann mir da jemand Helfen?

Gruß
Andreas
 

oc2pus

Ultimate Guru
der JBidWatcher braucht auch noch jdic.

da du kein SuSE hast, kannst du mal probieren mein Paket bei dir zu installieren.
Das Startscript muss gegebenfalls noch angepasst werden für Fedora.

Ansonsten kannst du meinem src.rpm den patch entnehmen das du es compilieren kannst.

du findest die entsprechenden Pakete (jdic, JBidWatcher, etc) hier:
http://ftp4.gwdg.de/pub/linux/suse/apt/SuSE/10.0-i386/RPMS.suser-oc2pus/
http://ftp4.gwdg.de/pub/linux/suse/apt/SuSE/10.0-i386/SRPMS.suser-oc2pus/
 
OP
andreas034

andreas034

Newbie
Hi oc2pus,

habe mal probiert, deine rpm's zu installieren, aber bei jdic bekomme ich folgende Fehlermeldung:
Fehler: Failed dependencies:
java >= 1.5 is needed by jdic-0.9.1-0.oc2pus.1.i586
libcairo.so.2 is needed by jdic-0.9.1-0.oc2pus.1.i586
libglitz.so.1 is needed by jdic-0.9.1-0.oc2pus.1.i586
libpangocairo-1.0.so.0 is needed by jdic-0.9.1-0.oc2pus.1.i586
dann habe ich auch probiert, dein JBidWatcher zu installieren, ohne erfolg, mit folgender Meldung:
Fehler: Failed dependencies:
java >= 1.5 is needed by JBidWatcher-1.0pre6-0.oc2pus.1.noarch

ich habe im internet mal nach jdic gesucht und bin auf diese Seite gestossen!
https://jdic.dev.java.net/servlets/ProjectDocumentList?folderID=1304&expandFolder=1304&folderID=0
dort habe ich mir die jdic-0.8.4-bin-linux.zip runtergeladen, aber dass hilft mir auch nicht wirklich weiter :-( in der Beschreibung zur Installation, da blicke ich nicht durch, da steht foilgendes!

Installation
To run the downloadable or built JDIC binaries, following below installation instructions(only Mozilla and IE be supported at present):
JDIC API:
Add jdic.jar to CLASSPATH.
Note: With earlier releases, on Windows, Browser component copies the bundled MozEmbed.exe file to the Mozilla binary path to work. Since 0.8.8, that file is not copied. While using the Browser component, BE SURE to remove the MozEmbed.exe file if it locates at the Mozilla binary path.
Below steps are ONLY necessary if the native library or executable files locate at a different location from jdic.jar. If a JDIC release (jdic-<version>-bin-<os>.zip) is unzipped, these files locate at the same location as jdic.jar and so below steps are unnecessary:
Add the path of native library files .dll to PATH (for Windows), or .so to LD_LIBRARY_PATH (for Linux/Unix).
Add the path of native executable files .exe (for Windows) or mozembed-<os>-gtk* (for Linux/Unix) to PATH.
Notes for earlier JDIC releases:
for JDIC release 0.8.6.*, additional setting to use package org.jdesktop.jdic.tray:
Set the environment variable JAVA_HOME to the J2SDK/J2RE installation path.
for JDIC release 0.8.5 or later, additional setting to use package org.jdesktop.jdic.browser:
On Windows, set the environment variable JAVA_HOME to the J2SDK/J2RE installation path.
for JDIC release 0.8.4.*, additional settings to use package org.jdesktop.jdic.browser:
Windows
- Add <J2SDK HOME>/jre/bin or <J2RE HOME>/bin to PATH.
- Add the path of native executable files (*.exe) to PATH.
- The system default browser (Mozilla or Internet Explorer) is embedded. If Mozilla is the embedded browser:
* Set the environment variable MOZILLA_FIVE_HOME to the absolute path of the Mozilla 1.4 (or later) executable file.
* Copy MozEmbed.exe file to the MOZILLA_FIVE_HOME directory.
* Add MOZILLA_FIVE_HOME to PATH.
Linux/Solaris
- Add the path of native executable files (mozembed-linux-gtk* or mozembed-solaris-gtk*) to PATH.
- Set the environment variable MOZILLA_FIVE_HOME to the absolute path of the Mozilla 1.4 (or later) executable file.
- Add MOZILLA_FIVE_HOME to LD_LIBRARY_PATH.
 

oc2pus

Ultimate Guru
ad jdic: jdic-0.9.1 brauchst du mindestens ...
... und jdic zu compilieren ist ziemlich knifflig ... dazu braucht man das ganze mozilla-gecko-sdk und muss dann immer noch ziemlich viel selber "schrauben" ...

schade, dann ist Fedora doch gaaaanz anders als SuSE :mrgreen:


dann verfolge den anderen Ansatz weiter und compiliere das JBidWatcher selber aus den Java-Sourcen. Dazu brauchst du dann aber einige andere jar-Dateien.
jdic nimmst du von hier:
https://jdic.dev.java.net/servlets/ProjectDocumentList?folderID=3606&expandFolder=3606&folderID=3740

und im build.xml von JBidWatcher musst du dann den Pfad anpassen zu dem Verzeichnis wo jdic.jar installiert ist.

oder du machst den download mit wget in einer Konsole:
wget -c http://www.jbidwatcher.com/download/JBidWatcher-1.0pre6.jar
das probiert dann öfter und du solltest KEIN kaputtes jar File mehr haben.
 
OP
andreas034

andreas034

Newbie
Alsoooo, so wie ich dass sehe, benötige ich dass alles:

GNU make version 3.78.1 habe ich die version 3.8
GNU gcc version 3.2.1-7 hab ich die version 4.02
pkg-config version 0.15.0 hab ich die version 0.20-1
Mozilla binary release 1.4 weiß nicht genau, ich habe einen mozilla 1.7.12-1.5.2 ist dass dieses binary?
Und was soll ich hier machen? Set MOZILLA_DIST to the directory. *achselzuck* :-(

und dass Mozilla Gecko SDK habe ich nach langem hin und her auch zum installieren bekommen :eek:) jetzt heißt es ja, ich solle Set GECKO_SDK to the direcotory. Aber wohin, in was für ein direktorie? Und vor allen dingen wie?

Jetzt habe ich dieses jdic file, weiß aber nicht, was ich damit anfangen soll :-( laut der beschreibung soll ich dieses tun!
Add the path of native library files .dll to PATH (for Windows), or .so to LD_LIBRARY_PATH (for Linux/Unix).
Add the path of native executable files .exe (for Windows) or mozembed-<os>-gtk* (for Linux/Unix) to PATH.

Mit dem befehl java -jar jdic.jar bekomme ich diese fehlermeldung!

Failed to load Main-Class manifest attribute from
jdic.jar

kann mir da jemand weiterhelfen, wie ich weiter vorgehen muss?
 

oc2pus

Ultimate Guru
es sieht nicht so aus als ob du weisst was du tust ...

1.) jdic ist KEIN Programm zum starten ...
2.) um jdic selber zu compilieren, braucht man das gecko-sdk und einen dazu passenden Mozilla.

dann muss man (BEISPIEL!)
Code:
export MOZILLA_DIST=/opt/mozilla/lib
export GECKO_SDK=%{_builddir}/%{name}-%{version}-src/gecko-sdk
dieses dem jdic-makefiles bekanntgeben wo diese beiden Komponenten installiert sind.

danach kann man sein jdic kompilieren mit dem Befehl:
ant buildall

allerdings habe ich noch diese drei Patches bei SuSE gebraucht um die Makefiles und das build.xml zu überreden etwas zu tun:

Code:
--- packager/build.xml	2005-06-16 06:53:51.000000000 +0200
+++ packager/build.xml	2006-02-13 08:14:34.000000000 +0100
@@ -234,7 +234,7 @@
           description="build the classes and jar file." >
     <javac srcdir="${share.classes.dir}:${unix.classes.dir}"
            destdir="${dist.dir}"
-           classpath="${dist.dir}" 
+           classpath="${dist.dir}:/usr/lib/jvm/jre/lib/deploy.jar:/usr/lib/jvm/java/jre/lib/javaws.jar" 
     />
 
     <jar destfile="${dist.dir}/${jar.file}" update="false">

Code:
--- jdic/src/unix/native/jni/Makefile	2005-06-20 09:36:21.000000000 +0200
+++ jdic/src/unix/native/jni/Makefile	2006-02-09 11:15:02.000000000 +0100
@@ -69,7 +69,7 @@
 LIBS = -L$(USR_LIB_DIR) \
        -lz \
        -lm \
-       -lgnome-2 
+       -L/opt/gnome/lib -lgnome-2 
 
 EXTRA_BROWSER_LIBS = \
     -L$(JAVA_HOME)/jre/lib/sparc \

Code:
--- jdic/src/unix/native/mozilla/Makefile	2006-02-13 07:55:21.000000000 +0100
+++ jdic/src/unix/native/nozilla/Makefile	2006-02-13 07:55:14.000000000 +0100
@@ -47,8 +47,8 @@
 # For Gecko SDK 1.6 or ealier, enable USING_GECKO_SDK_1_4. Or else, enable 
 # USING_GECKO_SDK_1_7.
 #
-USING_GECKO_SDK_1_4 = 1
-#USING_GECKO_SDK_1_7 = 1
+#USING_GECKO_SDK_1_4 = 1
+USING_GECKO_SDK_1_7 = 1
 
 # set gtk version
 #
die patches werden mit patch < "name" im jdic-Sourcen Verzeichnis eingespielt.

um ein Java-Programm mit jdic zu verwenden, muss man den Classpath um das jdic.jar erweitern und den Ort der nativ-Libraries angeben:

java -cp </pfad/zu/jdic.jar>:<andere-jar-files> -Djava.library.path=/<pfad wo die jdic-libs-stehen> <main-class-zum-ausführen>
 
OP
andreas034

andreas034

Newbie
Nun, ich dachte da an dass Programm "JAP" dies ist auch ein .jar file und wird mit java -jar gestartet, somit dachte ich, dass grundsätzlich alle .jar-files mit Java -jar gestartet werden :-( also ein Irrtum von mir und somit hast du recht, denn ich weiß nicht, was ich tu!

export MOZILLA_DIST=/opt/mozilla/lib

Also muss ich suche, wo die Datei MOZILLA_DIST liegt und dann anhand deines Befehles in das verzeichnis /opt/mozilla/lib exportieren?

export GECKO_SDK=%{_builddir}/%{name}-%{version}-src/gecko-sdk

Ich nehme an, dass ich die Zeile nicht einfach so übernehmen kann :-( oder doch?

Die Patches muss ich einfach kopieren, in enem editor speichern als von mir aus 1. 2 und 3 und diese dann mittels patch 1 /home/andreas/Desktop/jdic einspielen! als was für eine dateiendung muss ich den die patches abspeichern?

java -cp </pfad/zu/jdic.jar>:<andere-jar-files> -Djava.library.path=/<pfad wo die jdic-libs-stehen> <main-class-zum-ausführen>

der pfad zu jdic.jar ist klar, was meinst du mit andere-jar-files? die jdic-libs, die werde ichja mit hilfe der sucenfunktion finden und was meinst du mit main-class-zum-ausführen?

tschuldige, für die eventuell dummen fragen, ich blick da einfach nicht durch :-(
aber trotzdem danke schonmal für deine hilfe!
 

oc2pus

Ultimate Guru
MOZILLA_DIST und GECKO_SDK sind Umgebungsvariablen, diese werden von dem Makefile des jdic ausgewertet.
Umegbungsvariablen werden gesetzt mit export Variable=Wert

Das MOZILLA_DIST zeigt dorthin wo die mozilla-Bibliotheken stehen (bei SuSE in /opt/mozilla/lib)
Das GECKO_SDK zeigt dahin wo du das gecko-sdk installiert hast (also das Verzeichnis wo du das gecko-sdk entpackt hast)

die patches brauchen keine Extension, nur einen einfachen Namen.
1, 2, 3 würde funktionieren.
Aber du solltest diese patches nur als "Ideengeber" verwenden. Bei Fedora sehen diese patches bestimmt anders aus ...

Der java Aufruf mit jdic sollte dir verdeutlichen wie man Java-Programme startet wenn diese mehrere jar-Files benötigen.
Ich kenne Java Programme die brauchen bis zu 10 andere jar-Files, da sieht der Aufruf dann so aus :)
Beispiel: java -cp a.jar:b.jar:c.jar:d.jar -Djava.library.path=/usr/lib prog.main

Wenn ein java-jar ALLE benötigten klassen enthält und in dem integrierten Manifest-Filer der Name der "Haupt-Klasse" steht, kann man dieses Programm mit java -jar xxx.jar starten, aber nur dann. Also ist deine Idee nicht grundsätzlich verkehrt gewesen ;)
 
OP
andreas034

andreas034

Newbie
ahh, jetzt bin ich ein kleinwenig klüger! dann hat die JBidWatcher nicht alle .jarfiles, die es zum laufen benötigt mit drin :-( schön doof :-( und somit darf ich mich darum bemühen!

also sieht dass so aus:
export MOZILLA_DIST=/usr/lib/mozilla-1.7.12
da im reinem mozillaordner nur der ordner „chrome“ drinne ist :eek:)
und mein Ordner fürs sdk hier
export GECKO_SDK=%{_builddir}/%{name}-%{version}-/home/andreas/Desktop/gecko-sdk

nur mit den patches komme ich nicht weiter, da kenn ich mich ja nu noch weniger aus, als mit linux selbst :-( also müßte ich jemanden finden, der sich mit fedora und eben diesem jdic auskennt! mal sehen, ob sich da jemanden finden läßt!

vielen dank jetzt schonmal für deine hilfe!!
 

oc2pus

Ultimate Guru
Code:
export GECKO_SDK=%{_builddir}/%{name}-%{version}-/home/andreas/Desktop/gecko-sdk

besser so:
Code:
export GECKO_SDK=/home/andreas/Desktop/gecko-sdk

und wie gesagt das gecko-sdk MUSS zur Version des Mozilla passen!
hier schauen:
http://ftp.mozilla.org/pub/mozilla.org/mozilla/releases/

ad patches:
wechsele in das jdic Verzwichnis
patch < patch.1
patch < patch.2
...
dann ant buildall
 
Oben