delorie.com/archives/browse.cgi | search |
Mailing-List: | contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm |
List-Subscribe: | <mailto:cygwin-subscribe AT sources DOT redhat DOT com> |
List-Archive: | <http://sources.redhat.com/ml/cygwin/> |
List-Post: | <mailto:cygwin AT sources DOT redhat DOT com> |
List-Help: | <mailto:cygwin-help AT sources DOT redhat DOT com>, <http://sources.redhat.com/ml/#faqs> |
Sender: | cygwin-owner AT sources DOT redhat DOT com |
Delivered-To: | mailing list cygwin AT sources DOT redhat DOT com |
X-Internal-ID: | 39BCF0C400001287 |
Message-ID: | <451198D3C2EDD2118C990008C75D438C01D7D2F7@exwok01.capgemini.co.uk> |
From: | "Harris, Andrew S" <Andrew DOT Harris AT capgemini DOT co DOT uk> |
To: | "'cygwin AT sourceware DOT cygnus DOT com'" <cygwin AT sourceware DOT cygnus DOT com> |
Subject: | Problem creating a JNI DLL using Cygwin with Java 1.3 |
Date: | Mon, 11 Sep 2000 17:03:36 +0100 |
X-Mailer: | Internet Mail Service (5.5.2650.21) |
I'm trying to create a Java JNI DLL using Java 1.3 and the latest Cygwin, without success. I'm using the Java JNI examples from http://www.xraylith.wisc.edu/~khan/software/gnu-win32/index.html#java-jni, specifically Makefile.cyg with HelloWorldImp.c. The makefile fails with this message: $ make -mf Makefile.cyg gcc -c -DBUILDING_DLL=1 -D_DLL=1 -I. -Ic:/java/jdk1.3/include -Ic:/java/jdk1.3 /include/cygwin -g -Wall -O2 -o HelloWorldImp.o HelloWorldImp.c dllwrap --output-def hello.def --add-stdcall-alias --driver-name gcc -o hello. dll \ HelloWorldImp.o -Wl,-e,__cygwin_noncygwin_dll_entry AT 12 -s dllwrap: no export definition file provided dllwrap: creating one, but that may not be what you want /usr/lib/libcygwin.a(dll_entry.o)(.text+0xfa):dll_entry.cc: undefined reference to `_cygwin_dll_entry AT 12' collect2: ld returned 1 exit status dllwrap: gcc exited with status 1 make: *** [hello.dll] Error 1 $ Hope you can help me with this. My jni_md.h file is: #ifndef _JAVASOFT_JNI_MD_H_ #define _JAVASOFT_JNI_MD_H_ #define JNIEXPORT __declspec(dllexport) #define JNIIMPORT __declspec(dllimport) #define JNICALL __stdcall typedef long jint; #ifdef __GNUC__ typedef long long jlong; #else typedef __int64 jlong; #endif typedef signed char jbyte; #endif /* !_JAVASOFT_JNI_MD_H_ */ Previously I tried to follow the instructions in the Cygwin documentation, however it appears that these instructions may have been written before dllwrap was created, and in any case I was not able to create a dll according to the instructions. Thanks Andrew Harris -- Want to unsubscribe from this list? Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |