Re: JNI problems

2005-04-10 Thread Al Niessner
Thank you for the help. Using LD_PRELOAD, I was able to change the error quite a bit. Now it fails after starting the JVM because the current stack is corrupt. I am not sure if this is an improvement or not, but it does mean I should be able to try various JVMs. Unfortunately, I have been building

Re: JNI problems

2005-04-08 Thread Juergen Kreileder
Al Niessner <[EMAIL PROTECTED]> writes: > Since it works with a C++ main(), I am guessing that there is some > symbol in Octave that is clashing with what libzip.so Probably, AFAIK Sun internalizes symbols in the i386 build but not in the x86-64 and ia64 builds. Our 1.4.2-01 for x86-64 should be

Re: JNI Multithread Question in Linux

2004-01-07 Thread Neal Sanche
On January 7, 2004 10:37 pm, Paul Mclachlan wrote: > Kok Choon Kiat wrote: > > It appears to me that the native thread has *seized the entire > > flow of control* from java program and it is not running > > independently. Why is that so? How can I make the native thread > > independent and not seiz

Re: JNI Multithread Question in Linux

2004-01-07 Thread Paul Mclachlan
Kok Choon Kiat wrote: It appears to me that the native thread has *seized the entire flow of control* from java program and it is not running independently. Why is that so? How can I make the native thread independent and not seize the flow of control from the java program? I would really appre

Re: JNI and initialization of static C++ classes on Linux with JDK 1.3.1

2001-09-16 Thread Marcel Ruff
Matthias Pfisterer wrote: > Hi, > > a funktion void _init(void) is called on loading a shared library, if it > exists. See dlopen(3). This didn't help, i have reduced it to this example: InitTest.H --- class InitTest { public: static char * charName; public: static string strin

Re: JNI and initialization of static C++ classes on Linux with JDK 1.3.1

2001-09-16 Thread Matthias Pfisterer
Hi, a funktion void _init(void) is called on loading a shared library, if it exists. See dlopen(3). Matthias Marcel Ruff wrote: > > Hi, > > i am using Linux 2.4.4-4 with JDK 1.3.1 > > I want to call one method in a native, shared C++ library from > Java, using JNI. > > The C++ .so lib depe

Re: JNI and J2SE Runtime v1.3.1 for Linux/ARM Release Candidate

2001-06-23 Thread Juergen Kreileder
On Tue, 12 Jun 2001, Laurent Farrugia wrote: > We are trying to use JNI with the new J2SE runtime on an Ipaq with > Familiar 0.4. We run various JNI examples like > http://www.blackdown.org/java-linux/docs/faq/examples/jni-in-C/. > They all return a segmentation Violation. Does someone try to run

Re: JNI native code throws unexpected exception

2001-06-18 Thread Markus Suing
Hi Paul, I had a similar problem. This is a known bug from sun' bug databse (no 4389172). Besides suns says that it is not a bug. quote from the bug database entry : "... Evaluation The JNI specification makes no guarantees about wh

Re: jni link error

2001-05-29 Thread David Brownell
> I'm not sure, but I don't think the JVM uses ld to load its stuff. If the JVM uses anything other than the standard dlsym() I think it'd really be asking for trouble ... why would it want to do that, anyway? -- To UNSUBSCRI

Re: jni link error

2001-05-29 Thread Christopher Smith
--On Tuesday, May 29, 2001 17:21:41 -0500 Joi Ellis <[EMAIL PROTECTED]> wrote: > On Tue, 29 May 2001, Christopher Smith wrote: > >> >> Can anyone explain to me why having the file in the path set in >> ld.so.conf shouldn't be enough? > > Heh. Try getting the security nazis to agree to THAT for a

Re: jni link error

2001-05-29 Thread Joi Ellis
On Tue, 29 May 2001, Christopher Smith wrote: > > Can anyone explain to me why having the file in the path set in ld.so.conf > shouldn't be enough? Heh. Try getting the security nazis to agree to THAT for a user application. I'm not sure, but I don't think the JVM uses ld to load its stuff.

Re: jni link error

2001-05-29 Thread Christopher Smith
--On Tuesday, May 15, 2001 09:34:50 -0700 Nathan Meyers <[EMAIL PROTECTED]> wrote: > Zhihong Pan wrote: > >> I need jni in my java application. I created a shared library, and set >> my library path (export LD_LIBRARY=/home/mydir/), but I still get the >> following error message:java.lang.Unsatis

Re: jni link error

2001-05-15 Thread Nathan Meyers
Zhihong Pan wrote: > I need jni in my java application. I created a shared library, and set my library >path (export LD_LIBRARY=/home/mydir/), but I still get the following error >message:java.lang.UnsatisfiedLinkError: no java_gsapi in java.library.path. Could >anybody help me ? You need LD_

Re: JNI for linux

2001-04-10 Thread Weiqi Gao
On 09 Apr 2001 23:03:11 -0500, Weiqi Gao wrote: > > Try > javac -Djava.library.path=. JavaCallC Of course, it should have been "java -Djava.library.path=. JavaCallC". -- Weiqi Gao [EMAIL PROTECTED] -- To UNSUBSCRIBE, email

Re: JNI for linux

2001-04-09 Thread Weiqi Gao
> Chao Liu wrote: > > A problem was happened when I use JNI in linux to call my c programme. > I used jdk1.3 and the following is my little test programm: > > [...] > System.loadLibrary("javac"); > [...] > > Exception in thread "main" java.lang.UnsatisfiedLinkError: no javac in > java.library.p

Re: JNI and Threads

2001-02-23 Thread Nathan Meyers
Valerio Ferrucci wrote: > Hi, > I'm building a mutli thread C application using JNI and Invocation API to load > Java Virtual Machine and call Java code. > To launch a new thread I used the call: > > pthread_create > > Now that I link JNI, whit which call have I to substitute "pthread_create"? >

Re: JNI Question - I want to open a file for Read/Write

2001-02-15 Thread Santosh Dawara
Hi All, Thank you for replying. > > I am trying to open a file in the usual way, (fopen) > > However, fopen returns the an unusual NULL. At first > > I thought I probably did not have permissions. > > I am sure its not that. > > Check the errno after the fopen(). At least, you'll > no

RE: JNI Question - I want to open a file for Read/Write

2001-02-07 Thread Stefaan A Eeckels
On 07-Feb-2001 Santosh Dawara wrote: > I am trying to open a file in the usual way, (fopen) > However, fopen returns the an unusual NULL. At first > I thought I probably did not have permissions. > I am sure its not that. Check the errno after the fopen(). At least, you'll no longer ha

Re: JNI and command-line arguments

2001-01-18 Thread Juergen Kreileder
> "soonho" == soonho <[EMAIL PROTECTED]> writes: soonho> I have a C program running in Linux using command line soonho> argument - main (int argc, char *argv[]). How to use JNI soonho> to call this command-line argument? I need to use JNI soonho> cause my C program involve OS

Re: JNI problem

2001-01-09 Thread Paul Mclachlan
At 1:20 01 Jan 2001 +0530, Dushyanth Harinath wrote: > Iam trying to use a existing c library and build a java based interface for > it.I have written a java program for this and created the corresponding > header file and i have also written a c file to execute the native methods. > while compi

Re: JNI pthreads problem

2000-12-17 Thread Juergen Kreileder
> "Valerio" == Valerio Ferrucci <[EMAIL PROTECTED]> writes: Valerio> ok, I have an application that uses invocation API. But Valerio> there I have another problem. Valerio> When I launch it I see the logs message Valerio> [Dynamic-linking... Valerio> [Dynamic-linking...

Re: JNI pthreads problem

2000-12-17 Thread Juergen Kreileder
> "valerio" == valerio <[EMAIL PROTECTED]> writes: valerio> I have a problem. I'm building a module for valerio> apache. apache doesn't like modules linked with valerio> libpthread.so. valerio> To use JNI in my application (Invocation API) I link it valerio> with libjvm

Re: JNI pthreads problem

2000-12-14 Thread Valerio Ferrucci
Hi, thanks for your help. Generally I'm thinking that my code doesn't feel so comfortable in apache module. I already had a similar headache-problem with libmysqlclient.so (that linked against pthreads and made crash apache) and I think I will have more and more problems in the future if i don't

Re: JNI pthreads problem

2000-12-14 Thread Paul Mclachlan
At 9:52 12 Dec 2000 -0500, Rousseau, John wrote: > It's a very strange model in which Apache sends a request to your > module and you start up a VM to handle it. You probably should start > your VM as a seperate process and use a socket to communicate. I don't think this is so strange. While J

Re: JNI pthreads problem

2000-12-14 Thread Valerio Ferrucci
Hi John, ok, I have an application that uses invocation API. But there I have another problem. When I launch it I see the logs message [Dynamic-linking... [Dynamic-linking... ... [Dynamic-linking native method java/lang/Double.longBitsToDouble...JNI] SIGSEGV11* segmentation violation si_

Re: JNI pthreads problem

2000-12-14 Thread Rousseau, John
On Thursday Dec 14, 2000, Valerio Ferrucci wrote: > "Rousseau, John" wrote: > > > libhpi.so is the threading package. The one in native_threads is the > > LinuxThreads version. The one in green_threads (amazingly enough) is > > the Green (Sun's all-user-space package) threads version. > > Whic

Re: JNI pthreads problem

2000-12-14 Thread Valerio Ferrucci
"Rousseau, John" wrote: > libhpi.so is the threading package. The one in native_threads is the > LinuxThreads version. The one in green_threads (amazingly enough) is > the Green (Sun's all-user-space package) threads version. Which one have I to use? native or green? Where are the API of these t

Re: JNI pthreads problem

2000-12-14 Thread Rousseau, John
libhpi.so is the threading package. The one in native_threads is the LinuxThreads version. The one in green_threads (amazingly enough) is the Green (Sun's all-user-space package) threads version. Why does Apache "not like" modules using libpthreads.so? It probably (very probably) uses it itself.

Re: JNI pthreads problem

2000-12-14 Thread Valerio Ferrucci
Hi, I'm in trouble with thie JNI pthreads problem. Can someone help me on my JNI pthreads problem? Or perhaps can you point me to some other (more appropriate for this topic) mailing-list? Or some other source of support? Thanks > >Hi, > >I have a problem. > >I'm building a module for apache. a

Re: JNI pthreads problem

2000-12-13 Thread Mr.Y.SHIVAKANT
-Original Message- From: valerio <[EMAIL PROTECTED]> To: [EMAIL PROTECTED] <[EMAIL PROTECTED]> Date: Thursday, December 14, 2000 1:13 AM Subject: JNI pthreads problem >Hi, >I have a problem. >I'm building a module for apache. apache doesn't like modules linked >with libpthread.so. > >To

Re: JNI & _init() function in .so file

2000-02-07 Thread Nathan Meyers
On Mon, Feb 07, 2000 at 10:17:53AM -0600, [EMAIL PROTECTED] wrote: > Q2: After java jni loads a .so file, how can I find the number of links to > the .so file from a command line command and a lib call? I think you're asking: who has the .so open... true? The only way I know to get that info is

Re: JNI & _init() function in .so file

2000-02-07 Thread Paul Mclachlan
At 10:17 02 Feb 2000 -0600, [EMAIL PROTECTED] wrote: > Q1: I was told that when java jni loads .so file, the first function been > called is _init(). Can I use it as a constructor to setup something when > java app loads the .so file? If I put _init() func in .so C source file, > compiler gener

RE: JNI & .so Files

2000-02-07 Thread Lee_Xing
Thanks, Weiqi. Yes it works. Is it for two threads only? Regards, Lee -Original Message- From: Weiqi Gao [mailto:[EMAIL PROTECTED]] Sent: Friday, February 04, 2000 12:57 PM To: [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: Re: JNI & .so Files [EMAIL PROTECTED] w

RE: JNI & .so Files

2000-02-04 Thread Ekkehard Kraemer
Hallo Lee, LX>so2 in either t1 or t2 thread context, so2 always uses the second LX>thread t2's *JNIEnv to call back to java. But we need so2 call back to LX>so1 then As said before: try it without global variables. Even if everything works correctly for one thread - as you noticed, the JNIEn

RE: JNI & .so Files

2000-02-04 Thread Lee_Xing
not open libso1_beep.so in libso2_hello.so:%s\n", dlerror()); exit(1); } dlerror(); backToSo1 = (void *) dlsym(library, "backToJava"); error = dlerror(); if(error) { fprintf(stderr, "Could not find backToJava(): %s\n", er

Re: JNI & .so Files

2000-02-03 Thread Jeff Galyan
be able to call > a function in libso1.so (in the same address space) if libso2.so can resolve > that function's symbol, but how? > > Thanks. > > Lee > > -Original Message- > From: Nathan Meyers [mailto:[EMAIL PROTECTED]] > Sent: Wednesday, February 02, 2

Re: JNI & .so Files

2000-02-03 Thread Weiqi Gao
[EMAIL PROTECTED] wrote: > > jmethodID mid = (*gEnv)->GetMethodID(gEnv, cls, "callBack", "(V)V"); It's "()V" not "(V)V". It worked on my machine after the change. -- Weiqi Gao [EMAIL PROTECTED] -- To UNSUBSCRIBE, ema

Re: JNI & .so Files

2000-02-03 Thread Nathan Meyers
On Fri, Feb 04, 2000 at 12:23:00AM +, Ekkehard Kraemer wrote: > Hallo Lee, > > LX>figure out why. I have a feeling that saving JNIEnv and jobject in so1 > LX>to global vars may have problem but not sure. Thank you and forgive me > LX>for > > I am no expert on .so's, but "global variable

RE: JNI & .so Files

2000-02-03 Thread Ekkehard Kraemer
Hallo Lee, LX>figure out why. I have a feeling that saving JNIEnv and jobject in so1 LX>to global vars may have problem but not sure. Thank you and forgive me LX>for I am no expert on .so's, but "global variables" in conjunction with "dynamic binding" should ring an alarm bell immediately i

RE: JNI & .so Files

2000-02-03 Thread Lee_Xing
=========== -Original Message- From: Nathan Meyers [mailto:[EMAIL PROTECTED]] Sent: Thursday, February 03, 2000 1:27 PM To: [EMAIL PROTECTED] Cc: [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: Re: JNI & .so Files On Thu, Feb 03, 2000 at 12:28:25PM -0600,

Re: JNI & .so Files

2000-02-03 Thread Nathan Meyers
dress space. So, libso2.so should be able to call > a function in libso1.so (in the same address space) if libso2.so can resolve > that function's symbol, but how? > > Thanks. > > > Lee > > > -Original Message- > From: Nathan Meyers [mailto:[EMAIL PR

RE: JNI & .so Files

2000-02-03 Thread Lee_Xing
same address space. So, libso2.so should be able to call a function in libso1.so (in the same address space) if libso2.so can resolve that function's symbol, but how? Thanks. Lee -Original Message- From: Nathan Meyers [mailto:[EMAIL PROTECTED]] Sent: Wednesday, February 02, 2000 1

Re: JNI & .so Files

2000-02-02 Thread Weiqi Gao
[EMAIL PROTECTED] wrote: > > Hi, > > I got a question on JNI. It would be appreciated if someone could help. > > Q: > In order to hide java and jni related issues (e.g. jni function name > convention, etc.) from .so programmers, a wrapper .so file so1.so is used in > between java app and anoth

Re: JNI & .so Files

2000-02-02 Thread Nathan Meyers
[EMAIL PROTECTED] wrote: > > Hi, > > I got a question on JNI. It would be appreciated if someone could help. Lee, I'm having trouble understanding the problem you're posing. What is the difficulty you're trying to solve... how to call functions in one .so from another .so? You're already doin

RE: JNI and Dead Thread on Linux

2000-01-28 Thread Lee_Xing
Kreileder [mailto:[EMAIL PROTECTED]] Sent: Thursday, January 27, 2000 5:24 PM To: [EMAIL PROTECTED] Cc: [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: Re: JNI and Dead Thread on Linux >>>>> Lee Xing writes: Lee> -Original Message- Lee> From: Jo Uthus [ma

RE: JNI and Dead Thread on Linux

2000-01-27 Thread Lee_Xing
-Original Message- From: Jo Uthus [mailto:[EMAIL PROTECTED]] Sent: Thursday, January 27, 2000 1:31 AM To: [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] Subject: Re: JNI and Dead Thread on Linux [EMAIL PROTECTED] wrote: | Q1: | | command line command "ps -a" shows 4 java (JV

RE: JNI and Dead Thread on Linux

2000-01-26 Thread Lee_Xing
bMsgImpl.so is loaded OK, otherwise, it complains about file not found. What did I do wrong? Thank you. Lee -Original Message- From: Juergen Kreileder [mailto:[EMAIL PROTECTED]] Sent: Tuesday, January 25, 2000 12:38 PM To: [EMAIL PROTECTED] Cc: [EMAIL PROTECTED]; [EMAIL PROTECTED] Subje

Re: JNI and Dead Thread on Linux

2000-01-25 Thread Juergen Kreileder
> Lee Xing writes: Lee> Hi Nathan: Lee> Thank you for your information. Lee> I downloaded jdk_1.1.7-v3-glibc-x86-native.tar.gz and unpack it Lee> from the $JAVA_HOME directory. When I run "java -native app", I Lee> got an error message like: Lee> "Cannot open /proc

RE: JNI and Dead Thread on Linux

2000-01-25 Thread Lee_Xing
Hi Nathan: Thank you for your information. I downloaded jdk_1.1.7-v3-glibc-x86-native.tar.gz and unpack it from the $JAVA_HOME directory. When I run "java -native app", I got an error message like: "Cannot open /proc/00762 for GC/mnt/e/Linux/java/jni/Sample3/app", and every time when I re-t

Re: JNI and Dead Thread on Linux

2000-01-23 Thread Nathan Meyers
efaults to green), sets up the environment, and decides which actual executable (green or native) to run. Nathan > > Thank you. > > Lee > > -Original Message- > From: Nathan Meyers [mailto:[EMAIL PROTECTED]] > Sent: Tuesday, January 18, 2000 2:20 PM > To: [EMAIL

RE: JNI and Dead Thread on Linux

2000-01-23 Thread Lee_Xing
L PROTECTED]] Sent: Tuesday, January 18, 2000 2:20 PM To: [EMAIL PROTECTED]; [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] Subject: Re: JNI and Dead Thread on Linux On Tue, Jan 18, 2000 at 11:28:17AM -0600, [EMAIL PROTECTED] wrote: > Hi: > > I got a few questions on JNI on Linux. It would be a

Re: JNI and Dead Thread on Linux

2000-01-19 Thread Nathan Meyers
On Tue, Jan 18, 2000 at 11:28:17AM -0600, [EMAIL PROTECTED] wrote: > Hi: > > I got a few questions on JNI on Linux. It would be appreciated if someone > could help. > > Suppose a shared library file has a function that is used to do hardware > I/O, say hard drives R/W. A Java application uses

Re: jni + rmi = NoClassDefFoundError + consternation

1999-12-19 Thread Juergen Kreileder
> Jeff Galyan writes: Jeff> Jean-Pierre Fournier wrote: >> >> Does anyone know how one could get the same >> functionality as the -verbose option when >> starting a JVM from the commandline from >> within java or C? >> Jeff> Unfortunately, JNI in 1.1.x doesn

Re: jni + rmi = NoClassDefFoundError + consternation

1999-12-19 Thread Jeff Galyan
Jean-Pierre Fournier wrote: > > Does anyone know how one could get the same > functionality as the -verbose option when > starting a JVM from the commandline from > within java or C? > Do something like this in your C code: #define USER_OPTIONS = "-verbose"; #define OPTS_SEPARATOR = "\s"; #ifd

Re: jni + rmi = NoClassDefFoundError + consternation

1999-12-19 Thread Jean-Pierre Fournier
Hi, Thanks for the reply. Nathan Meyers wrote: > > Is the classfile for the remote stub in your > program's classpath? Yep. I have another class to just check the rmi side of things. When I run this class all works as expected, and I can get the remote object and see the remote methods exec

Re: jni + rmi = NoClassDefFoundError + consternation

1999-12-19 Thread Nathan Meyers
On Sun, Dec 19, 1999 at 10:10:01AM -0500, Jean-Pierre Fournier wrote: > > > Hi, > > linux 2.0.38 > java 1.1.7B > > > I am trying to get a handle to a remote > object from C. In my C program, I create > a VM, find the class I want, find the method > and then call CallStaticIntMethod(). It >

Re: JNI and X

1999-12-01 Thread Juergen Kreileder
> Nathan Meyers writes: Nathan> On Wed, Dec 01, 1999 at 07:47:00PM +, Ekkehard Kraemer wrote: >> Hi, >> >> is it possible to access X things from native code via JNI? >> E.g., paint in a X window direktly from native code? Nathan> Yes, but Nathan> Java d

Re: JNI and X

1999-12-01 Thread Nathan Meyers
On Wed, Dec 01, 1999 at 07:47:00PM +, Ekkehard Kraemer wrote: > Hi, > > is it possible to access X things from native code via JNI? E.g., paint in a X > window direktly from native code? Yes, but Java doesn't give you any way to discover the X resources used by the AWT... you can't get

Re: JNI problem - unresolved symbols at RUN TIME

1999-11-22 Thread Jacob Nikom
Thank you Nathan, You were right. I thought if you use C++ files the linker picks up correct libraries automatically - not yet. Anyway, your answer reminds me how great our listserver is. Thank you again, Jacob Nikom Nathan Meyers wrote: > > On Fri, Nov 19, 1999 at 06:44:48PM -0500, Jacob

Re: JNI problem - unresolved symbols at RUN TIME

1999-11-20 Thread Nathan Meyers
On Fri, Nov 19, 1999 at 06:44:48PM -0500, Jacob Nikom wrote: > I am writing JNI application called MainPanel using Java, C++ and > a bit of C. It compiles and links without problem, but when I run > it, it crushes with the message... My guess is that you linked your shared library using gcc ins

Re: JNI link to disk space

1999-10-21 Thread Peter Pilgrim
[EMAIL PROTECTED] wrote: > > > > > > I am interesting in getting the disk space and partition > > > > > in a Java program by using JNI. What is the std UNIX API > > > > > call to do this? I have tried grepping the man pages > > > > > and got the source to kdf program but it didn't help > > > >

Re: JNI link to disk space

1999-10-20 Thread Jörg Strebel
> > > > I am interesting in getting the disk space and partition > > > > in a Java program by using JNI. What is the std UNIX API > > > > call to do this? I have tried grepping the man pages > > > > and got the source to kdf program but it didn't help > > > > because it was executing `/usr/bin/df

RE: JNI link to disk space

1999-10-20 Thread Burkhart,Kelly
As soon as he said JNI he eliminated platform independence (at least in the Java sense). > -Original Message- > From: Aaron Mulder [mailto:[EMAIL PROTECTED]] > Sent: Wednesday, October 20, 1999 3:22 PM > To: Burkhart,Kelly > Cc: 'Dustin Lang'; Java Linux Mailin

RE: JNI link to disk space

1999-10-20 Thread Aaron Mulder
Sure, but the Java white papers keep mentioning things like "platform independent"... I figure they must have *some* reason for it... Aaron On Wed, 20 Oct 1999, Burkhart,Kelly wrote: > Why is it an ugly solution? Unix apps do this sort of thing frequently. It > works fine. > > >

RE: JNI link to disk space

1999-10-20 Thread Burkhart,Kelly
Why is it an ugly solution? Unix apps do this sort of thing frequently. It works fine. > -Original Message- > From: Dustin Lang [mailto:[EMAIL PROTECTED]] > Sent: Wednesday, October 20, 1999 12:00 PM > To: [EMAIL PROTECTED] > Cc: Java Linux Mailing List > Subject: Re

Re: JNI link to disk space

1999-10-20 Thread Dustin Lang
Hi, > > > I am interesting in getting the disk space and partition > > > in a Java program by using JNI. What is the std UNIX API > > > call to do this? I have tried grepping the man pages > > > and got the source to kdf program but it didn't help > > > because it was executing `/usr/bin/df -k -

Re: [Fwd: Re: JNI link to disk space]

1999-10-19 Thread Juergen Kreileder
> Peter Pilgrim writes: Peter> On Solaris 2.5.1 I found `/usr/include/statfs.h' Peter> Maybe it exists on linux too. Yes, see 'man 2 statfs'. Peter> struct statfs { Peter> short f_fstyp; //FS type Peter> long f_bsize; // block size Peter> long f_frs

[Fwd: Re: JNI link to disk space]

1999-10-19 Thread Peter Pilgrim
Original Message Subject: Re: JNI link to disk space Date: Tue, 19 Oct 1999 15:11:45 +0100 From: [EMAIL PROTECTED] To: [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: > > [EMAIL PROTECTED] wrote: > > > > Peter Pilgrim wrote: > > > > > >

Re: JNI link to disk space

1999-10-19 Thread Peter Pilgrim
[EMAIL PROTECTED] wrote: > > [EMAIL PROTECTED] wrote: > > > > Peter Pilgrim wrote: > > > > > > I am interesting in getting the disk space and partition > > > in a Java program by using JNI. What is the std UNIX API > > > call to do this? I have tried grepping the man pages > > > and got the sou

Re: JNI link to disk space

1999-10-19 Thread Peter Pilgrim
[EMAIL PROTECTED] wrote: > > Peter Pilgrim wrote: > > > > I am interesting in getting the disk space and partition > > in a Java program by using JNI. What is the std UNIX API > > call to do this? I have tried grepping the man pages > > and got the source to kdf program but it didn't help > > b

Re: JNI link to disk space

1999-10-18 Thread Sebastian-Anton Ponovescu
Hi Peter! Yes! There are! First to find out the partition do: fdisk -l. In fact fdisk is one of the few mechanisms you can use to manipulate partitions under linux. Second for disk size and free space do: df. Read the man for each of them as they provide lots of usefull information. Take Care!

Re: JNI link to disk space

1999-10-18 Thread Nathan Meyers
Peter Pilgrim wrote: > > I am interesting in getting the disk space and partition > in a Java program by using JNI. What is the std UNIX API > call to do this? I have tried grepping the man pages > and got the source to kdf program but it didn't help > because it was executing `/usr/bin/df -k -T'

Re: JNI on linux.

1999-10-14 Thread Juergen Kreileder
> Jacob Nikom writes: Jacob> Vijo Cherian wrote: >> >> i did everything as mentioned... >> and at `java HelloWorld` , i got the following error >> >> vijol@darkstar] ~/jni$ java HelloWorld >> Exception in thread "main" java.lang.UnsatisfiedLinkError: no hello in

RE: JNI on linux.

1999-10-14 Thread Sachin Goyal
rom: Jacob Nikom [mailto:[EMAIL PROTECTED]] Sent: Thursday, October 14, 1999 3:07 AM To: Vijo Cherian; Java-Linux listserver Subject: Re: JNI on linux. Hi, I am pretty sure, if you remove your libhello.so library completely from your directory, you are going to get exactly the same message. It means

Re: JNI on linux.

1999-10-13 Thread Jacob Nikom
Hi, I am pretty sure, if you remove your libhello.so library completely from your directory, you are going to get exactly the same message. It means that your loader cannot find your library libhello.so, even if it is in the directory. I don't think LD_LIBRARY_PATH matters. Verify that you h

Re: JNI & servlets

1999-09-17 Thread Juergen Kreileder
> Nathan Meyers writes: >> I have been trying how I can use JNI from within a servlet. I >> have tried the code that comes with Apache-jserv. Servlets >> compile and run without any problem. The problem is with javah. >> After a successful compilation (i hope) when I try to ma

Re: JNI & servlets

1999-09-17 Thread Nathan Meyers
devrim baris acar wrote: > > Hi, > I have been trying how I can use JNI from within a servlet. I have tried the > code that comes > with Apache-jserv. Servlets compile and run without any problem. The problem > is with javah. > After a successful compilation (i hope) when I try to make a C header

Re: JNI and packages

1999-09-14 Thread JB
Nathan Meyers wrote: > > Did you specify the right classname (with and without package) in the > two javah invocations? Did you notice that the two javah invocations > produced .h files with different names? Aha! So it's not 'javah MyClass' but 'javah 'org.digart.MyClass'. That did the trick. Th

Re: JNI and packages

1999-09-14 Thread Nathan Meyers
Did you specify the right classname (with and without package) in the two javah invocations? Did you notice that the two javah invocations produced .h files with different names? Nathan JB wrote: > > Nathan Meyers wrote: > > > > JB wrote: > > > > > > Hi all. I have created and successfully run

Re: JNI and packages

1999-09-14 Thread JB
Nathan Meyers wrote: > > JB wrote: > > > > Hi all. I have created and successfully run a JNI *.so on RH6 but for > > one thing. > > When I package the java src that contains the native methods, I get an > > UnsatifiedLinkerError for the method call. When I try to package it, it > > seems to load

Re: JNI and packages

1999-09-14 Thread Nathan Meyers
JB wrote: > > Hi all. I have created and successfully run a JNI *.so on RH6 but for > one thing. > When I package the java src that contains the native methods, I get an > UnsatifiedLinkerError for the method call. When I try to package it, it > seems to load properly but dies when I call any nat

Re: JNI on linux.

1999-09-14 Thread Jacob Nikom
There is no real difference between JNI on Linux and JNI on other operating systems (and not suppose to be). Look at Sun Java tutorial on JNI: http://java.sun.com/docs/books/tutorial/native1.1/index.html Take the source code for HelloWorld example and follow the instructions: after the first step

Re: JNI and C++ templates

1999-09-13 Thread Nathan Meyers
We're wandering OT here, but I hope this is useful to others dealing with JNI/C++ integration... Paul Beardsley wrote: > > That looks like the problem - I wasn't including the > templated source at the end of the .h file. > > It raises > a question for me though - for my template classes, > I p

Re: JNI and C++ templates

1999-09-13 Thread Paul Beardsley
That looks like the problem - I wasn't including the templated source at the end of the .h file. It raises a question for me though - for my template classes, I previously had a MyFile.H file (with no included source at the end) and a MyFile.C file which included MyFile.H at the start and the

Re: JNI and C++ templates

1999-09-13 Thread Nathan Meyers
Paul Beardsley wrote: > > Nathan, > > Thanks for the reply. > > I just tried recompiling using -D_REENTRANT -fpic, > but the same errors are occurring. When I run > java, I get You answered my point of curiosity about where the reference was coming from... it's one of your templated classes r

Re: JNI and C++ templates

1999-09-13 Thread Nathan Meyers
Paul Beardsley wrote: > I used "ldd -r libmylib.so" to look at my shared > library and that also gave a list > of undefined symbols, starting with the > same symbol which Java lists as an unsatisfied link. And what might that symbol (or some of those symbols) be? That info would help diagnose the

Re: My Thanks--Re: JNI Errors: Need Help

1999-07-28 Thread Jacob Nikom
Sun Tutorial is not for Linux. If you use JNI on SGI, you have to use -shared too. Jacob Nikom [EMAIL PROTECTED] wrote: > Many, many thanks. > The Sun Tutorial DOES NOT show that little trick. > > _ > Steve Gee > Java Developer > Maxor National Pharmacies > Information Technolog

My Thanks--Re: JNI Errors: Need Help

1999-07-28 Thread sgee
Many, many thanks. The Sun Tutorial DOES NOT show that little trick. _ Steve Gee Java Developer Maxor National Pharmacies Information Technologies [EMAIL PROTECTED] 806.324.5540 www.maxor.com 806.324.5400 -- T

Re: JNI Errors: Need Help

1999-07-28 Thread Juergen Kreileder
> sgee writes: sgee> Shared Library Command: sgee> cc -I/usr/local/jdk117/include -I/usr/local/jdk117/include/genunix sgee> HellWorldNative.c -o libhello.so That creates an executable, to build a shared library you have to add the '-shared' option. Juergen --

Re: [JNI header files]

1999-07-19 Thread Yuwin Fei
It should be in a directory right under whereever jni.h is. Depending on the platform you use, the directory should be "linux", or "solaris" etc. You should have that path in your include path as part of your -I compiling option. Good luck. -- Yuwinf Dustin Lang <[EMAIL PROTECTED]> wrote

Re: JNI/Linux pointers?

1999-07-15 Thread jools enticknap
Hi > >Does anybody have any pointers to using JNI on Linux? I'm starting a >project where I'll be hacking pine to access a running Java process. > JNI on Linux is much the same on all platforms( more or less:). If you want a good book on JNI I suggest you try 'Essential JNI' by Rob Gordon. It'

Re: JNI

1999-06-29 Thread Jeff Galyan
(answers below each question) > > --Simple question first: "Is it possible to use the JNI with AIX JDK 1.1.6 > and egcs/gcc C/C++ compiler under the AIX OS 4.x ??? " > Assuming IBM didn't mistakenly leave JNI out of their port, then yes. > --Harder question: "If the answer to the first quest

RE: jni for linux

1999-06-29 Thread Marcel Ruff
Hi, To use JNI you only need the blackdown JDK. I have attached some files how i always test the JNI on Linux: C++ calling JDK 2 Awt. the almost same example works with JDK 1.1.7 as well. regards Marcel HelloWorldAwt-1.2.tar.gz

Re: JNI to choose? 1.0 or 1.1 JDK

1999-06-23 Thread Anonymous
Hi, I cannot answer your questions directed to the porting team, but I would strongly recommend the 1.1/1.2 JNI model (there are some small extensions in 1.2). There are two major reasons: 1. libraries using the 1.1 model are to some extend portable between platforms and should be fully portable

RE: JNI problems with JDK 1.2 Pre2 (crashing Linux) -> solved!

1999-06-10 Thread Marcel Ruff
Hi, i used a symbolic link to point to the JDK 1.2pre2, this crashed my whole Linux : in /usr/local: drwxr-xr-x 9 marcel users1024 Jun 9 15:03 jdk1.2Pre2 lrwxrwxrwx 1 marcel users 10 Jun 8 21:47 jdk ->jdk1.2Pre2 in conjunction with using: echo $LD_LIBRARY

Re: JNI on a Netwinder ??

1999-06-09 Thread Amlan Saha
Kevin Ryan writes: > Please pardon my ignorance: what's a Netwinder, and is the SA-100 a > processor, or what? > The netwinder's a cute little machine developed by Corel computing canada. It has the SA1100 (strong arm) processor which used to be made by DEC but is now produced by Intel.

Re: JNI error! Need help.

1999-04-23 Thread Juergen Kreileder
> Gao Lei writes: Gao> Hello, All, Gao> I met an error when I port my windows JNI to Linux. The jni Gao> run well on Windows NT/95/98. I don't familiar with Linux Gao> platform I need your help. Gao> Error is Gao> FATAL ERROR in native method: try to unpin an object

Re: JNI / JKD2 / AWT / Linux 2.2.5 -> little C++/Java ´HelloWorldAwt´ gives a segmentation violation

1999-04-20 Thread Marcel Ruff
Juergen Kreileder wrote: > > Marcel Ruff writes: > > Marcel> [1 ] > Marcel> Hello, > > Marcel> i made a little HelloWorld C++ executable to popup a Java > Marcel> HelloWolrd GUI, but it gives a core dump. > > The combination AWT and Invocation API doesn't work currently. > It

Re: JNI / JKD2 / AWT / Linux 2.2.5 -> little C++/Java ´HelloWorldAwt´ gives a segmentation violation

1999-04-20 Thread Juergen Kreileder
> Marcel Ruff writes: Marcel> [1 ] Marcel> Hello, Marcel> i made a little HelloWorld C++ executable to popup a Java Marcel> HelloWolrd GUI, but it gives a core dump. The combination AWT and Invocation API doesn't work currently. It should work with the next release.

Re: JNI from JDK1.2 on Linux-2.0.36 hangs in method JNI_CreateJavaVM()

1999-04-16 Thread Marcel Ruff developer
Riyad Kalla wrote: > Wait... what is JNI? And why does all that code at the bottom look so > complicated for "Hello World"? > > Thanks in advance. > > Riyad > > -- > > From: Marcel Ruff developer <[EMAIL PROTECTED]> > > To: [EMAIL PROTECTED]; [EMAIL PROTECTED] > > Subject: JNI from JDK1.2

  1   2   >